The following commands work
$ ls -1t | head -1
git_sync_log20180924_00.txt
$ vi git_sync_log20180924_00.txt
But this does not
$ ls -1t | head -1 | vi
Vim: Warning: Input is not from a terminal
Vim: Error reading input, exiting...
Vim: preserving files...
Vim: Finished.
How can I accomplish this (open most recently modified file in vi)?
ls
(and what do to instead)? – David Foerster Sep 24 '18 at 16:58