Npm versioning (#4)

* replace patchversion with date-time stamp:  YYYYmmddHHMMSS

* Bump to first major version

Ready to start using this in gui.
This commit is contained in:
chrisgarrity 2017-10-05 10:20:59 -04:00 committed by GitHub
parent 39de2e5a0d
commit c6f52ae643
2 changed files with 7 additions and 5 deletions

View file

@ -12,12 +12,13 @@ jobs:
node_js: 6
script: npm run build
before_deploy:
- npm --no-git-tag-version version $($(npm bin)/json -f package.json version)-prerelease.$(date +%s)
- git config --global user.email $(git log --pretty=format:"%ae" -n1)
- git config --global user.name $(git log --pretty=format:"%an" -n1)
- VPKG=$($(npm bin)/json -f package.json version)
- export VERSION=${VPKG/%?/}$(date +%Y%m%d%H%M%S)
- npm --no-git-tag-version version $VERSION
deploy:
provider: npm
skip_cleanup: true
email: $NPM_EMAIL
api_key: $NPM_TOKEN
on:
all_branches: true

View file

@ -1,6 +1,6 @@
{
"name": "scratch-l10n",
"version": "0.1.0",
"version": "1.0.0",
"description": "Localization for the Scratch 3.0 components",
"main": "./dist/l10n.js",
"scripts": {
@ -31,6 +31,7 @@
"eslint-config-scratch": "^4.0.0",
"eslint-plugin-import": "^2.7.0",
"eslint-plugin-json": "1.2.0",
"json": "^9.0.6",
"lodash.defaultsdeep": "4.6.0",
"mkdirp": "^0.5.1",
"react-intl": "2.4.0",