forked from scratchfoundation/scratch-gui
-
Notifications
You must be signed in to change notification settings - Fork 2
/
azure-pipelines.yml
61 lines (48 loc) · 1.38 KB
/
azure-pipelines.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# Node.js
# Build a general Node.js project with npm.
# Add steps that analyze code, save build artifacts, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript
trigger:
- develop
pool:
vmImage: 'Ubuntu-20.04'
steps:
- task: Bash@3
inputs:
script: 'git clone https://github.com/Mobsya/scratch-vm --depth=1'
targetType: 'inline'
workingDirectory: $(Agent.BuildDirectory)
displayName: 'Cloning scratch vm'
- task: NodeTool@0
inputs:
versionSpec: '14.x'
displayName: 'Install Node.js'
- script: |
npm install
npm run build
npm link
displayName: 'npm install and build scratch-vm'
workingDirectory: $(Agent.BuildDirectory)/scratch-vm
- script: |
npm install
npm link scratch-vm
npm run build
displayName: 'npm install and build scratch-gui'
workingDirectory: $(Build.SourcesDirectory)
- task: Bash@3
inputs:
script: 'mv build scratch'
targetType: 'inline'
displayName: 'Renaming build directory'
- task: ArchiveFiles@2
inputs:
rootFolderOrFile: 'scratch'
archiveFile: '$(Build.ArtifactStagingDirectory)/scratch-gui.tar.gz'
includeRootFolder: true
replaceExistingArchive: true
archiveType: 'tar'
displayName: 'compressing build directory'
- task: PublishBuildArtifacts@1
inputs:
pathtoPublish: '$(Build.ArtifactStagingDirectory)'
artifactName: 'scratch-gui'