Skip to content

Commit

Permalink
Enable Travis (#21)
Browse files Browse the repository at this point in the history
* Enable Travis

* Update .travis.yml

Remove local variable and npm email
  • Loading branch information
Marcos Vinícius Rubido authored May 9, 2019
1 parent ccac475 commit 9a5b054
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
language: node_js

node_js:
- "node"
- "lts/*"

env:
global:
- REPO_VERSION="$(npx -c 'echo "$npm_package_version"')"

before_install:
- echo "REPO_VERSION=$REPO_VERSION"

before_script:
- npm run lint

before_deploy:
- |
if [ "$TRAVIS_BRANCH" == "master" ]; then
git tag -a -f "$REPO_VERSION"
echo "New Tag $(git describe --tags)";
fi
deploy:
- provider: releases
api_key: $GITHUB_TOKEN
on:
branch: master
- provider: npm
api_key: $NPM_API_KEY
on:
tags: true

0 comments on commit 9a5b054

Please sign in to comment.