Skip to content

Commit

Permalink
refactor(CI): enable strict branch rules for code review (#1269)
Browse files Browse the repository at this point in the history
  • Loading branch information
stipsan authored May 2, 2024
1 parent f18110f commit d4e16f1
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
2 changes: 2 additions & 0 deletions .github/renovate.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,11 @@
"github>sanity-io/renovate-config:studio-v3",
":reviewer(team:ecosystem)"
],
"ignorePresets": ["github>sanity-io/renovate-config:group-non-major"],
"packageRules": [
{
"matchDepTypes": ["dependencies"],
"semanticCommitType": "fix",
"rangeStrategy": "bump"
}
]
Expand Down
14 changes: 10 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,19 +51,25 @@ jobs:
release:
permissions:
contents: write # to be able to publish a GitHub release
issues: write # to be able to comment on released issues
pull-requests: write # to be able to comment on released pull requests
id-token: write # to enable use of OIDC for npm provenance
name: 'Semantic release'
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ secrets.ECOSPARK_APP_ID }}
private-key: ${{ secrets.ECOSPARK_APP_PRIVATE_KEY }}
- uses: actions/checkout@v4
with:
# Need to fetch entire commit history to
# analyze every commit since last release
fetch-depth: 0
# Uses generated token to allow pushing commits back
token: ${{ steps.app-token.outputs.token }}
# Make sure the value of GITHUB_TOKEN will not be persisted in repo's config
persist-credentials: false
- uses: actions/setup-node@v4
with:
node-version: lts/*
Expand All @@ -73,5 +79,5 @@ jobs:
- run: pnpm exec semantic-release
env:
NPM_CONFIG_PROVENANCE: true
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
NPM_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}

0 comments on commit d4e16f1

Please sign in to comment.