mirror of
https://github.com/BillyOutlast/posthog.com.git
synced 2026-02-04 03:11:21 +01:00
Yet another bot fix (#1099)
This commit is contained in:
3
.github/workflows/checks.yml
vendored
3
.github/workflows/checks.yml
vendored
@@ -32,8 +32,9 @@ jobs:
|
||||
|
||||
- name: Add safe redirects
|
||||
run: |
|
||||
export PR_DIFF=$(git diff ${{ github.base_ref }} ${{ github.head_ref }})
|
||||
git diff ${{ github.base_ref }} ${{ github.head_ref }} > pr_diff
|
||||
python3 ./scripts/safe_rename.py
|
||||
rm pr_diff
|
||||
git add .
|
||||
[ "$(git status -s)" = "" ] && exit 0 || git commit -m "Add safe redirects"
|
||||
|
||||
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -11,4 +11,5 @@ yarn-error.log
|
||||
.idea
|
||||
|
||||
package-lock.json
|
||||
pr_diff
|
||||
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import re
|
||||
import os
|
||||
|
||||
git_diff = os.environ['PR_DIFF']
|
||||
with open("./pr_diff", "r") as git_diff_file:
|
||||
git_diff = git_diff_file.read()
|
||||
|
||||
rename_from_regex = r'rename from contents(.*).md'
|
||||
rename_to_regex = r'rename to contents(.*).md'
|
||||
|
||||
Reference in New Issue
Block a user