Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature life cycle #5

Merged
merged 14 commits into from
Jan 15, 2019
5 changes: 5 additions & 0 deletions .commitlintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
'use strict';

module.exports = {
extends: ['@commitlint/config-conventional']
};
20 changes: 20 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# unconventional js
/blueprints/*/files/
/vendor/

# compiled output
/dist/
/tmp/

# dependencies
/bower_components/
/node_modules/

# misc
/coverage/
!.*

# ember-try
/.node_modules.ember-try/
/bower.json.ember-try
/package.json.ember-try
43 changes: 40 additions & 3 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-env node */
'use strict';

module.exports = {
Expand All @@ -7,8 +6,46 @@ module.exports = {
ecmaVersion: 2017,
sourceType: 'module'
},
extends: 'eslint-config-bbva',
plugins: [
'ember'
],
extends: [
'plugin:ember/recommended',
'eslint-config-bbva'
],
env: {
browser: true
}
},
overrides: [{
files: [
'.huskyrc.js',
'.commitlintrc.js',
'.eslintrc.js',
'.template-lintrc.js',
'ember-cli-build.js',
'index.js',
'testem.js',
'blueprints/*/index.js',
'config/**/*.js',
'tests/dummy/config/**/*.js'
],
excludedFiles: [
'addon/**',
'addon-test-support/**',
'app/**',
'tests/dummy/app/**'
],
parserOptions: {
sourceType: 'script',
ecmaVersion: 2015
},
env: {
browser: false,
node: true
},
plugins: ['node'],
rules: Object.assign({}, require('eslint-plugin-node').configs.recommended.rules, {
'no-process-env': 0
})
}]
};
28 changes: 15 additions & 13 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,23 +1,25 @@
# See https://help.github.com/ignore-files/ for more about ignoring files.

# compiled output
/dist
/tmp
/dist/
/tmp/

# dependencies
/node_modules
/bower_components
/bower_components/
/node_modules/

# misc
/.env*
/.sass-cache
/connect.lock
/coverage/*
/coverage/
/libpeerconnection.log
npm-debug.log*
yarn-error.log
testem.log
/npm-debug.log*
/testem.log
/yarn-error.log
/tags*

# ember-try
.node_modules.ember-try/
bower.json.ember-try
package.json.ember-try

tags
/.node_modules.ember-try/
/bower.json.ember-try
/package.json.ember-try
8 changes: 8 additions & 0 deletions .huskyrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
'use strict';

module.exports = {
hooks: {
'commit-msg': 'commitlint -E HUSKY_GIT_PARAMS',
'pre-push': 'npm run lint:js && npm run lint:hbs && npm test'
}
};
45 changes: 30 additions & 15 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -1,16 +1,31 @@
/bower_components
# compiled output
/dist/
/tmp/

# dependencies
/bower_components/

# misc
/.bowerrc
/.editorconfig
/.ember-cli
/.env*
/.eslintignore
/.eslintrc.js
/.gitignore
/.template-lintrc.js
/.travis.yml
/.watchmanconfig
/bower.json
/config/ember-try.js
/dist
/tests
/tmp
**/.gitkeep
.bowerrc
.editorconfig
.ember-cli
.gitignore
.eslintrc.js
.watchmanconfig
.travis.yml
bower.json
ember-cli-build.js
testem.js
/CONTRIBUTING.md
/ember-cli-build.js
/testem.js
/tests/
/yarn.lock
.gitkeep

# ember-try
/.node_modules.ember-try/
/bower.json.ember-try
/package.json.ember-try
13 changes: 13 additions & 0 deletions .releaserc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"prepare": [
"@semantic-release/changelog",
"@semantic-release/npm",
"@semantic-release/git"
],
"verifyConditions": [
"@semantic-release/changelog",
"@semantic-release/npm",
"@semantic-release/git",
"@semantic-release/github"
]
}
23 changes: 23 additions & 0 deletions .template-lintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
'use strict';

module.exports = {
extends: 'recommended',
rules: {
'no-bare-strings': true,
'block-indentation': 'tab',
'no-html-comments': true,
'no-nested-interactive': true,
'self-closing-void-elements': true,
'no-triple-curlies': true,
'deprecated-each-syntax': true,
'link-rel-noopener': true,
'no-invalid-interactive': true,
'img-alt-attributes': true,
'style-concatenation': true,
'deprecated-inline-view-helper': true,
'no-unused-block-params': true,
'inline-link-to': true,
'no-inline-styles': true,
'simple-unless': false
}
};
81 changes: 55 additions & 26 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
---
language: node_js
node_js:
- "stable"

