diff --git a/.github/workflows/deploy-preview.yml b/.github/workflows/deploy-preview.yml index a178fd0..d815529 100644 --- a/.github/workflows/deploy-preview.yml +++ b/.github/workflows/deploy-preview.yml @@ -9,6 +9,7 @@ on: jobs: deploy: + if: github.repository == 'loreddev/marknow' uses: loreddev/.github/.github/workflows/vercel-deploy.yml@main secrets: inherit with: diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 2016778..dcc2d47 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -1,12 +1,16 @@ name: โ–ฒ Deploy to Vercel on: - push: + workflow_run: + workflows: [๐Ÿงช Code checking, ๐ŸŽ‰ Release] + types: + - completed branches: - main jobs: deploy: + if: ${{ github.event.workflow_run.conclusion == 'success' && github.repository == 'loreddev/marknow' }} uses: loreddev/.github/.github/workflows/vercel-deploy.yml@main secrets: inherit with: diff --git a/.github/workflows/mirror.yml b/.github/workflows/mirror.yml index 6f05690..40405e0 100644 --- a/.github/workflows/mirror.yml +++ b/.github/workflows/mirror.yml @@ -8,6 +8,7 @@ on: jobs: mirror: + if: github.repository == 'loreddev/marknow' uses: loreddev/.github/.github/workflows/mirrors.yml@main secrets: inherit with: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1bd04e5..42f6706 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,7 +1,10 @@ name: ๐ŸŽ‰ Release on: - push: + workflow_run: + workflows: [๐Ÿงช Code checking] + types: + - completed branches: - main @@ -9,11 +12,13 @@ concurrency: ${{ github.workflow }}-${{ github.ref }} jobs: release: - if: github.repository == 'loreddev/marknow' + if: ${{ github.event.workflow_run.conclusion == 'success' && github.repository == 'loreddev/marknow' }} permissions: contents: write pull-requests: write name: Release + env: + HUSKY_SKIP_HOOKS: true runs-on: ubuntu-latest steps: - name: Checkout @@ -28,6 +33,8 @@ jobs: uses: changesets/action@v1 with: publish: pnpm release + commit: 'chore: ๐Ÿ”—๐Ÿฆ‹ version packages' + title: '๐Ÿฆ‹ Changeset: Version packages' env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }}