-
Notifications
You must be signed in to change notification settings - Fork 31
/
Copy path.release.json
61 lines (61 loc) · 2.5 KB
/
.release.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
{
"type": "JavaScript",
"ci": "circleci",
"slug": "twilio/twilio-voice-react-native",
"env": {
"GH_REF": "github.com/twilio/twilio-voice-react-native.git"
},
"plans": {
"release": {
"env": {
"GIT_USER_NAME": "twilio-vblocks-ci",
"GIT_USER_EMAIL": "[email protected]"
},
"commands": [
"git config user.name \"${GIT_USER_NAME}\"",
"git config user.email \"${GIT_USER_EMAIL}\"",
"git remote set-url origin \"https://${GH_TOKEN}@${GH_REF}\"",
"node ./node_modules/twilio-release-tool/release --bump ${CURRENT_VERSION} ${RELEASE_VERSION}",
"node ./scripts/substitute-constants-version.js ${RELEASE_VERSION}",
"git add package.json",
"git add constants/constants.src",
"yarn run build:docs",
"git add -f docs/api lib",
"git add -f src/constants.ts",
"git add -f ios/TwilioVoiceReactNativeConstants.h",
"git add -f android/src/main/java/com/twiliovoicereactnative/CommonConstants.java",
"git commit -nm \"${RELEASE_VERSION}\"",
"git tag ${RELEASE_VERSION}",
"git tag -d latest",
"git tag latest ${RELEASE_VERSION}^{commit}",
"git rebase HEAD ${BRANCH}",
"git push origin ${BRANCH} --tags --force &> /dev/null && echo \"Push to origin successful\" || (echo \"Push to origin failed\" 1>&2 && exit 1)"
]
},
"development": {
"commands": [
"git config user.name \"${GIT_USER_NAME}\"",
"git config user.email \"${GIT_USER_EMAIL}\"",
"git remote set-url origin \"https://${GH_TOKEN}@${GH_REF}\"",
"node ./node_modules/twilio-release-tool/release --bump ${RELEASE_VERSION} ${DEVELOPMENT_VERSION}",
"node ./scripts/substitute-constants-version.js ${DEVELOPMENT_VERSION}",
"git add package.json",
"git add constants/constants.src",
"git rm -r docs/api lib",
"git rm src/constants.ts",
"git rm ios/TwilioVoiceReactNativeConstants.h",
"git rm android/src/main/java/com/twiliovoicereactnative/CommonConstants.java",
"git commit -nm \"${DEVELOPMENT_VERSION}\"",
"git rebase HEAD ${BRANCH}",
"git push origin ${BRANCH} &> /dev/null && echo \"Push to origin successful\" || (echo \"Push to origin failed\" 1>&2 && exit 1)"
]
},
"publish": {
"commands": [
"git checkout ${RELEASE_VERSION}",
"echo \"//registry.npmjs.org/:_authToken=${NPM_AUTH_TOKEN}\" >~/.npmrc",
"npm publish"
]
}
}
}