Add devops config
This commit is contained in:
Родитель
d1b4ab12ca
Коммит
1f747c9223
|
@ -0,0 +1,42 @@
|
|||
trigger:
|
||||
branches:
|
||||
include: ['*']
|
||||
tags:
|
||||
include: ['*']
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
linux:
|
||||
imageName: 'ubuntu-16.04'
|
||||
|
||||
pool:
|
||||
vmImage: $(imageName)
|
||||
|
||||
steps:
|
||||
|
||||
- task: NodeTool@0
|
||||
inputs:
|
||||
versionSpec: '12.x'
|
||||
displayName: 'Install Node.js'
|
||||
|
||||
- bash: |
|
||||
/usr/bin/Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
|
||||
echo ">>> Started xvfb"
|
||||
displayName: Start xvfb
|
||||
condition: and(succeeded(), eq(variables['Agent.OS'], 'Linux'))
|
||||
|
||||
- bash: |
|
||||
echo ">>> Compile, line, test"
|
||||
yarn
|
||||
yarn compile
|
||||
yarn lint
|
||||
yarn test
|
||||
displayName: Compile, Lint, Test
|
||||
env:
|
||||
DISPLAY: ':99.0'
|
||||
|
||||
- bash: |
|
||||
echo ">>> Publish"
|
||||
npm run deploy -- -p $(VSCODE_MARKETPLACE_TOKEN)
|
||||
displayName: Publish
|
||||
condition: and(succeeded(), startsWith(variables['Build.SourceBranch'], 'refs/tags/'))
|
Загрузка…
Ссылка в новой задаче