diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml new file mode 100644 index 0000000..75030fa --- /dev/null +++ b/.github/workflows/deploy-docs.yml @@ -0,0 +1,37 @@ +name: Deploy Docs to GitHub Pages + +on: + # Trigger the workflow every time you push to the `main` branch + # Using a different branch name? Replace `main` with your branch’s name + push: + branches: [ main ] + # Allows you to run this workflow manually from the Actions tab on GitHub. + workflow_dispatch: + +# Allow this job to clone the repo and create a page deployment +permissions: + contents: read + pages: write + id-token: write + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Checkout your repository using git + uses: actions/checkout@v4 + - name: Install, build, and upload your site + uses: withastro/action@v3 + with: + path: ./docs/ + + deploy: + needs: build + runs-on: ubuntu-latest + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v4 diff --git a/docs/astro.config.mjs b/docs/astro.config.mjs index 0f45b2b..b38ee89 100644 --- a/docs/astro.config.mjs +++ b/docs/astro.config.mjs @@ -4,6 +4,8 @@ import starlight from '@astrojs/starlight'; // https://astro.build/config export default defineConfig({ + site: 'https://cruncher.iamshobe.com', + base: '/docs/', integrations: [ starlight({ title: 'Cruncher', diff --git a/docs/public/CNAME b/docs/public/CNAME new file mode 100644 index 0000000..463166e --- /dev/null +++ b/docs/public/CNAME @@ -0,0 +1 @@ +cruncher.iamshobe.com \ No newline at end of file