Skip to content
This repository has been archived by the owner on Jun 10, 2024. It is now read-only.

Merge pull request #176 from luckman212/2023-bash-scripts-update #71

Merge pull request #176 from luckman212/2023-bash-scripts-update

Merge pull request #176 from luckman212/2023-bash-scripts-update #71

Workflow file for this run

name: Release
on:
push:
tags:
- '**'
branches-ignore:
- '**'
jobs:
build-release:
runs-on: macos-12
steps:
# Not needed since it's a public repo
# - name: Granting private modules access
# run: |
# git config --global url."https://${{ secrets.GO_MODULES_TOKEN }}:x-oauth-basic@github.com/blacs30".insteadOf "https://github.com/blacs30"
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: ~1.18
- name: Check out code
uses: actions/checkout@v3
- name: Unshallow
run: git fetch --prune --unshallow
- name: "Validates GO releaser config"
uses: goreleaser/goreleaser-action@v2
with:
args: check
- name: Build Alfred workflow
run: |
make build
- name: Create universal binary
run: |
make universal-binary
- name: Upload artifacts
uses: actions/upload-artifact@v2
with:
name: universal-binary
path: workflow/bitwarden-alfred-workflow
release:
needs: build-release
runs-on: ubuntu-20.04
steps:
# Not needed since it's a public repo
# - name: Granting private modules access
# run: |
# git config --global url."https://${{ secrets.GO_MODULES_TOKEN }}:x-oauth-basic@github.com/blacs30".insteadOf "https://github.com/blacs30"
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: ~1.18
- name: Check out code
uses: actions/checkout@v3
- name: Dowload artifacts
uses: actions/download-artifact@v2
with:
name: universal-binary
path: download
- run: |
test -f download/bitwarden-alfred-workflow && cp download/bitwarden-alfred-workflow workflow/bitwarden-alfred-workflow
chmod +x workflow/bitwarden-alfred-workflow
rm -rf download
- name: Copy run dependencies
run: |
make copy-build-assets
- name: Package Alfred workflow
run: |
make package-alfred
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}