From 57d920244b2d6cf421f19d0cd66d8f1eb6776c16 Mon Sep 17 00:00:00 2001 From: Cell <1024@lruihao.cn> Date: Mon, 18 Aug 2025 12:51:47 +0800 Subject: [PATCH] :wrench: Chore: update CodeQL configuration, add Hugo test build workflow (#625) --- .github/configs/codeql.yml | 1 - .github/workflows/{build.yml => test.yml} | 4 ++-- CONTRIBUTING.md | 5 ++++- package.json | 1 + test/hugo.toml | 7 +------ 5 files changed, 8 insertions(+), 10 deletions(-) rename .github/workflows/{build.yml => test.yml} (83%) diff --git a/.github/configs/codeql.yml b/.github/configs/codeql.yml index cd53f354..c1c2961e 100644 --- a/.github/configs/codeql.yml +++ b/.github/configs/codeql.yml @@ -2,4 +2,3 @@ name: "CodeQL config" paths-ignore: - assets/lib/** - - docs/** \ No newline at end of file diff --git a/.github/workflows/build.yml b/.github/workflows/test.yml similarity index 83% rename from .github/workflows/build.yml rename to .github/workflows/test.yml index 3648003f..4f6328d9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/test.yml @@ -1,4 +1,4 @@ -name: Hugo build check +name: FixIt Test Build on: pull_request: branches: [ main ] @@ -18,4 +18,4 @@ jobs: hugo-version: ${{ vars.HUGO_VERSION || 'latest' }} extended: true - name: Build Hugo static files - run: hugo --source=demo --gc --minify --logLevel info + run: hugo --source=test --themesDir ../.. --theme $PWD --gc --minify --logLevel info diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 6a68efcc..cc48a74a 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -70,8 +70,11 @@ pnpm test:production ### Building ```bash -# Build the theme (production build with minification) +# Build demo site pnpm build + +# Build test site +pnpm build:test ``` ## Project Structure diff --git a/package.json b/package.json index 3e6b2eb6..267d52b5 100644 --- a/package.json +++ b/package.json @@ -22,6 +22,7 @@ "type": "module", "scripts": { "build": "hugo --source=demo --themesDir ../.. --theme $PWD --gc --minify --logLevel info", + "build:test": "hugo --source=test --themesDir ../.. --theme $PWD --gc --minify --logLevel info", "server": "hugo server --source=demo --themesDir ../.. --theme $PWD -D --disableFastRender --navigateToChanged --ignoreCache -O", "server:production": "npm run server -- -e production", "server:docs": "hugo server --source=../fixit-docs -D --disableFastRender --navigateToChanged --ignoreCache -O", diff --git a/test/hugo.toml b/test/hugo.toml index 61c5f1e4..3f24a0dc 100644 --- a/test/hugo.toml +++ b/test/hugo.toml @@ -1,15 +1,10 @@ -# ===================================================================================== -# The following is a necessary configuration for the FixIt theme. -# ===================================================================================== - # ------------------------------------------------------------------------------------- # Hugo Configuration # See: https://gohugo.io/getting-started/configuration/ # ------------------------------------------------------------------------------------- -title = "Hugo FixIt Demo" +title = "Hugo FixIt TEST" baseURL = "http://example.org/" -# theme = "FixIt" [markup] _merge = "shallow"