Indiana University
University Information Technology Services
  
What are archived documents?
Login>>
Login

Login is for authorized groups (e.g., UITS, OVPIT, and TCC) that need access to specialized Knowledge Base documents. Otherwise, simply use the Knowledge Base without logging in.

Close

In Emacs or Pico, what should I do if a huge chunk of my document disappears while I'm editing?

You may have mistakenly entered the command to kill the region (C-w in Emacs or Ctrl-k in Pico). This command is used to delete a large portion of a document, usually by setting a mark, moving the cursor to another spot, then using the command to kill all the text in between the spot you marked and the spot you're now on.

In Pico, you can usually tell when you're marking text, because the marked text is highlighted, but Emacs often gives no indication that a mark has been set.

Note: Normally in Pico, Ctrl-k deletes only the current line, but it will delete a whole region if you have set a mark.

Recovering text in Emacs

To get the text back in Emacs, type C-y . If that doesn't work, try typing C-x u . You might have to type this command several times. Watch carefully so that you can stop as soon as you get back the text that you want.

Note: If you aren't sure how to enter these commands in Emacs, see In Emacs, how are keystrokes denoted?

Recovering text in Pico

To get the text back in Pico, type Ctrl-u . If that doesn't work the first time, try typing Ctrl-u several more times, watching carefully to see when the command gets back the text that you want.

At Indiana University, for personal or departmental Linux or Unix systems support, see At IU, how do I get support for Linux or Unix?

This is document abjc in domain all.
Last modified on August 22, 2008.

Comments/Questions/Corrections

Use this form to offer suggestions, corrections, and additions to the Knowledge Base. We welcome your input!

If you are affiliated with Indiana University and would like assistance with a specific computing problem, please use the Ask a Consultant form, or contact your campus Support Center.

Contact Information

Note: We will reply to your comment at this address. If your message concerns a problem receiving email, please enter an alternate email address.