10

Is there any way that I can have the Delphi IDE auto-save all opened projects every X minutes, or just before compilatilation? I looked in XE2 and in Gexperts and didn't see anything, but that means nothing as I am thick.

Warren P
  • 65,725
  • 40
  • 181
  • 316
Mawg says reinstate Monica
  • 38,334
  • 103
  • 306
  • 551
  • 1
    You should really emphasise your question over stories, some people not very good at reading large bodies of text while in hurry to give an answer... Meanwhile, GExperts/CnPack do not have such feature, Castalia have (in not too stable state). Alternatively, you can write such wizard yourself, it is simple but you have to figure out what to do with never-saved-before modules. – OnTheFly Feb 16 '12 at 06:25
  • 1
    CTRL+SHIFT+S is your friend, I'm obsessed with this short cut since D7 days ((: –  Feb 16 '12 at 09:53
  • Bah, I like a little story. The "little dialog admitting guild" phrase put a smile on my face. – Leonardo Herrera Feb 16 '12 at 14:10
  • 1
    I think it's hilarious, but I deleted the rant, because this site is built around short readable questions and answers. Please have mercy on the non-english users especially, who have a hard time filtering out the noise, and finding the signal. Personally, Mawg, I'm right there with you and agree with your frustration, I hope you can understand why it's better to edit that stuff out though. – Warren P Feb 16 '12 at 14:15

4 Answers4

27

Check the checkbox in Tools->Options->Environment Options->Autosave->Editor Files. It will save the files on compile/run.

(If you haven't already, I'd also check Tools->Options->Editor Options->Create backup files, and set the File backup limit to 10 or more. This enables a sort of version control using the .history folder for each project (which you can access using the History tab at the bottom of the Code Editor.)

Ken White
  • 123,280
  • 14
  • 225
  • 444
  • -1, fails to comply with an OP's requirement. First guess never saves on compilation. Second one is off-topic because it never saves on compilation and nothing to backup. – OnTheFly Feb 16 '12 at 06:12
  • 3
    Au contraire, when those two are checked and you run the program, the files save. To prove it you can look at the "Save" toolbutton. It will be greyed out, suggesting that it has been done. – Martin Melka Feb 16 '12 at 07:57
  • @user, perhaps in the very old version of Delphi you use it doesn't, but in the modern versions like XE2 it certainly does. – Ken White Feb 16 '12 at 12:09
  • 2
    And the OP uses XE2. I cannot understand downvoting on such an issue. – Leonardo Herrera Feb 16 '12 at 14:12
  • @KenWhite: as I painfully discovered this morning the option to AutoSave on Compile is turned OFF by default in XE2. However the same setting you mention is available for XE2 as well. – santiagoIT Mar 28 '13 at 10:10
10

Andy's DDevExtensions has a "Compile Backup" option that automatically saves a copy of modified units to a .cbk file (e.g. Example.pas.cbk).

Community
  • 1
  • 1
Gerry Coll
  • 5,867
  • 1
  • 27
  • 36
  • 3
    @Mawg: Sorry; I missed the part of the question that said "How do I save before compiling and get other goodies thrown in as well?" :) Maybe you should edit your question? (+1 to Gerry, BTW. I'd forgotten DDevExtensions did this as well.) – Ken White Feb 16 '12 at 02:40
  • +1 and my apologies, Ken. You did answer correctly and more quickly, but I like those other goodies which I forgot to ask for :-) – Mawg says reinstate Monica Feb 18 '12 at 05:45
3

In Delphi Rio

Tools>Options>IDE>Saving and Desktop

jay fall
  • 184
  • 1
  • 4
2

CnPack seems to have such function since version 0.8.2

It is at CnPack - IDE enhancement Settings - Editor Enhancements - Tabset / Button - Auto Save All in my version 1.1.4.924 on the XE7: Auto Save Screenshot

Serhii Kheilyk
  • 933
  • 1
  • 8
  • 24