Page 1 of 1
sub-directories in /plugins but not /templates
Posted: Tue Aug 02, 2005 11:50 pm
by gwilsonmail
The plugin mechanism supports sub-directories - That is Serendipity finds plugins you have in a sub-directory of the plugins folder. I find that very useful for managing the additional plugins from CVS and for experimental plugins from others.
Templates are now supported by Serendipity but sub-directories are not supported.
Is this by design or an omission?
Posted: Wed Aug 03, 2005 5:07 am
by wesley
The plugins... they're searched under any subfolder within 'plugins'. Yes.
The templates... they're searched within 'templates' and each templates
are assumed to be contained in a subfolder of 'templates'.
So both are effectively stored in subfolders of the respective parent
folders. Serendipity finds plugins in a subfolder of plugins. It also finds
templates in a subfolder of templates. So in this sense, of course s9y
supports subfolders for templates.
But this is obvious.
Therefore, I'm assuming that you didn't word your first sentence correctly
and meant that you attempted to put a plugin within a subfolder OF a
subfolder within the plugins folder and found that it still worked?
e.g. usually the plugins reside in this sort of folder...
/plugins/serendipity_event_entrypaging
but you've made a subfolder in plugins and put plugins IN that?
/plugins/experimental/serendipity_event_entrypaging
like so? I haven't tried it because I'm away from my server at the moment
but if this is what you meant, please do tell.
Posted: Wed Aug 03, 2005 7:01 am
by gwilsonmail
/plugins/experimental/serendipity_event_entrypaging
This certainly works for plugins. It's even documented as such.
but a similar structure for a template does not work
Posted: Wed Aug 03, 2005 9:45 am
by Col. Kurtz
Doesnt 0.9 support subfolders for templates, if you use different templates for different categories?
from:
http://blog.s9y.org/archives/50-Maintai ... -blog.html
You can not only choose a different maintemplate ("blue", "kubrick", "moz-modern" etc.) - you can even select a sub-template of your template. Like "kubrick/category1", "kubrick/category2" and so forth. The directory structure of a "sub-template" is the same as a completely different template. So you have all options to fully tweak your templates dependant on the selected category.
I havent tried this yet.
Posted: Wed Aug 03, 2005 2:53 pm
by gwilsonmail
Doesnt 0.9 support subfolders for templates, if you use different templates for different categories?
yes allowing you to display each category with a different template.
i was simply trying to organize the folder structure on the server.
Posted: Wed Aug 03, 2005 6:21 pm
by garvinhicking
Thanks for this hin; in fact it was not possible to have subdirectories.
I've just committed a patch to 0.9 that allows this. BTW, Spartacus can also maintain your templates since 0.9!
Regards,
Garvin
Posted: Wed Aug 03, 2005 6:52 pm
by Col. Kurtz
garvinhicking wrote:BTW, Spartacus can also maintain your templates since 0.9!
And I´m loving it! Supersize please.
Posted: Fri Aug 05, 2005 1:50 am
by gwilsonmail
Thanks for the fix Garvin.
I note the following in the 0.9 changelog
Version 0.9 ()
------------------------------------------------------------------------
* Make template directory allow to contain subdirectories with more
templates. This allows you to symbolically link the "additional_themes"
CVS directory within your templates path, just like you can do
with the "additional_plugins" directory already (garvinhicking)
I tried to link an additional_plugins directory using a windows shortcut to a local folder with the latest additional_plugins from CVS. It doesn't work. How do you "symbolically link the "additional_themes" correctly. Being able to do this would be of great help.
Posted: Fri Aug 05, 2005 11:50 am
by garvinhicking
I tried it on my linux system; I just have my "templates/" directory, and put "templates/additional_themes" inside there. So I have:
templates/default
templates/kubrick
...
templates/additional_themes/perun_blue
templates/additional_themes/dreisechzig
...
And this works on my latest 0.9...did you fetch the recent nightly where the docs/NEWS contains the note about the new functionality?
I don't really know how this works on windows; does the plugin linking work with the same method?
Regards,
Garvin
Posted: Fri Aug 05, 2005 4:54 pm
by gwilsonmail
Neither plugins nor templates works using short cuts in windows.
i do have the latest build via SVN.
Posted: Fri Aug 05, 2005 6:28 pm
by garvinhicking
Yes, I thought so that it wouldn'T work on Windows.
Maybe if using true NTFS links it works. But I don't know how to build them.
Regards,
Garvin