File tree Expand file tree Collapse file tree 4 files changed +74
-4
lines changed
Expand file tree Collapse file tree 4 files changed +74
-4
lines changed Original file line number Diff line number Diff line change 1717 build :
1818 name : Build Jekyll
1919 runs-on : ubuntu-latest
20+ env :
21+ TMPDIR : /home/runner/work/tmp
2022 steps :
21- - name : Checkout
23+ - name : Checkout theme
2224 uses : actions/checkout@v4
25+ with :
26+ repository : LizardByte/LizardByte.github.io
27+ ref : ${{ github.repository == 'LizardByte/LizardByte.github.io' && github.ref || 'master' }}
28+ submodules : recursive
29+ path : theme
30+
31+ - name : Checkout project
32+ if : ${{ github.repository != 'LizardByte/LizardByte.github.io' }}
33+ uses : actions/checkout@v4
34+ with :
35+ path : project
36+
37+ - name : Setup project
38+ if : ${{ github.repository == 'LizardByte/LizardByte.github.io' }}
39+ run : |
40+ mkdir -p ${TMPDIR}
41+ mkdir -p ./project
42+ cp -r ./theme ./project/
43+ rm -rf ./project/third-party
44+
45+ - name : Create site
46+ run : |
47+ base_dirs=(
48+ ./theme/third-party/beautiful-jekyll
49+ ./theme
50+ )
51+
52+ targets=(
53+ *.gemspec
54+ _data
55+ _includes
56+ _layouts
57+ _sass
58+ assets
59+ 404.html
60+ _config.yml
61+ favicon.ico
62+ feed.xml
63+ Gemfile
64+ staticman.yml
65+ tags.html
66+ )
67+
68+ for base_dir in "${base_dirs[@]}"; do
69+ for target in "${targets[@]}"; do
70+ if [ -e "$base_dir/$target" ]; then
71+ cp -rf "$base_dir/$target" ${TMPDIR}/
72+ fi
73+ done
74+ done
75+
76+ # copy project directory, they should only come from the project repo
77+ cp -rf ./project/ ${TMPDIR}/
78+
79+ # remove the workspace
80+ cd ..
81+ rm -rf ${GITHUB_WORKSPACE}
82+
83+ # move the temporary directory to the workspace
84+ mv ${TMPDIR} ${GITHUB_WORKSPACE}
85+ cd ${GITHUB_WORKSPACE}
86+
87+ # debug contents recursively
88+ ls -Ra
2389
2490 - name : Setup Ruby
2591 uses : ruby/setup-ruby@v1
Original file line number Diff line number Diff line change 1+ [submodule "third-party/beautiful-jekyll "]
2+ path = third-party/beautiful-jekyll
3+ url = https://github.com/daattali/beautiful-jekyll.git
4+ branch = master
Original file line number Diff line number Diff line change 1111# ###########################
1212
1313# https://beautifuljekyll.com/getstarted/#method-1-github-repository-with-remote_theme
14- # remote_theme: daattali/beautiful-jekyll@6.0.1
15- remote_theme : daattali/beautiful-jekyll@b1b667e372acf5f602cca6fee64dd850af70f3da
16- # TODO: move to LizardByte fork, with customizations specific to our site
14+ # remote_theme: daattali/beautiful-jekyll
15+ # Our custom workflow will handle setting up the theme. E.g. combining beautifuljekyll with our customizations.
1716
1817# Name of website
1918title : LizardByte
You can’t perform that action at this time.
0 commit comments