make shellcheck happy #3
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: CI | |
on: push | |
jobs: | |
shellcheck: | |
name: ShellCheck | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Run ShellCheck | |
uses: ludeeus/action-shellcheck@master | |
release: | |
name: Release | |
runs-on: ubuntu-latest | |
needs: | |
- shellcheck | |
if: startsWith(github.ref, 'refs/tags/v') | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: softprops/action-gh-release@v1 | |
with: | |
files: ./assume-aws-sso-role | |
formula: | |
name: Update homebrew formula | |
runs-on: ubuntu-latest | |
needs: | |
- release | |
if: startsWith(github.ref, 'refs/tags/v') | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Update homebrew formula | |
run: | | |
# Update formula to latest release | |
./.github/scripts/update-formula.sh | |
# Configure git | |
git config --global user.name assume-aws-sso-role | |
git config --global user.email [email protected] | |
git remote set-url origin "https://${GITHUB_ACTOR}:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}" | |
# Commit and push changes | |
git add assume-aws-sso-role.rb | |
git commit --message "Update homebrew formula" | |
git push origin HEAD:main | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |