Last active
March 19, 2016 19:00
-
-
Save tomdwaggy/f1ab4b2dd7ed2dd04e4f to your computer and use it in GitHub Desktop.
locatedb size cc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
As mentioned by SHW, agedu indeed created an index. I thought I'd share | |
another way to create an index, after reading about locatedb. You can | |
create your own version of a locatedb from du output: | |
du | awk '{print $2,$1}' | /usr/lib/locate/frcode > du.locatedb | |
awk rearranges the du output to have filenames first, so that frcode works right. | |
Then use locate with this database to quickly report disk usage: | |
locate --database=du.locatedb pingus | |
You can expand this to suit your needs. I think it's a nice use of locatedb. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment