Page 1 of 1

[Implemented] settings saving option

Posted: Tue Oct 09, 2007 12:35 am
by lexvictory
we have an option to disable cursor position saving, so can we also have an option to prevent the IDE from saving the PB version in the file?
i'm using PB files with svn, and this is something that i think could get in the way...

Posted: Tue Oct 09, 2007 6:54 am
by Leonhard
Write this in the Header of the File.

Example:
;/
;/ File: <your file-name>
;/ PB-Version: 4.10 B3 (or other)
;/

;[...] The Code of the file

Posted: Tue Oct 09, 2007 6:59 am
by lexvictory
Leonhard wrote:Write this in the Header of the File.

Example:
;/
;/ File: <your file-name>
;/ PB-Version: 4.10 B3 (or other)
;/

;[...] The Code of the file
what good would that do?
i want to be able to stop the string being written, as i use the same source for windows and linux. i havent run into any issues yet, but i think that it could cause hassles with svn once more than just 1 person (me) is writing to the repository.

Posted: Tue Oct 09, 2007 12:46 pm
by freak
What we do on our repository is to use the option to save the settings to a separate "project.cfg"
file instead of the end of the sourcefile (Preferences->Editor), and then simply not put the
project.cfg in the repository.

This way everyone can have his cursor position etc saved without getting in the way.

Posted: Tue Oct 09, 2007 1:00 pm
by lexvictory
does it save all of the settings there?
like saving compile type (windows, dll, console, etc)?

i did see it as an option, but i guess it would just take some setting up if it does store compile type in the project.cfg as well

Posted: Tue Oct 09, 2007 1:16 pm
by freak
> i did see it as an option, but i guess it would just take some setting up if it does store compile type in the project.cfg as well

Everything is stored separately (the source file then only contains the code you see in the editor, no extra lines)

If you are worried about needing to redo all option when you change this, there is no problem.
The IDE will use the settings at the source end if none are present in the project.cfg, then
when you save the source again, it removes the settings at the source end and stores them in the project.cfg.
So the transition should be without problems.

The only thing that will happen of course is when you checkout your repository
to a new directory/computer, it will have none of these settings attached anymore (as the project.cfg is not included).
Then you either have to redo them all, or manually copy your project.cfg files back.

Maybe i could add a "version control friendly" mode to the IDE or something for this.
I don't have an idea yet on what shape this should take exactly though.

Posted: Tue Oct 09, 2007 2:28 pm
by lexvictory
freak wrote:Maybe i could add a "version control friendly" mode to the IDE or something for this.
I don't have an idea yet on what shape this should take exactly though.
you could have it so that cursor positions in project.cfg, all compiler settings in the source (ones that didnt change just by opening it somewhere else and saving)