File tree Expand file tree Collapse file tree 2 files changed +15
-9
lines changed Expand file tree Collapse file tree 2 files changed +15
-9
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @parfuemerie-douglas/scaffolder-backend-module-azure-pipelines" ,
3
- "version" : " 0.4.2-next.0 " ,
3
+ "version" : " 0.4.2" ,
4
4
"description" : " A collection of Backstage scaffolder backend modules for Azure pipelines." ,
5
5
"main" : " dist/index.cjs.js" ,
6
6
"types" : " dist/index.d.ts" ,
39
39
},
40
40
"homepage" : " https://github.com/Parfuemerie-Douglas/scaffolder-backend-module-azure-pipelines#readme" ,
41
41
"dependencies" : {
42
- "@backstage/backend-common" : " ^0.15.2-next.0 " ,
43
- "@backstage/errors" : " ^1.1.2-next.0 " ,
44
- "@backstage/integration" : " ^1.3.2-next.0 " ,
45
- "@backstage/plugin-scaffolder-backend" : " ^1.7.0-next .0" ,
42
+ "@backstage/backend-common" : " ^0.15.1 " ,
43
+ "@backstage/errors" : " ^1.1.1 " ,
44
+ "@backstage/integration" : " ^1.3.1 " ,
45
+ "@backstage/plugin-scaffolder-backend" : " ^1.6 .0" ,
46
46
"@backstage/types" : " ^1.0.0" ,
47
47
"@types/node-fetch" : " ^2.6.2" ,
48
48
"node-fetch" : " 2"
49
49
},
50
50
"devDependencies" : {
51
- "@backstage/cli" : " ^0.20.0-next .0"
51
+ "@backstage/cli" : " ^0.19 .0"
52
52
},
53
53
"files" : [
54
54
" dist"
Original file line number Diff line number Diff line change @@ -29,6 +29,7 @@ export const runAzurePipelineAction = (options: {
29
29
organization : string ;
30
30
pipelineId : string ;
31
31
project : string ;
32
+ branch ?: string ;
32
33
token ?: string ;
33
34
} > ( {
34
35
id : "azure:pipeline:run" ,
@@ -52,16 +53,21 @@ export const runAzurePipelineAction = (options: {
52
53
title : "Project" ,
53
54
description : "The name of the Azure project." ,
54
55
} ,
56
+ branch : {
57
+ title : "Repository Branch" ,
58
+ type : "string" ,
59
+ description : "The branch of the pipeline's repository." ,
60
+ } ,
55
61
token : {
56
- title : "Authenticatino Token" ,
62
+ title : "Authentication Token" ,
57
63
type : "string" ,
58
64
description : "The token to use for authorization." ,
59
65
} ,
60
66
} ,
61
67
} ,
62
68
} ,
63
69
async handler ( ctx ) {
64
- const { organization, pipelineId, project } = ctx . input ;
70
+ const { organization, pipelineId, project, branch } = ctx . input ;
65
71
66
72
const host = "dev.azure.com" ;
67
73
const integrationConfig = integrations . azure . byHost ( host ) ;
@@ -98,7 +104,7 @@ export const runAzurePipelineAction = (options: {
98
104
resources : {
99
105
repositories : {
100
106
self : {
101
- refName : " refs/heads/master" ,
107
+ refName : ` refs/heads/${ branch ?? "main" } ` ,
102
108
} ,
103
109
} ,
104
110
} ,
You can’t perform that action at this time.
0 commit comments