Release #11
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: | |
# Manual trigger. | |
workflow_dispatch: | |
jobs: | |
release: | |
if: startsWith(github.ref, 'refs/tags/v') | |
runs-on: ubuntu-latest | |
permissions: | |
# This is broad, but unfortunately it is required for creating | |
# releases. | |
contents: write | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: bazelbuild/setup-bazelisk@v2 | |
- name: Check Manifest | |
run: | | |
MANIFEST_VERSION=$(cat manifest.json | python3 -c "import sys, json; print(json.load(sys.stdin)['version'])") | |
TAG_VERSION=${{ github.ref_name }} | |
test "v${MANIFEST_VERSION}" = "${TAG_VERSION}" | |
- run: bazel build ... | |
- run: bazel test --test_output=errors ... | |
- name: Create Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
generate_release_notes: true | |
fail_on_unmatched_files: true | |
# bazel-bin symlink may not exist | |
files: | | |
bazel-out/k8-fastbuild/bin/chrome-ssh-agent.zip | |
- name: Publish to Webstore | |
uses: mnao305/[email protected] | |
with: | |
file-path: bazel-out/k8-fastbuild/bin/chrome-ssh-agent.zip | |
extension-id: eechpbnaifiimgajnomdipfaamobdfha | |
client-id: ${{ secrets.WEBSTORE_CLIENT_ID }} | |
client-secret: ${{ secrets.WEBSTORE_CLIENT_SECRET }} | |
refresh-token: ${{ secrets.WEBSTORE_REFRESH_TOKEN }} |