Skip to content

Commit 5eb7775

Browse files
authored
Merge pull request #147 from efx/update-ember-cli
upgrade ember-cli
2 parents d68d50f + a91e7ce commit 5eb7775

24 files changed

+16746
-15775
lines changed

.bowerrc

Lines changed: 0 additions & 4 deletions
This file was deleted.

.eslintignore

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# unconventional js
2+
/blueprints/*/files/
3+
/vendor/
4+
5+
# compiled output
6+
/dist/
7+
/tmp/
8+
9+
# dependencies
10+
/bower_components/
11+
/node_modules/
12+
13+
# misc
14+
/coverage/
15+
!.*
16+
17+
# ember-try
18+
/.node_modules.ember-try/
19+
/bower.json.ember-try
20+
/package.json.ember-try

.eslintrc.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
module.exports = {
22
root: true,
33
parserOptions: {
4-
ecmaVersion: 2017,
4+
ecmaVersion: 2018,
55
sourceType: 'module'
66
},
77
plugins: [
@@ -20,6 +20,8 @@ module.exports = {
2020
// node files
2121
{
2222
files: [
23+
'.eslintrc.js',
24+
'.template-lintrc.js',
2325
'ember-cli-build.js',
2426
'index.js',
2527
'testem.js',

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99
/bower_components
1010

1111
# misc
12+
/.env*
13+
/.pnp*
1214
/.sass-cache
1315
/connect.lock
1416
/coverage/*

.npmignore

Lines changed: 28 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,31 @@
1-
/bower_components
1+
# compiled output
2+
/dist/
3+
/tmp/
4+
5+
# dependencies
6+
/bower_components/
7+
8+
# misc
9+
/.bowerrc
10+
/.editorconfig
11+
/.ember-cli
12+
/.env*
13+
/.eslintignore
14+
/.eslintrc.js
15+
/.gitignore
16+
/.template-lintrc.js
17+
/.travis.yml
18+
/.watchmanconfig
19+
/bower.json
220
/config/ember-try.js
3-
/coverage
4-
/dist
5-
/tests
6-
/tmp
7-
**/.gitkeep
8-
.bowerrc
9-
.editorconfig
10-
.ember-cli
11-
.eslintrc.js
12-
.gitignore
13-
.watchmanconfig
14-
.travis.yml
15-
bower.json
16-
ember-cli-build.js
17-
testem.js
21+
/CONTRIBUTING.md
22+
/ember-cli-build.js
23+
/testem.js
24+
/tests/
25+
/yarn.lock
26+
.gitkeep
1827

1928
# ember-try
20-
.node_modules.ember-try/
21-
bower.json.ember-try
22-
package.json.ember-try
29+
/.node_modules.ember-try/
30+
/bower.json.ember-try
31+
/package.json.ember-try

.template-lintrc.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
'use strict';
2+
3+
module.exports = {
4+
extends: 'recommended'
5+
};

.travis.yml

Lines changed: 24 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ language: node_js
33
node_js:
44
# we recommend testing addons with the same minimum supported node version as Ember CLI
55
# so that your addon works for all apps
6-
- "6"
6+
- "8"
77

88
sudo: false
99
dist: trusty
@@ -20,32 +20,39 @@ env:
2020
# See https://git.io/vdao3 for details.
2121
- JOBS=1
2222
- CC_TEST_REPORTER_ID=f1b6bcc83789c103f7822eb2ec34bbdc34be1b36bdc66bc6de53c26ed1a14e27
23-
matrix:
23+
24+
jobs:
25+
fail_fast: true
26+
allow_failures:
27+
- env: EMBER_TRY_SCENARIO=ember-canary
28+
29+
include:
30+
# runs linting and tests with current locked deps
31+
32+
- stage: "Tests"
33+
name: "Tests"
34+
script:
35+
- npm run lint:hbs
36+
- npm run lint:js
37+
- npm test
38+
2439
# we recommend new addons test the current and previous LTS
2540
# as well as latest stable release (bonus points to beta/canary)
26-
- EMBER_TRY_SCENARIO=ember-lts-2.12
27-
- EMBER_TRY_SCENARIO=ember-lts-2.16
28-
- EMBER_TRY_SCENARIO=ember-lts-2.18
29-
- EMBER_TRY_SCENARIO=ember-release
30-
- EMBER_TRY_SCENARIO=ember-beta
31-
- EMBER_TRY_SCENARIO=ember-canary
32-
- EMBER_TRY_SCENARIO=ember-default
33-
34-
matrix:
35-
fast_finish: true
36-
allow_failures:
41+
- stage: "Additional Tests"
42+
env: EMBER_TRY_SCENARIO=ember-lts-2.18
43+
- env: EMBER_TRY_SCENARIO=ember-lts-3.4
44+
- env: EMBER_TRY_SCENARIO=ember-release
45+
- env: EMBER_TRY_SCENARIO=ember-beta
3746
- env: EMBER_TRY_SCENARIO=ember-canary
47+
- env: EMBER_TRY_SCENARIO=ember-default-with-jquery
3848

3949
before_script:
4050
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
4151
- chmod +x ./cc-test-reporter
4252
- ./cc-test-reporter before-build
4353

4454
script:
45-
- npm run lint:js
46-
# Usually, it's ok to finish the test scenario without reverting
47-
# to the addon's original dependency state, skipping "cleanup".
48-
- COVERAGE=true node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO test --skip-cleanup
55+
- COVERAGE=true node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO
4956

5057
after_script:
5158
- ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT

CONTRIBUTING.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# How To Contribute
2+
3+
## Installation
4+
5+
* `git clone <repository-url>`
6+
* `cd my-addon`
7+
* `npm install`
8+
9+
## Linting
10+
11+
* `npm run lint:hbs`
12+
* `npm run lint:js`
13+
* `npm run lint:js -- --fix`
14+
15+
## Running tests
16+
17+
* `ember test` – Runs the test suite on the current Ember version
18+
* `ember test --server` – Runs the test suite in "watch mode"
19+
* `ember try:each` – Runs the test suite against multiple Ember versions
20+
21+
## Running the dummy application
22+
23+
* `ember serve`
24+
* Visit the dummy application at [http://localhost:4200](http://localhost:4200).
25+
26+
For more information on using ember-cli, visit [https://ember-cli.com/](https://ember-cli.com/).

app/templates/head.hbs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{! template-lint-disable no-html-comments }}
12
<!-- `app/templates/head.hbs` -->
23
<!-- content from ember-page-title, injected by ember-cli-head -->
34
<!-- The 'model' available in this template can be populated by -->

bower.json

Lines changed: 0 additions & 4 deletions
This file was deleted.

config/ember-try.js

Lines changed: 27 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -9,28 +9,26 @@ module.exports = function() {
99
getChannelURL('canary')
1010
]).then((urls) => {
1111
return {
12+
command: 'ember test --skip-cleanup',
13+
//npmOptions: ['--loglevel=silent', '--no-shrinkwrap=true'],
1214
scenarios: [
1315
{
14-
name: 'ember-lts-2.12',
15-
npm: {
16-
devDependencies: {
17-
'ember-source': '~2.12.0'
18-
}
19-
}
20-
},
21-
{
22-
name: 'ember-lts-2.16',
16+
name: 'ember-lts-2.18',
17+
env: {
18+
EMBER_OPTIONAL_FEATURES: JSON.stringify({ 'jquery-integration': true })
19+
},
2320
npm: {
2421
devDependencies: {
25-
'ember-source': '~2.16.0'
22+
'@ember/jquery': '^0.5.1',
23+
'ember-source': '~2.18.0'
2624
}
2725
}
2826
},
2927
{
30-
name: 'ember-lts-2.18',
28+
name: 'ember-lts-3.4',
3129
npm: {
3230
devDependencies: {
33-
'ember-source': '~2.18.0'
31+
'ember-source': '~3.4.0'
3432
}
3533
}
3634
},
@@ -58,11 +56,28 @@ module.exports = function() {
5856
}
5957
}
6058
},
59+
// The default `.travis.yml` runs this scenario via `npm test`,
60+
// not via `ember try`. It's still included here so that running
61+
// `ember try:each` manually or from a customized CI config will run it
62+
// along with all the other scenarios.
6163
{
6264
name: 'ember-default',
6365
npm: {
6466
devDependencies: {}
6567
}
68+
},
69+
{
70+
name: 'ember-default-with-jquery',
71+
env: {
72+
EMBER_OPTIONAL_FEATURES: JSON.stringify({
73+
'jquery-integration': true
74+
})
75+
},
76+
npm: {
77+
devDependencies: {
78+
'@ember/jquery': '^0.5.1'
79+
}
80+
}
6681
}
6782
]
6883
};

0 commit comments

Comments
 (0)