Add extra dependencies to Projects

Let us know what you would like to see in the next version of this software

Moderator: kfury77

Forum rules
Please follow these guidelines when posting feature requests. This will help to increase the value of your contribution.
  • Do not create new topics for already requested features. Add your comments to the existing feature request topics instead;
  • Create separate topic for each feature suggestion. Do NOT post a number of non-related feature suggestions in a single topic;
  • Give your topic a meaningful title. Do NOT create topics with meaningless titles, such as "My Suggestion" or "My Problem".
Please note that we DO READ all suggestions, even if a reply is not posted. Thanks!
Post Reply
User avatar
pmk65
Posts: 678
Joined: Sun Dec 20, 2009 9:58 pm
Location: Copenhagen, Denmark

Add extra dependencies to Projects

Post by pmk65 »

Im currently working on a PHP CodeSniffer plugin for WeBuilder.
It uses a sniff file for validating the PHP code, and you can manually select different sniffer files in the plugin.

It would be nice if there was a way to add extra dependencies to Project.
That way I could setup different sniff files for each project and don't have to bother with changing the plugin settings every time I switch to a different project.
There are 10 types of people in the world: Those who understand binary and those who don't.
User avatar
Aivars
Blumentals Software Developer
Posts: 2462
Joined: Thu Aug 22, 2002 1:40 pm
Location: Latvia

Re: Add extra dependencies to Projects

Post by Aivars »

Could you give me some specific samples of the extra dependencies? I'm not sure I understand entirely, would that be something like a list of files for each project, to be used as meta-data for plugins?

Maybe you can change the plugin instead, to contain global settings and project-specific settings. You can use Script.ProjectSettings.SelectedProjectName to figure out which project is currently active.
Blumentals Software Programmer
User avatar
pmk65
Posts: 678
Joined: Sun Dec 20, 2009 9:58 pm
Location: Copenhagen, Denmark

Re: Add extra dependencies to Projects

Post by pmk65 »

With PHP CodeSniffer you select a sniff config to use when checking the code.
But different projects might require different sniff configs, depending on how they have defined their standard. (i.e. Wordpress uses a different standard than Drupal etc.)

I probably could incorporate some Project config directly in my plugin. But then you would have to configure each project two different places. That's why I want more options on the Projects config options.
There are 10 types of people in the world: Those who understand binary and those who don't.
User avatar
Aivars
Blumentals Software Developer
Posts: 2462
Joined: Thu Aug 22, 2002 1:40 pm
Location: Latvia

Re: Add extra dependencies to Projects

Post by Aivars »

So, ideally if a plugin could add new pages to Project Settings dialog? This doesn't sound easy but I'll consider if and how that can be added.
Blumentals Software Programmer
User avatar
pmk65
Posts: 678
Joined: Sun Dec 20, 2009 9:58 pm
Location: Copenhagen, Denmark

Re: Add extra dependencies to Projects

Post by pmk65 »

Yes. I got an idea to implement this.

If a plugin have a project.ini (with a format similar to plugins properties.ini, with type, label text and default value) then the fields defined there would be shown on the Create/Edit Project popup.
Any values entered in these fields would be saved in the "settings/projects.ini" along with the standard Projects settings.

That way it will be easy to access those fields from within a plugin using a TIniFile object.

All custom fields could be displayed on an extra tab.
There are 10 types of people in the world: Those who understand binary and those who don't.
Post Reply