mirror of
https://github.com/vale981/tridactyl
synced 2025-03-05 09:31:41 -05:00
Save one intermediate file
This commit is contained in:
parent
6e44bef6bd
commit
0d7fdb1abf
1 changed files with 1 additions and 2 deletions
|
@ -17,8 +17,7 @@ if [ -n "$uglyFiles" ]; then
|
||||||
# Get crazy: backup the working copy of the file, paste the staged version in its place, prettify, add, restore backup
|
# Get crazy: backup the working copy of the file, paste the staged version in its place, prettify, add, restore backup
|
||||||
backup=$(mktemp -p . $file.XXXXXXXXX)
|
backup=$(mktemp -p . $file.XXXXXXXXX)
|
||||||
mv "$file" "$backup"
|
mv "$file" "$backup"
|
||||||
staged "$file" > "$file"
|
staged "$file"|prettier --stdin-filepath "$file" > "$file"
|
||||||
prettier --write "$file"
|
|
||||||
git add "$file"
|
git add "$file"
|
||||||
mv "$backup" "$file"
|
mv "$backup" "$file"
|
||||||
echo "WARN: Working file restored"
|
echo "WARN: Working file restored"
|
||||||
|
|
Loading…
Add table
Reference in a new issue