55 branches :
66 - main
77
8+ env :
9+ LATEST_VERSION : 3.0.18
10+
811jobs :
912 build :
1013 name : Publish site
@@ -13,14 +16,40 @@ jobs:
1316 steps :
1417 - name : Checkout
1518 uses : actions/checkout@v4
16- - name : Build and Deploy
19+ - name : Replace version name
20+ env :
21+ GH_TOKEN : ${{ github.token }}
22+ run : |
23+ sed -i "s#v0\.19\.2#${{ env.LATEST_VERSION }}#g" content/_index.md
24+ export GITHUB_PAGES_URL=$(gh api "repos/${{ github.repository }}/pages" --jq '.html_url')
25+ sed -i "s#https:\/\/libical\.github\.io#${GITHUB_PAGES_URL}#g" config.toml
26+ export GITHUB_CODE_WEBSITE="${{ github.server_url }}/${{ github.repository }}"
27+ sed -i "s#https:\/\/github.com\/libical\/libical.github.io#${GITHUB_CODE_WEBSITE}#g" config.toml
28+ - name : Build website
1729 uses : shalzz/zola-deploy-action@v0.19.2
1830 env :
1931 BUILD_ONLY : true
32+ - name : Checkout libical v${{ env.LATEST_VERSION }}
33+ uses : actions/checkout@v4
34+ with :
35+ repository : libical/libical
36+ ref : v${{ env.LATEST_VERSION }}
37+ path : libical-sources
38+ - name : Install dependencies
39+ run : sudo apt-get -y install gtk-doc-tools xml-core libdb-dev gobject-introspection libgirepository1.0-dev cmake ninja-build doxygen graphviz
40+ - name : Configure libical
41+ run : |
42+ cd libical-sources
43+ mkdir build
44+ cmake -B build -G Ninja -DENABLE_GTK_DOC=True -DICAL_GLIB=True -DGOBJECT_INTROSPECTION=True -DICAL_BUILD_DOCS=True
45+ - name : Build libical documentation
46+ run : |
47+ cd libical-sources
48+ cmake --build build --target docs
2049 - name : Move Documentation
2150 run : |
2251 sudo rm -R public/docs/developer/libical
23- sudo mv public/ apidocs public/docs/developer/libical
52+ sudo mv libical-sources/build/ apidocs/html public/docs/developer/libical
2453 sudo rm -R public/docs/developer/libical-glib
2554 sudo mv public/libical-glib public/docs/developer/libical-glib
2655 - name : Upload Artifact
0 commit comments