File tree Expand file tree Collapse file tree 3 files changed +25
-7
lines changed Expand file tree Collapse file tree 3 files changed +25
-7
lines changed Original file line number Diff line number Diff line change @@ -3,12 +3,19 @@ name: version, tag and github release
3
3
4
4
on :
5
5
push :
6
- branches : [main]
6
+ branches :
7
+ - main
8
+ # point at specific branches, or a naming convention via wildcard
9
+ - prerelease
10
+ tags-ignore :
11
+ - ' *'
7
12
8
13
jobs :
9
14
release :
10
15
uses : salesforcecli/github-workflows/.github/workflows/githubRelease.yml@main
11
16
secrets : inherit
17
+ with :
18
+ prerelease : ${{ github.ref_name != 'main' }}
12
19
13
20
# most repos won't use this
14
21
# depends on previous job to avoid git collisions, not for any functionality reason
Original file line number Diff line number Diff line change @@ -2,20 +2,31 @@ name: publish
2
2
3
3
on :
4
4
release :
5
- types : [released]
6
- # support manual release in case something goes wrong and needs to be repeated or tested
5
+ types : [published]
7
6
workflow_dispatch :
8
7
inputs :
9
8
tag :
10
9
description : tag that needs to publish
11
10
type : string
12
11
required : true
12
+
13
13
jobs :
14
+ # parses the package.json version and detects prerelease tag (ex: beta from 4.4.4-beta.0)
15
+ getDistTag :
16
+ outputs :
17
+ tag : ${{ steps.distTag.outputs.tag }}
18
+ runs-on : ubuntu-latest
19
+ steps :
20
+ - uses : actions/checkout@v3
21
+ with :
22
+ ref : ${{ github.event.release.tag_name || inputs.tag }}
23
+ - uses : salesforcecli/github-workflows/.github/actions/getPreReleaseTag@main
24
+ id : distTag
25
+
14
26
npm :
15
27
uses : salesforcecli/github-workflows/.github/workflows/npmPublish.yml@main
28
+ needs : [getDistTag]
16
29
with :
17
- ctc : true
18
- sign : true
19
- tag : latest
30
+ tag : ${{ needs.getDistTag.outputs.tag || 'latest' }}
20
31
githubTag : ${{ github.event.release.tag_name || inputs.tag }}
21
32
secrets : inherit
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @salesforce/plugin-devops-center" ,
3
3
"description" : " The DevOps Center CLI plugin provides a command-line alternative to performing equivalent actions in the DevOps Center graphical UI" ,
4
- "version" : " 0.0.1 " ,
4
+ "version" : " 0.1.0-beta.0 " ,
5
5
"author" : " Salesforce" ,
6
6
"bugs" : " https://github.com/forcedotcom/cli/issues" ,
7
7
"dependencies" : {
You can’t perform that action at this time.
0 commit comments