This commit is contained in:
10
justfile
10
justfile
@@ -20,9 +20,13 @@ machine_ip := `ip -4 addr show scope global | grep -oP '(?<=inet\s)\d+(\.\d+){3}
|
||||
@amend:
|
||||
cd "{{root}}" && git add . && git commit --amend || (git restore --staged . && false)
|
||||
|
||||
# 统计代码量
|
||||
cloc:
|
||||
cd {{invocation_directory()}} && git ls-files | xargs cloc
|
||||
# 统计代码量(支持文件名包含空格)
|
||||
cloc range="":
|
||||
cd {{invocation_directory()}} && git ls-files -z \
|
||||
| grep -z -v -E '\.(g|freezed)\.dart$' \
|
||||
{{ if range != "all" { "| grep -z -v '^test/'" } else { "" } }} \
|
||||
| xargs -0 cloc
|
||||
|
||||
|
||||
|
||||
# === just 管理命令 ===
|
||||
|
||||
Reference in New Issue
Block a user