You are not logged in.
Pages: 1
If you are like me having trouble using find syntax, then this might be for you.
Simple wrapper around find command, targeted at interactive use, that should do stuff like
findosaurus # show what's changed in last 3 days
findosaurus stuff misc # find stuff OR misc
findosaurus -a foo bar # find foo AND bar
findosaurus -e jpg # ends with jpg
findosaurus -h # help
Note: This limits/hides what someone with the right find can do, but we get (slightly) more human-friendly syntax. For any more complex search pattern you should of course ask the mother find.
Code is ugly and repeatable at this point, probably should learn how to use getops or something.
p.s. If you have a certain search pattern that you use daily and would like included, tell me about it.
Last edited by brontosaurusrex (2017-09-05 19:13:56)
Offline
Nice idea, and almost nice 'execution'.
<devil advocate mode>
You should consider:
(o) de-facto standard arguments prefix: single '-' for one-letter short options, double '--' for long options
(o) I have file which ends with '-starts', and another one starting with '-ends'; how should I find those files? ]:D ]:D
(o) why not name this script like 'ffind' or 'fffind'? It is much easier to type with alt-tab completion, IMHO.
</devil advocate mode>
Otherwise, I think it is very nice.
Last edited by iMBeCil (2017-09-05 13:06:40)
Postpone all your duties; if you die, you won't have to do them ..
Offline
I have file which ends with '-starts', and another one starting with '-ends'; how should I find those files?
You would switch back to regular find and construct your syntax there, or is that an example search that you use daily?
You could say
findosaurus -e foo && findosaurus -s bar
I know. Is that something that one would use daily?
Will consider the rest. (ffind is a bit ffmpeg-ish, any other ideas?)
de-facto standard arguments prefix: single '-' for one-letter short options, double '--' for long options
fixed.
Last edited by brontosaurusrex (2017-09-05 14:08:35)
Offline
... (ffind is a bit ffmpeg-ish, any other ideas?)
findosaurus
Be Excellent to Each Other...
The Bunsenlabs Lithium Desktop » Here
FORUM RULES and posting guidelines «» Help page for forum post formatting
Artwork on DeviantArt «» BunsenLabs on DeviantArt
Offline
Offline
^^
Spot on!
Postpone all your duties; if you die, you won't have to do them ..
Offline
Added sort of an AND (using evil eval array expansion)
findosaurus --and find us
./findosaurus
Last edited by brontosaurusrex (2017-09-06 08:28:00)
Offline
Pages: 1