Thanks, Don, very useful.. On Wed, Apr 13, 2011 at 1:53 PM, Donald R. Ziesig <[email protected]> wrote:
> Domizio! > > I didn't think I need anything quite so sophisticated, so I just went into > the pre31 files and pasted the instrumentation line before all occurrences > of </content: and </form (after making a backup just in case). Et voila! > the funny little instrumentation lines showed up all over the place, even in > the rapid pages :-D . I edited about 15 files and made about 40 changes. > I may have missed some of the constructs that also might need > instrumentation ( </whatever? ), so I may have to go back later and add > them, but for now, I'm happy. > > This essentially duplicates the changes I made in rails way back when but > in dryml and dryml.erb rather than html.erb. > > Don Z. > > P.S. If anyone is interested, I'll send them a tgz file of the pre31 with > my changed included. If there is a lot of interest, I'll generate patch > files as well. I may have to do that anyway as soon as pre32 appears :'( > > On 4/13/2011 12:48 PM, Domizio Demichelis wrote: > > In the old days of rails 1.2, I used the 'annotate_renders' plugin, that > was adding html comments to each render. I modified it for my own purposes > so it was commenting start and end of each template with the data I needed > and for each used segment. Now I don't know whether any similar solution > exists. > > If I had to write it, I would probably implement it by patching some rails > method, putting it in an engine, so you could use it by just adding it to > the :development bundler group in your Gemfile. No patch when not in > development. nice and clean. > > You should try to write it, it shouln't be too complicated. ;-) > > ciao > dd > > On Wed, Apr 13, 2011 at 12:12 PM, Donald R. Ziesig <[email protected]>wrote: > >> I have been using the rails equivalent of the following for years and it >> has simplified my life significantly when working on a large website (I >> patched the rails generators to put it at the bottom of the files, but I'm >> not quite up to that in hobo yet). In rails, it helped point me to the >> right files, especially if I had been working elsewhere on the site for a >> while when I get a bug report (yeah :-( ). >> >> I manually put it in appropriate places in my hobo dryml files and it >> helps just like it did BH (before Hobo) provided I'm the one who generated >> the file. Could we have the hobo dryml generators put something like it in >> the appropriate places, too? >> >> <% if Rails.env == 'development' %> <p class="dryml_file">"#{__FILE__}, >> #{__LINE__}"</p> <% end %> >> >> It causes one or more extraneous lines in the output as in: >> >> "app/views/front/index.dryml, 28" >> >> that only appear in the development mode, and can be easily removed by >> hiding the dryml_file class in the css if you really need to see the precise >> appearance of your pages during development. I usually set its css to the >> smallest-readable font to keep it as unobtrusive as possible. >> >> In my case, having this available would eliminate most of the "Where is >> .... " posts I make to the group :-[ . >> >> Thanks, >> >> Don Z. >> >> P.S. It could be simplified by leaving off the conditional and having >> the css hide the output in production mode, but doing so would leave bits >> and pieces of extraneous html hanging around in the page outputs, so I think >> my current implementation is preferable. >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Hobo Users" group. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to >> [email protected]. >> For more options, visit this group at >> http://groups.google.com/group/hobousers?hl=en. >> >> > -- > You received this message because you are subscribed to the Google Groups > "Hobo Users" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/hobousers?hl=en. > > > -- > You received this message because you are subscribed to the Google Groups > "Hobo Users" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/hobousers?hl=en. > -- Owen Dall, Chief Systems Architect Barquin International www.barquin.com Cell: 410-991-0811 -- You received this message because you are subscribed to the Google Groups "Hobo Users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/hobousers?hl=en.
