Skip to content

Commit

Permalink
test: update docs workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
btlghrants committed Dec 2, 2023
1 parent dc9abb6 commit b512312
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 11 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,5 +43,7 @@ jobs:

- name: Run a multi-line script
run: |
echo "${{ steps.get_current_pepr_release_version.outputs.release }}"
./docs/build.sh ./docs ./core
./docs/build.sh \
./docs \
./core \
"${{ steps.get_current_pepr_release_version.outputs.release }}" \
25 changes: 16 additions & 9 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,26 @@ me="$(basename ${BASH_SOURCE[0]})"
function help() {
cat <<- EOH
$me <docs repo> <core repo>
$me <docs dir> <core dir> <current release>
Example:
./$me ./docs ./core v0.18.0
EOH
}

docs_repo="$1" ; shift 1
if [ -z "$docs_repo" ] ; then help ; echo "Required: <docs repo>"$'\n' ; exit 1 ; fi
docs_repo=$( realpath "$docs_repo" )
docs_dir="$1" ; shift 1
if [ -z "$docs_dir" ] ; then help ; echo "Required: <docs dir>"$'\n' ; exit 1 ; fi
docs_dir=$( realpath "$docs_dir" )

core_dir="$1" ; shift 1
if [ -z "$core_dir" ] ; then help ; echo "Required: <core dir>"$'\n' ; exit 1 ; fi
core_dir=$( realpath "$core_dir" )

core_repo="$1" ; shift 1
if [ -z "$core_repo" ] ; then help ; echo "Required: <core repo>"$'\n' ; exit 1 ; fi
core_repo=$( realpath "$core_repo" )
curr_rel="$1" ; shift 1
if [ -z "$curr_rel" ] ; then help ; echo "Required: <current release>"$'\n' ; exit 1 ; fi


echo " Docs repo path: \"$docs_repo\""
echo " Core repo path: \"$core_repo\""
echo " Docs repo path: \"$docs_dir\""
echo " Core repo path: \"$core_dir\""
echo " Core release: \"$curr_rel\""

0 comments on commit b512312

Please sign in to comment.