-1

Im just starting with nano, and I'm wondering if is there any way to open the last edited file in nano after close and open it again?

tirenweb
  • 30,963
  • 73
  • 183
  • 303

1 Answers1

0

Not 100% sure about the portability, I tested it on my zsh shell. This opens the last instance of nano:

eval $(fc -l 100 | cut -c 8- | grep -v grep | grep "[n]ano" | tail -n 1)
farbiondriven
  • 2,450
  • 2
  • 15
  • 31