From m.kristian at web.de Tue Jul 1 14:41:45 2008 From: m.kristian at web.de (kristian) Date: Wed, 2 Jul 2008 00:11:45 +0530 Subject: [Erector-devel] problems with form_for In-Reply-To: <1d7ddd110806301735w6524e46fide236d367f52e9db@mail.gmail.com> References: <932801940806291207i39ad56g22e281a324f98d9@mail.gmail.com> <1d7ddd110806301735w6524e46fide236d367f52e9db@mail.gmail.com> Message-ID: <932801940807011141w31a8bca1g5b5f237c4aed7562@mail.gmail.com> hello Brian, On 7/1/08, Brian Takita wrote: > On Sun, Jun 29, 2008 at 12:07 PM, kristian wrote: >> >> I also setup a resource generator creating nice classes for a restful >> resource in rails. any interest ? > Yes. Do you have some code samples? Probably the easiest way to show > them off is using http://pastie.caboo.se >> see http://pastie.org/225699 these are the template files for the view generator. the file view_new.rb and view_show.rb are essentially the same as view_edit.rb. the rest of the generator is "stolen" from rails source tree and modified it a little. the html is my personal style (fieldsets and legends) but can be easily changed to want rails produces. with regards Kristian >> with regards >> Kristian > Cheers, > Brian >> _______________________________________________ >> Erector-devel mailing list >> Erector-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/erector-devel >> > -- Kristian Meier & Saumya Sharma & Sanuka Mulavelil Malayabhavan Cheriyanad, PO Chengannur-689511 Allepey District, Kerala, INDIA tel: +91 479 3241550 pgp: http://tinyurl.com/2f35fp my home: http://tinyurl.com/3bnkv9 From brian.takita at gmail.com Mon Jul 7 00:16:11 2008 From: brian.takita at gmail.com (Brian Takita) Date: Sun, 6 Jul 2008 21:16:11 -0700 Subject: [Erector-devel] problems with form_for In-Reply-To: <932801940807011141w31a8bca1g5b5f237c4aed7562@mail.gmail.com> References: <932801940806291207i39ad56g22e281a324f98d9@mail.gmail.com> <1d7ddd110806301735w6524e46fide236d367f52e9db@mail.gmail.com> <932801940807011141w31a8bca1g5b5f237c4aed7562@mail.gmail.com> Message-ID: <1d7ddd110807062116h4320793k4249ab1687801989@mail.gmail.com> On Tue, Jul 1, 2008 at 11:41 AM, kristian wrote: > hello Brian, > > > > On 7/1/08, Brian Takita wrote: >> On Sun, Jun 29, 2008 at 12:07 PM, kristian wrote: >>> >>> I also setup a resource generator creating nice classes for a restful >>> resource in rails. any interest ? >> Yes. Do you have some code samples? Probably the easiest way to show >> them off is using http://pastie.caboo.se >>> > > see http://pastie.org/225699 > > these are the template files for the view generator. the file > view_new.rb and view_show.rb are essentially the same as view_edit.rb. > the rest of the generator is "stolen" from rails source tree and > modified it a little. the html is my personal style (fieldsets and > legends) but can be easily changed to want rails produces. Kristian, the generators look good to me. We actually have a task called erect that translates erb into Erector classes. The idea is Rails will generate erb templates and then we can run erect on it. This ensures that "proper" Rails Erector templates will be generated. We (Alex, Jim, and I) came to the conclusion that its better not to add yet another generator and use the built in generators instead. However, I'm not sure how fully baked the erect script is though, since I have not been using it lately. Alex, can you comment on this? Is it still compatible with the latest changes? Thanks, Brian > > with regards > Kristian > >>> with regards >>> Kristian >> Cheers, >> Brian >>> _______________________________________________ >>> Erector-devel mailing list >>> Erector-devel at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/erector-devel >>> >> > > > -- > Kristian Meier & Saumya Sharma & Sanuka > Mulavelil Malayabhavan > Cheriyanad, PO Chengannur-689511 > Allepey District, Kerala, INDIA > > tel: +91 479 3241550 > pgp: http://tinyurl.com/2f35fp > my home: http://tinyurl.com/3bnkv9 > From brian.takita at gmail.com Mon Jul 7 00:18:11 2008 From: brian.takita at gmail.com (Brian Takita) Date: Sun, 6 Jul 2008 21:18:11 -0700 Subject: [Erector-devel] problems with form_for In-Reply-To: <1d7ddd110807062116h4320793k4249ab1687801989@mail.gmail.com> References: <932801940806291207i39ad56g22e281a324f98d9@mail.gmail.com> <1d7ddd110806301735w6524e46fide236d367f52e9db@mail.gmail.com> <932801940807011141w31a8bca1g5b5f237c4aed7562@mail.gmail.com> <1d7ddd110807062116h4320793k4249ab1687801989@mail.gmail.com> Message-ID: <1d7ddd110807062118g15f0d004hdf1602b89d514627@mail.gmail.com> On Sun, Jul 6, 2008 at 9:16 PM, Brian Takita wrote: > On Tue, Jul 1, 2008 at 11:41 AM, kristian wrote: >> hello Brian, >> >> >> >> On 7/1/08, Brian Takita wrote: >>> On Sun, Jun 29, 2008 at 12:07 PM, kristian wrote: >>>> >>>> I also setup a resource generator creating nice classes for a restful >>>> resource in rails. any interest ? >>> Yes. Do you have some code samples? Probably the easiest way to show >>> them off is using http://pastie.caboo.se >>>> >> >> see http://pastie.org/225699 >> >> these are the template files for the view generator. the file >> view_new.rb and view_show.rb are essentially the same as view_edit.rb. >> the rest of the generator is "stolen" from rails source tree and >> modified it a little. the html is my personal style (fieldsets and >> legends) but can be easily changed to want rails produces. > Kristian, the generators look good to me. We actually have a task > called erect that translates erb into Erector classes. > The idea is Rails will generate erb templates and then we can run > erect on it. This ensures that "proper" Rails Erector templates will > be generated. > > We (Alex, Jim, and I) came to the conclusion that its better not to > add yet another generator and use the built in generators instead. > However, I'm not sure how fully baked the erect script is though, > since I have not been using it lately. Of course this decision is open to be changed if its better to go with the generators. > > Alex, can you comment on this? Is it still compatible with the latest changes? > > Thanks, > Brian >> >> with regards >> Kristian >> >>>> with regards >>>> Kristian >>> Cheers, >>> Brian >>>> _______________________________________________ >>>> Erector-devel mailing list >>>> Erector-devel at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/erector-devel >>>> >>> >> >> >> -- >> Kristian Meier & Saumya Sharma & Sanuka >> Mulavelil Malayabhavan >> Cheriyanad, PO Chengannur-689511 >> Allepey District, Kerala, INDIA >> >> tel: +91 479 3241550 >> pgp: http://tinyurl.com/2f35fp >> my home: http://tinyurl.com/3bnkv9 >> > From m.kristian at web.de Mon Jul 7 05:42:54 2008 From: m.kristian at web.de (kristian) Date: Mon, 7 Jul 2008 15:12:54 +0530 Subject: [Erector-devel] problems with form_for In-Reply-To: <1d7ddd110806301735w6524e46fide236d367f52e9db@mail.gmail.com> References: <932801940806291207i39ad56g22e281a324f98d9@mail.gmail.com> <1d7ddd110806301735w6524e46fide236d367f52e9db@mail.gmail.com> Message-ID: <932801940807070242j4d002f9bt7e629981a4ea35be@mail.gmail.com> On 7/1/08, Brian Takita wrote: > On Sun, Jun 29, 2008 at 12:07 PM, kristian wrote: >> hello, > Hello Kristian, >> >> I hope this is the right way to send a patch. >> >> my story is that I wanted to upgrade rails from 2.0.2 to 2.1.0 and >> markaby gave me some problems. than I came across erector and I >> immediately liked the OO approach. so I gave it a trial, but I ran >> into problems with form_for which is used a lot in my application. >> >> so dug into the code and found a simple patch. I did not test it with >> other version since I do not understand your current implementation >> completely - I might have missed something. the patch works for me >> using rails 2.1.0. in case your are interested tell me where I can >> post the patch. > Thank you for giving Erector a try. I hope its going well for you. yes, I liked markaby at once, but found it a bit too easy to write insecure html (css issues), but after seeing the OO approach and seeing the proper escaping even on parameters of rails helper, I immediately switch my codebase. > > Also, thank you for making the patch. I don't think you attached the > patch to the email though. > The best way to send patches is to use Erector's rubyforge page at > http://rubyforge.org/tracker/?atid=18572&group_id=4797&func=browse > I will update the docs. > did you see the patch ? with regards Kristian From brian.takita at gmail.com Mon Jul 7 17:55:13 2008 From: brian.takita at gmail.com (Brian Takita) Date: Mon, 7 Jul 2008 14:55:13 -0700 Subject: [Erector-devel] problems with form_for In-Reply-To: <932801940807070242j4d002f9bt7e629981a4ea35be@mail.gmail.com> References: <932801940806291207i39ad56g22e281a324f98d9@mail.gmail.com> <1d7ddd110806301735w6524e46fide236d367f52e9db@mail.gmail.com> <932801940807070242j4d002f9bt7e629981a4ea35be@mail.gmail.com> Message-ID: <1d7ddd110807071455y755e2660ib2c42ce0db4548c@mail.gmail.com> On Mon, Jul 7, 2008 at 2:42 AM, kristian wrote: > On 7/1/08, Brian Takita wrote: >> On Sun, Jun 29, 2008 at 12:07 PM, kristian wrote: >>> hello, >> Hello Kristian, >>> >>> I hope this is the right way to send a patch. >>> >>> my story is that I wanted to upgrade rails from 2.0.2 to 2.1.0 and >>> markaby gave me some problems. than I came across erector and I >>> immediately liked the OO approach. so I gave it a trial, but I ran >>> into problems with form_for which is used a lot in my application. >>> >>> so dug into the code and found a simple patch. I did not test it with >>> other version since I do not understand your current implementation >>> completely - I might have missed something. the patch works for me >>> using rails 2.1.0. in case your are interested tell me where I can >>> post the patch. >> Thank you for giving Erector a try. I hope its going well for you. > > yes, I liked markaby at once, but found it a bit too easy to write > insecure html (css issues), but after seeing the OO approach and > seeing the proper escaping even on parameters of rails helper, I > immediately switch my codebase. > >> >> Also, thank you for making the patch. I don't think you attached the >> patch to the email though. >> The best way to send patches is to use Erector's rubyforge page at >> http://rubyforge.org/tracker/?atid=18572&group_id=4797&func=browse >> I will update the docs. >> > > did you see the patch ? Yes, I saw that the patch was created, however it says "No Files Currently Attached". Perhaps its a rubyforge issue? > > with regards > Kristian > From alex at pivotallabs.com Tue Jul 29 14:36:10 2008 From: alex at pivotallabs.com (Alex Chaffee) Date: Tue, 29 Jul 2008 11:36:10 -0700 Subject: [Erector-devel] Erector gem? In-Reply-To: References: Message-ID: <7a93bd340807291136o59365e35m387dcf7fba32ce4c@mail.gmail.com> There's a well-documented release process at http://erector.rubyforge.org/developers.html and it's super easy to do so it could happen whenever you like. I'm in favor of releasing whatever we have on HEAD assuming the rest of the developers think it's stable. I'm cc'ing erector-devel to work out the details. - A On Tue, Jul 29, 2008 at 9:58 AM, Mike Grafton wrote: > Commoners, > > Is there any plan for releasing a new Erector gem? We could use it on > Casebook. > > I don't know what this requires, but I'm willing to help out if there's some > legwork to do. > > In the meantime I'm just going to install the trunk (from GitHub) into > vendor/plugins. > > Mike > -- Alex Chaffee alexch at gmail.com From alex at pivotallabs.com Tue Jul 29 14:36:16 2008 From: alex at pivotallabs.com (Alex Chaffee) Date: Tue, 29 Jul 2008 11:36:16 -0700 Subject: [Erector-devel] problems with form_for In-Reply-To: <1d7ddd110807062116h4320793k4249ab1687801989@mail.gmail.com> References: <932801940806291207i39ad56g22e281a324f98d9@mail.gmail.com> <1d7ddd110806301735w6524e46fide236d367f52e9db@mail.gmail.com> <932801940807011141w31a8bca1g5b5f237c4aed7562@mail.gmail.com> <1d7ddd110807062116h4320793k4249ab1687801989@mail.gmail.com> Message-ID: <7a93bd340807291136p237a65e4na270f75e8ee0f2ce@mail.gmail.com> I haven't used erect since the latest changes but it should still work ok. It was always intended to be a first-pass for converting templates that would still require manual grooming for everything to come out ok, but it should work pretty well (like 99%) with the standard scaffold generated templates. - A On Sun, Jul 6, 2008 at 9:16 PM, Brian Takita wrote: > On Tue, Jul 1, 2008 at 11:41 AM, kristian wrote: >> hello Brian, >> >> >> >> On 7/1/08, Brian Takita wrote: >>> On Sun, Jun 29, 2008 at 12:07 PM, kristian wrote: >>>> >>>> I also setup a resource generator creating nice classes for a restful >>>> resource in rails. any interest ? >>> Yes. Do you have some code samples? Probably the easiest way to show >>> them off is using http://pastie.caboo.se >>>> >> >> see http://pastie.org/225699 >> >> these are the template files for the view generator. the file >> view_new.rb and view_show.rb are essentially the same as view_edit.rb. >> the rest of the generator is "stolen" from rails source tree and >> modified it a little. the html is my personal style (fieldsets and >> legends) but can be easily changed to want rails produces. > Kristian, the generators look good to me. We actually have a task > called erect that translates erb into Erector classes. > The idea is Rails will generate erb templates and then we can run > erect on it. This ensures that "proper" Rails Erector templates will > be generated. > > We (Alex, Jim, and I) came to the conclusion that its better not to > add yet another generator and use the built in generators instead. > However, I'm not sure how fully baked the erect script is though, > since I have not been using it lately. > > Alex, can you comment on this? Is it still compatible with the latest changes? > > Thanks, > Brian >> >> with regards >> Kristian >> >>>> with regards >>>> Kristian >>> Cheers, >>> Brian >>>> _______________________________________________ >>>> Erector-devel mailing list >>>> Erector-devel at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/erector-devel >>>> >>> >> >> >> -- >> Kristian Meier & Saumya Sharma & Sanuka >> Mulavelil Malayabhavan >> Cheriyanad, PO Chengannur-689511 >> Allepey District, Kerala, INDIA >> >> tel: +91 479 3241550 >> pgp: http://tinyurl.com/2f35fp >> my home: http://tinyurl.com/3bnkv9 >> > _______________________________________________ > Erector-devel mailing list > Erector-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/erector-devel > -- Alex Chaffee alexch at gmail.com From kingdon at panix.com Wed Jul 30 02:00:02 2008 From: kingdon at panix.com (Jim Kingdon) Date: Wed, 30 Jul 2008 02:00:02 -0400 (EDT) Subject: [Erector-devel] Erector gem? In-Reply-To: <7a93bd340807291136o59365e35m387dcf7fba32ce4c@mail.gmail.com> (alex@pivotallabs.com) References: <7a93bd340807291136o59365e35m387dcf7fba32ce4c@mail.gmail.com> Message-ID: <20080730060002.6CEAD241B1@panix5.panix.com> > There's a well-documented release process at > http://erector.rubyforge.org/developers.html Agreed and thanks for the pointer. > it's super easy to do Uh, not yet. I have documented most of the hoops I had to jump through in web/developers.rb. I've mostly succeeded in making a 1.4.191 release but didn't get the new documentation out to the web site. The pages seemed to build OK but when it came time to sync, I got: rsync -av --delete rdoc/ jkingdon at rubyforge.org:/var/www/gforge-projects/erector/rdoc building file list ... done rsync: delete_file: unlink "/var/www/gforge-projects/erector/rdoc/dot/f_4.png" failed: Permission denied (13) Do I need to have different permissions on rubyforge? > I'm in favor of releasing whatever we have on HEAD assuming the rest > of the developers think it's stable. I'm cc'ing erector-devel to work > out the details. Well, I asked Brian about this last week and both of us were thinking it is a good time. From alex at pivotallabs.com Wed Jul 30 11:28:17 2008 From: alex at pivotallabs.com (Alex Chaffee) Date: Wed, 30 Jul 2008 08:28:17 -0700 Subject: [Erector-devel] Erector gem? In-Reply-To: <20080730060002.6CEAD241B1@panix5.panix.com> References: <7a93bd340807291136o59365e35m387dcf7fba32ce4c@mail.gmail.com> <20080730060002.6CEAD241B1@panix5.panix.com> Message-ID: <7a93bd340807300828v1b3ddccaydde4414e0d387345@mail.gmail.com> > rsync -av --delete rdoc/ > jkingdon at rubyforge.org:/var/www/gforge-projects/erector/rdoc > building file list ... done > rsync: delete_file: unlink > "/var/www/gforge-projects/erector/rdoc/dot/f_4.png" failed: Permission > denied (13) > > Do I need to have different permissions on rubyforge? Ah, the dreaded "works for me" problem. Since I'm the only one who's ever pushed the site, the files must be owned by me alone. I'll take a look. -- Alex Chaffee alexch at gmail.com From alex at pivotallabs.com Wed Jul 30 11:31:36 2008 From: alex at pivotallabs.com (Alex Chaffee) Date: Wed, 30 Jul 2008 08:31:36 -0700 Subject: [Erector-devel] Erector gem? In-Reply-To: <7a93bd340807300828v1b3ddccaydde4414e0d387345@mail.gmail.com> References: <7a93bd340807291136o59365e35m387dcf7fba32ce4c@mail.gmail.com> <20080730060002.6CEAD241B1@panix5.panix.com> <7a93bd340807300828v1b3ddccaydde4414e0d387345@mail.gmail.com> Message-ID: <7a93bd340807300831g70ee2678k2d5d1158f1339936@mail.gmail.com> :-( $ ssh alexch at erector.rubyforge.org This is a restricted account. You cannot execute anything here. Goodbye. Is the svn head up to date? If so, I'll push the docs myself... On Wed, Jul 30, 2008 at 8:28 AM, Alex Chaffee wrote: >> rsync -av --delete rdoc/ >> jkingdon at rubyforge.org:/var/www/gforge-projects/erector/rdoc >> building file list ... done >> rsync: delete_file: unlink >> "/var/www/gforge-projects/erector/rdoc/dot/f_4.png" failed: Permission >> denied (13) >> >> Do I need to have different permissions on rubyforge? > > Ah, the dreaded "works for me" problem. Since I'm the only one who's > ever pushed the site, the files must be owned by me alone. I'll take a > look. > > -- > Alex Chaffee > alexch at gmail.com > -- Alex Chaffee alexch at gmail.com From alex at pivotallabs.com Wed Jul 30 12:13:46 2008 From: alex at pivotallabs.com (Alex Chaffee) Date: Wed, 30 Jul 2008 09:13:46 -0700 Subject: [Erector-devel] Erector gem 0.4.191 released Message-ID: <7a93bd340807300913wda7ce18x3adc17b55f6bcfb7@mail.gmail.com> === 0.4.191 / 2008-07-29 * Renamed HtmlParts to Doc * Widget#doc is now a HtmlParts which proxies to the passed in IO stream * Better compatibility with standard Rails rendering because ActionController::Base#render and #render_widget now have the Widget write directly to _erbout. * ActionView::Base objects run with Erector now receive all of the instance variables * Erector works with erb layouts * Deprecate fake_erbout * Better handling for file with .html.rb extension. * Fix overwriting issue when using Rails helpers * New method Widget#character * Widget#nbsp without arguments now outputs a single non-breaking space. From alex at pivotallabs.com Wed Jul 30 12:20:47 2008 From: alex at pivotallabs.com (Alex Chaffee) Date: Wed, 30 Jul 2008 09:20:47 -0700 Subject: [Erector-devel] Erector gem 0.4.191 released Message-ID: <7a93bd340807300920l7eccecc3wb4bd316c8c5537b1@mail.gmail.com> === 0.4.191 / 2008-07-29 * Renamed HtmlParts to Doc * Widget#doc is now a HtmlParts which proxies to the passed in IO stream * Better compatibility with standard Rails rendering because ActionController::Base#render and #render_widget now have the Widget write directly to _erbout. * ActionView::Base objects run with Erector now receive all of the instance variables * Erector works with erb layouts * Deprecate fake_erbout * Better handling for file with .html.rb extension. * Fix overwriting issue when using Rails helpers * New method Widget#character * Widget#nbsp without arguments now outputs a single non-breaking space. From brian.takita at gmail.com Wed Jul 30 21:11:14 2008 From: brian.takita at gmail.com (Brian Takita) Date: Wed, 30 Jul 2008 18:11:14 -0700 Subject: [Erector-devel] Erector gem 0.4.191 released In-Reply-To: <7a93bd340807300913wda7ce18x3adc17b55f6bcfb7@mail.gmail.com> References: <7a93bd340807300913wda7ce18x3adc17b55f6bcfb7@mail.gmail.com> Message-ID: <1d7ddd110807301811y65b383bfge92c754e44c5c328@mail.gmail.com> Alex, thank you for releasing the latest version. On Wed, Jul 30, 2008 at 9:13 AM, Alex Chaffee wrote: > === 0.4.191 / 2008-07-29 > * Renamed HtmlParts to Doc > * Widget#doc is now a HtmlParts which proxies to the passed in IO stream > * Better compatibility with standard Rails rendering because > ActionController::Base#render and #render_widget now have the Widget > write directly to _erbout. > * ActionView::Base objects run with Erector now receive all of the > instance variables > * Erector works with erb layouts > * Deprecate fake_erbout > * Better handling for file with .html.rb extension. > * Fix overwriting issue when using Rails helpers > * New method Widget#character > * Widget#nbsp without arguments now outputs a single non-breaking space. > _______________________________________________ > Erector-devel mailing list > Erector-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/erector-devel > From alex at pivotallabs.com Wed Jul 30 23:06:48 2008 From: alex at pivotallabs.com (Alex Chaffee) Date: Wed, 30 Jul 2008 20:06:48 -0700 Subject: [Erector-devel] Erector gem 0.4.191 released In-Reply-To: <1d7ddd110807301811y65b383bfge92c754e44c5c328@mail.gmail.com> References: <7a93bd340807300913wda7ce18x3adc17b55f6bcfb7@mail.gmail.com> <1d7ddd110807301811y65b383bfge92c754e44c5c328@mail.gmail.com> Message-ID: <7a93bd340807302006q2ca21916i931d6d9e7d2e656b@mail.gmail.com> Actually, I just pushed the docs and announced it; Jim made the release to Rubyforge. Or somebody did... - A On Wed, Jul 30, 2008 at 6:11 PM, Brian Takita wrote: > Alex, thank you for releasing the latest version. > > On Wed, Jul 30, 2008 at 9:13 AM, Alex Chaffee wrote: >> === 0.4.191 / 2008-07-29 >> * Renamed HtmlParts to Doc >> * Widget#doc is now a HtmlParts which proxies to the passed in IO stream >> * Better compatibility with standard Rails rendering because >> ActionController::Base#render and #render_widget now have the Widget >> write directly to _erbout. >> * ActionView::Base objects run with Erector now receive all of the >> instance variables >> * Erector works with erb layouts >> * Deprecate fake_erbout >> * Better handling for file with .html.rb extension. >> * Fix overwriting issue when using Rails helpers >> * New method Widget#character >> * Widget#nbsp without arguments now outputs a single non-breaking space. >> _______________________________________________ >> Erector-devel mailing list >> Erector-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/erector-devel >> > -- Alex Chaffee alexch at gmail.com