User forums > General (but related to Code::Blocks)
New project wizard - remove files from project
oth_florian:
--- Quote from: oBFusCATed on May 24, 2017, 10:00:10 am ---You can try ProjectFile::RemoveBuildTarget, but I'm not sure it will work.
--- End quote ---
I tried it ;) And it does not work, I have no idea for what this is...
But I have a solution which work for me:
--- Code: ---
if ((project.GetFile(i).relativeFilename.Matches(_T("FatFS/doc*"))) || (project.GetFile(i).relativeFilename.Matches(_T("FatFS/src/option*"))))
{
project.GetFile(i).compile = false;
project.GetFile(i).link = false;
}
--- End code ---
I do it like this and it compiles and links...
The documentation is not very helpful...
BlueHazzard:
--- Quote from: oth_florian on May 24, 2017, 10:09:35 am ---The documentation is not very helpful...
--- End quote ---
any more complaining on this so we can fix it? ;)
oth_florian:
--- Quote from: BlueHazzard on May 24, 2017, 04:03:21 pm ---
--- Quote from: oth_florian on May 24, 2017, 10:09:35 am ---The documentation is not very helpful...
--- End quote ---
any more complaining on this so we can fix it? ;)
--- End quote ---
I mean this site
http://wiki.codeblocks.org/index.php/Scripting_commands
But at the moment I don't know how to the things better, but examples always help.
How can I contribute to the documentation?
BlueHazzard:
The forum log in should be the same as on the wiki. If not, you may have to send a pm to jens so he can add you to the wiki user list
BlueHazzard:
Just to come back to your question: You want to remove files from the codeblocks project?
Why do you don't use the function cbProject::RemoveFile function?
You can iterate through the project file and check the relative filename and remove the wrong files....
Or do you want only to not compile this files, but still let them in the project? If that is what you want, i think you can set ProjectFile::compile to false
Navigation
[0] Message Index
[*] Previous page
Go to full version