[kwlug-disc] ncurses file selection tool
Doug Moen
doug at moens.org
Thu Jan 14 12:52:13 EST 2021
I use a brutally primitive subset of vim.
Open a new buffer.
:r ls
reads a list of files from the current directory into the buffer.
Then, edit the buffer into a shell script. Eg, to remove all the files,
:%s,^,rm ,
Delete any lines that remove files you don't want to remove.
Then run the shell script:
:w !sh
I don't general use this technique just to remove files, usually the commands are more complicated. That was just an example.
The benefit of this technique is that it is Turing complete. I can accomplish anything. I don't have to learn a new tool, and I don't run into the limitations that high level tools usually suffer from.
More information about the kwlug-disc
mailing list