A Astro blog hosted on Vercel

rework deployment action

Changed files
+27 -39
.tangled
+26
.tangled/workflows/deploy.yaml
··· 1 + name: Deploy to Vercel 2 + 3 + when: 4 + - event: ["push", "pull_request"] 5 + branch: ["main"] 6 + 7 + dependencies: 8 + nixpkgs: 9 + - nodejs 10 + 11 + steps: 12 + - name: Install dependencies 13 + command: npm ci 14 + 15 + - name: Build project 16 + command: npm run build 17 + 18 + - name: Deploy to Vercel 19 + env: 20 + VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }} 21 + VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }} 22 + VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }} 23 + command: | 24 + npx vercel pull --yes --environment=production --token=$VERCEL_TOKEN 25 + npx vercel build --prod --token=$VERCEL_TOKEN 26 + npx vercel deploy --prebuilt --prod --token=$VERCEL_TOKEN
-35
.tangled/workflows/deploy.yml
··· 1 - name: Deploy to Vercel 2 - 3 - on: 4 - push: 5 - branches: 6 - - main 7 - 8 - jobs: 9 - deploy: 10 - runs-on: ubuntu-latest 11 - steps: 12 - - name: Checkout repository 13 - uses: actions/checkout@v4 14 - 15 - - name: Setup Node.js 16 - uses: actions/setup-node@v4 17 - with: 18 - node-version: "22" 19 - cache: "npm" 20 - 21 - - name: Install dependencies 22 - run: npm ci 23 - 24 - - name: Build project 25 - run: npm run build 26 - 27 - - name: Deploy to Vercel 28 - env: 29 - VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }} 30 - VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }} 31 - VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }} 32 - run: | 33 - npx vercel pull --yes --environment=production --token=$VERCEL_TOKEN 34 - npx vercel build --prod --token=$VERCEL_TOKEN 35 - npx vercel deploy --prebuilt --prod --token=$VERCEL_TOKEN
+1 -4
package.json
··· 6 6 "dev": "astro dev", 7 7 "build": "astro build", 8 8 "preview": "astro preview", 9 - "astro": "astro", 10 - "vercel-login": "vercel login", 11 - "deploy": "vercel --prod", 12 - "vercel-env": "vercel env" 9 + "astro": "astro" 13 10 }, 14 11 "dependencies": { 15 12 "@astrojs/mdx": "^4.3.4",