scripts: add count-source-lines

This commit is contained in:
thislight 2024-11-19 21:12:28 +08:00
parent e174b7aafd
commit 9e9a831785
No known key found for this signature in database
GPG key ID: FCFE5192241CCD4E
2 changed files with 12 additions and 1 deletions

10
scripts/src-lc.sh Executable file
View file

@ -0,0 +1,10 @@
#!/bin/sh
# Count the source lines.
find . '(' ! -path "./node_modules/**" ')' \
-and '(' ! -path "./.git/**" ')' \
-and '(' ! -path "./*dist/**" ')' \
-and '(' ! -path "./bun.lockb" ')' \
-and '(' ! -path "./docs/**" ')' \
-type f -print0 \
| wc -l --files0-from=-