Bump DavidAnson/markdownlint-cli2-action from 16.0.0 to 17.0.0 (#13830) #40
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
push: | |
branches: | |
- main | |
- v*.* | |
tags: | |
- v* | |
env: | |
ELIXIR_OPTS: "--warnings-as-errors" | |
ERLC_OPTS: "warnings_as_errors" | |
LANG: C.UTF-8 | |
permissions: | |
contents: write | |
id-token: write | |
attestations: write | |
jobs: | |
create_draft_release: | |
runs-on: ubuntu-22.04 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
steps: | |
- name: Create draft release | |
if: github.ref_type != 'branch' | |
run: | | |
gh release create \ | |
--repo ${{ github.repository }} \ | |
--title ${{ github.ref_name }} \ | |
--notes '' \ | |
--draft \ | |
${{ github.ref_name }} | |
- uses: actions/checkout@v4 | |
if: github.ref_type == 'branch' | |
with: | |
fetch-depth: 50 | |
- name: Update ${{ github.ref_name }}-latest | |
if: github.ref_type == 'branch' | |
run: | | |
ref_name=${{ github.ref_name }}-latest | |
git tag $ref_name --force | |
git push origin $ref_name --force | |
gh release create \ | |
$ref_name \ | |
—-latest=false \ | |
--title $ref_name \ | |
--notes "Automated release for latest ${{ github.ref_name }}." \ | |
|| true | |
release_pre_built: | |
needs: create_draft_release | |
strategy: | |
fail-fast: true | |
matrix: | |
include: | |
- otp: 25 | |
otp_version: "25.3" | |
- otp: 26 | |
otp_version: "26.0" | |
- otp: 27 | |
otp_version: "27.0" | |
build_docs: build_docs | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 50 | |
- uses: ./.github/workflows/release_pre_built | |
with: | |
otp_version: ${{ matrix.otp_version }} | |
otp: ${{ matrix.otp }} | |
build_docs: ${{ matrix.build_docs }} | |
- uses: actions/attest-build-provenance@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
subject-path: 'elixir-otp-${{ matrix.otp }}.*' | |
- uses: actions/attest-build-provenance@v1 | |
if: ${{ matrix.build_docs }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
subject-path: 'Docs.*' | |
- name: "Sign files with Trusted Signing" | |
if: github.repository == 'elixir-lang/elixir' | |
uses: azure/[email protected] | |
with: | |
azure-tenant-id: ${{ secrets.AZURE_TENANT_ID }} | |
azure-client-id: ${{ secrets.AZURE_CLIENT_ID }} | |
azure-client-secret: ${{ secrets.AZURE_CLIENT_SECRET }} | |
endpoint: https://eus.codesigning.azure.net/ | |
trusted-signing-account-name: trusted-signing-elixir | |
certificate-profile-name: Elixir | |
files-folder: ${{ github.workspace }} | |
files-folder-filter: exe | |
file-digest: SHA256 | |
timestamp-rfc3161: http://timestamp.acs.microsoft.com | |
timestamp-digest: SHA256 | |
- name: Upload Pre-built | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
if [ "${{ github.ref_type }}" == "branch" ]; then | |
tag=${{ github.ref_name }}-latest | |
else | |
tag="${{ github.ref_name }}" | |
fi | |
gh release upload --clobber "$tag" \ | |
elixir-otp-${{ matrix.otp }}.zip \ | |
elixir-otp-${{ matrix.otp }}.zip.sha{1,256}sum \ | |
elixir-otp-${{ matrix.otp }}.exe \ | |
elixir-otp-${{ matrix.otp }}.exe.sha{1,256}sum | |
if [ "${{ matrix.build_docs }}" == "build_docs" ]; then | |
gh release upload --clobber "$tag" \ | |
Docs.zip \ | |
Docs.zip.sha{1,256}sum | |
fi |