From 1ce48f47997af1a41ec522d058f3da89c75fbf2a Mon Sep 17 00:00:00 2001 From: Andreas Gerlach Date: Tue, 12 Mar 2019 10:58:17 +0100 Subject: [PATCH] initial commit for travis ci integration --- .gitattributes | 5 ++++- .prettierrc | 4 ++++ .travis.yml | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++ README.md | 2 ++ package.json | 25 +++++++++++++++++++-- 5 files changed, 93 insertions(+), 3 deletions(-) create mode 100644 .prettierrc create mode 100644 .travis.yml diff --git a/.gitattributes b/.gitattributes index 78a31a8..d9e0b3c 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,6 +1,9 @@ * text=auto eol=lf -/spec export-ignore /.gitattributes export-ignore /.gitignore export-ignore +/.prettierrc export-ignore +/.travis.yml export-ignore /screenshot.png export-ignore +/spec export-ignore +/typings export-ignore diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 0000000..2634817 --- /dev/null +++ b/.prettierrc @@ -0,0 +1,4 @@ +{ + "singleQuote": true, + "trailingComma": true +} diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..8653ff5 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,60 @@ +### Project specific config ### +language: node_js +node_js: lts/* +os: linux + +env: + matrix: + - ATOM_CHANNEL=stable + - ATOM_CHANNEL=beta + +script: + - commitlint-travis + +stages: + - test + - name: release + if: (NOT type = pull_request) AND branch = master + +jobs: + include: + - stage: release + node_js: lts/* + script: + - export PATH=${PATH}:${HOME}/atom/usr/bin/ + deploy: + provider: script + skip_cleanup: true + script: + - npx semantic-release + +### Generic setup follows ### +install: + - curl -s -O https://raw.githubusercontent.com/atom/ci/master/build-package.sh + - chmod u+x build-package.sh + - "./build-package.sh" + +notifications: + email: + on_success: never + on_failure: change + +branches: + only: + - master + - "/^greenkeeper/.*$/" + +git: + depth: 10 + +sudo: false + +dist: trusty + +addons: + apt: + packages: + - build-essential + - fakeroot + - git + - libsecret-1-dev diff --git a/README.md b/README.md index aadad1d..6939fb5 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # atom-ide-datatip package +[![Build Status](https://api.travis-ci.org/atom-ide-community/atom-ide-datatip.png)](https://travis-ci.org/atom-ide-community/atom-ide-datatip) + A replacement of the DataTip functionality from the original Atom-IDE / Nuclide package developed by Facebook. ![A screenshot of your package](screenshot.png) diff --git a/package.json b/package.json index eeb7755..2f5ca8f 100644 --- a/package.json +++ b/package.json @@ -21,13 +21,34 @@ "react-dom": "^16.7.0" }, "devDependencies": { - "@types/atom": "^1.31.0", + "@commitlint/cli": "^7.5.2", + "@commitlint/config-conventional": "^7.5.0", + "@commitlint/travis-cli": "^7.5.2", + "@semantic-release/apm-config": "^6.0.1", + "@types/atom": "^1.31.1", "@types/dompurify": "0.0.32", "@types/marked": "^0.6.0", "@types/node": "^10.12.18", "@types/react": "^16.7.21", "@types/react-dom": "^16.0.11", - "atom-languageclient": "^0.9.9" + "atom-languageclient": "^0.9.9", + "commitlint": "^7.5.2", + "husky": "^1.3.1", + "prettier": "1.16.4", + "semantic-release": "^15.13.3" + }, + "release": { + "extends": "@semantic-release/apm-config" + }, + "commitlint": { + "extends": [ + "@commitlint/config-conventional" + ] + }, + "husky": { + "hooks": { + "commit-msg": "commitlint -E HUSKY_GIT_PARAMS" + } }, "configSchema": { "showDataTipOnCursorMove": {