-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: remote git repo fix to have push permission
- Loading branch information
1 parent
797cbaf
commit 1004e78
Showing
1 changed file
with
3 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -72,9 +72,6 @@ async function run() { | |
// Setting up Git | ||
await runInWorkspace('git', ['config', 'user.name', `"${process.env.GITHUB_USER || 'Dart Conventional Release'}"`]) | ||
await runInWorkspace('git', ['config', 'user.email', `"${process.env.GITHUB_EMAIL || '[email protected]'}"`]) | ||
const remoteGitRepoUrl = `https://${githubToken}:[email protected]/${process.env.GITHUB_REPOSITORY}.git` | ||
await runInWorkspace('git', ['remote', 'set-url', 'origin', remoteGitRepoUrl]) | ||
|
||
|
||
// Committing changes | ||
await runInWorkspace('git', ['add', 'pubspec.yaml']) | ||
|
@@ -84,8 +81,9 @@ async function run() { | |
await runInWorkspace('git', ['tag', tag]) | ||
|
||
// Pushing changes | ||
await runInWorkspace('git', ['push', 'origin']) | ||
await runInWorkspace('git', ['push', 'origin', '--tags']) | ||
const remoteGitRepoUrl = `https://${githubToken}:[email protected]/${process.env.GITHUB_REPOSITORY}.git` | ||
await runInWorkspace('git', ['push', remoteGitRepoUrl]) | ||
await runInWorkspace('git', ['push', remoteGitRepoUrl, '--tags']) | ||
await uploadDartProject() | ||
} catch (error) { | ||
core.setFailed(`Action failed with error: ${error}`) | ||
|