Skip to content

build(deps): bump actions/checkout from 3.5.2 to 3.6.0 #63

build(deps): bump actions/checkout from 3.5.2 to 3.6.0

build(deps): bump actions/checkout from 3.5.2 to 3.6.0 #63

Workflow file for this run

name: Release
on:
pull_request:
paths:
- .github/actions/package/*
- .github/workflows/release.yml
- justfile
push:
tags:
- 'release/*'
permissions:
contents: write
env:
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
CHECKSEC_VERSION: 2.5.0
RUSTFLAGS: "-D warnings -A deprecated"
RUSTUP_MAX_RETRIES: 10
jobs:
meta:
timeout-minutes: 5
runs-on: ubuntu-latest
steps:
- id: meta
shell: bash
run: |
shopt -s extglob
ref="${{ github.ref }}"
if [[ "$ref" == refs/tags/release/* ]]; then
ver="${ref##refs/tags/release/}"
if [[ "$ver" != v+([0-9]).+([0-9]).+([0-9])?(-+([a-z0-9-])) ]]; then
echo "Invalid version: $ver" >&2
exit 1
fi
echo ::set-output name=publish::true
echo ::set-output name=version::"$ver"
else
sha="${{ github.sha }}"
echo ::set-output name=version::"test-${sha:0:7}"
fi
outputs:
publish: ${{ steps.meta.outputs.publish }}
version: ${{ steps.meta.outputs.version }}
package:
needs: [meta]
strategy:
matrix:
arch: [amd64, arm64, arm]
name: Package (${{ matrix.arch }})
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744
- name: package
uses: ./.github/actions/package
with:
entrypoint: just
args: release
env:
CARGO: cross
CARGO_RELEASE: "1"
CROSS_DOCKER_IN_DOCKER: true
PACKAGE_VERSION: ${{ needs.meta.outputs.version }}
ARCH: ${{ matrix.arch }}
- uses: actions/upload-artifact@v3
with:
name: ${{ matrix.arch }}-artifacts
path: release/*
publish:
needs: [meta, package]
name: GitHub Release
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744
- uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a
with:
path: artifacts
- run: find artifacts -type f -ls
- if: needs.meta.outputs.publish == 'true'
uses: softprops/action-gh-release@de2c0eb89ae2a093876385947365aca7b0e5f844
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
name: ${{ needs.meta.outputs.version }}
files: artifacts/**/*
generate_release_notes: true