cotes2020/jekyll-theme-chirpy에 포스팅을 하는 중
github ACTION tab에서 자꾸 page build error가 발생했다.
jekyll-theme-chirpy 설명서를 보면 배포할 때 master branch로 push하면 자동으로 gh-pages가 생성될 것이라 나오는데 나의 경우 _config.yml파일에 문제가 있어서 계속 배포가 되지 않고 있었다.
1
2
3
4
5
6
7
8
9
10
#### Deploy on GitHub Pages
For security reasons, GitHub Pages build runs on `safe` mode, which restricts us from using plugins to generate additional page files. Therefore, we can use **GitHub Actions** to build the site, store the built site files on a new branch, and use that branch as the source of the Pages service.
1. Push any commit to `origin/master` to trigger the GitHub Actions workflow. Once the build is complete and successful, a new remote branch named `gh-pages` will appear to store the built site files.
2. Browse to your repo's landing page on GitHub and select the branch `gh-pages` as the [publishing source](https://docs.github.com/en/github/working-with-github-pages/configuring-a-publishing-source-for-your-github-pages-site) throught _Settings_ → _Options_ → _GitHub Pages_:
![gh-pages-sources](https://raw.githubusercontent.com/cotes2020/jekyll-theme-chirpy/master/assets/img/sample/gh-pages-sources.png)
3. Visit your website at the address indicated by GitHub.
ruby를 몰라 어디서부터 손을 대야할지 막막해서 repository를 하나 더 만들어서 css의 module를 못읽고 있다는 error 메세지를 발견하고 _config.yml파일에서 아래 부분을 건드린 게 문제였다는 것을 발견했다.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
sass:
sass_dir: /assets/css
style: compressed
compress_html:
clippings: all
comments: all
endings: all
profile: false
blanklines: false
ignore:
envs: []
exclude:
- vendor
- Gemfile.lock
- Gemfile
- tools
- docs
- README.md
- LICENSE
jekyll-archives:
enabled: [categories, tags]
layouts:
category: category
tag: tag
permalinks:
tag: /tags/:name/
category: /categories/:name/
_posts 폴더에서도 에러가 나자 yml파일의 경우 띄어쓰기가 잘못되도 에러가 난다는 블로그 글을 읽고 아예 파일을 새로 가져왔더니 에러가 자동으로 해결되고 배포까지 성공했다!!