@@ -10,18 +10,18 @@ jobs:
10
10
Build-website :
11
11
runs-on : ubuntu-latest
12
12
steps :
13
- - uses : actions/checkout@v2
13
+ - uses : actions/checkout@v4
14
14
# Adds keys to work with other repositories used in this lesson (e.g., UCL/github-example)
15
- - uses : webfactory/ssh-agent@v0.5.4
15
+ - uses : webfactory/ssh-agent@v0.9.0
16
16
with :
17
17
ssh-private-key : ${{ secrets.SSH_PRIVATE_KEY }}
18
- - uses : actions/cache@v2 # FIXME: add apt(latex)
18
+ - uses : actions/cache@v4 # FIXME: add apt(latex)
19
19
with :
20
20
path : vendor/bundle
21
21
key : ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile') }}
22
22
restore-keys : |
23
23
${{ runner.os }}-gems-
24
- - uses : actions/cache@v2
24
+ - uses : actions/cache@v4
25
25
with :
26
26
path : ~/.cache/pip
27
27
key : ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt', '.github/python/requirements.txt') }}
@@ -31,23 +31,30 @@ jobs:
31
31
32
32
- id : setup-python
33
33
name : Setup Python
34
- uses : actions/setup-python@v2
34
+ uses : actions/setup-python@v5
35
35
with :
36
- python-version : 3.8
36
+ python-version : 3.12
37
37
- name : Install dependencies
38
- uses : py-actions/py-dependency-install@v2
39
- with :
40
- path : " .github/python/requirements.txt"
38
+ run : python -m pip install -r .github/python/requirements.txt
41
39
- name : Building notes
42
40
run : make ready
43
- - name : Builds website
44
- uses : helaili/jekyll-action@v2
41
+ - uses : ruby/setup-ruby@v1
45
42
with :
46
- target_branch : ' gh-pages'
47
- build_only : true
48
- - name : Build website and deploy
49
- if : github.ref == 'refs/heads/main'
50
- uses : helaili/jekyll-action@v2
43
+ ruby-version : ' 3.3'
44
+ - name : Install bundler and dependencies
45
+ run : |
46
+ gem install bundler
47
+ bundle install
48
+ - name : Build website
49
+ run : bundle exec jekyll build
50
+ - name : Upload artifact
51
+ uses : actions/upload-pages-artifact@v3
51
52
with :
52
- target_branch : ' gh-pages'
53
- token : ${{ secrets.GITHUB_TOKEN }}
53
+ path : _site
54
+ - name : Deploy to GitHub Pages
55
+ if : >
56
+ success()
57
+ && github.ref == 'refs/heads/main'
58
+ && github.repository == 'UCL/rsd-engineeringcourse'
59
+ id : deployment
60
+ uses : actions/deploy-pages@v4
0 commit comments