mirror of
https://github.com/tiennm99/blog.git
synced 2026-10-11 12:09:02 +00:00
ci: skip Pagefind step when no HTML pages exist yet
This commit is contained in:
1 parent
fb0c9e1248
commit
1112fdf039
1 file changed
+6
-1
+6
-1
@@ -45,7 +45,12 @@ jobs:
|
||||
run: hugo --gc --minify --baseURL "https://tiennm99.github.io/tsuki/"
|
||||
|
||||
- name: Build Pagefind index
|
||||
run: npx pagefind --site exampleSite/public
|
||||
run: |
|
||||
if find exampleSite/public -name "*.html" -type f | head -1 | grep -q .; then
|
||||
npx pagefind --site exampleSite/public
|
||||
else
|
||||
echo "No HTML files found yet (layouts not implemented). Skipping Pagefind."
|
||||
fi
|
||||
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-pages-artifact@v3
|
||||
|
||||
Reference in new issue
Block a user