Added highlight and bookmark feature in notes #743 #68
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: Clean up PR Preview | |
| on: | |
| pull_request: | |
| types: [closed] | |
| branches: | |
| - main | |
| jobs: | |
| cleanup-preview: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| pages: write | |
| steps: | |
| - name: Checkout gh-pages branch | |
| uses: actions/checkout@v4 | |
| with: | |
| ref: gh-pages | |
| fetch-depth: 1 | |
| - name: Remove PR preview directory | |
| run: | | |
| if [ -d "pr-preview/pr-${{ github.event.pull_request.number }}" ]; then | |
| rm -rf pr-preview/pr-${{ github.event.pull_request.number }} | |
| echo "Removed preview for PR #${{ github.event.pull_request.number }}" | |
| else | |
| echo "No preview directory found for PR #${{ github.event.pull_request.number }}" | |
| fi | |
| - name: Commit cleanup | |
| run: | | |
| git config --local user.email "github-actions[bot]@users.noreply.github.com" | |
| git config --local user.name "github-actions[bot]" | |
| if [ -n "$(git status --porcelain)" ]; then | |
| git add . | |
| git commit -m "Clean up preview for PR #${{ github.event.pull_request.number }}" | |
| git push | |
| else | |
| echo "No changes to commit" | |
| fi |