fish conf dir, justfile

This commit is contained in:
Dylan Knutson
2024-12-18 18:29:37 +00:00
parent 276a4adc0c
commit f2074a8544
7 changed files with 51 additions and 13 deletions

14
justfile Normal file
View File

@@ -0,0 +1,14 @@
default:
@just --list
[private]
changed-ruby-files:
@git diff --name-only | \
(grep -v 'db/schema.rb' || true) | \
(grep -E '(\.(rb|rake|erb)|Rakefile)$' || true)
format-changed:
just changed-ruby-files | xargs -I{} bash -c "stree format {} > {}.tmp && mv {}.tmp {}"
format-all:
find . -name '*.rb' -type f -exec sh -c 'stree format "$1" > "$1.tmp" && mv "$1.tmp" "$1"' sh {} \;