Text editor where unsaved files can be recovered after computer crash?
Solution 1
Scribes is like Text Editor.
But it saves files automatically in your home folder, with a name like:
oqiowdq - (2013-04-05 16:49:15)
Where "oqiowdq" is the first line you typed.
This file is removed when you really save your file.
Unfortunately, it does not have tabs, so feel free to post better answers.
Also, the line number on the left make the text less readable than Gedit.
Solution 2
Besides Notepadqq, another alternative is Geany with Save Actions
plugin.
Both of them support autosaving as well as backup.
And both of them can restore the last session on startup.
Solution 3
If you use gedit, you can turn on autosave in preferences -> editor and it saves documents with the period you specified. And about the autosaved documents place, if I'm right it saves any file in the same folder and same name with extra ~ at the beginning (it would be hidden so press ctrl+H to see it.)
Solution 4
Vim (and by extension, GVim) has swapfiles, which are usually created in the same directory as the file, but can also be placed in a single common directory. Swapfiles are enabled by default, and for configuring the location, see :h 'directory
:
'directory' 'dir'
'directory' 'dir' string (default for Amiga: ".,t:",
for MS-DOS and Win32: ".,$TEMP,c:\tmp,c:\temp"
for Unix: ".,~/tmp,/var/tmp,/tmp")
global
List of directory names for the swap file, separated with commas.
- The swap file will be created in the first directory where this is
possible.
- Empty means that no swap file will be used (recovery is
impossible!).
- A directory "." means to put the swap file in the same directory as
the edited file. On Unix, a dot is prepended to the file name, so
it doesn't show in a directory listing. On MS-Windows the "hidden"
attribute is set and a dot prepended if possible.
- A directory starting with "./" (or ".\" for MS-DOS et al.) means to
put the swap file relative to where the edited file is. The leading
"." is replaced with the path name of the edited file.
- For Unix and Win32, if a directory ends in two path separators "//"
or "\\", the swap file name will be built from the complete path to
the file with all path separators substituted to percent '%' signs.
This will ensure file name uniqueness in the preserve directory.
So, in your ~/.vimrc
, add:
set directory^=/path/to/swapfiles
And make sure that /path/to/swapfiles
exists.
Solution 5
You can also use Notepadqq. It is like Notepad++ in MS Windows. http://notepadqq.altervista.org/wp/download/
Related videos on Youtube
Nicolas Raoul
I am Nicolas Raoul, IT consultant in Tokyo. Feel free to copy/paste the source code from my StackExchange answers, I release it to the public domain.
Updated on September 18, 2022Comments
-
Nicolas Raoul over 1 year
I use Text Editor to draft emails and other messages.
Not files that I want to save, just drafts.Problem: When my computer crashes (happens often recently), I loose the drafts.
Is there a text editor that backs up unsaved files somewhere? (preferably in a single place)
I tried Text Editor (Gedit), and Leafpad.
Note: I don't want
~example
files to be created everywhere, because they are a mess in the terminal, and can be dangerous when sharing USB sticks. So unfortunately I can't use GEdit's backup feature. -
Nicolas Raoul about 11 yearsSorry, I should have explained why I can't use this feature, see the notes I added in my question.
-
ddzzbbwwmm over 6 years+1 for Notepadqq. PS: do you know where notepadqq puts the autosaving files?
-
Thorsten Niehues about 5 yearsNotepadqq - very nice name for people who see that pp and qq are the same shape just mirrored. So the first impression is as expected similar to notepad++ / notepadpp ;)