Skip to content

Commit f8c2d55

Browse files
committed
fix: set working directory for Jekyll build
1 parent d9f6c35 commit f8c2d55

File tree

1 file changed

+15
-16
lines changed

1 file changed

+15
-16
lines changed

.github/workflows/pages.yml

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -34,22 +34,21 @@ jobs:
3434
bundle install --jobs 4
3535
3636
- name: Build Jekyll (branch-aware)
37-
run: |
38-
if [ "${GITHUB_REF_NAME}" = "main" ]; then
39-
echo "Building production"
40-
bundle exec jekyll build --trace \
41-
--source docs \
42-
--destination docs/_site \
43-
--config docs/_config.yml,docs/_config.prod.yml
44-
echo "nhstech.uk" > docs/_site/CNAME
45-
else
46-
echo "Building staging"
47-
bundle exec jekyll build --trace \
48-
--source docs \
49-
--destination docs/_site \
50-
--config docs/_config.yml,docs/_config.staging.yml
51-
echo "staging.nhstech.uk" > docs/_site/CNAME
52-
fi
37+
working-directory: docs
38+
run: |
39+
if [ "${GITHUB_REF_NAME}" = "main" ]; then
40+
echo "Building production"
41+
bundle exec jekyll build --trace \
42+
--destination _site \
43+
--config _config.yml,_config.prod.yml
44+
echo "nhstech.uk" > _site/CNAME
45+
else
46+
echo "Building staging"
47+
bundle exec jekyll build --trace \
48+
--destination _site \
49+
--config _config.yml,_config.staging.yml
50+
echo "staging.nhstech.uk" > _site/CNAME
51+
fi
5352
5453
- name: Upload Pages artifact
5554
uses: actions/upload-pages-artifact@v3

0 commit comments

Comments
 (0)