mirror of
https://github.com/Vonng/ddia.git
synced 2026-08-28 17:53:30 +08:00
chore: upgrade OINK and retire GitHub Pages
This commit is contained in:
77
.github/workflows/pages.yaml
vendored
77
.github/workflows/pages.yaml
vendored
@@ -1,77 +0,0 @@
|
||||
# Sample workflow for building and deploying a Hugo site to GitHub Pages
|
||||
name: Deploy Hugo site to Pages
|
||||
|
||||
on:
|
||||
# Runs on pushes targeting the default branch
|
||||
push:
|
||||
branches: ["main"]
|
||||
|
||||
# Allows you to run this workflow manually from the Actions tab
|
||||
workflow_dispatch:
|
||||
|
||||
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
|
||||
permissions:
|
||||
contents: read
|
||||
pages: write
|
||||
id-token: write
|
||||
|
||||
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
|
||||
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
|
||||
concurrency:
|
||||
group: "pages"
|
||||
cancel-in-progress: false
|
||||
|
||||
# Default to bash
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
jobs:
|
||||
# Build job
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
HUGO_VERSION: 0.164.0
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v7
|
||||
with:
|
||||
fetch-depth: 0 # fetch all history for .GitInfo and .Lastmod
|
||||
submodules: recursive
|
||||
- name: Setup Go
|
||||
uses: actions/setup-go@v7
|
||||
with:
|
||||
go-version: '1.26'
|
||||
cache: false
|
||||
- name: Setup Pages
|
||||
id: pages
|
||||
uses: actions/configure-pages@v6
|
||||
- name: Setup Hugo
|
||||
run: |
|
||||
wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \
|
||||
&& sudo dpkg -i ${{ runner.temp }}/hugo.deb
|
||||
- name: Build with Hugo
|
||||
env:
|
||||
# For maximum backward compatibility with Hugo modules
|
||||
HUGO_ENVIRONMENT: production
|
||||
HUGO_ENV: production
|
||||
run: |
|
||||
hugo \
|
||||
--gc --minify \
|
||||
--baseURL "${{ steps.pages.outputs.base_url }}/"
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-pages-artifact@v5
|
||||
with:
|
||||
path: ./public
|
||||
|
||||
# Deployment job
|
||||
deploy:
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deployment.outputs.page_url }}
|
||||
runs-on: ubuntu-latest
|
||||
needs: build
|
||||
steps:
|
||||
- name: Deploy to GitHub Pages
|
||||
id: deployment
|
||||
uses: actions/deploy-pages@v5
|
||||
@@ -10,7 +10,7 @@
|
||||
|
||||
**校订**: [@yingang](https://github.com/yingang) | [**繁體中文**](content/tw/_index.md) by [@afunTW](https://github.com/afunTW) | [完整贡献者列表](#贡献)
|
||||
|
||||
**阅读**:访问 [https://ddia.vonng.com](https://ddia.vonng.com) 阅读本书在线版本,或使用 [Hugo](https://gohugo.io/documentation/) / [OINK 0.4.1](https://oink.pgsty.com/) 主题自行构建。在线版支持稳定图表编号与交叉引用、顺序阅读、整书打印、Markdown / `llms.txt` 输出和 EPUB 导出。
|
||||
**阅读**:访问 [https://ddia.vonng.com](https://ddia.vonng.com) 阅读本书在线版本,或使用 [Hugo](https://gohugo.io/documentation/) / [OINK 0.8.0](https://oink.pgsty.com/) 主题自行构建。在线版支持稳定图表编号与交叉引用、顺序阅读、整书打印、Markdown / `llms.txt` 输出和 EPUB 导出。
|
||||
|
||||
> [!NOTE]
|
||||
> [**DDIA 第二版**](https://ddia.vonng.com) 十四章译文均已上线并持续校订,欢迎阅览并提出宝贵意见。
|
||||
|
||||
4
go.mod
4
go.mod
@@ -1,5 +1,5 @@
|
||||
module github.com/Vonng/ddia
|
||||
|
||||
go 1.26.6
|
||||
go 1.27.0
|
||||
|
||||
require github.com/pgsty/oink v0.7.0 // indirect
|
||||
require github.com/pgsty/oink v0.8.0 // indirect
|
||||
|
||||
6
go.sum
6
go.sum
@@ -1,4 +1,2 @@
|
||||
github.com/pgsty/oink v0.6.1 h1:fsajKQEXat8Tr6uBpC4uwyFXx8XgiQAp960DBEF6ogc=
|
||||
github.com/pgsty/oink v0.6.1/go.mod h1:wHzQR6qVOx5rgkDCvXBZhmsDrAb3O+0CRNBHyIzsYT0=
|
||||
github.com/pgsty/oink v0.7.0 h1:BY0SgsphppMSOsPsGAj/SsFL+wKGATaAIYmVXvvr0Lc=
|
||||
github.com/pgsty/oink v0.7.0/go.mod h1:wHzQR6qVOx5rgkDCvXBZhmsDrAb3O+0CRNBHyIzsYT0=
|
||||
github.com/pgsty/oink v0.8.0 h1:8+dkKYJUAWKjn2/FL256OcNFF896z6p6xcdhUXe4jLk=
|
||||
github.com/pgsty/oink v0.8.0/go.mod h1:pHvbUhJCfseB41n5RGwsF7abT3i32VSTpofLQoq4b7Y=
|
||||
|
||||
Reference in New Issue
Block a user