Skip to content

Commit

Permalink
Build Elixir main docs with ExDoc main (#12736)
Browse files Browse the repository at this point in the history
  • Loading branch information
wojtekmach authored Jun 30, 2023
1 parent 99785cc commit 2c78c73
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions .github/workflows/release_pre_built/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,17 +36,21 @@ runs:
mv lib/elixir/scripts/windows_installer/tmp/elixir-otp-${{ inputs.otp }}.exe .
shasum -a 1 elixir-otp-${{ inputs.otp }}.exe > elixir-otp-${{ inputs.otp }}.exe.sha1sum
shasum -a 256 elixir-otp-${{ inputs.otp }}.exe > elixir-otp-${{ inputs.otp }}.exe.sha256sum
- name: Get latest stable ExDoc version
if: ${{ inputs.build_docs }}
- name: Get ExDoc ref
if: ${{ inputs.build_docs && github.ref_name != "main" }}
shell: bash
run: |
EX_DOC_LATEST_STABLE_VERSION=$(curl -s https://hex.pm/api/packages/ex_doc | jq --raw-output '.latest_stable_version')
echo "EX_DOC_LATEST_STABLE_VERSION=${EX_DOC_LATEST_STABLE_VERSION}" >> $GITHUB_ENV
if [ "${{ github.ref_name }}" = "main" ]; then
ref=main
else
ref=v$(curl -s https://hex.pm/api/packages/ex_doc | jq --raw-output '.latest_stable_version')
fi
echo "EX_DOC_REF=$ref" >> $GITHUB_ENV
- uses: actions/checkout@v3
if: ${{ inputs.build_docs }}
with:
repository: elixir-lang/ex_doc
ref: v${{ env.EX_DOC_LATEST_STABLE_VERSION }}
ref: ${{ env.EX_DOC_REF }}
path: ex_doc
- name: Build ex_doc
if: ${{ inputs.build_docs }}
Expand Down

0 comments on commit 2c78c73

Please sign in to comment.