Use search query parameters for additional search views in the API #1560
Workflow file for this run
This file contains 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: PR Closed | |
on: | |
pull_request: | |
types: | |
- closed | |
jobs: | |
clean-gh-pages: | |
name: Clean GH Pages preview | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: gh-pages | |
- name: Determine if cleaning is necessary | |
id: should-clean | |
run: | | |
if [ -d "_preview/${{ github.event.pull_request.number }}" ]; then | |
echo "PR preview exists, cleaning" | |
echo "clean=true" >> "$GITHUB_OUTPUT" | |
else | |
echo "PR preview does not exist, skipping" | |
echo "clean=false" >> "$GITHUB_OUTPUT" | |
fi | |
- name: Remove PR preview | |
run: rm -rf _preview/${{ github.event.pull_request.number }} | |
- name: Push cleaned branch | |
if: ${{ steps.should-clean.outputs.clean == 'true' }} | |
run: | | |
git config --global user.name 'PR Closed action' | |
git config --global user.email 'openverse@wordpress.org' | |
git commit -am 'Clean preview for PR ${{ github.event.pull_request.number }}' | |
git push |