LyXMeaning of the ".lyx~" File

Information and discussion about LyX, a WYSIWYM editor, available for Linux, Windows and Mac OS X systems.
Post Reply
harper
Posts: 9
Joined: Thu Dec 01, 2011 5:15 pm

Meaning of the ".lyx~" File

Post by harper »

Hey there,

does anyone know what the .lyx~ files do that LyX creates for every document? I did not find any references in the manual. My questions are:
  • What is it and what does it do?
  • Can I delete it without destroying the original Document?
  • Can I rename the original Document, without renaming the .lyx~ File?
Thank you for your help and time =)
Harper

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Stefan Kottwitz
Site Admin
Posts: 10324
Joined: Mon Mar 10, 2008 9:44 pm

Re: Meaning of the ".lyx~" File

Post by Stefan Kottwitz »

Hi Harper,

welcome to the board!

I don't use LyX, however I guess it's a backup file. Some editors add a tilde to the names of backup files. Open it with a text editor or any program to read it, look if it's similar to the original .lyx file.

Stefan
LaTeX.org admin
harper
Posts: 9
Joined: Thu Dec 01, 2011 5:15 pm

Re: Meaning of the ".lyx~" File

Post by harper »

Thank you =)

Seems the files are identical...
meho_r
Posts: 823
Joined: Tue Aug 07, 2007 5:28 pm

Meaning of the ".lyx~" File

Post by meho_r »

As Stefan said, it is a backup file indeed. If you rename your main .lyx file, a new .lyx~ file will be created, with the new name, while the old one, with the old name, will not be deleted. It is good to have these files in case of a disaster (e.g., power-cut might destroy your document completely or mess it up badly).

There are two things you might want to know regarding backup files:
1. You can tell LyX how often it should create/update backup files, or even disable them completely (which is not a good idea): Tools > Preferences > Look & Feel > User Interface (first two checkboxes under "Document")
2. You can create a directory in which backup files of all your projects will be stored, instead of the current directory: Tools > Preferences > Paths > Backup directory.
Post Reply