Quoting Neil Williams <[EMAIL PROTECTED]>:
On Tuesday 17 January 2006 8:21 pm, Derek Atkins wrote:
I was wondering what you think about sharing gnucash.css between
the htdocs (website) and the mail-search modules? Do you think
it's reasonable to work towards sharing the same css and support
(iconsm etc)?
Yes, but I thought about the two servers and wondered how it would be done.
It is, essentially, the same file but it's actually quite small and I think
the bigger benefit comes from sharing the menu*.phtml files.
Sharing the menu files would mean that the search page links are always in
step with all the other pages. It seems strange for one page to have the
wrong links like that. search.php can include the menu files directly but
that's extra network traffic each time the search page is displayed. Better
if - once I'm done - future changes to the en/menu/* files get propagated to
mail-search.
That was sort of my thought, too. I'm sure there's more than just the
.css that needs to be "shared". There's also the icons, the graphics,
the menu links, etc.
To me it's not the size that matters -- it's knowing that you need to keep
two files in sync. That's why I'm imaginging that it would be "best" if
we could just have one file in SVN that appears two places in the checkout
using svn:externals.
We COULD leave notes in every duplicated file "if you make changes here,
be sure to change <other file> the same way"... But if we can figure out
some way to use the exact same file on both servers (without changes) -- that
would be ideal.... I'm worried about having multiple files in SVN that
we need to keep in sync.
Problem: We'd have to have absolute URL's in the menu links which makes it
hard to test the htdocs/ svn locally - or use a PHP redirect but that would
be executed each time, not just when testing. That could be a real PITA.
Alternatively, scripting the links means either generating them every time a
page is viewed according to the current host (bad) or creating a bespoke
commit hook that tries to mangle the local links to absolute (sounds like
trouble).
Hmm.. Good point. I would think that for testing htdocs one could
(temporarily) fix the file and use relative paths... and then return
back when it's done.
Once I'm done here, the CSS isn't likely to change that much - and there will
be new parts to gnucash.css that aren't needed in search.css. It's as easy to
copy the CSS file across locally between the two trees and make a separate
commit, if there are changes that need to be shared. I'll make sure there
aren't any overlaps so if it's better to have just one CSS with some
redundant content, we can do that too.
As you mention, it's not necessarily the CSS, but also all the other
supporting files (e.g. menus.phtml). Also, the fact that it's not changing
much implies that it's even MORE important to figure out a way to consolidate.
If you're changing a file multiple times a week it's easy to remember to
propagate changes.. If you're modifying it once every year or two, that
memory fades and you forget you need to make changes in multiple places.
Yet another reason I want to see if we can make changes in one place and
have it appear on both servers at once.
One approach to sharing would be moving gnucash.css from the top-level
and into its own subdirectory (htdocs/css/gnucash.css) and then
in the mail-search we could use the subversion svn:externals
<snip>
It would imply that changes to the css get propagated into both
locations, which would make it much easier to keep it all in sync.
What do you think?
Whichever way we do it, sharing one site across two servers is going to make
things difficult. We can't move mail-search without moving the list archives.
If we want mail-search truly joined up with the rest of the content the only
real solution is to move the gnucash.org website to lists.gnucash.org.
Note that I didn't say "sharing one site across two servers".. I'm saying
that we could share some of the files across both sites/servers, and have
only one "copy" in the SVN repository that show up on both servers. For
example, there's no reason we need to have the gnucash.png file in SVN twice.
We may just have to live with copying files between sites and adapting where
necessary.
We may... But it would be nice if we didn't have to..
-derek
--
Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
Member, MIT Student Information Processing Board (SIPB)
URL: http://web.mit.edu/warlord/ PP-ASEL-IA N1NWH
[EMAIL PROTECTED] PGP key available
_______________________________________________
gnucash-devel mailing list
[email protected]
https://lists.gnucash.org/mailman/listinfo/gnucash-devel