Skip to content

Commit 904e912

Browse files
chore(defaults): update
1 parent a7dee8c commit 904e912

11 files changed

+1684
-1252
lines changed

.eslintrc.js

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
module.exports = {
22
root: true,
3-
parser: 'babel-eslint',
43
plugins: ['prettier'],
54
extends: ['@webpack-contrib/eslint-config-webpack'],
65
rules: {
76
'prettier/prettier': ['error'],
87
},
9-
};
8+
};

.github/ISSUE_TEMPLATE/BUG.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ about: Something went awry and you'd like to tell us about it.
3333

3434
```js
3535
// webpack.config.js
36-
// If your bitchin' code blocks are over 20 lines, please paste a link to a gist
36+
// If your code blocks are over 20 lines, please paste a link to a gist
3737
// (https://gist.github.com).
3838
```
3939

.prettierrc.js

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
module.exports = {
2+
singleQuote: true,
3+
trailingComma: 'es5',
4+
arrowParens: 'always',
5+
};

appveyor.yml

-45
This file was deleted.

azure-pipelines.yml

+201
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,201 @@
1+
trigger:
2+
- master
3+
- next
4+
5+
jobs:
6+
- job: Lint
7+
pool:
8+
vmImage: ubuntu-16.04
9+
steps:
10+
- task: NodeTool@0
11+
inputs:
12+
versionSpec: ^10.13.0
13+
displayName: 'Install Node.js'
14+
- task: Npm@1
15+
inputs:
16+
command: custom
17+
customCommand: i -g npm@latest
18+
displayName: 'Install latest NPM'
19+
- script: |
20+
node -v
21+
npm -v
22+
displayName: 'Print versions'
23+
- task: Npm@1
24+
inputs:
25+
command: custom
26+
customCommand: ci
27+
displayName: 'Install dependencies'
28+
- script: npm run lint
29+
displayName: 'Run lint'
30+
- script: npm run security
31+
displayName: 'Run NPM audit'
32+
- script: ./node_modules/.bin/commitlint-azure-pipelines
33+
displayName: 'Run lint commit message'
34+
35+
- job: Linux
36+
pool:
37+
vmImage: ubuntu-16.04
38+
strategy:
39+
maxParallel: 5
40+
matrix:
41+
node-12:
42+
node_version: ^12.0.0
43+
webpack_version: latest
44+
node-10:
45+
node_version: ^10.13.0
46+
webpack_version: latest
47+
node-8:
48+
node_version: ^8.9.0
49+
webpack_version: latest
50+
node-6:
51+
node_version: ^6.9.0
52+
webpack_version: latest
53+
node-8-canary:
54+
node_version: ^8.9.0
55+
webpack_version: next
56+
continue_on_error: true
57+
steps:
58+
- task: NodeTool@0
59+
inputs:
60+
versionSpec: $(node_version)
61+
displayName: 'Install Node.js $(node_version)'
62+
- task: Npm@1
63+
inputs:
64+
command: custom
65+
customCommand: i -g npm@latest
66+
displayName: 'Install latest NPM'
67+
- script: |
68+
node -v
69+
npm -v
70+
displayName: 'Print versions'
71+
- task: Npm@1
72+
inputs:
73+
command: custom
74+
customCommand: ci
75+
displayName: 'Install dependencies'
76+
- script: npm i webpack@$(webpack_version)
77+
displayName: 'Install "webpack@$(webpack_version)"'
78+
- script: npm run test:coverage -- --ci --reporters="default" --reporters="jest-junit" || $(continue_on_error)
79+
displayName: 'Run tests with coverage'
80+
- task: PublishTestResults@2
81+
inputs:
82+
testRunTitle: 'Linux with Node.js $(node_version)'
83+
testResultsFiles: '**/junit.xml'
84+
condition: succeededOrFailed()
85+
displayName: 'Publish test results'
86+
- script: curl -s https://codecov.io/bash | bash -s -- -t $(CODECOV_TOKEN)
87+
condition: succeededOrFailed()
88+
displayName: 'Submit coverage data to codecov'
89+
90+
- job: macOS
91+
pool:
92+
vmImage: macOS-10.14
93+
strategy:
94+
maxParallel: 5
95+
matrix:
96+
node-12:
97+
node_version: ^12.0.0
98+
webpack_version: latest
99+
node-10:
100+
node_version: ^10.13.0
101+
webpack_version: latest
102+
node-8:
103+
node_version: ^8.9.0
104+
webpack_version: latest
105+
node-6:
106+
node_version: ^6.9.0
107+
webpack_version: latest
108+
node-8-canary:
109+
node_version: ^8.9.0
110+
webpack_version: next
111+
continue_on_error: true
112+
steps:
113+
- task: NodeTool@0
114+
inputs:
115+
versionSpec: $(node_version)
116+
displayName: 'Install Node.js $(node_version)'
117+
- task: Npm@1
118+
inputs:
119+
command: custom
120+
customCommand: i -g npm@latest
121+
displayName: 'Install latest NPM'
122+
- script: |
123+
node -v
124+
npm -v
125+
displayName: 'Print versions'
126+
- task: Npm@1
127+
inputs:
128+
command: custom
129+
customCommand: ci
130+
displayName: 'Install dependencies'
131+
- script: npm i webpack@$(webpack_version)
132+
displayName: 'Install "webpack@$(webpack_version)"'
133+
- script: npm run test:coverage -- --ci --reporters="default" --reporters="jest-junit" || $(continue_on_error)
134+
displayName: 'Run tests with coverage'
135+
- task: PublishTestResults@2
136+
inputs:
137+
testRunTitle: 'Linux with Node.js $(node_version)'
138+
testResultsFiles: '**/junit.xml'
139+
condition: succeededOrFailed()
140+
displayName: 'Publish test results'
141+
- script: curl -s https://codecov.io/bash | bash -s -- -t $(CODECOV_TOKEN)
142+
condition: succeededOrFailed()
143+
displayName: 'Submit coverage data to codecov'
144+
145+
- job: Windows
146+
pool:
147+
vmImage: windows-2019
148+
strategy:
149+
maxParallel: 5
150+
matrix:
151+
node-12:
152+
node_version: ^12.0.0
153+
webpack_version: latest
154+
node-10:
155+
node_version: ^10.13.0
156+
webpack_version: latest
157+
node-8:
158+
node_version: ^8.9.0
159+
webpack_version: latest
160+
node-6:
161+
node_version: ^6.9.0
162+
webpack_version: latest
163+
node-8-canary:
164+
node_version: ^8.9.0
165+
webpack_version: next
166+
continue_on_error: true
167+
steps:
168+
- script: 'git config --global core.autocrlf input'
169+
displayName: 'Config git core.autocrlf'
170+
- checkout: self
171+
- task: NodeTool@0
172+
inputs:
173+
versionSpec: $(node_version)
174+
displayName: 'Install Node.js $(node_version)'
175+
- task: Npm@1
176+
inputs:
177+
command: custom
178+
customCommand: i -g npm@latest
179+
displayName: 'Install latest NPM'
180+
- script: |
181+
node -v
182+
npm -v
183+
displayName: 'Print versions'
184+
- task: Npm@1
185+
inputs:
186+
command: custom
187+
customCommand: ci
188+
displayName: 'Install dependencies'
189+
- script: npm i webpack@$(webpack_version)
190+
displayName: 'Install "webpack@$(webpack_version)"'
191+
- script: npm run test:coverage -- --ci --reporters="default" --reporters="jest-junit" || $(continue_on_error)
192+
displayName: 'Run tests with coverage'
193+
- task: PublishTestResults@2
194+
inputs:
195+
testRunTitle: 'Linux with Node.js $(node_version)'
196+
testResultsFiles: '**/junit.xml'
197+
condition: succeededOrFailed()
198+
displayName: 'Publish test results'
199+
- script: curl -s https://codecov.io/bash | bash -s -- -t $(CODECOV_TOKEN)
200+
condition: succeededOrFailed()
201+
displayName: 'Submit coverage data to codecov'

babel.config.js

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
const MIN_BABEL_VERSION = 7;
2+
3+
module.exports = (api) => {
4+
api.assertVersion(MIN_BABEL_VERSION);
5+
api.cache(true);
6+
7+
return {
8+
presets: [
9+
[
10+
'@babel/preset-env',
11+
{
12+
targets: {
13+
node: '6.9.0',
14+
},
15+
},
16+
],
17+
],
18+
};
19+
};

commitlint.config.js

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
extends: ['@commitlint/config-conventional'],
3+
};

husky.config.js

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
module.exports = {
2+
hooks: {
3+
'pre-commit': 'lint-staged',
4+
'commit-msg': 'commitlint -E HUSKY_GIT_PARAMS',
5+
},
6+
};

lint-staged.config.js

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
module.exports = {
2+
ignore: ['package-lock.json'],
3+
linters: {
4+
'*.js': ['eslint --fix', 'git add'],
5+
},
6+
};

0 commit comments

Comments
 (0)