v got #9
Workflow file for this run
This file contains 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 Tag | |
permissions: | |
contents: write | |
on: | |
push: | |
tags: | |
- 'v*' # Match tags starting with 'v' | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out the code | |
uses: actions/checkout@v2 | |
- name: Make create_deb.sh executable | |
run: chmod +x create_deb.sh | |
- name: Set up package_version from Git tag | |
id: package_version | |
run: echo "::set-output name=package_version::${{ github.ref }}" | sed 's/refs\/tags\/v//' | |
- name: Run create_deb.sh script with environment variables | |
run: | | |
PACKAGE_NAME="aws-sam-cli" | |
PACKAGE_VERSION="${{ steps.package_version.outputs.package_version }}" | |
PACKAGE_DESCRIPTION="AWS SAM CLI" | |
MAINTAINER="${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>" | |
SAM_CLI_ZIP_URL="https://github.com/aws/aws-sam-cli/releases/download/v${{ steps.package_version.outputs.package_version }}/aws-sam-cli-linux-x86_64.zip" | |
export PACKAGE_NAME PACKAGE_VERSION PACKAGE_DESCRIPTION MAINTAINER SAM_CLI_ZIP_URL | |
./create_deb.sh | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Create and upload release | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: | | |
aws-sam-cli-*.deb | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |