Merge pull request #7187 from simonstamm/patch-1

Change hardcoded master to $defaultBranch
This commit is contained in:
Fredrik Adelöw
2021-09-16 11:18:19 +02:00
committed by GitHub
3 changed files with 7 additions and 1 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-scaffolder-backend': patch
---
Change hardcoded branch `master` to $defaultBranch in GitLab provider
+1
View File
@@ -97,6 +97,7 @@ GraphQL
graphviz
Hackathons
haproxy
hardcoded
Helidon
Heroku
hoc
@@ -127,7 +127,7 @@ export function createPublishGitlabAction(options: {
});
const remoteUrl = (http_url_to_repo as string).replace(/\.git$/, '');
const repoContentsUrl = `${remoteUrl}/-/blob/master`;
const repoContentsUrl = `${remoteUrl}/-/blob/${defaultBranch}`;
const gitAuthorInfo = {
name: config.getOptionalString('scaffolder.defaultAuthor.name'),