Today i lost some 4 hours of programming as the Arduino.exe froze after compiling my project, and i had forgotten to save before compiling. There SHOULD be a choice in the Preference, where you could instruct Arduino to autosave before compiling! best regards svein..
Hei Svein! (From your name I guess you're Norwegian?)
I completely agree! Autosave is a feature that for the most part makes life easier. I must say that some applications clear the undo queue on save, and that can make the autosave a pain in the ass.
I think Arduino should support autosave without clearing the undo queue.
Yes, im from the land of snow and ice, and we are getting more and more of it..... But right now, the frustration of reconstructing a days work, keep me warm.... Im new to Arduino, but the love is growing!
Take comfort in the fact that you're not the first to lose work this way, and that you most likely will write it faster and better this time :) Greetings from Oslo!
Your code is still in your machine, if you checked it (compiling) there are a build.tmp folder in your %temp% with a .cpp file inside.
You can rebuild your .pde file easily from that .cpp file.
I have mixed feelings about an auto save feature. Many times I'm just fooling around with an existing sketch trying things and wouldn't want those changes saved automatically unless it also saved a pre-changes sketch. Making it an option might be OK. It's hard to protect against a locked up PC for all possible situations I would think?
Thanks eried! I will check it.
yes, I think the same.
Autosave must be well implemented, it's not just a matter of emulating a click over the "save" button with a timer.
Autosave is perhaps not the best term. What i meant was an option "Save before compile" Im a lifetime Visual Basic programmer, and this option in VB, have saved me MANY hours. I always have this option checked, and have never experienced any negative results.
A good autosave saves a seperate entity. Know those prompts ‘there is a more recent autosave, load this instead?’?
Thats how it should be done
Autosaves saved independently from the source file, but linked to (ie: an autosave of one file won’t overwrite that of another project).
Many times I'm just fooling around with an existing sketch trying things and wouldn't want those changes saved automatically
just make a fiddling copy of the sketch on beforehand?