-
Notifications
You must be signed in to change notification settings - Fork 8
/
bitrise.yml
83 lines (78 loc) · 2.26 KB
/
bitrise.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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
format_version: 5
default_step_lib_source: https://github.com/bitrise-io/bitrise-steplib.git
description: |
Official guides: http://www.mkdocs.org
workflows:
ci:
before_run:
- setup
steps:
- script:
inputs:
- content: |-
#!/bin/bash
set -ex
mkdocs build
deploy-to-github-pages:
before_run:
- setup
steps:
- script:
description: |
Note: mkdocs builds into `./site/`
Official GitHub Pages deploy guide: https://help.github.com/articles/creating-project-pages-manually/
*You can find infos about how to initialize the required `gh-pages` branch
in the official guide.*
inputs:
- content: |-
#!/bin/bash
set -ex
# Build & Deploy
mkdocs build --clean
mkdocs gh-deploy
# Reset credentials
set +x
set -v
curl -X DELETE "https://api.cloudflare.com/client/v4/zones/${CLOUDFLARE_ZONEID}/purge_cache" \
-H "X-Auth-Email: ${CLOUDFLARE_EMAIL}" \
-H "X-Auth-Key: ${CLOUDFLARE_KEY}" \
-H "Content-Type: application/json" \
--data '{"purge_everything":true}'
setup:
steps:
- script:
deps:
brew:
- name: python
bin_name: pip
apt_get:
- name: python-pip
- name: python-dev
- name: build-essential
inputs:
- content: |
#!/bin/bash
set -ex
sudocmd=""
if [[ "$(uname)" == "Linux" ]] ; then
sudocmd="sudo"
fi
pipcmd="pip"
if [[ "$(uname)" == "Darwin" ]] ; then
pipcmd="pip3"
fi
# On Linux, with apt installed python / python-pip
# these commands have to be performed with `sudo`!
${sudocmd} ${pipcmd} install --upgrade pip
${sudocmd} ${pipcmd} install --upgrade virtualenv
${sudocmd} ${pipcmd} install -r requirements.txt
mkdocs --version
${pipcmd} show mkdocs-material
up:
steps:
- script:
inputs:
- content: |-
#!/bin/bash
set -ex
mkdocs serve