shell - How can I recursively print a list of files with filenames shorter than 25 characters using a one-liner? -


i need 1 line command below requirement.

search files root directory , print files names file name length less 25.

i suppose can find command below:

find / -type f |xargs basename .... not sure furthur command.

my gnu find supports this, unsure whether it's part of standard find.

find / -type f -regextype posix-extended -regex '.*/.{1,24}$' 

alternatively, use find | grep.

find / -type f | egrep '.*/.{1,24}$' 

Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -