Shell scripts: determining filename length

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Good morning.

I'm working on some shell scripts that process directories full of times
shared by Samba and used by Windows people.  We all know that Windows
people have a habit of really, really, really, long filenames.

In a shell script, inside a `for f in *` loop, how can I go about
finding how long a filename is ... And then truncate the name, keeping
the three letter extension, to less than 64 characters?

Thanks!

-brian
 
Brian D. McGrew { brian@xxxxxxxxxxxxx || brian@xxxxxxxxxxxxxxxxxxx }
---
> Those of you who think you know it all,
  really annoy those of us who do!


-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list

[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux