Skip to content

Commit 52bda43

Browse files
authored
Merge pull request #56 from dscho/hugo
Migrate to Hugo
2 parents 9d6731d + c7866b6 commit 52bda43

File tree

80 files changed

+413
-2966
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

80 files changed

+413
-2966
lines changed

.github/workflows/deploy.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Deploy to Pages
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
concurrency:
15+
group: "pages"
16+
cancel-in-progress: false
17+
18+
jobs:
19+
deploy:
20+
runs-on: ubuntu-latest
21+
environment:
22+
name: github-pages
23+
url: ${{ steps.deployment.outputs.page_url }}
24+
steps:
25+
- uses: actions/checkout@v4
26+
- name: configure Hugo
27+
run: |
28+
set -x &&
29+
echo "HUGO_VERSION=$(sed -n 's/^ *hugo_version: *//p' <hugo.yml)" >>$GITHUB_ENV
30+
- name: install Hugo ${{ env.HUGO_VERSION }}
31+
run: |
32+
set -x &&
33+
deb=hugo_extended_${HUGO_VERSION}_linux-amd64.deb &&
34+
curl -LO https://github.com/gohugoio/hugo/releases/download/v$HUGO_VERSION/$deb &&
35+
sudo dpkg -i $deb
36+
- uses: actions/configure-pages@v5
37+
id: pages
38+
- name: run Hugo to build the pages
39+
env:
40+
HUGO_CACHEDIR: ${{ runner.temp }}/hugo_cache
41+
HUGO_ENVIRONMENT: production
42+
HUGO_RELATIVEURLS: false
43+
run: hugo config && hugo --minify --baseURL '${{ steps.pages.outputs.base_url }}/'
44+
- uses: actions/upload-pages-artifact@v3
45+
with:
46+
path: ./public
47+
- uses: actions/deploy-pages@v4
48+
id: deployment

.github/workflows/pr.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Hugo
2+
on: [pull_request]
3+
4+
jobs:
5+
build:
6+
runs-on: ubuntu-latest
7+
steps:
8+
- uses: actions/checkout@v4
9+
- name: configure Hugo
10+
run: |
11+
set -x &&
12+
echo "HUGO_VERSION=$(sed -n 's/^ *hugo_version: *//p' <hugo.yml)" >>$GITHUB_ENV
13+
- name: install Hugo ${{ env.HUGO_VERSION }}
14+
run: |
15+
set -x &&
16+
curl -Lo /tmp/hugo.deb https://github.com/gohugoio/hugo/releases/download/v$HUGO_VERSION/hugo_extended_${HUGO_VERSION}_linux-amd64.deb &&
17+
sudo dpkg -i /tmp/hugo.deb
18+
- name: run Hugo to build the pages
19+
run: hugo
20+
- name: build tar archive
21+
run: cd public && tar czvf ../pages.tar.gz *
22+
- name: Upload build artifact
23+
uses: actions/upload-artifact@v4
24+
with:
25+
name: pages
26+
path: pages.tar.gz

.gitignore

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
1-
/node_modules/
2-
/npm-debug.log
1+
/.hugo_build.lock
2+
/public/
3+
/resources/_gen/

32-bit.html

Lines changed: 0 additions & 82 deletions
This file was deleted.

Gruntfile.js

Lines changed: 0 additions & 84 deletions
This file was deleted.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)