Update replace-strings.yml #2
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: Replace strings in HTML files | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
replace: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Install dependencies | |
run: sudo apt-get install sed | |
- name: Replace strings in HTML files | |
run: | | |
find . -type f -name "*.html" -exec sed -i 's|https://closure-next.github.io|/|g' {} \; | |
find . -type f -name "*.html" -exec sed -i 's|assets|/assets|g' {} \; | |
- name: Commit changes | |
run: | | |
git config --local user.name "MilesONerd" | |
git config --local user.email "150525657+MilesONerd@users.noreply.github.com" | |
git add . | |
git commit -m "Replace URLs in HTML files" | |
git push |