From 5b68ecc8c32e02e0ad03196268466b31b7c0f7b0 Mon Sep 17 00:00:00 2001 From: baegteun Date: Mon, 13 Feb 2023 20:55:21 +0900 Subject: [PATCH] :construction_worker: :: Github Pages Deploy --- .github/workflows/deploy.yml | 46 ++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 .github/workflows/deploy.yml diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 0000000..ba26f62 --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,46 @@ +name: Github Pages + +on: + push: + branches: + - "master" + +jobs: + deploy: + runs-on: macos-12 + strategy: + matrix: + swift: ["5.7"] + steps: + - uses: actions/checkout@v2 + + - name: Setup Webber + run: brew install swifweb/tap/webber + + - name: Release Webber + run: webber release + + - name: Config Git + run: | + git config --global user.name 'baekteun' + git config --global user.email 'baegteun@gmail.com' + git config pull.rebase false + git checkout -t origin/gh-pages + git pull origin gh-pages + git merge master + + - name: Remove Prev Web + run: | + rm -rf ./docs + + - name: Result move to docs + run: | + mv .webber/release/ . + mv release docs + + - name: git commit & push + run: | + git add -A + git commit -m ":rocket: :: github pages deploy" + git push +