Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

active target setting

(1/2) > >>

killerbot:
Before I submit a change request, I'd like to have some feedback first.

I just noticed that the active target is stored in the cbp file.
Typically I would say the cbp file is also put together with the sources in a version control system.
Say your project has several targets working on the same code (debug build, release build ,maybe a special build with some more logging code turned on).

Now when you switch say from your debug target to your release target and you close the project, CB asks you to save the changes you made.
Yes, you made changes to the project, namely that active target (which changed from debug to release in the example) will be stored in the cbp file. So that means, when working with a version control system, you need to check it out, and later check it in, and later the same story when switching back to your debug target and so on ...

My suggestion is (open for discussion from this point on) :
  - don't store the active target in the cbp file
  - store it maybe in the layout file, whick keeps track of the open files in your project (editors) and where the cursor is in those editors , or some other file with a similar purporse ...

What do you think ?

Cheers,
Lieven

rickg22:
Yes, go for it!

MortenMacFly:

--- Quote from: killerbot on November 27, 2005, 03:49:38 pm ---What do you think ?

--- End quote ---
I think it also has some drawbacks:
Everything to repeat the compilation of a project is currently in the project file. Thus, you provide somebody with this file and he will be able to compile exactly as you did.
What do you do with the second layout file? With your proposed changes it has vital information stored in it because the target selection might be important to successfully compile a project. So it should belong to the project sources and therefore to CVS. Thus you have the same CVS problem but on a differrent file.
I for myself update the project files in CVS only, if I really changed something (added/removed files, changed configuration...). If only the target has changed and this change is not vital I don't commit the project file.

I wonder where and how MS VisualStudio stores the current configuration...?!

Morten.

killerbot:
Definetely not in the project file (vcproj), I think it stores it in the ncb or suo files, which are unreadable :-(

killerbot:

--- Quote from: MortenMacFly on November 27, 2005, 04:52:55 pm ---What do you do with the second layout file? With your proposed changes it has vital information stored in it because the target selection might be important to successfully compile a project. So it should belong to the project sources and therefore to CVS. Thus you have the same CVS problem but on a differrent file.

--- End quote ---

No, don't add it to version control, since when you turn off CB (or pc) the next day you want to continue with for example your release build, but in the version control system it was stored as debug build, you have to switch again. I think if this settings make it in a file which is in a version control system, the version tree for that file would quickly become very big, especially when there are several developers.
What if you say, ok should always be debug, during development you are for some reason in the release target, then you change another setting of the project, you store the cbp. Woops, next to the 'real adjusted' setting also the active target slipped into the saved version which is handed back to the version control system.
I guess ...

Navigation

[0] Message Index

[#] Next page

Go to full version