summaryrefslogtreecommitdiff
path: root/azure-pipelines.yml
blob: 3b409171f0314dccd61fee0857c65f2c4c90fc89 (plain)
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
trigger:
- master

jobs:
- job: windows
  pool:
    vmImage: 'windows-latest'

  steps:
  - script: |
      git submodule update --init --recursive
    displayName: 'Init'
  - script: |
      cd 3rd\luamake
      tools\ninja.exe -f ninja\msvc.ninja
      cd ..\..
    displayName: 'Compile luamake'
  - script: |
      3rd\luamake\luamake.exe rebuild
    displayName: 'Compile'
  - task: CopyFiles@2
    inputs:
      Contents: '**'
      SourceFolder: 'bin\Windows'
      TargetFolder: '$(Build.ArtifactStagingDirectory)'
  - task: PublishBuildArtifacts@1
    inputs:
      pathToPublish: $(Build.ArtifactStagingDirectory)
      artifactName: sumneko.lua-windows

- job: macos
  pool:
    vmImage: 'macos-latest'

  steps:
  - bash: |
      git submodule update --init --recursive
    displayName: 'Init'
  - bash: |
      sudo xcode-select -s /Applications/Xcode_10.2.app
      brew install ninja
    displayName: 'Install'
  - bash: |
      cd 3rd/luamake
      ninja -f ninja/macos.ninja
      cd ../..
    displayName: 'Compile luamake'
  - bash: |
      rm -r server/macOS/*
      ./3rd/luamake/luamake rebuild
    displayName: 'Compile'
  - task: CopyFiles@2
    inputs:
      Contents: '**'
      SourceFolder: 'bin/macOS'
      TargetFolder: '$(Build.ArtifactStagingDirectory)'
  - task: PublishBuildArtifacts@1
    inputs:
      pathToPublish: $(Build.ArtifactStagingDirectory)
      artifactName: sumneko.lua-macos

- job: linux
  pool:
    vmImage: 'ubuntu-latest'

  steps:
  - bash: |
      git submodule update --init --recursive
    displayName: 'Init'
  - bash: |
      sudo apt-get update
      sudo apt-get install -y libreadline-dev ninja-build
      sudo apt-get install -y g++-8
    displayName: 'Install'
  - bash: |
      cd 3rd/luamake
      ninja -f ninja/linux.ninja
      cd ../..
    displayName: 'Compile luamake'
  - bash: |
      rm -r server/Linux/*
      ./3rd/luamake/luamake rebuild
    displayName: 'Compile'
  - task: CopyFiles@2
    inputs:
      Contents: '**'
      SourceFolder: 'bin/Linux'
      TargetFolder: '$(Build.ArtifactStagingDirectory)'
  - task: PublishBuildArtifacts@1
    inputs:
      pathToPublish: $(Build.ArtifactStagingDirectory)
      artifactName: sumneko.lua-linux