Skip to content

Commit 8ed0e68

Browse files
committed
try to only generate docs on master branch
1 parent 5e00c72 commit 8ed0e68

File tree

1 file changed

+26
-16
lines changed

1 file changed

+26
-16
lines changed

.github/workflows/CI.yml

Lines changed: 26 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,13 @@
11
name: CI
2-
32
on: [push]
4-
53
jobs:
64
Build:
75
runs-on: ${{ matrix.os }}
86
strategy:
97
fail-fast: false
108
matrix:
119
os: [ubuntu-latest]
12-
gcc_v: [9, 10] # Version of GFortran we want to use.
10+
gcc_v: [9] # Version of GFortran we want to use.
1311
env:
1412
FC: gfortran-${{ matrix.gcc_v }}
1513
GCC_V: ${{ matrix.gcc_v }}
@@ -18,19 +16,6 @@ jobs:
1816
- name: Checkout code
1917
uses: actions/checkout@v1
2018

21-
- name: Set up Python 3.x
22-
uses: actions/setup-python@v1 # Use pip to install latest CMake, & FORD/Jin2For, etc.
23-
with:
24-
python-version: 3.x
25-
26-
- name: Install other tools
27-
if: contains( matrix.os, 'ubuntu')
28-
run: |
29-
sudo apt-get install graphviz
30-
sudo -H pip install numpy
31-
sudo -H pip install ford && ford --version
32-
sudo -H pip install matplotlib
33-
3419
- name: Install GFortran Linux
3520
if: contains( matrix.os, 'ubuntu')
3621
run: |
@@ -49,6 +34,31 @@ jobs:
4934
- name: Run test
5035
run: ./bin/test
5136

37+
name: Build and Deploy Documentation
38+
on:
39+
push:
40+
branches:
41+
- master
42+
jobs:
43+
build-and-deploy:
44+
runs-on: ubuntu-latest
45+
steps:
46+
- name: Checkout code
47+
uses: actions/checkout@v1
48+
49+
- name: Set up Python 3.x
50+
uses: actions/setup-python@v1 # Use pip to install latest CMake, & FORD/Jin2For, etc.
51+
with:
52+
python-version: 3.x
53+
54+
- name: Install other tools
55+
if: contains( matrix.os, 'ubuntu')
56+
run: |
57+
sudo apt-get install graphviz
58+
sudo -H pip install numpy
59+
sudo -H pip install ford && ford --version
60+
sudo -H pip install matplotlib
61+
5262
- name: Build documentation
5363
run: ford ./pyplot-fortran.md
5464

0 commit comments

Comments
 (0)