node_js: stable
sudo: false
dist: trusty

Expand All @@ -12,37 +10,68 @@ addons:
cache:
directories:
- $HOME/.npm
- $HOME/.cache # includes bowers cache

env:
# we recommend new addons test the current and previous LTS
# as well as latest stable release (bonus points to beta/canary)
- EMBER_TRY_SCENARIO=ember-lts-2.12
- EMBER_TRY_SCENARIO=ember-lts-2.16
- EMBER_TRY_SCENARIO=ember-release
- EMBER_TRY_SCENARIO=ember-beta
- EMBER_TRY_SCENARIO=ember-canary
- EMBER_TRY_SCENARIO=ember-default

matrix:
fast_finish: true
global:
- JOBS=1

jobs:
fail_fast: true
allow_failures:
- env: EMBER_TRY_SCENARIO=ember-canary

include:
- stage: "Tests"
before_install:
- npm config set spin false
- npm install -g npm@6
- npm install -g codecov
- npm install -g greenkeeper-lockfile@1
- npm install -g @commitlint/travis-cli
- npm --version
install:
- if [[ $TRAVIS_BRANCH =~ greenkeeper || $TRAVIS_PULL_REQUEST_BRANCH =~ greenkeeper ]]; then npm install; else npm ci; fi
before_script:
- greenkeeper-lockfile-update
script:
- commitlint-travis
- npm run lint:js
- npm run lint:hbs
- npm test
after_script:
- greenkeeper-lockfile-upload

- stage: "Regression Tests"
env: EMBER_TRY_SCENARIO=ember-lts-2.18
- env: EMBER_TRY_SCENARIO=ember-lts-3.4
- env: EMBER_TRY_SCENARIO=ember-release
- env: EMBER_TRY_SCENARIO=ember-beta
- env: EMBER_TRY_SCENARIO=ember-canary
- env: EMBER_TRY_SCENARIO=ember-default-with-jquery

- stage: "Release"
script: skip
deploy:
provider: script
skip_cleanup: true
script:
- npx semantic-release

before_install:
- npm config set spin false
- npm install -g npm@^5.7
- npm install -g npm@6
- npm install -g codecov
- npm --version

install:
- npm ci
script:
- COVERAGE=true node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO

after_success:
- codecov --file=coverage/lcov.info

before_script:
- sudo chown root /opt/google/chrome/chrome-sandbox
- sudo chmod 4755 /opt/google/chrome/chrome-sandbox
stages:
- "Tests"
- "Regression Tests"
- name: "Release"
if: branch = master

script:
# Usually, it's ok to finish the test scenario without reverting
# to the addon's original dependency state, skipping "cleanup".
- node_modules/.bin/eslint '**/*.js'
- node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO --skip-cleanup
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ This doc outlines the details of collaborating on this Ember addon.
## Installation

* `git clone <repository-url>` this repository
* `cd ember-route-promise-chain`
* `cd <repository-name>`
* `npm install`

## Eslint
Expand Down
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# The MIT License (MIT)

Copyright (c) 2017
Copyright (c) 2019

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# ember-route-promise-chain
# ember-route-promise-chain

[![Build Status](https://travis-ci.org/BBVAEngineering/ember-route-promise-chain.svg?branch=master)](https://travis-ci.org/BBVAEngineering/ember-route-promise-chain)
[![GitHub version](https://badge.fury.io/gh/BBVAEngineering%2Fember-route-promise-chain.svg)](https://badge.fury.io/gh/BBVAEngineering%2Fember-route-promise-chain)
[![npm version](https://badge.fury.io/js/ember-route-promise-chain.svg)](https://badge.fury.io/js/ember-route-promise-chain)
[![NPM version](https://badge.fury.io/js/ember-route-promise-chain.svg)](https://badge.fury.io/js/ember-route-promise-chain)
[![Dependency Status](https://david-dm.org/BBVAEngineering/ember-route-promise-chain.svg)](https://david-dm.org/BBVAEngineering/ember-route-promise-chain)
[![codecov](https://codecov.io/gh/BBVAEngineering/ember-route-promise-chain/branch/master/graph/badge.svg)](https://codecov.io/gh/BBVAEngineering/ember-route-promise-chain)
[![Greenkeeper badge](https://badges.greenkeeper.io/BBVAEngineering/ember-route-promise-chain.svg)](https://greenkeeper.io/)
[![Ember Observer Score](https://emberobserver.com/badges/ember-route-promise-chain.svg)](https://emberobserver.com/addons/ember-route-promise-chain)

## Information

Expand Down
Loading