File tree Expand file tree Collapse file tree 4 files changed +17
-17
lines changed Expand file tree Collapse file tree 4 files changed +17
-17
lines changed Original file line number Diff line number Diff line change 4
4
test :
5
5
required : false
6
6
type : boolean
7
- secrets : inherit
8
7
jobs :
9
8
images :
10
9
runs-on : ubuntu-latest
Original file line number Diff line number Diff line change 5
5
bump :
6
6
type : choice
7
7
required : true
8
- description : Bump version number
8
+ description : Bump version number
9
9
options : [major, minor, patch]
10
10
default : patch
11
11
pull_request :
@@ -21,14 +21,17 @@ jobs:
21
21
git config --global user.email 64868532+iterative-olivaw@users.noreply.github.com
22
22
git checkout -b bump/$(npm version ${{ github.event.inputs.bump }})
23
23
git push --set-upstream origin --follow-tags HEAD
24
- gh pr create --title "Bump version to $(git describe --tags)" --fill
24
+ gh pr create --title "Bump version to $(git describe --tags)" --body "Approve me 🤖"
25
+ gh pr merge --squash --auto
25
26
env:
26
- GITHUB_TOKEN: ${{ github.token }}
27
+ GITHUB_TOKEN: ${{ secrets.ADMIN_GITHUB_TOKEN }}
27
28
release :
28
29
if : github.event.pull_request.merged && startsWith(github.head_ref, 'bump/')
29
30
runs-on : ubuntu-latest
30
31
steps :
31
32
- uses : actions/checkout@v2
32
- - run : gh release create --generate-notes --draft {--target=,--title=CML\ ,}$(basename ${{ github.head_ref }})
33
+ - run :
34
+ gh release create --generate-notes {--title=CML\ ,}$(basename ${{
35
+ github.head_ref }})
33
36
env :
34
- GITHUB_TOKEN : ${{ github.token }}
37
+ GITHUB_TOKEN : ${{ secrets.ADMIN_GITHUB_TOKEN }}
Original file line number Diff line number Diff line change @@ -2,8 +2,8 @@ name: Test & Deploy
2
2
on :
3
3
schedule :
4
4
- cron : ' 0 8 * * 1' # M H d m w (Mondays at 8:00)
5
- push :
6
- tags : ['v*' ]
5
+ release :
6
+ types : [created ]
7
7
pull_request_target :
8
8
workflow_dispatch :
9
9
jobs :
48
48
- run : |
49
49
pip install tensorboard
50
50
pip install -I protobuf==3.20.1
51
- - run : npm ci
51
+ - run : npm ci && npm install --global
52
52
- run : npm run test
53
53
env :
54
54
GITHUB_TOKEN : ${{ github.token }}
99
99
registry-url : https://registry.npmjs.org
100
100
- run : npm install
101
101
- run :
102
- npm ${{ github.event_name == 'push ' && 'publish' || 'publish
102
+ npm ${{ github.event_name == 'release ' && 'publish' || 'publish
103
103
--dry-run' }}
104
104
env :
105
105
NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
@@ -121,11 +121,8 @@ jobs:
121
121
cp build/cml-linux{-x64,}
122
122
cp build/cml-macos{-x64,}
123
123
- uses : softprops/action-gh-release@v1
124
- if : github.event_name == 'push '
124
+ if : github.event_name == 'release '
125
125
with :
126
- name : CML ${{ steps.build.outputs.tag }}
127
- draft : true
128
- generate_release_notes : true
129
126
files : |
130
127
build/cml-alpine-arm64
131
128
build/cml-alpine-x64
@@ -143,4 +140,5 @@ jobs:
143
140
GITHUB_TOKEN : ${{ secrets.TEST_GITHUB_TOKEN }}
144
141
images :
145
142
needs : packages
146
- uses : .github/workflows/images.yml
143
+ secrets : inherit
144
+ uses : ./.github/workflows/images.yml
Original file line number Diff line number Diff line change @@ -8,8 +8,8 @@ const commands = Object.keys(bin)
8
8
describe ( 'command-line interface tests' , ( ) => {
9
9
for ( const command of commands )
10
10
test ( `legacy cml-${ command } behaves as the new cml ${ command } ` , async ( ) => {
11
- const legacyOutput = await exec ( `npx --package=. cml-${ command } --help` ) ;
12
- const newOutput = await exec ( `npx --package=. cml ${ command } --help` ) ;
11
+ const legacyOutput = await exec ( `cml-${ command } --help` ) ;
12
+ const newOutput = await exec ( `cml ${ command } --help` ) ;
13
13
expect ( legacyOutput ) . toBe ( newOutput ) ;
14
14
} ) ;
15
15
} ) ;
You can’t perform that action at this time.
0 commit comments