This commit is contained in:
parent
eb5933c020
commit
fbba465ad9
1 changed files with 9 additions and 0 deletions
9
doc/tips/yet_another_simple_disk_usage_like_utility.mdwn
Normal file
9
doc/tips/yet_another_simple_disk_usage_like_utility.mdwn
Normal file
|
@ -0,0 +1,9 @@
|
|||
Here's the annex-du script that I use:
|
||||
|
||||
#!/bin/sh
|
||||
git annex find "$@" --include '*' --format='${bytesize}\n' |awk '{ sum += $1; nfiles++; } END { printf "%d files, %.3f MB\n", nfiles, sum/1000000 } '
|
||||
|
||||
This one can be slow on a large number of files, but it has an advantage of being able to use all of the filtering available in git annex find.
|
||||
For example, to figure out how much is stored in remote X, do
|
||||
|
||||
annex-du --in=X
|
Loading…
Add table
Reference in a new issue