Skip to content

Commit 2523582

Browse files
committed
build: auth as both in release action
1 parent c45cfda commit 2523582

File tree

2 files changed

+1
-3
lines changed
  • .github/workflows
  • packages/build-utils/src/executors/sync-dependencies

2 files changed

+1
-3
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ jobs:
6565
- uses: actions/checkout@v3
6666
with:
6767
fetch-depth: 0
68+
token: ${{ secrets.DEPLOY_TOKEN }}
6869
- uses: './.github/actions/release'
6970
with:
7071
gh_token: ${{ secrets.DEPLOY_TOKEN }}

packages/build-utils/src/executors/sync-dependencies/executor.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,10 @@ function commitToPrevious(baseBranch: string, remote: string) {
3333
const diffCommand = `git diff HEAD`;
3434
const addCommand = `git add .`;
3535
const commitToPreviousCommand = `git commit --no-edit -m "chore: [skip ci] sync dependencies"`;
36-
// reset the original remote to allow bypass branch protection
37-
const remoteCommand = 'git remote remove origin && git remote add origin https://${GH_TOKEN}@github.com/scalprum/scaffolding.git';
3836
const pushCommand = `git push ${remote} ${baseBranch}`;
3937
// check if there are any changes to be committed
4038
const isDiff = execSync(diffCommand).toString().length > 0;
4139
if (isDiff) {
42-
execSync(remoteCommand);
4340
execSync(addCommand);
4441
execSync(commitToPreviousCommand);
4542
execSync(pushCommand);

0 commit comments

Comments
 (0)