Community
    • Login

    FAQ: Autosaving "unnamed" `new 1` files

    Scheduled Pinned Locked Moved FAQ
    autosavefaqunnamednew 1
    1 Posts 1 Posters 9.2k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • PeterJonesP
      PeterJones
      last edited by PeterJones

      Hello, and welcome to the FAQ Desk. You have likely been directed to this page because you asked a question about autosaving “unnamed” files (which show up as new 1 and similar).

      Editor’s Note: There is an updated version of this FAQ entry with more up-to-date information at FAQ Desk: Periodic Backup vs AutoSave Plugin. The original FAQ entry is kept below for reference.

      -----

      The autosave feature for the “new #” tabs (and any other file that’s not saved) is found in Settings > Preferences > Backup.

      d1bdf36a-23ce-45f3-87d9-2c354291fecc-image.png
      (Image Credit: @Scott-Sumner in “Forgetful Notepad” thread)

      If you enable ☑ Remember current session... and ☑ Enable session snapshot..., then even if you forget to hit save, it will make a backup; on your next load of Notepad++, the “unsaved” file will still be in the same state as it was before you closed Notepad++.

      If something happens, and Notepad++ doesn’t load your previous session after it’s made the session-snapshot of unsaved files, you might find it in %AppData%\Notepad++\backup\ (often c:\users\user.name\AppData\Roaming\Notepad++\backup\ on modern Windows, but see “FAQ Desk: What is %AppData%” for more details)

      HOWEVER: it is your responsibility to make sure files are properly saved and backed up. This feature is meant to temporarily protect you from forgetting to hit save; this is not intended as a long term solution for storing your critical data in “unnamed” files. Crashes can cause data loss. Relying on autosave of an unnamed file for critical data is a good way to set yourself up for a problem. Please, save the file to a named location, save early, save often, and backup.

      If you turn off ☐ Enable session snapshot..., then if you try to close Notepad++ with a file with unsaved changes (whether it’s a named file, or one of the unnamed “new #” files), Notepad++ will prompt you to save changes (Yes), lose your changes (No), or stop closing Notepad++ (Cancel). I personally find this a much safer situation: that way, named files are saved where you expect them to be, and all files must have a meaningful name. (Quick, when you’ve got “new 1” through “new 27” open, which file did you put your note about the project that your boss wants you to work on next week? Will you still remember that next week? Whereas, if it’s named “boss-priorities.txt”, it’s easily identifiable in the future.)

      1 Reply Last reply Reply Quote 4
      • Alan KilbornA Alan Kilborn referenced this topic on
      • mkupperM mkupper referenced this topic on
      • Alan KilbornA Alan Kilborn referenced this topic on
      • First post
        Last post
      The Community of users of the Notepad++ text editor.
      Powered by NodeBB | Contributors