News:

The new Release 25.03 is out! You can download binaries for Windows and many major Linux distros here .

Main Menu

Add Command Line Argument to plugin?

Started by yasman, January 29, 2012, 01:49:11 PM

Previous topic - Next topic

yasman

I've searched, but can't seem to find..

Short of re-compiling the source of course, is there a way to change the arguments of a specific plugin?

In this code I would like to add --force to cppcheck?

Thanks for any advice!

oBFusCATed

No, you can't, you have to change the code and them compile it.
(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!]

stahta01

#2
In theory yes, create a script file with same name as exec the CB program calls the script file.
And, the script file calls the exec. Note, in this exact instance it might not work.

NOTE: This is NOT for adding a command line argument to the plugin; but, adding a command line argument to the exe called by the plugin.

Tim S.
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]

MortenMacFly

Quote from: oBFusCATed on January 29, 2012, 02:06:28 PM
No, you can't, you have to change the code and them compile it.
True, but it should be very easy to patch. E.g. prompting for additional parameter before running cppcheck should be a 3-5 liner. Patches are welcome.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

yasman

Thanks for the replies, and yes it should be an easy patch..

After looking at the code, I found this dirty workaround...

I added the following include path (although I'm sure it will break my build...):

 
Quote./" --force "./

Worked good to add the argument I wanted.  Thanks to all.