Skip to content

Commit 51963e1

Browse files
committed
github action script revised (again)
1 parent 08be2db commit 51963e1

File tree

1 file changed

+25
-5
lines changed

1 file changed

+25
-5
lines changed

.github/workflows/pluto_export.yml

Lines changed: 25 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,42 @@
1-
name: Pluto Export
1+
name: Pluto Interactive Export
22
on:
33
push:
44
branches: [main]
5+
56
jobs:
67
build-and-deploy:
78
runs-on: ubuntu-latest
89
steps:
9-
- name: Checkout
10+
- name: Checkout Repo
1011
uses: actions/checkout@v4
12+
1113
- name: Install Julia
1214
uses: julia-actions/setup-julia@v2
1315
with:
1416
version: '1.11'
15-
- name: Run PlutoSliderServer
17+
18+
- name: Install Packages and Export All Notebooks
1619
run: |
17-
julia -e 'using Pkg; Pkg.add("PlutoSliderServer"); using PlutoSliderServer; export_notebook("Taylor_Polynome.jl")'
20+
julia -e '
21+
using Pkg
22+
# Activate the environment and install dependencies from Project.toml
23+
Pkg.activate(".")
24+
Pkg.instantiate()
25+
26+
using PlutoSliderServer
27+
28+
# Loop through all files to find Julia notebooks
29+
for file in readdir()
30+
if endswith(file, ".jl")
31+
println("Exporting $file...")
32+
# save_everystep = false prevents creating huge state files
33+
export_notebook(file; save_everystep = false)
34+
end
35+
end
36+
'
37+
1838
- name: Deploy to GitHub Pages
1939
uses: JamesIves/github-pages-deploy-action@v4
2040
with:
2141
folder: .
22-
branch: gh-pages # Erstellt einen extra Zweig für die Webseite
42+
branch: gh-pages

0 commit comments

Comments
 (0)