-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prototype on-tagging-for-release workflow
- Loading branch information
1 parent
8793a79
commit 5bcc271
Showing
3 changed files
with
62 additions
and
24 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
name: Create Release from Tag | ||
|
||
on: | ||
push: | ||
tags: | ||
- 'v*' | ||
|
||
# Allows you to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
|
||
jobs: | ||
create-release: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Create Release | ||
id: create_release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
tag_name: ${{ github.ref }} | ||
release_name: Release ${{ github.ref }} | ||
draft: false | ||
prerelease: false | ||
body: | | ||
Tagged release ${{ github.ref }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,20 @@ | ||
#!/bin/bash | ||
tar -zxf ./output/package.tgz -C ./output | ||
node updatePackage.js | ||
cp ./output/*-2.json ./output/package/ # Copy over original json+eml | ||
node localizeLibraryPaths.js ./output/package/*-2.json | ||
echo "registry=https://npm.pkg.github.com/chronic-care" >> ./output/package/.npmrc | ||
cd ./output/package | ||
npm publish | ||
|
||
packageVersion=false | ||
|
||
while [ "$#" -gt 0 ]; do | ||
case $1 in | ||
--release-version) packageVersion="$2" ;; | ||
esac | ||
shift | ||
done | ||
|
||
echo Package Version: $packageVersion | ||
|
||
#tar -zxf ./output/package.tgz -C ./output | ||
#node updatePackage.js | ||
#cp ./output/*-2.json ./output/package/ # Copy over original json+eml | ||
#node localizeLibraryPaths.js ./output/package/*-2.json | ||
#echo "registry=https://npm.pkg.github.com/chronic-care" >> ./output/package/.npmrc | ||
#cd ./output/package | ||
#npm publish |