From manfred at gmail.com Wed Jan 21 08:45:23 2009 From: manfred at gmail.com (Manfred Stienstra) Date: Wed, 21 Jan 2009 14:45:23 +0100 Subject: EAST FORK GROUP CAMP USE AGREEMENT Message-ID: <1DB7BFD7-756D-4438-99AA-E7D2BC27A6E1@gmail.com> Hi, I've been noticing some disturbance in #camping lately, and I would like to remind everyone about the Group Camp Agreement. http://dnr.wi.gov/forestry/stateforests/SF-BlackRiver/pdf/BlackRiver-GroupCampAgreement.pdf Please study it carefully. Also, point 2 about threaded applications begs for some extra consideration: ?When multiple requests are simultaneously received on the same day for the same period, a lottery drawing will be used to select an application.? Thanks for you time and happy camping. Oh, and I hope you win something nice at the lottery! Manfred From judofyr at gmail.com Fri Jan 23 17:09:34 2009 From: judofyr at gmail.com (Magnus Holm) Date: Fri, 23 Jan 2009 23:09:34 +0100 Subject: I CAN HAZ 3K FRAIMWURK? Message-ID: <391a49da0901231409w7ade8f4an468b89cd80416734@mail.gmail.com> Hey, campers! I've been messin' with camping.rb again :-) * http://github.com/judofyr/camping/commit/cbbfe41 I've ported the flipbook template to RDoc 2 (RDoc 1 has always had problems with building the docs at my computer) * http://github.com/judofyr/camping/commit/9dc2233 Since we save all the applications in Camping::Apps we can easily figure out which apps are defined when a file is loaded. I've refactored Camping::Server and Camping::Reloader (truly a refactoring - mostly just moved the bytes around) and now we no longer need to name our file the same as the app. You can also define multiple apps in one file and Camping::Reloader will work just as expected. * http://github.com/judofyr/camping/commit/c8da0f7 The @response object was never really used, so now we're creating it on-demand in #to_a. Save quite a few bytes. * http://github.com/judofyr/camping/commit/c04a6c7 It has always annoyed me that if you overwrite r404, r500 or r501 you also need to set the @status. Now we're doing a @status = @method =~ /r(\d+)/ ? $1.to_i : 200, so the default status will be set to 404, 500 or 501 in those methods. We also had a sexy r500 even though we sent all the errors to Rack::ShowExceptions (again, many bytes saved by removing that). I've also replaced Camping.method_missing to use Rack::MockRequest which is shorter and more solid. * http://github.com/judofyr/camping/commit/5739bb0 Camping now supports nested params (post[title]=Hello&post[body]=World). See http://judofyr.net/posts/when-in-doubt.html for more information. * http://github.com/judofyr/camping/commit/582d94b Before, class PostX would route to /post/(\w+), just to be sure to catch everything I replaced it with /post/([^/]+) (everything until next slash) which makes more sense IMO * http://github.com/judofyr/camping/commit/c55001f After synchronizing camping.rb and camping-unabridged.rb, camping.rb ended up at 2947 and we have now passed the 3k limit :D Any thoughts? There's still missing a lot of documentation and I guess we should add some tests too. //Magnus Holm -------------- next part -------------- An HTML attachment was scrubbed... URL: From judofyr at gmail.com Sat Jan 24 09:01:33 2009 From: judofyr at gmail.com (Magnus Holm) Date: Sat, 24 Jan 2009 15:01:33 +0100 Subject: H with indifferent access Message-ID: <391a49da0901240601j44dcf02en3cc7905b53923c77@mail.gmail.com> Camping::H hasn't longer indiffenrent access: h = Camping::H.new h.title = "Sweet!" h[:title] != h["title"] Should we (1) don't make it indifferent at all, but rather say you should always use method_missing (2) add indifferent access? Here is one such implementation in 86 bytes, in case we want it: class H < Hash i='def []!(k,v)Symbol===k ?self[k.to_s]!v:super end;' eval i.tr('!','=')+i.tr('!,v','') end //Magnus Holm -------------- next part -------------- An HTML attachment was scrubbed... URL: From zimbatm at oree.ch Sat Jan 24 09:24:32 2009 From: zimbatm at oree.ch (zimbatm) Date: Sat, 24 Jan 2009 15:24:32 +0100 Subject: H with indifferent access In-Reply-To: <391a49da0901240601j44dcf02en3cc7905b53923c77@mail.gmail.com> References: <391a49da0901240601j44dcf02en3cc7905b53923c77@mail.gmail.com> Message-ID: Hi Magnus, I prefer using method_missing, with string access for fallback when key names are not compatible with ruby method names. From zimbatm at oree.ch Sat Jan 24 09:25:59 2009 From: zimbatm at oree.ch (zimbatm) Date: Sat, 24 Jan 2009 15:25:59 +0100 Subject: I CAN HAZ 3K FRAIMWURK? In-Reply-To: <391a49da0901231409w7ade8f4an468b89cd80416734@mail.gmail.com> References: <391a49da0901231409w7ade8f4an468b89cd80416734@mail.gmail.com> Message-ID: Looks all sane to me. Good job From aredridel at nbtsc.org Sat Jan 24 09:50:36 2009 From: aredridel at nbtsc.org (Aria Stewart) Date: Sat, 24 Jan 2009 07:50:36 -0700 Subject: H with indifferent access In-Reply-To: References: <391a49da0901240601j44dcf02en3cc7905b53923c77@mail.gmail.com> Message-ID: On Jan 24, 2009, at 7:24, zimbatm wrote: > Hi Magnus, > > I prefer using method_missing, with string access for fallback when > key names are not compatible with ruby method names. And I prefer symbols, but it's a total edge case to me. Strings are great too, and it'd bug me less than indifference. Aria From judofyr at gmail.com Sat Jan 24 13:09:16 2009 From: judofyr at gmail.com (Magnus Holm) Date: Sat, 24 Jan 2009 19:09:16 +0100 Subject: Do we still need to be alert when on SQLite3? Message-ID: <391a49da0901241009n770a607teadaa0ea91dd3b90@mail.gmail.com> Anyone knows if we still need to follow the instructions at http://web.archive.org/web/20080113055731/code.whytheluckystiff.net/camping/wiki/BeAlertWhenOnSqlite3, or if the stable release is good enough? //Magnus Holm -------------- next part -------------- An HTML attachment was scrubbed... URL: From kprojection at gmail.com Sat Jan 24 13:12:13 2009 From: kprojection at gmail.com (Eric Mill) Date: Sat, 24 Jan 2009 10:12:13 -0800 Subject: I CAN HAZ 3K FRAIMWURK? In-Reply-To: <391a49da0901231409w7ade8f4an468b89cd80416734@mail.gmail.com> References: <391a49da0901231409w7ade8f4an468b89cd80416734@mail.gmail.com> Message-ID: You are the Duke of Camping. That is awesome work, Magnus. On Fri, Jan 23, 2009 at 2:09 PM, Magnus Holm wrote: > Hey, campers! I've been messin' with camping.rb again :-) > * http://github.com/judofyr/camping/commit/cbbfe41 > I've ported the flipbook template to RDoc 2 (RDoc 1 has always had problems > with building the docs at my computer) > * http://github.com/judofyr/camping/commit/9dc2233 > Since we save all the applications in Camping::Apps we can easily figure out > which apps are defined when a file is loaded. I've refactored > Camping::Server and Camping::Reloader (truly a refactoring - mostly just > moved the bytes around) and now we no longer need to name our file the same > as the app. You can also define multiple apps in one file and > Camping::Reloader will work just as expected. > * http://github.com/judofyr/camping/commit/c8da0f7 > The @response object was never really used, so now we're creating it > on-demand in #to_a. Save quite a few bytes. > * http://github.com/judofyr/camping/commit/c04a6c7 > It has always annoyed me that if you overwrite r404, r500 or r501 you also > need to set the @status. Now we're doing a @status = @method =~ /r(\d+)/ ? > $1.to_i : 200, so the default status will be set to 404, 500 or 501 in those > methods. We also had a sexy r500 even though we sent all the errors to > Rack::ShowExceptions (again, many bytes saved by removing that). > I've also replaced Camping.method_missing to use Rack::MockRequest which is > shorter and more solid. > * http://github.com/judofyr/camping/commit/5739bb0 > Camping now supports nested params (post[title]=Hello&post[body]=World). > See http://judofyr.net/posts/when-in-doubt.html for more information. > * http://github.com/judofyr/camping/commit/582d94b > Before, class PostX would route to /post/(\w+), just to be sure to catch > everything I replaced it with /post/([^/]+) (everything until next slash) > which makes more sense IMO > * http://github.com/judofyr/camping/commit/c55001f > After synchronizing camping.rb and camping-unabridged.rb, camping.rb ended > up at 2947 and we have now passed the 3k limit :D > Any thoughts? There's still missing a lot of documentation and I guess we > should add some tests too. > //Magnus Holm > > _______________________________________________ > Camping-list mailing list > Camping-list at rubyforge.org > http://rubyforge.org/mailman/listinfo/camping-list > From blueberry at creativepony.com Sat Jan 24 15:12:52 2009 From: blueberry at creativepony.com (Jenna Fox) Date: Sun, 25 Jan 2009 07:12:52 +1100 Subject: H with indifferent access In-Reply-To: References: <391a49da0901240601j44dcf02en3cc7905b53923c77@mail.gmail.com> Message-ID: <078723EE-428D-49AD-8C8C-3D665863EE73@creativepony.com> Yes, I want my method access too!.. Perhaps it'd be extra worthy of the '2.0' if you also did something akin to: def [](k);super(k.to_s);end def []=(k,v);super(k.to_s,v);end it's some bytes, but I think it's worth it! What ever happened to Mash? On 25/01/2009, at 1:50 AM, Aria Stewart wrote: > On Jan 24, 2009, at 7:24, zimbatm wrote: > >> Hi Magnus, >> >> I prefer using method_missing, with string access for fallback when >> key names are not compatible with ruby method names. > > And I prefer symbols, but it's a total edge case to me. Strings are > great too, and it'd bug me less than indifference. > > Aria > _______________________________________________ > Camping-list mailing list > Camping-list at rubyforge.org > http://rubyforge.org/mailman/listinfo/camping-list From judofyr at gmail.com Sat Jan 24 15:35:56 2009 From: judofyr at gmail.com (Magnus Holm) Date: Sat, 24 Jan 2009 21:35:56 +0100 Subject: H with indifferent access In-Reply-To: <078723EE-428D-49AD-8C8C-3D665863EE73@creativepony.com> References: <391a49da0901240601j44dcf02en3cc7905b53923c77@mail.gmail.com> <078723EE-428D-49AD-8C8C-3D665863EE73@creativepony.com> Message-ID: <391a49da0901241235t6dd70850t106c6fd695fd6aba@mail.gmail.com> Doh, the snippet I wrote was actually really stupid. Forgot we can safely call super without thinking of recursive calls. What do you guys think? Is it worth it? Method access won't go away, and Mash was just an experiement; I don't want to add another dependency on Camping. //Magnus Holm On Sat, Jan 24, 2009 at 21:12, Jenna Fox wrote: > Yes, I want my method access too!.. > > Perhaps it'd be extra worthy of the '2.0' if you also did something akin > to: > > def [](k);super(k.to_s);end > def []=(k,v);super(k.to_s,v);end > > it's some bytes, but I think it's worth it! > > What ever happened to Mash? > > > > On 25/01/2009, at 1:50 AM, Aria Stewart wrote: > > On Jan 24, 2009, at 7:24, zimbatm wrote: >> >> Hi Magnus, >>> >>> I prefer using method_missing, with string access for fallback when >>> key names are not compatible with ruby method names. >>> >> >> And I prefer symbols, but it's a total edge case to me. Strings are great >> too, and it'd bug me less than indifference. >> >> Aria >> _______________________________________________ >> Camping-list mailing list >> Camping-list at rubyforge.org >> http://rubyforge.org/mailman/listinfo/camping-list >> > > _______________________________________________ > Camping-list mailing list > Camping-list at rubyforge.org > http://rubyforge.org/mailman/listinfo/camping-list > -------------- next part -------------- An HTML attachment was scrubbed... URL: From blueberry at creativepony.com Sat Jan 24 18:15:31 2009 From: blueberry at creativepony.com (Jenna Fox) Date: Sun, 25 Jan 2009 10:15:31 +1100 Subject: H with indifferent access In-Reply-To: <391a49da0901241235t6dd70850t106c6fd695fd6aba@mail.gmail.com> References: <391a49da0901240601j44dcf02en3cc7905b53923c77@mail.gmail.com> <078723EE-428D-49AD-8C8C-3D665863EE73@creativepony.com> <391a49da0901241235t6dd70850t106c6fd695fd6aba@mail.gmail.com> Message-ID: Yes! give me indifferent access! :D On 25/01/2009, at 7:35 AM, Magnus Holm wrote: > Doh, the snippet I wrote was actually really stupid. Forgot we can > safely call super without thinking of recursive calls. What do you > guys think? Is it worth it? > > Method access won't go away, and Mash was just an experiement; I > don't want to add another dependency on Camping. > > //Magnus Holm > > > On Sat, Jan 24, 2009 at 21:12, Jenna Fox > wrote: > Yes, I want my method access too!.. > > Perhaps it'd be extra worthy of the '2.0' if you also did something > akin to: > > def [](k);super(k.to_s);end > def []=(k,v);super(k.to_s,v);end > > it's some bytes, but I think it's worth it! > > What ever happened to Mash? > > > > On 25/01/2009, at 1:50 AM, Aria Stewart wrote: > > On Jan 24, 2009, at 7:24, zimbatm wrote: > > Hi Magnus, > > I prefer using method_missing, with string access for fallback when > key names are not compatible with ruby method names. > > And I prefer symbols, but it's a total edge case to me. Strings are > great too, and it'd bug me less than indifference. > > Aria > _______________________________________________ > Camping-list mailing list > Camping-list at rubyforge.org > http://rubyforge.org/mailman/listinfo/camping-list > > _______________________________________________ > Camping-list mailing list > Camping-list at rubyforge.org > http://rubyforge.org/mailman/listinfo/camping-list > > _______________________________________________ > Camping-list mailing list > Camping-list at rubyforge.org > http://rubyforge.org/mailman/listinfo/camping-list -------------- next part -------------- An HTML attachment was scrubbed... URL: From kprojection at gmail.com Sat Jan 24 18:17:40 2009 From: kprojection at gmail.com (Eric Mill) Date: Sat, 24 Jan 2009 15:17:40 -0800 Subject: H with indifferent access In-Reply-To: References: <391a49da0901240601j44dcf02en3cc7905b53923c77@mail.gmail.com> <078723EE-428D-49AD-8C8C-3D665863EE73@creativepony.com> <391a49da0901241235t6dd70850t106c6fd695fd6aba@mail.gmail.com> Message-ID: I'm pretty indifferent about access. On Sat, Jan 24, 2009 at 3:15 PM, Jenna Fox wrote: > Yes! give me indifferent access! :D > > On 25/01/2009, at 7:35 AM, Magnus Holm wrote: > > Doh, the snippet I wrote was actually really stupid. Forgot we can safely > call super without thinking of recursive calls. What do you guys think? Is > it worth it? > Method access won't go away, and Mash was just an experiement; I don't want > to add another dependency on Camping. > //Magnus Holm > > > On Sat, Jan 24, 2009 at 21:12, Jenna Fox wrote: >> >> Yes, I want my method access too!.. >> >> Perhaps it'd be extra worthy of the '2.0' if you also did something akin >> to: >> >> def [](k);super(k.to_s);end >> def []=(k,v);super(k.to_s,v);end >> >> it's some bytes, but I think it's worth it! >> >> What ever happened to Mash? >> >> >> On 25/01/2009, at 1:50 AM, Aria Stewart wrote: >> >>> On Jan 24, 2009, at 7:24, zimbatm wrote: >>> >>>> Hi Magnus, >>>> >>>> I prefer using method_missing, with string access for fallback when >>>> key names are not compatible with ruby method names. >>> >>> And I prefer symbols, but it's a total edge case to me. Strings are great >>> too, and it'd bug me less than indifference. >>> >>> Aria >>> _______________________________________________ >>> Camping-list mailing list >>> Camping-list at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/camping-list >> >> _______________________________________________ >> Camping-list mailing list >> Camping-list at rubyforge.org >> http://rubyforge.org/mailman/listinfo/camping-list > > _______________________________________________ > Camping-list mailing list > Camping-list at rubyforge.org > http://rubyforge.org/mailman/listinfo/camping-list > > _______________________________________________ > Camping-list mailing list > Camping-list at rubyforge.org > http://rubyforge.org/mailman/listinfo/camping-list > From manfred at gmail.com Sat Jan 24 19:46:47 2009 From: manfred at gmail.com (Manfred Stienstra) Date: Sun, 25 Jan 2009 01:46:47 +0100 Subject: Do we still need to be alert when on SQLite3? In-Reply-To: <391a49da0901241009n770a607teadaa0ea91dd3b90@mail.gmail.com> References: <391a49da0901241009n770a607teadaa0ea91dd3b90@mail.gmail.com> Message-ID: <17284669-74EA-4513-8691-D1465CDC9403@gmail.com> On Jan 24, 2009, at 7:09 PM, Magnus Holm wrote: > Anyone knows if we still need to follow the instructions at http://web.archive.org/web/20080113055731/code.whytheluckystiff.net/camping/wiki/BeAlertWhenOnSqlite3 > , or if the stable release is good enough? I think the reason for the Sqlite gem fork was that it needed Swig to built back in the day. Nowadays that not necessary anymore, so you can just install the normal gem. Manfred