Jeff Barczewski
2006-Jun-28 14:35 UTC
[Masterview-devel] I would like to do a release today for 0.2.1, let me know if that is ok, and need input on a few new config items
I would like to do a release for 0.2.1 today since it has an important fix to support Mongrel. I found out that I needed to change the init slightly to support running from mongrel otherwise MasterView didn''t get loaded. Mongrel has been showing much popularity these days, so I would like to get this out asap. That being said, there is one other thing that I would like to add to the initialization and I need some help with the naming and explanation around that. I added the feature to image_tag, stylesheet_link, and javascript_include so that if you don''t specify an absolute in the attr_value that it will use a regular expression to find the relative path from the src attribute. Currently these are constants embedded in each of these three directives, however after talking with Ed Howland one of our users, the way he was using things it might be better if these are configurable constants. This would allow you to put your images, javascripts, and stylesheets elsewhere on your file system for designing and not be locked into public/*. So I am looking for naming and description for JAVASCRIPT_SRC_EXTRACT_REGEX = /public\/javascripts\/(.*)/ IMAGE_SRC_EXTRACT_REGEX = /public\/images\/(.*)/ STYLESHEET_SRC_EXTRACT_REGEX = /public\/stylesheets\/(.*)/ Basically the way I designed these is that if the src value finds a match with this regular expression then it takes the contents of the first group (which in these examples is the relative path) and uses that for the path to the appropriate helper. If the regex did not match, then it just uses the entire contents of src since it doesn''t know what else to do. Hope that makes sense. Deb I can make the updates if you can just help me with the naming and description for these. I guess this doesn''t have to be put in 0.2.1 but since it was fresh in my mind I thought I would knock it out if possible. I have also updated the content with the diagram and put a new shorter video up. Thanks, Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/masterview-devel/attachments/20060628/449c6895/attachment.html
Deb Lewis
2006-Jun-28 14:51 UTC
[Masterview-devel] I would like to do a release today for 0.2.1, let me know if that is ok, and need input on a few new config items
Jeff - by all means do the update for mongrel today. (and include your fine new diagrams!) I''ll look at the naming/config issue for assert refs and get back to you asap, but have meetings this morning so I''ll have to juggle it in. Suggest not holding the update for this; let''s not rush config additions and names until we''ve had a chance to consider properly, better to let it wait a day . Ed''s example is actually a case I''ve already run into with my own stylesheets and images, so it was already kind of in my mind to look at while going over directives impls and asset support. I think his suggestion is on the right track, it''s roughly what I''d been thinking of. I keep a separate design-time stash of stylesheets that have a more palatable rel ref for use in my MasterView templates; the stylesheets themselves actually just contain the nasty ../../public/stylesheets sorts of paths (and can be easily replaced or modified when working separately from my rails dev setup), along with any design-time overrides/additions I want in my styles. ~ Deb>> I added the feature to image_tag, stylesheet_link, and javascript_includeso that>> if you don''t specify an absolute in the attr_value that it will use aregular expression>> to find the relative path from the src attribute. Currently these areconstants>> embedded in each of these three directives, however after talking with EdHowland>> one of our users, the way he was using things it might be better if theseare>> configurable constants.-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/masterview-devel/attachments/20060628/9cef927f/attachment.html
Jeff Barczewski
2006-Jun-28 14:57 UTC
[Masterview-devel] I would like to do a release today for 0.2.1, let me know if that is ok, and need input on a few new config items
Sounds good! Will do the mongel release this morning. On 6/28/06, Deb Lewis <djlewis at acm.org> wrote:> > Jeff - by all means do the update for mongrel today. (and include your > fine new diagrams!) > > I''ll look at the naming/config issue for assert refs and get back to you > asap, but have meetings this morning so I''ll have to juggle it in. Suggest > not holding the update for this; let''s not rush config additions and > names until we''ve had a chance to consider properly, better to let it wait a > day . > > Ed''s example is actually a case I''ve already run into with my own > stylesheets and images, so it was already kind of in my mind to look at > while going over directives impls and asset support. I think his suggestion > is on the right track, it''s roughly what I''d been thinking of. I keep a > separate design-time stash of stylesheets that have a more palatable rel ref > for use in my MasterView templates; the stylesheets themselves actually just > contain the nasty ../../public/stylesheets sorts of paths (and can be easily > replaced or modified when working separately from my rails dev setup), along > with any design-time overrides/additions I want in my styles. > > ~ Deb > > >> I added the feature to image_tag, stylesheet_link, and > javascript_include so that > >> if you don''t specify an absolute in the attr_value that it will use a > regular expression > >> to find the relative path from the src attribute. Currently these are > constants > >> embedded in each of these three directives, however after talking with > Ed Howland > >> one of our users, the way he was using things it might be better if > these are > >> configurable constants. > > _______________________________________________ > Masterview-devel mailing list > Masterview-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/masterview-devel > >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/masterview-devel/attachments/20060628/af9eb45f/attachment-0001.html
Ed Howland
2006-Jun-28 15:17 UTC
[Masterview-devel] I would like to do a release today for 0.2.1, let me know if that is ok, and need input on a few new config items
On 6/28/06, Deb Lewis <djlewis at acm.org> wrote:> > > > Ed''s example is actually a case I''ve already run into with my own > stylesheets and images, so it was already kind of in my mind to look at > while going over directives impls and asset support. I think his suggestion > is on the right track, it''s roughly what I''d been thinking of. I keep a > separate design-time stash of stylesheets that have a more palatable rel ref > for use in my MasterView templates; the stylesheets themselves actually just > contain the nasty ../../public/stylesheets sorts of paths (and can be easily > replaced or modified when working separately from my rails dev setup), along > with any design-time overrides/additions I want in my styles. > > ~ Deb >Nice tip, I''ll pass that along to Jeswin. And I''m incouraging him to join this list. Lurking he can learn, and he has a lot of good ideas design-wise. He too is a type of masterview user. The problem I expressed to Jeff last night (btw, great presentation on RailsConf Jeff, ) was that under Linux I can easily create a symbolic link from app/views/masterview/images to public/images. But Jeswin is working out of Subversion, on Windows. I don''t know any way to have symbolic links in WinXP.I don''t want his images (or other stylesheets or javascripts) to get out of sync with the true place for these files. Also, designers like to group related images into subdirectories under the main images dir. So, I think Jeff''s explanation of his current implementation should allow for that. I''ll get an experimental HEAD tag from SVN tonight and try it out.> >> I added the feature to image_tag, stylesheet_link, and javascript_include > so that > >> if you don''t specify an absolute in the attr_value that it will use a > regular expression > >> to find the relative path from the src attribute. Currently these are > constants > >> embedded in each of these three directives, however after talking with Ed > Howland > >> one of our users, the way he was using things it might be better if these > are > >> configurable constants.-- Ed Howland http://greenprogrammer.blogspot.com