|
1 |
| -name: Build and Deploy |
| 1 | +name: Deploy |
| 2 | + |
2 | 3 | on:
|
3 | 4 | push:
|
4 | 5 | branches:
|
5 | 6 | - main
|
6 |
| - - master |
| 7 | + |
7 | 8 | jobs:
|
8 |
| - build-and-deploy: |
| 9 | + deploy: |
9 | 10 | runs-on: ubuntu-latest
|
| 11 | + permissions: write-all |
10 | 12 | steps:
|
11 |
| - - name: Checkout |
12 |
| - uses: actions/checkout@v2 |
13 |
| - with: |
14 |
| - persist-credentials: false |
15 |
| - # NOTE: Python is necessary for the pre-rendering (minification) step |
16 |
| - - name: Install python |
17 |
| - uses: actions/setup-python@v2 |
18 |
| - with: |
19 |
| - python-version: '3.8' |
20 |
| - # NOTE: Here you can install dependencies such as matplotlib if you use |
21 |
| - # packages such as PyPlot. |
22 |
| - # - run: pip install matplotlib |
23 |
| - - name: Install Julia |
24 |
| - uses: julia-actions/setup-julia@v1 |
25 |
| - with: |
26 |
| - version: 1.6 |
27 |
| - # NOTE |
28 |
| - # The steps below ensure that NodeJS and Franklin are loaded then it |
29 |
| - # installs highlight.js which is needed for the prerendering step |
30 |
| - # (code highlighting + katex prerendering). |
31 |
| - # Then the environment is activated and instantiated to install all |
32 |
| - # Julia packages which may be required to successfully build your site. |
33 |
| - # The last line should be `optimize()` though you may want to give it |
34 |
| - # specific arguments, see the documentation or ?optimize in the REPL. |
35 |
| - - run: julia -e ' |
36 |
| - using Pkg; Pkg.activate("."); Pkg.instantiate(); |
37 |
| - using NodeJS; run(`$(npm_cmd()) install highlight.js`); |
38 |
| - using Franklin; |
39 |
| - optimize()' |
40 |
| - - name: Build and Deploy |
41 |
| - uses: JamesIves/github-pages-deploy-action@releases/v3 |
42 |
| - with: |
43 |
| - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
44 |
| - BRANCH: gh-pages |
45 |
| - FOLDER: __site |
| 13 | + - uses: actions/checkout@v2 |
| 14 | + - uses: tlienart/[email protected] |
| 15 | + with: |
| 16 | + # NOTE: this is the Xranklin branch the site is built with |
| 17 | + BRANCH: "dev" |
| 18 | + # NOTE: this is the base URL prefix (landing page at /$BASE_URL_PREFIX/) |
| 19 | + BASE_URL_PREFIX: "juliaparallel-xr" |
| 20 | + |
| 21 | + # =================================================================== |
| 22 | + # DON'T CHANGE THE FOLLOWING UNLESS YOU HAVE GOOD REASONS TO |
| 23 | + # >> amounts to build(clear=true) when commit message contains [clear] |
| 24 | + CLEAR_CACHE: ${{ contains(github.event.head_commit.message, '[clear]') }} |
| 25 | + # >> change the digit at the end if, for some reason, you believe |
| 26 | + # that the cache used by the github action has an issue |
| 27 | + CACHE_KEY: "franklin-cache" |
0 commit comments