Spiff59 Posted August 6, 2008 Share Posted August 6, 2008 (Maybe this question should go on another website?) Here's my habit: I need a one-time quick-fix or test job, so: I jump into some source file with code similar to what I'll need. I butcher the heck out of it to suit my needs. Then I "Save As" in SciTE with a new filename, and exit SciTE. Does anyone know why a couple times now, with no prompt out of SciTE, , I've also ended up with the original file chopped to pieces? Thinking (way) back, I can't recall ICCF, X-Edit or any editor I've used since allowing me to unknowingly get away with this. Is there a preference/option I can change to put more prompting on SciTE's save routines, or stop save-as from doing a hidden, no-prompt, save of the original file? Link to comment Share on other sites More sharing options...
ResNullius Posted August 6, 2008 Share Posted August 6, 2008 (edited) (Maybe this question should go on another website?)Here's my habit:I need a one-time quick-fix or test job, so:I jump into some source file with code similar to what I'll need.I butcher the heck out of it to suit my needs.Then I "Save As" in SciTE with a new filename, and exit SciTE.Does anyone know why a couple times now, with no prompt out of SciTE, , I've also ended up with the original file chopped to pieces? Thinking (way) back, I can't recall ICCF, X-Edit or any editor I've used since allowing me to unknowingly get away with this.Is there a preference/option I can change to put more prompting on SciTE's save routines, or stop save-as from doing a hidden, no-prompt, save of the original file?Did you run the script from within SciTE before your "save-as"? That causes an automatic save.Best habit: open the file you want to steal from, immediately do a save-as, and then start butchering Edited August 6, 2008 by ResNullius Link to comment Share on other sites More sharing options...
Spiff59 Posted August 6, 2008 Author Share Posted August 6, 2008 (edited) Did you run the script from within SciTE before your "save-as"? That causes an automatic save.Best habit: open the file you want to steal from, immediately do a save-as, and then start butchering Thanks, Res.That would explain it.SciTE must submit the actual original source file to the interpreter and therefore needs to save the changes you've made in the editor first. A shame it doesn't just build a temp file and submit that, and let me decide what files are saved when.Are there no options to avoid this, other than tying a string around my finger?Thanks again.Edit: I found an answer on the Scintilla site. You can edit the SciTE .properties file:When running or building a file, its most likely that you want the file to be saved first. To enable a confirmation dialog for performing Compile, Build or Go commands, set are.you.sure.for.build=1.Now, I have to decide if the hassle of getting prompted every time I do a run out of SciTE is worth it... Edited August 6, 2008 by Spiff59 Link to comment Share on other sites More sharing options...
Developers Jos Posted August 6, 2008 Developers Share Posted August 6, 2008 You could also use the SciTE4Autoit3 installer which has an option that will keep the last X version of the file. This allows for an oops SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
herewasplato Posted August 7, 2008 Share Posted August 7, 2008 ....SciTE must submit the actual original source file to the interpreter and therefore needs to save the changes you've made in the editor first....Yes, it does that.Another trick that you might try is to place a read-only attribute on the original file and/or make a copy of it before editing. [size="1"][font="Arial"].[u].[/u][/font][/size] Link to comment Share on other sites More sharing options...
jvnorris Posted August 7, 2008 Share Posted August 7, 2008 THe best option which is what I have learned to do. Very first thing when you are about to butcher an existing script just save it with a name like testblahblahblah . Just makes life easier and this does not happen. I got used to this after the first three times or so of losing my originals Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now