I'm in a Linux class right now and the question was brought up as to if there was a command to see what's in your buffer list inside vi. I searched online to see if I could find anything, but found nothing, so I went ahead and started to attempt creating a script myself, however I cannot seem to get the commands right.
Here's what I have so far:
while [ : ] do clear echo "What buffer position would you like to see?" read choice case $choice in 1) '"1p' ;; 2) '"2p' ;; 3) '"3p' ;; 4) '"4p' ;; 5) '"5p' ;; 6) '"6p' ;; 7) '"7p' ;; 8) '"8p' ;; 9) '"9p' ;; 0) '"0p' ;; esac ; read -n 1 ; done
I've tried swapping the command for something like this too:
1) vi -c \"1p ;;
Any ideas on how I might be able to pull a vi command out into command line like that? Thank you! (Side note, this is NOT homework or required. I just want to see if it can be done. I asked my professor to help me with it, and even he was stumped)