Re:Show HN: Nnn – unorthodox terminal file manager
by Scarbutt on Tuesday November 17, 2020 @12:15PM
(#25126350)
If you are saying you are OK with scanning the whole filesystem every time you are looking for something that can be anywhere under /
You can specify a target directory from which to start the search.
Re:Show HN: Nnn – unorthodox terminal file manager
by apjana on Tuesday November 17, 2020 @12:34PM
(#25126649)
Bookmarks you mean. Yes, in nnn you can jump to the bookmark from anywhere and then press `Alt-O` (my preferred key) to start the search.
But you know what, let me share a smarter workflow:
find . -iname "*.mp3" -print0 | nnn -p -
Now you list all yours mp3 files in nnn, examine/play them and finally get to cherry-pick some and print them to stdout when you quit nnn.BTW, you can also run the find within nnn and list in nnn.
Re:Show HN: Nnn – unorthodox terminal file manager
by joshuak on Tuesday November 17, 2020 @03:32PM
(#25129407)
I see what you did there
Re:Show HN: Nnn – unorthodox terminal file manager
by mst on Tuesday November 17, 2020 @04:25PM
(#25130068)
If you're looking for something that can be anywhere under /, then the target directory needs to be /.
Re:Show HN: Nnn – unorthodox terminal file manager
by apjana on Tuesday November 17, 2020 @11:27PM
(#25133214)
Yes, that's what I intended to convey.
Re:Show HN: Nnn – unorthodox terminal file manager
by mekster on Tuesday November 17, 2020 @04:16PM
(#25129959)
> endless cd-ls loop
Better to have "chpwd() { ls }" in your .zshrc as this executes ls after cd'ing to save up on your infinite amount of ls typing.
Re:Show HN: Nnn – unorthodox terminal file manager
by apjana on Tuesday November 17, 2020 @04:51PM
(#25130405)
That'll print the list of files even in a populated directory like /usr/bin and leave me at the prompt with the last few files listed above. As soon as you want the list of files not to go away so you can control/manage/examine them, you are talking of a file manager.
Re:Show HN: Nnn – unorthodox terminal file manager
by mekster on Tuesday November 17, 2020 @05:11PM
(#25130622)
Who would regularly cd into /usr/bin/?
If you only work inside messy folders with hundreds of files all the time, maybe it's time to tidy up.
Re:Show HN: Nnn – unorthodox terminal file manager
by apjana on Tuesday November 17, 2020 @09:03PM
(#25132339)
There can be other frequented examples, say, ~/Pictures.
Also, find/fzf etc. are useful as long as you are not on a slow disk and a mid-range Android device/the Pi. If you are saying you are OK with scanning the whole filesystem every time you are looking for something that can be anywhere under /, I simply don't prefer that.