Skip to content

Commit

Permalink
ci(GitHub): Improve workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
ardalanamini committed Jun 19, 2022
1 parent 7a5862f commit 1e770e6
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 6 deletions.
16 changes: 11 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@ jobs:
release:
name: Create Release

concurrency: github-release
concurrency:
group: github-release-${{ github.ref_name }}
cancel-in-progress: true

environment:
name: release
Expand Down Expand Up @@ -40,10 +42,12 @@ jobs:
publish-npm:
name: Publish to NPM

concurrency: npm-release
concurrency:
group: npm-release-${{ github.ref_name }}
cancel-in-progress: true

environment:
name: release
name: npm
url: https://www.npmjs.com/package/kutt

runs-on: ubuntu-latest
Expand All @@ -70,10 +74,12 @@ jobs:
publish-gpr:
name: Publish to GitHub Packages

concurrency: gpr-release
concurrency:
group: gpr-release-${{ github.ref_name }}
cancel-in-progress: true

environment:
name: release
name: gpr
url: https://github.com/${{ github.repository }}/packages

permissions:
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,17 @@ name: Test

on:
schedule:
- cron: "0 0 * * *"
- cron: "0 0 1 * *"
push:
branches:
- master
pull_request:
workflow_call:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}

jobs:
test:
name: Test
Expand All @@ -31,6 +35,7 @@ jobs:
- 15
- 16
- 17
- 18

env:
OS: ${{ matrix.os }}
Expand Down

0 comments on commit 1e770e6

Please sign in to comment.