diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 856a40281..96f6bff2f 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -6,7 +6,7 @@ on: - main permissions: - contents: read + contents: write jobs: deploy: @@ -19,24 +19,24 @@ jobs: with: fetch-depth: 2 - uses: ./.github/actions/setup-project - # - name: Set up Node.js - # uses: actions/setup-node@v3 - # with: - # node-version: '20.15.1' - # - name: Install dependencies - # run: npm ci - # - name: Build Svelte App - # run: npm run build - # - name: Commit build artifacts - # # env: - # # GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }} # Use PAT_TOKEN secret for authentication - # run: | - # git config --global user.name 'github-actions[bot]' - # git config --global user.email 'github-actions[bot]@users.noreply.github.com' - # git remote set-url origin https://x-access-token:${GITHUB_TOKEN}@github.com/${{ github.repository }} - # git add -f build/ # Force add the build directory - # git commit -m 'Add build artifacts for deployment' || echo "No changes to commit" - # git push + - name: Set up Node.js + uses: actions/setup-node@v3 + with: + node-version: '20.15.1' + - name: Install dependencies + run: npm ci + - name: Build Svelte App + run: npm run build + - name: Commit build artifacts + # env: + # GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }} # Use PAT_TOKEN secret for authentication + run: | + git config --global user.name 'github-actions[bot]' + git config --global user.email 'github-actions[bot]@users.noreply.github.com' + git remote set-url origin https://x-access-token:${GITHUB_TOKEN}@github.com/${{ github.repository }} + git add -f build/ # Force add the build directory + git commit -m 'Add build artifacts for deployment' || echo "No changes to commit" + git push - name: Deploy to cloud.gov uses: 18f/cg-deploy-action@main env: