From fcb5412e04c236b94a5232db26d7bf10e0acf071 Mon Sep 17 00:00:00 2001 From: usbharu <64310155+usbharu@users.noreply.github.com> Date: Thu, 14 Mar 2024 18:09:45 +0900 Subject: [PATCH] =?UTF-8?q?ci=20=E3=82=92=E6=A7=8B=E6=88=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitea/workflows/build-page.yaml | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .gitea/workflows/build-page.yaml diff --git a/.gitea/workflows/build-page.yaml b/.gitea/workflows/build-page.yaml new file mode 100644 index 0000000..c7e1979 --- /dev/null +++ b/.gitea/workflows/build-page.yaml @@ -0,0 +1,32 @@ +name: github pages + +on: + push: + branches: + - main # Set a branch name to trigger deployment + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + with: + submodules: true # Fetch Hugo themes (true OR recursive) + fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod + + - name: Setup Hugo + uses: peaceiris/actions-hugo@v2 + with: + hugo-version: "0.123.8" + + - name: Build + run: hugo --minify + - name: Publish to Cloudflare Pages + uses: cloudflare/pages-action@v1 + with: + apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} + accountId: 76906b4e38909e314e89939ec9f8e485 + projectName: blog-usbharu + directory: public + # Optional: Enable this if you want to have GitHub Deployments triggered + gitHubToken: ${{ secrets.GITHUB_TOKEN }}