diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 00000000..dc3dbceb --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,32 @@ +name: CI +on: + push: + branches: + - main + +jobs: + deploy: + runs-on: ubuntu-latest + concurrency: + group: ${{ github.workflow }} + steps: + - name: Git checkout + uses: actions/checkout@v3 + with: + fetch-depth: 0 + + - name: Setup hugo + uses: peaceiris/actions-hugo@v2 + with: + hugo-version: '0.104.3' + extended: true + + - name: Build + run: hugo --minify + + - name: Deploy + uses: peaceiris/actions-gh-pages@v3 + with: + personal_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./public + cname: www.byjp.me