From 51d7de5ab8c50443c9a4f77ba0461a09dfb8689c Mon Sep 17 00:00:00 2001 From: michalrozekariane Date: Mon, 18 Mar 2024 15:52:27 +0100 Subject: [PATCH] feat: add deploy config Signed-off-by: michalrozekariane --- .github/workflows/deploy.yml | 29 +++++++++++++++++++++++++++++ vite.config.ts | 1 + 2 files changed, 30 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..a88c2e7 --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,29 @@ +name: Deploy to GitHub Pages + +on: + push: + branches: + - main + +jobs: + build-and-deploy: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - name: Setup Node + uses: actions/setup-node@v2 + with: + node-version: '21' + + - name: Install dependencies + run: pnpm install + + - name: Build + run: pnpm run build + + - name: Deploy + uses: JamesIves/github-pages-deploy-action@4.1.4 + with: + branch: gh-pages + folder: dist \ No newline at end of file diff --git a/vite.config.ts b/vite.config.ts index 526bd8c..b27fb06 100755 --- a/vite.config.ts +++ b/vite.config.ts @@ -5,6 +5,7 @@ import * as path from 'path'; // https://vitejs.dev/config/ export default defineConfig({ plugins: [react()], + base: '/airdrop-list-builder/', resolve: { alias: { '@': path.resolve(__dirname, './src'),