File tree 9 files changed +63
-26
lines changed
9 files changed +63
-26
lines changed Original file line number Diff line number Diff line change
1
+ $timestamp = Get-Date - Format yyyyMMddhhmmss
2
+ $patchVersion = (npm -- no- git- tag version patch)
3
+ $nextVersion = " ${patchVersion} -next.${timestamp} " .Substring(1 )
4
+ echo $nextVersion
5
+
6
+ npm version -- no- git- tag -f $nextVersion
7
+ npm run publish:next
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+ set -ex
3
+
4
+ patchVersion=$( npm --no-git-tag version patch)
5
+ nextVersion=${patchVersion} -next." $( date +%Y%m%d%H%M%S) "
6
+ echo " ${nextVersion: 1} "
7
+
8
+ npm version --no-git-tag -f " ${nextVersion: 1} "
9
+ npm run publish:next
Original file line number Diff line number Diff line change
1
+ npm publish
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+ set -ex
3
+
4
+ npm publish
Original file line number Diff line number Diff line change @@ -36,21 +36,29 @@ install: true
36
36
37
37
script :
38
38
- npm run patch && npm i
39
- - if [[ $TRAVIS_OS_NAME = "windows" ]]; then npm run build:release:win; else npm run build:release; fi
39
+ - npm run build:release
40
40
- cd test
41
41
- npm cit
42
42
- cd window-integration-tests
43
43
- npm cit
44
44
- cd ../..
45
45
46
+ stages :
47
+ - test
48
+ - name : deploy
49
+ if : (branch = develop) OR (tag IS present)
50
+
46
51
before_deploy :
47
52
- echo "//registry.npmjs.org/:_authToken=\${NPM_TOKEN}" >> $HOME/.npmrc 2> /dev/null
48
53
49
54
deploy :
50
55
- provider : script
51
- skip_cleanup : true
52
- script : npm publish --access public
56
+ skip_cleanup : false
57
+ script : bash ./.build/pre-release.sh
58
+ on :
59
+ branch : develop
60
+ - provider : script
61
+ skip_cleanup : false
62
+ script : bash ./.build/release.sh
53
63
on :
54
64
tags : true
55
- node_js : ' 12'
56
-
Original file line number Diff line number Diff line change @@ -22,23 +22,9 @@ npm install
22
22
npm run build:release
23
23
```
24
24
25
- Installation and build on Windows
26
-
27
- ```
28
- npm install
29
- npm run build:release:win
30
- ```
31
-
32
25
### Debug build
33
26
34
27
```
35
28
npm install
36
29
npm run build:debug
37
30
```
38
-
39
- Installation and build on Windows
40
-
41
- ```
42
- npm install
43
- npm run build:debug:win
44
- ```
Original file line number Diff line number Diff line change @@ -5,8 +5,7 @@ image: Visual Studio 2017
5
5
# Test against these versions of Io.js and Node.js.
6
6
environment :
7
7
matrix :
8
- # node.js
9
- - nodejs_version : " 10"
8
+ - nodejs_version : " 12"
10
9
11
10
cache :
12
11
- node_modules
@@ -25,7 +24,7 @@ install:
25
24
- ps : ' "//registry.npmjs.org/:_authToken=$env:npm_auth_token`n" | out-file "$env:userprofile\.npmrc" -Encoding ASCII'
26
25
- npm whoami
27
26
- npm run patch && npm install
28
- - npm run build:release:win
27
+ - npm run build:release
29
28
30
29
test_script :
31
30
# Output useful info for debugging.
@@ -42,5 +41,15 @@ test_script:
42
41
on_success :
43
42
- IF defined APPVEYOR_REPO_TAG_NAME npm publish
44
43
44
+ deploy :
45
+ - provider : script
46
+ path : ./.build/release.ps1
47
+ on :
48
+ APPVEYOR_REPO_TAG : true
49
+ - provider : script
50
+ path : ./.build/pre-release.ps1
51
+ on :
52
+ branch : develop
53
+
45
54
build : off
46
55
version : " {build}"
Original file line number Diff line number Diff line change 7
7
"scripts" : {
8
8
"clean" : " cmake-js clean" ,
9
9
"patch" : " node ./patch-packagename.js" ,
10
- "build:debug" : " cmake-js rebuild --debug" ,
11
- "build:debug:win" : " cmake-js rebuild --debug -G \" Visual Studio 15 2017 Win64\" " ,
12
- "build:release" : " cmake-js rebuild" ,
13
- "build:release:win" : " cmake-js rebuild -G \" Visual Studio 15 2017 Win64\" "
10
+ "build:debug" : " run-script-os" ,
11
+ "build:debug:default" : " cmake-js rebuild --debug" ,
12
+ "build:debug:win32" : " cmake-js rebuild --debug -G \" Visual Studio 15 2017 Win64\" " ,
13
+ "build:release" : " run-script-os" ,
14
+ "build:release:default" : " cmake-js rebuild" ,
15
+ "build:release:win32" : " cmake-js rebuild -G \" Visual Studio 15 2017 Win64\" " ,
16
+ "prepublishOnly" : " npm run build:release" ,
17
+ "publish:next" : " npm publish --tag next"
14
18
},
15
19
"repository" : {
16
20
"type" : " git" ,
41
45
},
42
46
"engines" : {
43
47
"node" : " >=10.15.3"
48
+ },
49
+ "devDependencies" : {
50
+ "run-script-os" : " 1.1.1"
44
51
}
45
52
}
You can’t perform that action at this time.
0 commit comments