馃殌 v1.0.0 - Initial Release #2
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: Build Worklfow | |
on: | |
release: | |
types: [published] | |
permissions: | |
contents: write | |
jobs: | |
publish: | |
name: "Build & Publish" | |
runs-on: ubuntu-latest | |
environment: build | |
steps: | |
- id: checkout | |
uses: actions/checkout@v3 | |
- name: Create Alfred Workflow | |
id: create_alfred_workflow | |
env: | |
VERSION: ${{ github.event.release.tag_name }} | |
run: | | |
set -e | |
# Alfred adds the version number to the workflow name, so we need to remove the "v" prefix | |
# Zip up the workflow | |
version_without_v=$(echo "${VERSION}" | sed 's/^v//') | |
sed -i "s/1.3.37/${version_without_v}/g" "info.plist" | |
mkdir -p build | |
find . -not -path '*/.git*' -exec zip --symlinks "build/alfred-granted-${VERSION}.alfredworkflow" {} + | |
echo "artifactPath=build/alfred-granted-${VERSION}.alfredworkflow" >> $GITHUB_ENV | |
- uses: diamondburned/action-upload-release@main | |
with: | |
files: ${{ env.artifactPath }} |