[Tex/LaTex] Automatic file backup in Texstudio

texstudio

Is it possible to set up Texstudio such that it makes a backup of each LaTeX file it opens before any edit?

Best Answer

You can do this via scripting (Macros -> Edit Macros ...)

enter image description here

Note, that TXS will ask you to confirm the writing of the file because automatic writing of files from a script may pose a secuity hole.

If you like, you can improve the script, e.g. to prevent that an existing backup is overwritten. You may also be interested in this related solution. But as stated there, you might consider using a version control system instead of creating multiple copies of files.