Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
⚒ improve azure-pipelines.yml (#173)
- Loading branch information
1 parent
a85d541
commit b757c3e
Showing
4 changed files
with
92 additions
and
82 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
jobs: | ||
- job: lint | ||
displayName: Lint | ||
pool: | ||
vmImage: Ubuntu-16.04 | ||
steps: | ||
- task: NodeTool@0 | ||
displayName: Install Node.js | ||
inputs: | ||
versionSpec: 12.x | ||
|
||
- script: npm install | ||
displayName: Install Packages | ||
|
||
- script: npm run -s lint | ||
displayName: Lint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
parameters: | ||
name: "" | ||
displayName: "" | ||
vmImage: "" | ||
nodeVersion: "" | ||
eslintVersion: "" | ||
|
||
jobs: | ||
- job: ${{parameters.name}} | ||
displayName: ${{parameters.displayName}} | ||
pool: | ||
vmImage: ${{parameters.vmImage}} | ||
steps: | ||
- task: NodeTool@0 | ||
displayName: Install Node.js | ||
inputs: | ||
versionSpec: ${{parameters.nodeVersion}} | ||
|
||
- script: npm install && npm install --no-save async | ||
displayName: Install Packages | ||
|
||
- script: | | ||
# We need to execute this command twice because of npm's bug. | ||
# See also: https://npm.community/t/error-node-modules-staging-eslint-e7cf6846-node-modules-eslint | ||
npm install --no-save eslint@${{parameters.eslintVersion}} | ||
npm install --no-save eslint@${{parameters.eslintVersion}} | ||
displayName: Install Specific ESLint | ||
condition: ne('${{parameters.eslintVersion}}', '') | ||
- script: npm run -s test:ci | ||
displayName: Test | ||
|
||
- script: npm run -s codecov -- -t $(CODECOV_TOKEN) | ||
displayName: Send Coverage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters