-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove all file preparation, now handled by git. Remove submodule. Rework sample workflow. Update doc. Rework diff script to be used by GIT_EXTERNAL_DIFF. Remove VSCode launch config. BREAKING CHANGE: Total rework
- Loading branch information
Robert Duncan
committed
Oct 21, 2023
1 parent
45faf55
commit 850cc7b
Showing
7 changed files
with
379 additions
and
112 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,59 +15,16 @@ jobs: | |
ref: ${{ github.ref }} | ||
fetch-depth: 2 | ||
|
||
- name: Find changed json | ||
id: changed-json | ||
uses: tj-actions/[email protected] | ||
with: | ||
files: | | ||
**/*.json | ||
include_all_old_new_renamed_files: true | ||
|
||
- name: Copy head paths files | ||
run: | | ||
mkdir head | ||
touch head/acmr.txt | ||
for file in ${{ steps.changed-json.outputs.added_files }}; do | ||
echo "A,head/${file}" >> head/acmr.txt | ||
cp --parents $file head/ | ||
done | ||
for file in ${{ steps.changed-json.outputs.copied_files }}; do | ||
echo "C,head/${file}" >> head/acmr.txt | ||
cp --parents $file head/ | ||
done | ||
for file in ${{ steps.changed-json.outputs.modified_files }}; do | ||
echo "M,head/${file}" >> head/acmr.txt | ||
cp --parents $file head/ | ||
done | ||
for file in ${{ steps.changed-json.outputs.renamed_files }}; do | ||
echo "R,head/${file}" >> head/acmr.txt | ||
cp --parents $file head/ | ||
done | ||
- name: Checkout base | ||
run: git checkout $(git --no-pager log --oneline -n 2 | awk 'NR==2 {print $1}') | ||
|
||
- name: Copy base paths | ||
run: | | ||
mkdir base | ||
touch base/mrd.txt | ||
for file in ${{ steps.changed-json.outputs.modified_files }}; do | ||
echo "M,${file}" >> base/mrd.txt | ||
done | ||
for file in ${{ steps.changed-json.outputs.all_old_new_renamed_files }}; do | ||
echo "R,${file}" >> base/mrd.txt | ||
done | ||
for file in ${{ steps.changed-json.outputs.deleted_files }}; do | ||
echo "D,${file}" >> base/mrd.txt | ||
done | ||
- name: Setup requirements and script | ||
run: | | ||
pip install rich | ||
pip install json_source_map | ||
git clone --depth 1 https://gist.github.com/74017707b676c3ce947528fb00dd46d0.git fsjd | ||
wget https://raw.githubusercontent.com/robproject/fsjd/main/frappe_schema_json_diff.py | ||
- name: Diff table | ||
run: python3 fsjd/frappe_schema_json_diff.py base/mrd.txt head/acmr.txt 1 | ||
- name: Run script file | ||
run: | | ||
chmod +x ./run.sh | ||
./run.sh | ||
shell: bash | ||
|
||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.