-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathazure-pipelines.yml
More file actions
37 lines (34 loc) · 873 Bytes
/
azure-pipelines.yml
File metadata and controls
37 lines (34 loc) · 873 Bytes
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
# Code originally from https://github.com/ofek/ofek.github.io/blob/site/azure-pipelines.yml
trigger:
- site
pr:
- site
jobs:
- job: 'Build'
pool:
vmImage: 'ubuntu-latest'
steps:
- task: UsePythonVersion@0
inputs:
versionSpec: '3.7'
displayName: 'Use Python 3.7'
- script: |
pip install pelican
displayName: 'Install dependencies'
- script: pelican content
displayName: 'Build Pelican Content'
- publish: $(System.DefaultWorkingDirectory)/output
artifact: site
- job: 'Publish'
dependsOn: 'Build'
condition: and(succeeded(), ne(variables['Build.Reason'], 'PullRequest'))
pool:
vmImage: 'ubuntu-latest'
steps:
- download: current
artifact: site
- script: ./scripts/publish-site.sh
env:
GITHUB_TOKEN: $(GITHUB_TOKEN)
SITE_DIR: $(Pipeline.Workspace)/output
displayName: 'Push to master'