Author Topic: Bug encountered while opening a Code::blocks project ?? [ Resolved ]  (Read 5392 times)

Offline Ghostwhowalks

  • Single posting newcomer
  • *
  • Posts: 2
I'm not sure if this bug has been reported. I have created a Code-blocks project with three files:  main1.h, main2.h and main.cpp. The project compiles and I can run a console application built with those files. I have saved the project and exited Codeblocks. Now, when I reopen the project , The IDE/editor loads only main.cpp and I have to open the other files manually even though all those files belonged to one project. I wanted to know if it is possible to see/open all source files related to a project when a user opens a project file. If this is a bug, can you please fix it in your next Codeblocks release?

Thanks,
AM
« Last Edit: January 29, 2010, 09:30:14 pm by Ghostwhowalks »

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Re: Bug encountered while opening a Code::blocks project ??
« Reply #1 on: January 29, 2010, 07:02:57 am »
I wanted to know if it is possible to see/open all source files related to a project when a user opens a project file. If this is a bug, can you please fix it in your next Codeblocks release?
This is surely not a bug. Code::Blocks opens the files as layout in the last session if you have enabled the option accordingly:
Settings -> Environment -> General settings -> Group "On project load" -> "Open all project files" OR "Open last open files".

Make sure you choose the right options. If e.g. working with a big project (Linux kernel sources) the first option will lead to the fact that you can grab a coffee while the IDE opens several 10000 files for you. Not sure if this would work at all. So be careful.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: Bug encountered while opening a Code::blocks project ??
« Reply #2 on: January 29, 2010, 07:09:21 am »
I'm not sure if this bug has been reported. I have created a Code-blocks project with three files:  main1.h, main2.h and main.cpp. The project compiles and I can run a console application built with those files. I have saved the project and exited Codeblocks. Now, when I reopen the project , The IDE/editor loads only main.cpp and I have to open the other files manually even though all those files belonged to one project. I wanted to know if it is possible to see/open all source files related to a project when a user opens a project file. If this is a bug, can you please fix it in your next Codeblocks release?

Thanks,
AM

Please have a look at "Settings -> Environment -> General settings -> On project load:".

By the way, you forgot to tell us which version of C::B and which OS (and version) you use. This might be needed.

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: Bug encountered while opening a Code::blocks project ??
« Reply #3 on: January 29, 2010, 07:10:53 am »
Make sure you choose the right options. If e.g. working with a big project (Linux kernel sources) the first option will lead to the fact that you can grab a coffee while the IDE opens several 10000 files for you. Not sure if this would work at all. So be careful.

It works, I use the kernel-sources to test opening very much files in C::B.  :D

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Re: Bug encountered while opening a Code::blocks project ??
« Reply #4 on: January 29, 2010, 07:30:11 am »
It works, I use the kernel-sources to test opening very much files in C::B.  :D
So... just for the record: How long does it take (for how many files)?
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Bug encountered while opening a Code::blocks project ??
« Reply #5 on: January 29, 2010, 09:49:27 am »
Make sure you choose the right options. If e.g. working with a big project (Linux kernel sources) the first option will lead to the fact that you can grab a coffee while the IDE opens several 10000 files for you. Not sure if this would work at all. So be careful.

This option could be transformed to "Open the last N files", so accidents are avoided :)

Also I've thought of an option to auto close a file that is not used for 10min and there are more than 10 open files, but I'm not sure if that would be useful. Can this be done with a plugin or I need to modify the SDK/app code?
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Re: Bug encountered while opening a Code::blocks project ??
« Reply #6 on: January 29, 2010, 10:26:50 am »
Can this be done with a plugin or I need to modify the SDK/app code?
A plugin can do. Check the autosave plugin. And/or even adapt it.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: Bug encountered while opening a Code::blocks project ??
« Reply #7 on: January 30, 2010, 09:01:00 am »
It works, I use the kernel-sources to test opening very much files in C::B.  :D
So... just for the record: How long does it take (for how many files)?

Sorry for the misinformation, I thought I used it to open all files, but now I'm sure I only used it to measure the time it took to open and parse a very large project (> 21000 files).
Yesterday I started to open the kernel-project and let C::B open all files. This runs now since about 24 hours but is not ready, I am not sure about the amount of files that is opened now (more than the half of all surely), but it's definitely absolutely unusable.