diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml new file mode 100644 index 00000000..08aece89 --- /dev/null +++ b/.github/workflows/preview.yml @@ -0,0 +1,38 @@ +name: Build and Deploy Preview environment on Vercel +on: + pull_request: + branches: ['main'] + +jobs: + deploy-job: + runs-on: ubuntu-latest + + # Update the "Preview" environment with the Vercel deployed URL + environment: + name: Preview + url: ${{ steps.vercel-deploy.outputs.deployment_url }} + + steps: + - uses: actions/setup-node@v4 + - uses: actions/checkout@v4 + - id: vercel-deploy + run: | + npx -y vercel deploy --target=preview --token=${{ secrets.VERCEL_TOKEN }} \ + --build-env MDX=docs \ + --build-env NEXT_PUBLIC_LIBNAME="Poimandres" \ + --build-env NEXT_PUBLIC_LIBNAME_SHORT="pmndrs" \ + --build-env BASE_PATH= \ + --build-env DIST_DIR= \ + --build-env OUTPUT=export \ + --build-env HOME_REDIRECT=/introduction \ + --build-env MDX_BASEURL="https://github.com/${{ github.repository }}/raw/${{ github.head_ref }}/docs" \ + --build-env EDIT_BASEURL="https://github.com/${{ github.repository }}/edit/${{ github.head_ref }}/docs" \ + --build-env NEXT_PUBLIC_URL="$VERCEL_PROJECT_PRODUCTION_URL" \ + --build-env ICON="🖨️" \ + --build-env LOGO=gutenberg.jpg \ + > deployment-url.txt + + echo "deployment_url=$(cat deployment-url.txt)" >> $GITHUB_OUTPUT + env: + VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }} + VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }} diff --git a/docs/gutenberg.jpg b/docs/gutenberg.jpg new file mode 100644 index 00000000..0aee5e11 Binary files /dev/null and b/docs/gutenberg.jpg differ diff --git a/docs/introduction.mdx b/docs/introduction.mdx new file mode 100644 index 00000000..1f4731ba --- /dev/null +++ b/docs/introduction.mdx @@ -0,0 +1,10 @@ +--- +title: Poimandres documentation +description: A documentation generator for `pmndrs/*` projects. +--- + +![](gutenberg.jpg) + +## Heading 1 + +TODO