Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Archive

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

_exclude.php


Go to End
Reply

11 Posts   3636 Views

Avatar
Nathan Cox

21 June 2007 at 11:54am Community Member, 99 Posts

Hi, I was experimenting the other day and wanted to exclude certain directories from being processed. _exclude.php does the trick, but I was wondering if it wouldn't make more sense to have a way of specifying modules to EXCLUDE instead of INCLUDE.
With the current

ManifestBuilder::$restrict_to_modules = array(
'cms',
'jsparty',
'mysite',
'sapphire'
);

you have to update it every time you add a new module you want processed, right?
I think it would be handy to have the option of saying

ManifestBuilder::$exclude_modules = array(
'yoursite'
);

or even ManifestBuilder::$exclude_modules[] = 'yoursite';

Just a thought..

Avatar
xmedeko

21 June 2007 at 2:13pm Community Member, 94 Posts

_exclude.php is just what i need. thanks :-)

Avatar
Sam

21 June 2007 at 10:38pm Administrator, 685 Posts

The next version of SilverStripe requires the presence of an _config.php in each of your module folders. So that by default, non-SS folders won't be interpreted as part of SilverStripe.

Avatar
Nathan Cox

22 June 2007 at 10:34am Community Member, 99 Posts

That makes sense...speaking of which, do you guys have some kind of timeframe for 2.1?

Avatar
Sigurd

22 June 2007 at 6:15pm Forum Moderator, 628 Posts

It depends on Google Summer of Code to a big degree. The first milestone for their work is July 9 so hopefully shortly after that we'll be able to see how quickly all their work is going...

Avatar
Markus

11 July 2007 at 10:22pm Google Summer of Code Hacker, 152 Posts

I just committed a change to the ManifestBuilder to the GSoC branch so that now it is possible to exclude any directory (and all its subdirectories) from inclusion by adding a _manifest_exclude file.

The changes are in r38451. Maybe you can add that already to the 2.0.2 version since after reviewing the code.
It's a small change and but I think nevertheless it would help a lot of people.

Avatar
Sigurd

11 July 2007 at 11:16pm Forum Moderator, 628 Posts

I'm not sure it is needed when 2.0.2 automatically assumes folders are not to be included; you can download this code right now...

(as sam mentioned, you must specifically include each directory you want... )

Avatar
Markus

12 July 2007 at 9:36pm (Last edited: 12 July 2007 9:36pm), Google Summer of Code Hacker, 152 Posts

Is it not so that all (top-level) directories with an _config.php file and all of its subdirectories are automatically included?

With the patch you can exclude subdirectories and also directories of other applications that use an _config.php file.

Go to Top