Last active
April 5, 2017 16:15
-
-
Save mcenirm/7b538f3a8d9187a468e6be86863260e4 to your computer and use it in GitHub Desktop.
GNU find printf specifier for JSON output
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
find -printf '{"atime":%A@,"blocks512":%b,"ctime":%C@,"depth":%d,"devno":"%D","name":"%f","fstype":"%F","group":"%g","gid":"%G","dirs":"%h","arg":"%H","inode":"%i","blocks1024":%k,"symlinkto":"%l","perm8":"%m","perm":"%M","nlinks":%n,"path":"%p","pathsub":"%P","size":%s,"sparseness":"%S","mtime":%T@,"user":"%u","uid":"%U","type":"%y","typeto":"%Y","selinux":"%Z"}\n' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment