0
Fork 0
mirror of https://github.com/verdaccio/verdaccio.git synced 2024-12-30 22:34:10 -05:00

build: improve beta and alpha release

This commit is contained in:
Juan Picado @jotadeveloper 2018-01-07 19:16:44 +01:00
parent 6ce4f79a30
commit 1eb8e58e0e
No known key found for this signature in database
GPG key ID: 18AC54485952D158
4 changed files with 30 additions and 2 deletions

View file

@ -31,9 +31,17 @@ test:
- yarn run test - yarn run test
deployment: deployment:
production: production:
tag: /.*?/ tag: /(v)?[0-9]+(\.[0-9]+)*/
commands: commands:
- ./scripts/publish.sh - ./scripts/publish.sh
alpha-release:
tag: /.*-alpha.*/
commands:
- ./scripts/alpha-publish.sh
beta-release:
tag: /.*-beta.*/
commands:
- ./scripts/beta-publish.sh
general: general:
branches: branches:
ignore: ignore:

10
scripts/alpha-publish.sh Executable file
View file

@ -0,0 +1,10 @@
#!/bin/bash
# Get the last tag from GitHub
lastTag=$(git describe --tags $(git rev-list --tags --max-count=1))
# Print it to the console for verification
echo "Bumping version to new tag: ${lastTag}"
# Publish to NPM
npm publish --tag alpha

10
scripts/beta-publish.sh Executable file
View file

@ -0,0 +1,10 @@
#!/bin/bash
# Get the last tag from GitHub
lastTag=$(git describe --tags $(git rev-list --tags --max-count=1))
# Print it to the console for verification
echo "Bumping version to new tag: ${lastTag}"
# Publish to NPM
npm publish --tag beta

View file

@ -7,4 +7,4 @@ lastTag=$(git describe --tags $(git rev-list --tags --max-count=1))
echo "Bumping version to new tag: ${lastTag}" echo "Bumping version to new tag: ${lastTag}"
# Publish to NPM # Publish to NPM
npm publish --tag beta npm publish