Skip to content

Commit

Permalink
Updated actions
Browse files Browse the repository at this point in the history
  • Loading branch information
gautamkrishnar committed Aug 11, 2020
1 parent 4eb7ee1 commit f595a4c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
name: Build and test
on: [push, pull_request]
jobs:
version-bump:
test:
if: "! contains(toJSON(github.event.commits.*.message), '[skip-ci]')"
name: Generate build and test
runs-on: ubuntu-latest
steps:
Expand Down
9 changes: 6 additions & 3 deletions .github/workflows/version-bump.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
name: Update dist

name: Version bump
on:
workflow_dispatch:
inputs:
tag_name:
description: 'Version'
required: true
jobs:
version-bump:
name: Update dist
Expand All @@ -12,4 +15,4 @@ jobs:
with:
node-version: "12"
- run: yarn install
- run: yarn build && yarn run test-dist && git clone https://${{secrets.GH_TOKEN}}@github.com/gautamkrishnar/blog-post-workflow.git publish-repo > /dev/null 2>&1 && cd publish-repo && cp -fv ../dist/blog-post-workflow.js ./dist/blog-post-workflow.js && git config --global user.email "[email protected]" && git config --global user.name "gkr-bot" && git add ./dist/blog-post-workflow.js && git commit -m "[skip ci] Updated dist" && git push --quiet
- run: yarn build && yarn run test-dist && git clone https://${{secrets.GH_TOKEN}}@github.com/gautamkrishnar/blog-post-workflow.git publish-repo > /dev/null 2>&1 && cd publish-repo && yarn version --new-version ${{ github.event.inputs.tag_name }} --no-git-tag-version && cp -fv ../dist/blog-post-workflow.js ./dist/blog-post-workflow.js && git config --global user.email "[email protected]" && git config --global user.name "gkr-bot" && git add ./dist/blog-post-workflow.js ./package.json && git commit -m "[skip ci] Published ${{ github.event.inputs.tag_name }}" && git push --quiet

0 comments on commit f595a4c

Please sign in to comment.