-
-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: Set HUGO_MODULE_REPLACEMENTS (#358)
- replacements https://gohugo.io/hugo-modules/configuration/ - https://gohugo.io/news/0.77.0-relnotes/
- Loading branch information
Showing
11 changed files
with
1,525 additions
and
1,439 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
HUGO_VERSION=0.83.1 | ||
HUGO_CACHEDIR=~/.hugo_cache | ||
HUGO_MODULE_REPLACEMENTS='replace github.com/peaceiris/hugo-theme-iris -> ../' | ||
BASE_URL=https://hugothemeiris.peaceiris.app |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,9 @@ on: | |
schedule: | ||
- cron: "13 13 * * *" | ||
|
||
env: | ||
HUGO_CACHEDIR: /tmp/hugo_cache | ||
|
||
jobs: | ||
deploy: | ||
runs-on: ubuntu-18.04 | ||
|
@@ -35,7 +38,7 @@ jobs: | |
|
||
- uses: actions/[email protected] | ||
with: | ||
path: /tmp/hugo_cache | ||
path: ${{ env.HUGO_CACHEDIR }} | ||
key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.sum') }} | ||
restore-keys: | | ||
${{ runner.os }}-hugomod- | ||
|
@@ -58,18 +61,11 @@ jobs: | |
timeout-minutes: 1 | ||
|
||
- name: Build | ||
working-directory: ./exampleSite | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
export BASE_URL="https://hugothemeiris.peaceiris.app" | ||
export GH_USER_ID="peaceiris" | ||
bash ./scripts/fetch_data.sh "${GH_USER_ID}" > "./data/github/${GH_USER_ID}.json" | ||
hugo --minify --cleanDestinationDir \ | ||
--themesDir ../../ \ | ||
--baseURL "${BASE_URL}" \ | ||
--i18n-warnings --path-warnings | ||
wget -O ./public/report.html "${BASE_URL}/report.html" || true | ||
make cibuild-prod | ||
- name: Deploy | ||
uses: peaceiris/[email protected] | ||
|
@@ -131,20 +127,17 @@ jobs: | |
|
||
- uses: actions/[email protected] | ||
with: | ||
path: /tmp/hugo_cache | ||
path: ${{ env.HUGO_CACHEDIR }} | ||
key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.sum') }} | ||
restore-keys: | | ||
${{ runner.os }}-hugomod- | ||
- name: Build Testing with Docker | ||
run: | | ||
export HUGO_CACHEDIR=/tmp/hugo_cache | ||
make build | ||
- run: make build | ||
|
||
test-setup: | ||
runs-on: ubuntu-18.04 | ||
timeout-minutes: 2 | ||
if: github.event_name == 'push' || github.event_name == 'pull_request' | ||
if: github.ref == 'refs/heads/main' | ||
strategy: | ||
matrix: | ||
extended: | ||
|
@@ -167,7 +160,7 @@ jobs: | |
|
||
- uses: actions/[email protected] | ||
with: | ||
path: /tmp/hugo_cache | ||
path: ${{ env.HUGO_CACHEDIR }} | ||
key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.sum') }} | ||
restore-keys: | | ||
${{ runner.os }}-hugomod- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
Oops, something went wrong.