Repository navigation
docs: add guidance for pasted tables #155
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Remove PR Preview | ||
|
Check warning on line 1 in .github/workflows/pr-preview-cleanup.yml
|
||
| on: | ||
| pull_request_target: | ||
| types: [closed] | ||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
| concurrency: | ||
| group: pr-cleanup-${{ github.event.pull_request.number }} | ||
| cancel-in-progress: false | ||
| jobs: | ||
| cleanup: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Checkout repository | ||
| uses: actions/checkout@v4 | ||
| - name: Create empty deploy folder | ||
| run: mkdir -p empty | ||
| - name: Remove PR Preview folder using GitHub Pages Deploy Action | ||
| uses: JamesIves/github-pages-deploy-action@v4 | ||
| with: | ||
| branch: gh-pages | ||
| folder: ./empty | ||
| target-folder: pr-preview/pr-${{ github.event.pull_request.number }} | ||
| token: ${{ secrets.GITHUB_TOKEN }} | ||
| clean: true | ||
| - name: Get timestamp (UTC) | ||
| id: ts | ||
| run: echo "utc=$(date -u '+%Y-%m-%d %H:%M UTC')" >> "$GITHUB_OUTPUT" | ||
| - name: Post removal sticky PR comment | ||
| uses: marocchino/sticky-pull-request-comment@v2 | ||
| with: | ||
| number: ${{ github.event.pull_request.number }} | ||
| header: pr-preview | ||
| message: | | ||
| **PR Preview** | ||
| :---: | ||
| Preview removed because the pull request was closed. | ||
| ${{ steps.ts.outputs.utc }} | ||