Topic for #ruby is now Ruby programming language || ruby-lang.org || RUBY SUMMER OF CODE! rubysoc.org/ || Paste >3 lines of text in http://pastie.org || Para a nossa audiencia em portugues http://ruby-br.org/
fridim_ [fridim_!~fridim@2a01:e35:2ece:f2d0:223:4eff:fe6c:c754] has joined #ruby
wmoxam_ [wmoxam_!~wmoxam@69-196-162-55.dsl.teksavvy.com] has joined #ruby
Fraeon [Fraeon!~kzer-za@virgo.dreamhost.com] has joined #ruby
eywu [eywu!~Adium@205-170-107-4.dia.static.qwest.net] has quit [#ruby]
dasfugufish [dasfugufish!~Adium@68-170-39-205.mammothnetworks.com] has joined #ruby
guns [guns!~guns@c-98-228-72-208.hsd1.il.comcast.net] has joined #ruby
akem [akem!~akem@205.139.120.78.rev.sfr.net] has joined #ruby
shevy [shevy!~shevy@178-191-179-93.adsl.highway.telekom.at] has joined #ruby
akem [akem!~akem@unaffiliated/akem] has joined #ruby
jay_zawrotny [jay_zawrotny!~Jay@50-77-200-126-static.hfc.comcastbusiness.net] has joined #ruby
rubyruy [rubyruy!~ruy@76.77.91.41] has joined #ruby
yfeldblum [yfeldblum!~Jay@c-71-206-30-119.hsd1.md.comcast.net] has joined #ruby
colint [colint!~ColinT@69-11-97-130.regn.static.sasknet.sk.ca] has joined #ruby
dhodgkin [dhodgkin!~dhodgkin@cpe-76-179-199-112.maine.res.rr.com] has joined #ruby
wmoxam_ [wmoxam_!~wmoxam@75-119-252-170.dsl.teksavvy.com] has joined #ruby
philcrissman [philcrissman!~philcriss@206.57.45.116] has joined #ruby
randym [randym!~randym@113x33x226x118.ap113.ftth.ucom.ne.jp] has joined #ruby
dankest [dankest!~dankest@ip68-108-246-82.sb.sd.cox.net] has joined #ruby
colint_ [colint_!~ColinT@69-11-97-130.regn.static.sasknet.sk.ca] has joined #ruby
tcrayford [tcrayford!~user@31.205.1.102] has joined #ruby
DiabloHorn [DiabloHorn!~DiabloHor@unaffiliated/diablohorn] has joined #ruby
<DiabloHorn> evening
<seejohnrun> DiabloHorn: yo
havenn [havenn!~skipper@pool-72-67-31-69.lsanca.fios.verizon.net] has joined #ruby
<DiabloHorn> :)
<DiabloHorn> I was wondering if anyone has any experience with flvedit and if he would recommend it or recomment an alternative?
<seejohnrun> fivedit?
replore_ [replore_!~replore@203.152.213.161.static.zoot.jp] has joined #ruby
<DiabloHorn> fLvedit
<seejohnrun> haha wow my eyes are bad
<DiabloHorn> hehehe np :P
apok_ [apok_!~apok@c-107-3-149-167.hsd1.ca.comcast.net] has joined #ruby
dark3rdre4ms [dark3rdre4ms!~Ethan@unaffiliated/eth4n] has joined #ruby
<mksm> wow chrome crashed hard with some chinese message
<mksm> and i'm not in china
quest88 [quest88!~quest88@12.181.53.99] has joined #ruby
Sailias [Sailias!~jonathan@99.234.118.225] has joined #ruby
`brendan [`brendan!~b@64-121-18-195.c3-0.upd-ubr1.trpr-upd.pa.cable.rcn.com] has joined #ruby
nanoyak [nanoyak!~nanoyak@50-0-164-69.dsl.dynamic.sonic.net] has joined #ruby
<maletor> is there a more intelligent way to write this
<maletor> CloudspongeContact.all.map { |cc| cc.emails.map { |a| a[:address] } }
<maletor> i just want an Array of Strings
<maletor> CloudspongeContact.all.map { |cc| cc.emails.map { |a| a[:address] }.to_s } does the trick
IHateHavingToReg [IHateHavingToReg!~rda@adsl-72-152-9-127.asm.bellsouth.net] has joined #ruby
stringoO [stringoO!~JLstring@CPE001346cbe31b-CM00111ae502a8.cpe.net.cable.rogers.com] has joined #ruby
IHateHavingToReg [IHateHavingToReg!~rda@adsl-72-152-9-127.asm.bellsouth.net] has quit [#ruby]
dhodgkin [dhodgkin!~dhodgkin@cpe-76-179-199-112.maine.res.rr.com] has joined #ruby
billy_ran_away [billy_ran_away!~billy_ran@pool-173-69-211-31.bltmmd.fios.verizon.net] has joined #ruby
tomhsx [tomhsx!~tomhsx@c-76-109-169-195.hsd1.fl.comcast.net] has joined #ruby
thatryan [thatryan!~thatryan@c-24-4-167-46.hsd1.ca.comcast.net] has quit ["Linkinus - http://linkinus.com"]
tatsuya_o [tatsuya_o!~tatsuya_o@113x33x226x118.ap113.ftth.ucom.ne.jp] has joined #ruby
macmartine [macmartine!~macmartin@069-064-227-254.pdx.net] has joined #ruby
_debo [_debo!~marco.deb@cpc18-enfi16-2-0-cust743.hari.cable.virginmedia.com] has joined #ruby
skinnymuch [skinnymuch!~skinnymuc@c-68-36-123-133.hsd1.nj.comcast.net] has joined #ruby
Jay_Levitt [Jay_Levitt!~Jay_Levit@home.jay.fm] has joined #ruby
dotnull [dotnull!~DotNull@173-31-158-182.client.mchsi.com] has joined #ruby
dbgster [dbgster!~dbgster@CPE0013f7b7170c-CM0013f7b71708.cpe.net.cable.rogers.com] has joined #ruby
sarkis_ [sarkis_!~sarkis@cpe-72-134-22-221.socal.res.rr.com] has joined #ruby
looopy [looopy!~looopy@pool-151-200-236-181.washdc.btas.verizon.net] has joined #ruby
Silker [Silker!~ponies@31.185.225.248] has joined #ruby
wilmoore [wilmoore!~wilmoore@mail2.remycorp.com] has joined #ruby
jbw [jbw!~jbw@dsl-044-084.cust.imagine.ie] has joined #ruby
ephemerian [ephemerian!~ian@82-71-51-229.dsl.in-addr.zen.co.uk] has joined #ruby
havenn [havenn!~skipper@pool-72-67-31-69.lsanca.fios.verizon.net] has joined #ruby
rtsph [rtsph!rtsph@gateway/shell/xzibition.com/x-wwcvqepzygclfdrq] has joined #ruby
d2dchat [d2dchat!~d2dchat@c-98-209-18-197.hsd1.mi.comcast.net] has joined #ruby
bwlang [bwlang!~anonymous@static-71-245-233-146.bstnma.fios.verizon.net] has joined #ruby
Synthead [Synthead!~max@173-165-179-126-atlanta.hfc.comcastbusiness.net] has joined #ruby
looopy [looopy!~looopy@pool-151-200-236-181.washdc.btas.verizon.net] has joined #ruby
<robert_> so, hmm.. "dl.c:106:1: error: expected ';', ',' or ')' before 'static'"
<robert_> (the latest ruby 1.8.x, trying to compile from source)
eywu [eywu!~Adium@205-170-107-4.dia.static.qwest.net] has joined #ruby
<csmrfx> I guess the next step is comments about paste or gtfo or similar
<robert_> csmrfx: I'm trying to compile 1.8.7p2 from source. and I have no idea why it's breaking
<banisterfiend> csmrfx: hey carl
<csmrfx> robert_: oh sorry bout that
<csmrfx> I must have dyxeslia
<robert_> it's okay
Pip_ [Pip_!~Pip@unaffiliated/pip] has joined #ruby
<csmrfx> robert_: you have all the headers ('n shiz)?
<robert_> yeah
<robert_> I can compile other stuff just fine
<robert_> what else do I need?
<robert_> ext/dl is breaking
<csmrfx> yeah
vitoravelino [vitoravelino!~rockhampt@unaffiliated/vtr] has joined #ruby
<csmrfx> kernel headers, ruby headers, ... what else is there
nari [nari!~nari@2001:268:306:1:f2de:f1ff:fe55:2de0] has joined #ruby
Knodi [Knodi!~Knodi@c-68-43-246-216.hsd1.mi.comcast.net] has joined #ruby
<csmrfx> robert_: solution here http://bugs.ruby-lang.org/issues/5108
iamjarvo [iamjarvo!~Adium@c-71-230-13-201.hsd1.nj.comcast.net] has quit [#ruby]
QaDeS_ [QaDeS_!~mklaus@frbg-5d84fe49.pool.mediaWays.net] has joined #ruby
<csmrfx> banisterfiend: wadap
otakutomo [otakutomo!~otakutomo@KD027083117212.ppp-bb.dion.ne.jp] has joined #ruby
<banisterfiend> csmrfx: the usual: feelin' cute, lookin' cute
<robert_> csmrfx: ah. :D
adeponte [adeponte!~adeponte@67.110.253.162.ptr.us.xo.net] has joined #ruby
<csmrfx> np
Behi [Behi!~Behi@203-206-227-95.perm.iinet.net.au] has joined #ruby
dotnull [dotnull!~dot_null@173-31-158-182.client.mchsi.com] has joined #ruby
<robert_> I'll test it in just a moment.
statarb3 [statarb3!~CoreD@unaffiliated/statarb3] has joined #ruby
benofsky [benofsky!~benofsky@cpe-72-229-186-250.nyc.res.rr.com] has joined #ruby
closedbracket [closedbracket!~closedbra@cpe-098-024-125-117.carolina.res.rr.com] has joined #ruby
mikepack [mikepack!~mikepack@c-174-51-77-22.hsd1.co.comcast.net] has joined #ruby
thatryan [thatryan!~thatryan@c-71-202-3-49.hsd1.ca.comcast.net] has joined #ruby
otakutomo [otakutomo!~otakutomo@KD027083117212.ppp-bb.dion.ne.jp] has joined #ruby
<robert_> csmrfx: still doing it.
<csmrfx> report to my assistant banisterfiend after you are done
apok [apok!~apok@c-107-3-149-167.hsd1.ca.comcast.net] has joined #ruby
mikepack [mikepack!~mikepack@c-174-51-77-22.hsd1.co.comcast.net] has joined #ruby
le_ [le_!~le@host154.190-227-23.telecom.net.ar] has joined #ruby
<le_> hello
<le_> im having this when running jekyll
<le_> ms/custom_require.rb:55:in `require': iconv will be deprecated in the future, use String#encode instead.
<le_> any idea?
<csmrfx> look into documentation about string encoding in 1.9.1
<csmrfx> le_: ^^^
<le_> csmrfx: alright
<csmrfx> props to J. E. Grey II for his contribution to documentating this
<csmrfx> (give or take ta)
tar_ [tar_!~tar@d118-75-81-132.try.wideopenwest.com] has joined #ruby
thatryan [thatryan!~thatryan@c-71-202-3-49.hsd1.ca.comcast.net] has joined #ruby
Brozilla [Brozilla!~Brozilla@ip11-49-212-87.adsl2.static.versatel.nl] has joined #ruby
igotnolegs [igotnolegs!~igotnoleg@174-27-214-73.slkc.qwest.net] has joined #ruby
wilmoore [wilmoore!~wilmoore@mail2.remycorp.com] has joined #ruby
Aaaarg [Aaaarg!~Arthur@121-74-43-214.telstraclear.net] has joined #ruby
tomzx [tomzx!~tomzx@dsl-216-221-32-204.aei.ca] has joined #ruby
roaminghorse [roaminghorse!~roamingho@210.22.86.58] has joined #ruby
fayimora_ [fayimora_!~fayimora@95.175.159.32] has joined #ruby
bpfh [bpfh!~bpfh@201-66-149-252.paemt700.dsl.brasiltelecom.net.br] has joined #ruby
quest88 [quest88!~quest88@c-98-207-205-137.hsd1.ca.comcast.net] has joined #ruby
n8ji [n8ji!~n8ji@c-76-105-192-7.hsd1.or.comcast.net] has joined #ruby
Aaaarg [Aaaarg!~Arthur@121-74-32-24.telstraclear.net] has joined #ruby
looopy_ [looopy_!~looopy@c-68-34-92-100.hsd1.md.comcast.net] has joined #ruby
dotnull [dotnull!~dot_null@173-31-158-182.client.mchsi.com] has joined #ruby
colint [colint!~ColinT@69-11-97-130.regn.static.sasknet.sk.ca] has joined #ruby
colint [colint!~ColinT@69-11-97-130.regn.static.sasknet.sk.ca] has joined #ruby
wmoxam [wmoxam!~wmoxam@69-196-160-133.dsl.teksavvy.com] has joined #ruby
tomzx [tomzx!~tomzx@dsl-216-221-32-204.aei.ca] has joined #ruby
kuadrosx [kuadrosx!~quassel@186.87.191.80] has joined #ruby
Cerales [Cerales!cbceefd3@gateway/web/freenode/ip.203.206.239.211] has joined #ruby
looopy [looopy!~looopy@pool-151-200-236-181.washdc.btas.verizon.net] has joined #ruby
<Cerales> I'm trying to set up Unicorn and I've got it working listening on an HTTP port, but I can't figure out how to get the workers to listen to a shared socket
<Cerales> when i boot Unicorn I get "pack_sockaddr_in": getaddrinfo: nodename nor servname provided, or not known (SocketError)
<Cerales> the unicorn configuration line is just listen APP_PATH + 'tmp/unicorn.sock'; i've tried touch unicorn.sock but it didn't help
<Cerales> anyone have any advice on this?
awesome [awesome!~awesome@212.62.202.84.customer.cdi.no] has joined #ruby
confounds [confounds!~confounds@CPE78cd8e667600-CM78cd8e6675fd.cpe.net.cable.rogers.com] has joined #ruby
patrick99e99 [patrick99e99!~patrick@76.89.148.64] has joined #ruby
davidcelis [davidcelis!~david@c-76-115-58-79.hsd1.or.comcast.net] has joined #ruby
<patrick99e99> can anyone recommend an easy way to round a number by the nearest thousand?
youdonotexist [youdonotexist!~youdonote@c-67-166-121-94.hsd1.ut.comcast.net] has joined #ruby
<patrick99e99> should it be (num * 0.01).floor ?
<csmrfx> divide by thousand, rund, multi
Hellojere [Hellojere!~Hellojere@89.7.90.160] has joined #ruby
pootpoot [pootpoot!~pootpoot@38.108.250.130] has quit [#ruby]
Aristata [Aristata!~Adium@c-67-167-205-42.hsd1.il.comcast.net] has joined #ruby
dasfugufish [dasfugufish!~Adium@68-170-39-205.mammothnetworks.com] has joined #ruby
Sailias [Sailias!~jonathan@99.234.118.225] has joined #ruby
<Aristata> Does anyone know a way to refactor this http://pastie.org/3024281 so I am not passing 'plurality' into every single function?
crescendo [crescendo!~eric@unaffiliated/crescendo] has joined #ruby
<Aristata> I feel like a block or something would work well here but I am not very good with them to see the pattern
looopy_ [looopy_!~looopy@c-68-34-92-100.hsd1.md.comcast.net] has joined #ruby
<csmrfx> patrick99e99: lol not thousand, hundreds
<patrick99e99> csmrfx: no-- thousand seems to be right.. 12345 / 1000 * 1000 will give me 12000
<Aristata> Here is a little better context: http://pastie.org/private/jiruhdbey4mvpxf8udwslw Would a block of some sort work better here? And if so how would I implement it?
<csmrfx> Aristata hm perhaps have an array with the functions that has the plurality set once
<patrick99e99> no need to round though
<Aristata> csmrfx: How do you mean? Like procs?
<csmrfx> Aristata: I mean, have a hash with the nominative etc as keys
<Aristata> Ahhh yes that would be a better way to do it
<csmrfx> not sure if method values are a bit js idea but prolly possible in ruby too
<Aristata> If I have a hash of 5 keys, would that run faster than a case statement with 5 cases?
wedtm [wedtm!~wedtm@173-12-163-78-oregon.hfc.comcastbusiness.net] has joined #ruby
malkomalko [malkomalko!~malkomalk@66-234-41-82.nyc.cable.nyct.net] has joined #ruby
<csmrfx> you would not test every key but instead call the one value (method) with the key (kase) passed into the decline method
<csmrfx> if you follow my mixed up sentence
Squee-D [Squee-D!~Squee-D@static.visfleet.com] has joined #ruby
<Aristata> I am not sure I do :(
nonotza [nonotza!~nonotza@cpe-72-225-173-7.nyc.res.rr.com] has joined #ruby
<Aristata> csmrfx: Maybe I should just do self.send("decline_#{kase}", plurality) ?
<csmrfx> maybe, its 5 am here so Im in no position to advice specifics
<Aristata> haha, no worries
perryh [perryh!~root@unaffiliated/perry753] has joined #ruby
kennethreitz [kennethreitz!~kennethre@c-24-127-96-129.hsd1.va.comcast.net] has joined #ruby
<csmrfx> but I was thinking along the lines of: hashContainingTheDeclinationHandlingMethods[kase].call
dagnachewa [dagnachewa!~dagnachew@modemcable142.238-179-173.mc.videotron.ca] has joined #ruby
wilmoore [wilmoore!~wilmoore@mail2.remycorp.com] has joined #ruby
tayy [tayy!~tayy@208.59.93.230] has joined #ruby
<mksm> what is people using to create zip files using ruby?
chubba [chubba!chubba@cpc5-dund11-2-0-cust410.sgyl.cable.virginmedia.com] has joined #ruby
dark3rdre4ms [dark3rdre4ms!~Ethan@adsl-108-67-95-63.dsl.bltnin.sbcglobal.net] has joined #ruby
dark3rdre4ms [dark3rdre4ms!~Ethan@unaffiliated/eth4n] has joined #ruby
krz [krz!~foobar@unaffiliated/krz] has joined #ruby
<chubba> hey, im kinda new to ruby, would somone mind having a look at my attempt at the first euler problem, cant get it to work?
radic [radic!~radic@dslb-094-216-240-242.pools.arcor-ip.net] has joined #ruby
<mksm> chubba, pastie
<mksm> chubba, "three == 0 ? true : false"
Azure|netbook [Azure|netbook!~azt@unaffiliated/azure] has joined #ruby
<chubba> thanks, will try it like that :)
iks [iks!~iks@c-68-84-140-13.hsd1.md.comcast.net] has joined #ruby
savage- [savage-!~savage-@c-67-180-11-89.hsd1.ca.comcast.net] has joined #ruby
<iks> Hi all. I am trying to parse an HTML page downloaded from a given website. My basic goal is to extract information from a basic table. I would like to be able to go to the next page of the listing to parse the second part of the information. Unfortunately, the page is written using .aspx and uses some Javascript for call backs (Microsofts' doPostBack) to call events in the underlying C# code. How can I execute the javascript and in particular e
<iks> xecute it to obtain an AJAXish HTTP request? Thanks.
perryh [perryh!~root@far3226.urh.uiuc.edu] has joined #ruby
perryh [perryh!~root@unaffiliated/perry753] has joined #ruby
<mksm> iks, use wireshark/firebug (ff)/developer tools (chrome) to sniff the requests made by JS
MarcoBXBRO1 [MarcoBXBRO1!~MarcoBXBR@c-68-34-17-197.hsd1.md.comcast.net] has joined #ruby
roaminghorse [roaminghorse!~roamingho@210.22.86.58] has joined #ruby
andrewhl [andrewhl!~andrew@24-246-15-43.cable.teksavvy.com] has joined #ruby
Knodi [Knodi!~Knodi@c-68-43-246-216.hsd1.mi.comcast.net] has joined #ruby
ceej [ceej!~anonymous@cpe-72-190-40-203.tx.res.rr.com] has joined #ruby
<iks> mksm, I tried that. Wireshark didn't help because the requests are over SSL but developer tools did. It seems it's a mix of cookies for the "viewstate" and POST arguments. I guess if I can keep and send cookies I might be able to simply copy the HTTP request...
<mksm> iks, yep. If you're doing just a few requests for a one time scrape, then there might be an easier way.
juarlex [juarlex!~juarlex@189.136.9.58] has joined #ruby
confounds [confounds!~confounds@CPE78cd8e667600-CM78cd8e6675fd.cpe.net.cable.rogers.com] has joined #ruby
x0F__ [x0F__!~x0F@unaffiliated/x0f] has joined #ruby
brownies [brownies!~brownies@unaffiliated/brownies] has joined #ruby
confounds [confounds!~confounds@CPE78cd8e667600-CM78cd8e6675fd.cpe.net.cable.rogers.com] has joined #ruby
p0y [p0y!~p0y@122.52.126.66] has joined #ruby
skrewler [skrewler!~skrewler@c-76-21-41-61.hsd1.ca.comcast.net] has joined #ruby
rippa [rippa!~splitta@85.158.54.234] has joined #ruby
rpowell [rpowell!~rpowell@CPE-58-168-99-83.lns7.ken.bigpond.net.au] has joined #ruby
brownies [brownies!~brownies@unaffiliated/brownies] has joined #ruby
wilmoore [wilmoore!~wilmoore@mail2.remycorp.com] has joined #ruby
Sailias_ [Sailias_!~jonathan@173.32.33.27] has joined #ruby
dyer [dyer!~dyer@unaffiliated/dyer] has joined #ruby
ryh [ryh!~ryh@174.45.125.160] has joined #ruby
diegoviola [diegoviola!~diego@host-1-211.b15.cvc.com.py] has joined #ruby
diegoviola [diegoviola!~diego@host-1-211.b15.cvc.com.py] has quit [#ruby]
cola_zero [cola_zero!~cola_zero@www5054u.sakura.ne.jp] has joined #ruby
diegoviola [diegoviola!~diego@host-1-211.b15.cvc.com.py] has joined #ruby
diegoviola [diegoviola!~diego@host-1-211.b15.cvc.com.py] has quit [#ruby]
confounds [confounds!~confounds@CPE78cd8e667600-CM78cd8e6675fd.cpe.net.cable.rogers.com] has joined #ruby
Aaaarg [Aaaarg!~Arthur@121-74-32-232.telstraclear.net] has joined #ruby
MarcoBXBRO1 [MarcoBXBRO1!~MarcoBXBR@c-68-34-17-197.hsd1.md.comcast.net] has joined #ruby
Hellojere [Hellojere!~Hellojere@89.7.90.160] has joined #ruby
minijupe [minijupe!~benlieb@adsl-74-243-183-162.ard.bellsouth.net] has joined #ruby
bjorkintosh [bjorkintosh!~bjork@ip70-189-66-194.ok.ok.cox.net] has joined #ruby
brownies- [brownies-!~brownies@216.38.150.34] has joined #ruby
apok [apok!~apok@96.24.67.22] has joined #ruby
wyhaines [wyhaines!~wyhaines@65.39.118.15] has joined #ruby
brownies [brownies!~brownies@unaffiliated/brownies] has joined #ruby
tatsuya_o [tatsuya_o!~tatsuya_o@113x33x226x118.ap113.ftth.ucom.ne.jp] has joined #ruby
Aaaarg [Aaaarg!~Arthur@121-74-35-160.telstraclear.net] has joined #ruby
Boohbah [Boohbah!boohbah@gateway/shell/anapnea.net/x-firrncbflrkzkcyy] has quit [#ruby]
wilmoore [wilmoore!~wilmoore@mail2.remycorp.com] has joined #ruby
Aaaarg [Aaaarg!~Arthur@121-74-38-206.telstraclear.net] has joined #ruby
maletor [maletor!~maletor@c-69-181-28-195.hsd1.ca.comcast.net] has joined #ruby
hemanth [hemanth!~hemanth@121.244.159.130] has joined #ruby
wedtm [wedtm!~wedtm@173-12-163-78-oregon.hfc.comcastbusiness.net] has joined #ruby
Aaaarg [Aaaarg!~Arthur@121-74-42-170.telstraclear.net] has joined #ruby
skrewler [skrewler!~skrewler@70-36-139-140.dsl.dynamic.sonic.net] has joined #ruby
epochwolf [epochwolf!~epochwolf@unaffiliated/epochwolf] has joined #ruby
zalesz [zalesz!~zalesz@user-164-127-79-12.play-internet.pl] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
GreaseMonkey [GreaseMonkey!~gm@unaffiliated/greasemonkey] has joined #ruby
h4mz1d [h4mz1d!~hamfz@99-0-57-199.lightspeed.tsclal.sbcglobal.net] has joined #ruby
jergason [jergason!~jergason@c-67-161-248-217.hsd1.ut.comcast.net] has joined #ruby
dv310p3r [dv310p3r!~dv310p3r@c-98-203-41-91.hsd1.fl.comcast.net] has joined #ruby
traph_ [traph_!~traph@95-42-78-184.btc-net.bg] has joined #ruby
traph_ [traph_!~traph@95-42-78-184.btc-net.bg] has quit [#ruby]
traph1 [traph1!~traph@95-42-78-184.btc-net.bg] has joined #ruby
brownies- [brownies-!~brownies@216.38.150.34] has joined #ruby
traph [traph!~traph@95-42-78-184.btc-net.bg] has joined #ruby
traph [traph!~traph@95-42-78-184.btc-net.bg] has quit [#ruby]
ckknight [ckknight!~ckknight@c-68-62-172-239.hsd1.al.comcast.net] has joined #ruby
Seisatsu [Seisatsu!~seisatsu@2001:c08:3700:ffff::77b] has joined #ruby
amerine [amerine!~mturner@bc171197.bendcable.com] has joined #ruby
Asher [Asher!~asher@98.158.127.150] has joined #ruby
bluOxigen [bluOxigen!ssf@unaffiliated/bluOxigen] has joined #ruby
Hellojere [Hellojere!~Hellojere@89.7.90.160] has joined #ruby
LittleBill902 [LittleBill902!~smith@c-76-114-25-2.hsd1.ca.comcast.net] has joined #ruby
yxhuvud [yxhuvud!mongo@h-17-224.a149.priv.bahnhof.se] has joined #ruby
aleksi [aleksi!~aleksi@85.235.191.82] has joined #ruby
banisterfiend [banisterfiend!~baniseter@118.82.185.158] has joined #ruby
voodoofish430 [voodoofish430!~mtorres@99-28-3-175.lightspeed.milwwi.sbcglobal.net] has joined #ruby
burgestrand [burgestrand!~burgestra@h-163-174.a155.priv.bahnhof.se] has joined #ruby
Cervajz [Cervajz!~Cervajz@opensuse/member/Cervajz] has joined #ruby
Cervajz [Cervajz!~Cervajz@opensuse/member/Cervajz] has joined #ruby
Nanuq [Nanuq!~nanuq@cave45.ecks.ca] has joined #ruby
Wroathe [Wroathe!~Wroathe@173-17-249-11.client.mchsi.com] has joined #ruby
ryh [ryh!~ryh@174.45.125.160] has joined #ruby
luckyruby [luckyruby!~luckyruby@125-187.96-97.tampabay.res.rr.com] has joined #ruby
Wroathe [Wroathe!~Wroathe@173-17-249-11.client.mchsi.com] has quit [#ruby]
brownies [brownies!~brownies@unaffiliated/brownies] has joined #ruby
p1d [p1d!~p1d@ns1.vonaffenfels.de] has joined #ruby
krz [krz!~foobar@unaffiliated/krz] has joined #ruby
Shamgar [Shamgar!~mbainter@adsl-76-233-98-184.dsl.rcsntx.sbcglobal.net] has joined #ruby
blueadept [blueadept!~blueadept@unaffiliated/blueadept] has joined #ruby
ph^ [ph^!~ph^@cm-84.212.225.74.getinternet.no] has joined #ruby
macmartine [macmartine!~macmartin@c-24-21-112-60.hsd1.or.comcast.net] has joined #ruby
wilmoore [wilmoore!~wilmoore@c-67-190-17-108.hsd1.co.comcast.net] has joined #ruby
Shamgar [Shamgar!~mbainter@adsl-76-233-98-184.dsl.rcsntx.sbcglobal.net] has joined #ruby
brownies- [brownies-!~brownies@216.38.150.34] has joined #ruby
Jrz [Jrz!~jrz@87.239.184.141] has joined #ruby
fractastical [fractastical!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
Mchl [Mchl!~Mchl@h1881165560.rev.rootvps.pl] has joined #ruby
abstrusenick [abstrusenick!~abstrusen@bb119-74-130-142.singnet.com.sg] has joined #ruby
Shamgar [Shamgar!~mbainter@76.233.99.255] has joined #ruby
senny [senny!~senny@edge.garaio.com] has joined #ruby
havenn [havenn!~skipper@pool-72-67-31-69.lsanca.fios.verizon.net] has joined #ruby
Shamgar [Shamgar!~mbainter@adsl-76-233-99-255.dsl.rcsntx.sbcglobal.net] has joined #ruby
tonini [tonini!~zastav@edge.garaio.com] has joined #ruby
voodoofish4301 [voodoofish4301!~mtorres@il-la.la.idealab.com] has joined #ruby
crankycoder [crankycoder!~crankycod@24-246-44-226.cable.teksavvy.com] has joined #ruby
JohnBat26 [JohnBat26!~Eugene@89.175.77.90] has joined #ruby
<crankycoder> has anyone ever seen a case where the .iso8601 methods simply *disappear* from Time objects?
<crankycoder> and i've google around and seen other people with roughly the same problem
<crankycoder> I'm getting this: http://pastebin.com/UNkPgGn9
JohnBat26 [JohnBat26!~Eugene@89.175.77.90] has joined #ruby
JohnBat26 [JohnBat26!~Eugene@89.175.77.90] has joined #ruby
thatryan [thatryan!~thatryan@c-71-202-3-49.hsd1.ca.comcast.net] has quit ["Linkinus - http://linkinus.com"]
adeponte [adeponte!~adeponte@pool-173-51-131-236.lsanca.fios.verizon.net] has joined #ruby
dr_bob [dr_bob!c100f615@gateway/web/freenode/ip.193.0.246.21] has joined #ruby
Hellojere [Hellojere!~Hellojere@89.7.90.160] has joined #ruby
Azure|netbook [Azure|netbook!~azt@unaffiliated/azure] has joined #ruby
workmad3 [workmad3!~workmad3@cpc1-bagu10-2-0-cust81.1-3.cable.virginmedia.com] has joined #ruby
zommi [zommi!quassel@nat/ibm/x-tvegmnavwgzllxhk] has joined #ruby
juarlex_alt [juarlex_alt!~juarlex@189.136.9.58] has joined #ruby
Azure [Azure!~azt@unaffiliated/azure] has joined #ruby
Hellojere [Hellojere!~Hellojere@89.7.90.160] has joined #ruby
fractastical [fractastical!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
jensn [jensn!~Jens@c-83-233-145-148.cust.bredband2.com] has joined #ruby
alanp [alanp!~quassel@206-248-132-83.dsl.teksavvy.com] has joined #ruby
thoraxe [thoraxe!~thoraxe@50-73-95-6-static.hfc.comcastbusiness.net] has joined #ruby
Spockz` [Spockz`!~Spockz@21pc198.sshunet.nl] has joined #ruby
michael_mbp [michael_mbp!~Marin@112.134.196.69] has joined #ruby
jensn [jensn!~Jens@165-244-96-87.cust.blixtvik.se] has joined #ruby
h4mz1d [h4mz1d!~hamfz@99-0-57-199.lightspeed.tsclal.sbcglobal.net] has joined #ruby
LittleBill902_ [LittleBill902_!~smith@c-76-114-25-2.hsd1.ca.comcast.net] has joined #ruby
batlock666 [batlock666!~quassel@bvderbau.ugent.be] has joined #ruby
mafolz [mafolz!~mafolz@dhcp50-203.start.uni-saarland.de] has joined #ruby
fractastical_ [fractastical_!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
Morkel [Morkel!~Morkel@xdsl-87-78-205-136.netcologne.de] has joined #ruby
ghosTM55 [ghosTM55!~user@li279-245.members.linode.com] has joined #ruby
bosphorus [bosphorus!~bosphorus@81.214.127.71] has joined #ruby
Shamgar [Shamgar!~mbainter@adsl-76-233-109-185.dsl.rcsntx.sbcglobal.net] has joined #ruby
berserkr [berserkr!~david@212.122.111.205.dyn.user.ono.com] has joined #ruby
fractastical_ [fractastical_!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
kawa_xxx [kawa_xxx!~kawa_xxx@w0109-49-133-1-205.uqwimax.jp] has joined #ruby
matti [matti!matti@madwifi/support/matti] has joined #ruby
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
mengu [mengu!~mengu@unaffiliated/mengu] has joined #ruby
ph^ [ph^!~ph^@cm-84.212.225.74.getinternet.no] has joined #ruby
Steppenwolf [Steppenwolf!~maus@86-45-26-32-dynamic.b-ras1.wtd.waterford.eircom.net] has quit ["Leaving"]
dnjaramba [dnjaramba!~dnjaramba@41.72.193.86] has joined #ruby
MAD [MAD!~MAD@mail.11labo.net] has joined #ruby
Pip [Pip!~Pip@host-85-156-66-217.spbmts.ru] has joined #ruby
Pip [Pip!~Pip@unaffiliated/pip] has joined #ruby
MAD_ [MAD_!~MAD@mail.11labo.net] has joined #ruby
andreime [andreime!~andrei-ci@82.79.96.20] has joined #ruby
pi3r [pi3r!~pi3r@LSt-Amand-152-32-39-189.w80-11.abo.wanadoo.fr] has joined #ruby
cyri_ [cyri_!~cyri_@236.200.72.86.rev.sfr.net] has joined #ruby
abstrusenick [abstrusenick!~abstrusen@bb119-74-130-142.singnet.com.sg] has joined #ruby
Monie [Monie!~Monie@unaffiliated/monie] has joined #ruby
jensn [jensn!~Jens@ip231-140.wireless.lu.se] has joined #ruby
tatsuya_o [tatsuya_o!~tatsuya_o@113x33x226x118.ap113.ftth.ucom.ne.jp] has joined #ruby
Samoi [Samoi!~Salmon-fr@unaffiliated/root-ninja/x-7047552] has joined #ruby
xpot [xpot!~xpot@166-70-100-198.ip.xmission.com] has joined #ruby
mklappstuhl [mklappstuhl!~mklappstu@p5B2C5CA7.dip.t-dialin.net] has joined #ruby
tvw [tvw!~tv@212.79.9.150] has joined #ruby
saschaheylik [saschaheylik!~sascha@80-121-41-83.adsl.highway.telekom.at] has joined #ruby
Ammar01 [Ammar01!~hassaa10@gatek.thls.bbc.co.uk] has joined #ruby
dnjaramba [dnjaramba!~dnjaramba@41.72.193.86] has joined #ruby
saschaheylik [saschaheylik!~sascha@80-121-41-83.adsl.highway.telekom.at] has joined #ruby
nari [nari!~nari@raichu.netlab.jp] has joined #ruby
bastilian [bastilian!~bastilian@chello213047077012.23.11.vie.surfer.at] has joined #ruby
Indian [Indian!~Indian@unaffiliated/londonmet050] has joined #ruby
gregorg [gregorg!~Greg@78.155.152.6] has joined #ruby
gregorg [gregorg!~Greg@unaffiliated/gregorg] has joined #ruby
will_b [will_b!~wob@cpc17-seac19-2-0-cust202.7-2.cable.virginmedia.com] has joined #ruby
fractastical_ [fractastical_!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
Helius [Helius!~Adium@88-149-226-23.dynamic.ngi.it] has joined #ruby
pestouille [pestouille!~adrien@LAubervilliers-151-13-7-1.w217-128.abo.wanadoo.fr] has joined #ruby
xec [xec!~xec@2a00:10b0:1:1002:5ab0:35ff:fef8:6a01] has joined #ruby
Ammar01 [Ammar01!~hassaa10@gatek.mh.bbc.co.uk] has joined #ruby
adambeynon [adambeynon!~adambeyno@82-69-1-211.dsl.in-addr.zen.co.uk] has joined #ruby
ikaros [ikaros!~ikaros@dslb-084-059-073-057.pools.arcor-ip.net] has joined #ruby
replore [replore!~replore@203.152.213.161.static.zoot.jp] has joined #ruby
Ammar01 [Ammar01!~hassaa10@gatek.mh.bbc.co.uk] has joined #ruby
james_cotterill [james_cotterill!~james_cot@89.238.149.34] has joined #ruby
will_b [will_b!~wob@cpc17-seac19-2-0-cust202.7-2.cable.virginmedia.com] has joined #ruby
tvo [tvo!~tvo@5354CF57.cm-6-5d.dynamic.ziggo.nl] has joined #ruby
tvo [tvo!~tvo@katapult/developer/tvo] has joined #ruby
Manhose [Manhose!~Manhose@dial-b1-238-132.telepac.pt] has joined #ruby
<aces1up> how can i report how much a particular object is taking up in memory?
<andreime> hello, I have a question.. how do you debug with ruby ( i'm coming from c++ )
<andreime> how to add text in the server console for example
<andreime> i also found log4r but where does it print/save the log
tonini [tonini!~zastav@edge.garaio.com] has joined #ruby
Faris [Faris!~faris@41.248.191.126] has joined #ruby
jhchabran [jhchabran!~jh@bne75-11-88-189-148-57.fbx.proxad.net] has quit [#ruby]
workmad3 [workmad3!~workmad3@vpn164.its.manchester.ac.uk] has joined #ruby
jbpros [jbpros!~jbpros@185.55-66-87.adsl-dyn.isp.belgacom.be] has joined #ruby
<jsaak> andreime: there is rdebug, ruby-debug, but usually a puts is enough
<Asher> also check out pry
fractastical_ [fractastical_!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
kedare [kedare!~kedare@scuderia.internet-fr.net] has joined #ruby
EddieS [EddieS!~ed@212.59.167.161] has joined #ruby
crankyco_ [crankyco_!~crankycod@24-246-44-226.cable.teksavvy.com] has joined #ruby
hurikhan|Work [hurikhan|Work!~kakra@82-198-195-142.briteline.de] has joined #ruby
kedare [kedare!~kedare@scuderia.internet-fr.net] has joined #ruby
fridim_ [fridim_!~fridim@2a01:e35:2ece:f2d0:223:4eff:fe6c:c754] has joined #ruby
_md [_md!~mduarte@141.0.34.138] has joined #ruby
<andreime> jsaak: thanks
hinogi [hinogi!~Stefan@mnsr-4db1d8e7.pool.mediaWays.net] has joined #ruby
hinogi [hinogi!~Stefan@facade/contributor/hinogi] has joined #ruby
hinogi1 [hinogi1!~Stefan@mnsr-4db1d8e7.pool.mediaWays.net] has joined #ruby
dazoakley [dazoakley!~dazoakley@hocuspokus.vm.bytemark.co.uk] has joined #ruby
fractastical [fractastical!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
<catphish> same question different day: is it practical to make an environment in ruby 1.9.3 where it is safe to eval untrusted (even malicious) code by overriding Kernel's methods
<jsaak> no, eval, untrusted eval, ovverriding Kernel are all EVIL
<catphish> is there a better way, or one that works?
<jsaak> redesign your program
<catphish> i haven't designed it at all yet
<jsaak> well then just avoid them, there has to be a better way
<catphish> but it's sole function is to run untrusted ruby code
<catphish> so what's the better way?
<banisterfiend> catphish: why dnt you look at the code for a number of ruby sandboxes already out there?
<banisterfiend> like tryruby, and so on
<catphish> i couldnt find any maintained sandboxes
<banisterfiend> catphish: tryruby is a fairly active project at the moment
<banisterfiend> it just got a recent redesign
<banisterfiend> and was apparently rewritten from scratch
<banisterfiend> i assume it's open source
randym [randym!~randym@EM114-48-215-88.pool.e-mobile.ne.jp] has joined #ruby
saschaheylik [saschaheylik!~sascha@80-121-53-194.adsl.highway.telekom.at] has joined #ruby
<catphish> the other problem i have is that i need native MRI performance, so ideally no ruby-in-ruby
<banisterfiend> catphish: if you know C you could write a patched interpreter
<catphish> in what way(s) would it need to be modified?
Shamgar [Shamgar!~mbainter@adsl-76-233-109-185.dsl.rcsntx.sbcglobal.net] has joined #ruby
<catphish> just a case of pulling unsafe methods?
<banisterfiend> i dont know
<banisterfiend> you'd have to do some research
<catphish> ok, thanks
<banisterfiend> but MRI internals aren't that scary
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
shellox_ [shellox_!~pb@p5099cceb.dip0.t-ipconnect.de] has joined #ruby
<shellox_> hello, how to enumerate a hash in ruby
<shellox_> @x.each do |e| works for ararys
<rippa> same way
<shellox_> but not well for hashes since it shows the attribut too
<catphish> .each_pair
<catphish> each_pair do |k, v|
dekroning [dekroning!~dekroning@541B931D.cm-5-4c.dynamic.ziggo.nl] has joined #ruby
<rippa> catphish: it's an alias
<rippa> does exactly the same as #each
<catphish> oh yeah, you're right
<catphish> but it does make it a little more understandable
Pip [Pip!~Pip@unaffiliated/pip] has joined #ruby
<shellox_> ok, thanks.
prudhvi [prudhvi!~supr@look.ma.i.am.on.ipv6.at.prudhvi.de] has joined #ruby
enikar [enikar!~gil@cl-140.mrs-01.fr.sixxs.net] has joined #ruby
<catphish> can ruby modify its process UID?
<catphish> ah it can :D
<catphish> win
<catphish> ok no it can't in the way i thought
<catphish> Process.uid = 1000 executes but doesn't appear to have any effect
<shellox_> i love ruby for stuff like that: %w(sinatra nokogiri redis hiredis yaml).each { |e| require e }
<catphish> i prefer my arrays to be defined as ['sinatra', 'etc']
<catphish> dunno why, just feels cleaner
<shellox_> well, this are more chars ;)
<catphish> i like chars, by code is usually verbose and fast :)
<catphish> other people prefer fitting more operations per line
<shellox_> yep :)
<shellox_> keep it minimal, but dont let it look lik perl
<shellox_> +e
Brozilla [Brozilla!~Brozilla@ip11-49-212-87.adsl2.static.versatel.nl] has joined #ruby
Morkel [Morkel!~Morkel@xdsl-87-78-205-136.netcologne.de] has joined #ruby
JonnieCache [JonnieCache!~jonnie@87.252.60.35] has joined #ruby
<catphish> Process::Sys.setuid :)
kalusn [kalusn!~claus@2.111.18.26] has joined #ruby
andreime [andreime!~andrei-ci@82.79.96.20] has joined #ruby
musee [musee!~musee@unaffiliated/musee] has joined #ruby
<shevy> catphish I used to prefer [] too
<shevy> until I realized that I could get rid of the ',' parts
<shevy> it saves typing
<shevy> so I fell for what was easier in the end
<banisterfiend> shevy: what kind of liste for example?
<banisterfiend> list
<banisterfiend> cos you could always do: "word1 word2 word3 word4".split
<banisterfiend> nicer than %w[word1 word2 word3 word4]
<banisterfiend> which *does* look perlish imo
<shevy> banisterfiend hmm the last I remember was a big ass array I have where all members of it added to Abbrev.abbrev + Readline autocomplete
<shevy> the layout was like
<shevy> %w(
<shevy> bla
<shevy> blasjbadsbladsblasd
<shevy> whatever
<shevy> )
<banisterfiend> shellox_: in fact it's embarrassing when ppl show things like %w[1 2 3].map(&:to_i) and give it examples as ruby's 'beauty'
<banisterfiend> that looks ugly as all hell
<JonnieCache> why would you do that
<JonnieCache> i mean i know its just an example
<JonnieCache> but we do have 1..3 :)
<banisterfiend> JonnieCache: yeah just an example
<banisterfiend> the use of Symbol#to_proc and the %w syntax in a single expression
<shevy> yeah
<shevy> the & looks very odd
Morkel [Morkel!~Morkel@xdsl-87-78-205-136.netcologne.de] has joined #ruby
<shevy> wonder how perl guys would do the same in perl
<JonnieCache> i do enjoy Symbol to_proc it is very useful
<banisterfiend> i like symbol to_proc too, it's great, but i agree it looks kinda ugly
<JonnieCache> theres that other construction with #method which is similar but i can never remember it
<rippa> banisterfiend: %w[1 2 3].inject([], :<<)
<banisterfiend> i wish that iterators accepted plain symbols
<banisterfiend> map(:to_i)
alem0lars [alem0lars!~quassel@87.19.30.252] has joined #ruby
<banisterfiend> JonnieCache: ["helo", "bab", "littl"].each(&method(:require))
<JonnieCache> thats the one
<JonnieCache> kind the opposite of symbol to_proc
<rippa> cool stuff too
<shevy> oh dear
<shevy> %w[1 2 3].inject([], :<<)
<shevy> I couldn't even tell you what that means
<shevy> But there is a smiley!
<shevy> :<
<shevy> so it can't be all bad
<JonnieCache> yeah that is bordering on perl-style executable line noise
<rippa> (70..80).map(&method(:rand))
<shellox_> we should do a ruby twitter contest :P
<shellox_> what can you code in 140? chars
<shellox_> or are it 120, i dunno ;)
<rippa> exit
<rippa> here you go
statarb3 [statarb3!~CoreD@unaffiliated/statarb3] has joined #ruby
<JonnieCache> ruby cant really touch C for awesome obfuscatedness
<JonnieCache> then go to the guys homepage and click on the snippet of C code in the footer
mmokrysz [mmokrysz!~mmokrysz@pdpc/supporter/student/mmokrysz] has joined #ruby
<catphish> does anyone know if ruby can set ulimit parameters?
<JonnieCache> yeah its in stdlib somewhere
mxweas_ [mxweas_!~max@c-71-226-112-145.hsd1.az.comcast.net] has joined #ruby
<JonnieCache> one of the ugly, neglected parts of stdlib
<catphish> my script needs to set process limits then setUID itself
<sh_ellox> JonnieCache: what is the dirtiest you can do in ruby?
<sh_ellox> is it possible to code in this style
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
<sh_ellox> =!$(%%%?$ ;)
<catphish> sure you can
<JonnieCache> in rubinius you could i think, because it exposes its own bytecode/parser api so you could do anything you want
<JonnieCache> in mri/yarv you would be somewhat limited
<JonnieCache> not sure though
<shevy> good old rubinius
<shevy> reaching 5 years eh?
<JonnieCache> its very good by all accounts. faster than yarv in a lot of cases apparently. i dont think it has full 1.9 compatbility yet though
<catphish> lol
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
Morkel [Morkel!~Morkel@xdsl-87-78-205-136.netcologne.de] has joined #ruby
kawa_xxx [kawa_xxx!~kawa_xxx@d307ba3b.t-net.ne.jp] has joined #ruby
JStoker [JStoker!jstoker@unaffiliated/jstoker] has joined #ruby
<shevy> in 5 years it will
envygeeks [envygeeks!~envygeeks@pdpc/supporter/professional/envygeeks] has joined #ruby
<envygeeks> Is there a way to declare a conflict with another Gem in the Gemspec?
<JonnieCache> dont think so
Morkel [Morkel!~Morkel@xdsl-87-78-205-136.netcologne.de] has joined #ruby
JStoker [JStoker!jstoker@unaffiliated/jstoker] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
Manhose [Manhose!~Manhose@193.136.33.133] has joined #ruby
will_b [will_b!~wob@cpc17-seac19-2-0-cust202.7-2.cable.virginmedia.com] has joined #ruby
Shamgar [Shamgar!~mbainter@76.233.109.185] has joined #ruby
chrismcg [chrismcg!~chrismcg@pdpc/supporter/active/chrismcg] has joined #ruby
skurt [skurt!~Benz@8.233.broadband4.iol.cz] has joined #ruby
looopy [looopy!~looopy@c-68-34-92-100.hsd1.md.comcast.net] has joined #ruby
Manhose_ [Manhose_!~Manhose@193.136.33.133] has joined #ruby
incluye [incluye!~incluye@LO1-ESR-74-215-187-208.fuse.net] has joined #ruby
JStoker [JStoker!jstoker@unaffiliated/jstoker] has joined #ruby
james_cotterill [james_cotterill!~james_cot@89.238.149.34] has joined #ruby
fermo [fermo!~fermo@ppp-247-49.26-151.libero.it] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
Faris2 [Faris2!~faris@41.248.191.126] has joined #ruby
bdiallo [bdiallo!~bdiallo@vol75-15-88-177-155-107.fbx.proxad.net] has joined #ruby
demian`_ [demian`_!~demian_@80.149.254.69] has joined #ruby
kalusn [kalusn!~claus@2.111.18.26] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
Manhose_ [Manhose_!~Manhose@193.136.33.133] has joined #ruby
berserkr [berserkr!~david@212.122.111.205.dyn.user.ono.com] has joined #ruby
Ypsilon [Ypsilon!~opera@p54B89E2D.dip0.t-ipconnect.de] has joined #ruby
niklasb [niklasb!~codeslay0@p5B310842.dip0.t-ipconnect.de] has joined #ruby
<catphish> how easy is it to create a pipe between 2 forks?
JStoker [JStoker!jstoker@unaffiliated/jstoker] has joined #ruby
Morkel [Morkel!~Morkel@xdsl-87-78-205-136.netcologne.de] has joined #ruby
jbpros [jbpros!~jbpros@185.55-66-87.adsl-dyn.isp.belgacom.be] has joined #ruby
p0y [p0y!~p0y@125.212.56.5] has joined #ruby
kalusn [kalusn!~claus@2.111.18.26] has joined #ruby
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
kalusn [kalusn!~claus@2.111.18.26] has joined #ruby
flip_digits [flip_digits!~textual@c-76-122-14-228.hsd1.fl.comcast.net] has joined #ruby
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
p0y_ [p0y_!~p0y@125.212.56.5] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
closedbracket [closedbracket!~closedbra@cpe-098-024-125-117.carolina.res.rr.com] has joined #ruby
<csmrfx> catphish: should be easy, fp, but wont work in win
will_b_ [will_b_!~wob@178.106.6.44] has joined #ruby
TheShadowFog [TheShadowFog!~TheShadow@ool-1826fa3a.dyn.optonline.net] has joined #ruby
tk_ [tk_!~tk@p083061.doubleroute.jp] has joined #ruby
<catphish> thats ok, i dont have win
<catphish> fp?
dv310p3r [dv310p3r!~dv310p3r@c-98-203-41-91.hsd1.fl.comcast.net] has joined #ruby
TheShadowFog [TheShadowFog!~TheShadow@ool-1826fa3a.dyn.optonline.net] has joined #ruby
andreime [andreime!~andrei-ci@82.79.96.20] has joined #ruby
<saschaheylik> can you enable indentations instead of "end" keywords in ruby?
<catphish> nope
<catphish> ruby mostly ignores whitespace between statements
<saschaheylik> hm.. why use end instead of indentation?
<catphish> because that's what ruby does
<saschaheylik> yes but why that decision
<catphish> because thats what the developers preferred
<saschaheylik> does anyone know why
<catphish> and if you like it, you should use ruby, if not, consider python
<saschaheylik> if not, im going to implement it myself or something like that
<catphish> thats just what Yukihiro liked
<catphish> ruby is formless like C
<saschaheylik> yeah but all those ends are a bit confusing
<Mon_Ouie> Indentation shifts are just the same
<saschaheylik> yes but you dont have to write "end"
<catphish> i find code without end or } to be confusing
<catphish> i guess its just about tasts
<Mon_Ouie> Have your editor type it automatically then
<catphish> *taste
<saschaheylik> yes i know its about taste. why shouldnt developers be able to choose between end, } and indent
<catphish> they can
<saschaheylik> within ruby
<catphish> but not if they want to use ruby :)
<catphish> feel free to make it an option
<saschaheylik> im thinking about how to support something like set_use_indent true; while still supporting the default parser
Shamgar [Shamgar!~mbainter@adsl-76-233-109-185.dsl.rcsntx.sbcglobal.net] has joined #ruby
<catphish> of course, you should always indent too
<catphish> so it shouldn't be any harder to read
<saschaheylik> but "end"s are a waste of space and time :P
<catphish> you're allowed to put the end *before* you un-indent
<saschaheylik> maybe a converter would do
<envygeeks> better than tab sensitive languages that bitch
<envygeeks> like *cough* python
<catphish> but people use ruby because they like it
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
<saschaheylik> i like ruby
<catphish> i'd hate ruby if it were whitespace sensitive
<catphish> sadly you can't pick and choose syntax from different languages
<envygeeks> I would never have moved from Python if Ruby were tab sensitive because there would just be no reason :/
<saschaheylik> maybe i could write a vim plugin that simply removes the "end"s on file load, corrects indentations, and puts back the ends of file save
<catphish> yes you could
<envygeeks> that would be rather hard to do
<catphish> the indentations should already be correct though
<catphish> if the indentations need changing you're indenting wrong
<saschaheylik> envygeeks: even if it was written in ruby? :P
<catphish> its just a case of inserting an end when you detect a reduced indentation
<saschaheylik> catphish: yeah but if they were wrong, the code would break
p0y [p0y!~p0y@125.212.56.5] has joined #ruby
<saschaheylik> so the vim plugin would have to parse the ends and make sure the statement inbetween is at the right indent level
<envygeeks> yessum because you can't ever assume how somebody will write code, like people like me who sometimes do stuff like 'if condition then value = 'this' end' (just an example since I would never one line an if but I do one line elses with end
<catphish> it will be much harder if you want to edit someone else's code
<catphish> but yes, you could strip all indentation and recreate it
<saschaheylik> envygeeks: you dont have to use it
<catphish> you're in trouble if someone writes statement; end; statement
<saschaheylik> everything between condition and end is the statement
<saschaheylik> the initial parse will act just like ruby
<catphish> you will split all statements onto a separate line first?
<catphish> that seems wise
<saschaheylik> either that or simply ignore the whitespace like ruby does
<envygeeks> Ruby doesn't always ignore whitespace :P
<catphish> it does mostly
<saschaheylik> "simply ignore whitespace like ruby does, but not always"
<saschaheylik> better? xD
<catphish> lol
<catphish> well good luck
<catphish> but i promise you'll do better in life if you just learn to close your blocks
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<saschaheylik> catphish: i dont have to learn that ive been doing it for years, except for python.
<catphish> ok then
<catphish> that was easy
<andreime> that was trolling level 12
p0y_ [p0y_!~p0y@112.210.52.42] has joined #ruby
pestouille [pestouille!~adrien@LAubervilliers-151-13-7-1.w217-128.abo.wanadoo.fr] has joined #ruby
<catphish> what happens if you fork when you have open file descriptors?
<saschaheylik> the no-end-version is in RAM
<saschaheylik> the saved one is just like very other file of ruby code
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<catphish> makes sense
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
p0y [p0y!~p0y@125.212.56.5] has joined #ruby
5EXAAO5KP [5EXAAO5KP!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
45PAAGPCN [45PAAGPCN!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
RomD` [RomD`!~Roman@nrbg-4dbe092a.pool.mediaWays.net] has joined #ruby
aLinux [aLinux!~aLinux@unaffiliated/alinux] has joined #ruby
`brendan [`brendan!~b@66-208-246-34-ubr02b-waldlk01-mi.hfc.comcastbusiness.net] has joined #ruby
p0y [p0y!~p0y@125.212.56.5] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<`brendan> mornig
<aLinux> mornig
nari [nari!~nari@p62e324.totrnt01.ap.so-net.ne.jp] has joined #ruby
lukasik [lukasik!~lukasik@sakiko.dcit.cz] has joined #ruby
hyperboreean [hyperboreean!~none@unaffiliated/hyperboreean] has joined #ruby
aLinux [aLinux!~aLinux@unaffiliated/alinux] has quit ["Leaving"]
tcrayford [tcrayford!~user@31.205.1.102] has joined #ruby
chrxn [chrxn!chrxn@69.4.233.32] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
JonnieCache [JonnieCache!~jonnie@87.252.60.35] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
Targen [Targen!~iguana@190.39.181.108] has joined #ruby
jay12 [jay12!~user@adsl-65-0-133-179.jan.bellsouth.net] has joined #ruby
wyhaines [wyhaines!~wyhaines@65.39.118.15] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
sepp2k [sepp2k!~sexy@g224101130.adsl.alicedsl.de] has joined #ruby
p0y_ [p0y_!~p0y@125.212.56.5] has joined #ruby
setmeaway [setmeaway!~setmeaway@119.201.52.190] has joined #ruby
TheShadowFog [TheShadowFog!~TheShadow@ool-1826fa3a.dyn.optonline.net] has joined #ruby
tommyvyo [tommyvyo!~tommyvyo@38.123.129.115] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
musee [musee!~musee@unaffiliated/musee] has joined #ruby
trivol [trivol!~aurelien@gra94-1-81-57-175-179.fbx.proxad.net] has joined #ruby
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
xhr [xhr!~xhr@94.177.39.155] has joined #ruby
yekta [yekta!~yekta@nat-165-91-14-245.tamulink.tamu.edu] has joined #ruby
yfeldblum [yfeldblum!~Jay@pool-71-246-76-76.bltmmd.east.verizon.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
burgestrand [burgestrand!~burgestra@2.69.243.51.mobile.tre.se] has joined #ruby
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
tomzx [tomzx!~tomzx@dsl-216-221-32-204.aei.ca] has joined #ruby
jessopher [jessopher!~jessopher@optimusbrine.com] has quit [#ruby]
er1c_ [er1c_!~eric@irontusk.net] has joined #ruby
Spockz [Spockz!~Spockz@131.211.235.110] has joined #ruby
dyer [dyer!~dyer@unaffiliated/dyer] has joined #ruby
rippa [rippa!~rippa@109-161-75-186.pppoe.yaroslavl.ru] has joined #ruby
gener1c [gener1c!~gener1c@unaffiliated/gener1c] has joined #ruby
apocalyptiq [apocalyptiq!~apocalypt@77-254-155-10.adsl.inetia.pl] has joined #ruby
andysparsons [andysparsons!~andy@216.174.91.1] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
poppiez [poppiez!~unknown@0x5da1840a.cpe.ge-0-1-0-1104.henqu2.customer.tele.dk] has joined #ruby
<poppiez> hi, I'm doing this gsub: text.gsub!(/\/#{f}/, CDN + "/" + digest). for some reason, I get a: invalid byte sequence in UTF-8. can anyone identify what this is?
andysp [andysp!~andy@216.174.91.1] has joined #ruby
<catphish> it means your input text is marked as UTF8 but has non-UTF8 characters in it
JStoker [JStoker!jstoker@unaffiliated/jstoker] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<poppiez> catphish: the variable "text"?
<catphish> or f
<catphish> either of them could contain invalid characters
bluOxigen [bluOxigen!ssf@unaffiliated/bluOxigen] has joined #ruby
<poppiez> text has encoding UTF-8. f is ASCII-8BIT
fractastical_ [fractastical_!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
Sliker [Sliker!~ponies@31.185.225.248] has joined #ruby
<catphish> well they should both be the same really since you're comparing them
<catphish> but the problem is in "text"
<catphish> assuming this is parsing other people's data, i'd be inclined just to force both to BINARY
metadave [metadave!~dparfitt@acsb-dparfitt.facilities.buffalo.edu] has joined #ruby
<poppiez> catphish: how may I do so?
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<catphish> but the "correct" solution is to ensure both are marked as UTF8 and contain only valid UTF8
<catphish> text.force_encoding('BINARY')
bluOxigen [bluOxigen!ssf@unaffiliated/bluOxigen] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<poppiez> catphish: that fixed it. I'm not 100% sure why it's needed
axl_ [axl_!~axl@173-11-52-113-Minnesota.hfc.comcastbusiness.net] has joined #ruby
p0y [p0y!~p0y@125.212.56.5] has joined #ruby
<catphish> your text obviously has some binary data in
dv310p3r [dv310p3r!~dv310p3r@host-208-68-238-122.biznesshosting.net] has joined #ruby
<catphish> or non-utf8 data
albemuth [albemuth!~albemuth@201.198.78.18] has joined #ruby
asobrasil [asobrasil!~asantioli@palpatine.privatedns.com] has joined #ruby
<JonnieCache> encodings are hard. maybe they should be added to the list of hard problems in computer science
<JonnieCache> 1: cache invalidation, 2: naming things
<poppiez> catphish: the text is a javascript file
<JonnieCache> i guess encodings is a special case of "naming things"
bwlang [bwlang!~anonymous@70-91-134-14-ma-ne.hfc.comcastbusiness.net] has joined #ruby
<catphish> poppiez: i don't know then :(
<poppiez> catphish: actually, it's .php, .tpl, .html, .js and .css files
cjs226 [cjs226!~cjs226@rrcs-71-40-79-154.sw.biz.rr.com] has joined #ruby
<catphish> well someone probably put something odd in there
<catphish> like a latin1 character
<JonnieCache> this came up the other day. isnt there some generic tool that can tell you "which of these bytes is not like the others?"
<poppiez> catphish: you might be right. anyway, my script is more robust now. thx a lot. "f" should be binary too, right? otherwise, they won't compare
<JonnieCache> a bad encoding detector
<poppiez> JonnieCache: not a bad idea :)
spyvspy [spyvspy!~nonenone@108-82-153-117.lightspeed.stlsmo.sbcglobal.net] has joined #ruby
<JonnieCache> surely it exists already, its such a common problem
bwlang [bwlang!~anonymous@70-91-134-14-ma-ne.hfc.comcastbusiness.net] has joined #ruby
pen [pen!~pen@g1pc2n249.g1.ntu.edu.tw] has joined #ruby
theRoUS [theRoUS!KenCoar@apache/committer/coar] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
fractastical [fractastical!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
<JonnieCache> it would basically be an encoding detector with specialist error reporting i suppose
ChrisKempson [ChrisKempson!~Chris@88-109-120-128.dynamic.dsl.as9105.com] has joined #ruby
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
<poppiez> catphish: do I have to encode "f" as well?
jgrimes_ [jgrimes_!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
<JonnieCache> hahaha how ironic, this page is detected as the wrong charset in chrome: http://www-archive.mozilla.org/projects/intl/UniversalCharsetDetection.html
<JonnieCache> its full of diamond question mark glyphs
<JonnieCache> chrome detects it as utf-8 when its actually iso-85591 or whatever
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
bwlang_ [bwlang_!~anonymous@70-91-134-14-ma-ne.hfc.comcastbusiness.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
csavola [csavola!~csavola@76-10-149-67.dsl.teksavvy.com] has joined #ruby
crankycoder [crankycoder!~crankycod@66.207.208.98] has joined #ruby
gearaholic [gearaholic!~gearaholi@c-71-238-98-243.hsd1.mi.comcast.net] has joined #ruby
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
bbttxu [bbttxu!~adam@pool-71-96-208-205.dfw.dsl-w.verizon.net] has joined #ruby
Manhose_ [Manhose_!~Manhose@193.136.33.133] has joined #ruby
<wereHamster> how cna I detect whether I run on linux or macosx?
<banisterfiend> wereHamster: RUBY_PLATFORM =~ /darwin/
<banisterfiend> and i think RUBY_PLATFORM returns something matched by /linux/ on linux systems too
mmokrysz [mmokrysz!~mmokrysz@pdpc/supporter/student/mmokrysz] has joined #ruby
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
<JonnieCache> RUBY_PLATFORM isnt very reliable
<banisterfiend> JonnieCache: how so
<metadave> nevermind.
<JonnieCache> you could get all sorts of things out of it under jruby, and so on
<JonnieCache> the interpreter can put anything it wants in there
<banisterfiend> JonnieCache: jruby is different though
bluOxigen [bluOxigen!ssf@unaffiliated/bluOxigen] has joined #ruby
orbit [orbit!9506a6d6@gateway/web/freenode/ip.149.6.166.214] has joined #ruby
<JonnieCache> under jruby RUBY_PLATFORM is 'java' under any OS
bbttxu_ [bbttxu_!~adam@pool-71-96-208-205.dfw.dsl-w.verizon.net] has joined #ruby
<banisterfiend> JonnieCache: you can view 'java' as the legitimate platform for jruby
<banisterfiend> yeah
<JonnieCache> but I suppose jruby abstracts away OS differences by its very nature so it doesnt matter
<JonnieCache> what you definitely shouldnt do to detect windows is RUBY_PLATFORM =~ /win/ because that will match "darwin" as well
<JonnieCache> ive seen people get screwed by that one :)
ryh [ryh!~ryh@174.45.125.160] has joined #ruby
colint [colint!~ColinT@69-11-97-130.regn.static.sasknet.sk.ca] has joined #ruby
dfamorato [dfamorato!~dfamorato@host-67-23-71-110.biznesshosting.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
bbttxu_ [bbttxu_!~adam@pool-71-96-208-205.dfw.dsl-w.verizon.net] has joined #ruby
<orbita> I'm looking for any project/script ideas to improve my skill. Any advices ?
colint [colint!~ColinT@69-11-97-130.regn.static.sasknet.sk.ca] has joined #ruby
andrewhl [andrewhl!~andrew@24.246.15.43] has joined #ruby
<banisterfiend> Tasser: hooking C exceptions :P https://gist.github.com/1486202
PaciFisT [PaciFisT!~PeaCE@76-10-149-67.dsl.teksavvy.com] has joined #ruby
<Tasser> banisterfiend, evil
<wereHamster> I need to depend the file type, and I use `file -Ib/ib` for that. I don't mind if the gem won't work in jruby
<wereHamster> s/depend/detect/
nanderoo [nanderoo!~nanders@38.124.137.226] has joined #ruby
<banisterfiend> wereHamster: surely ruby has a stdlib method for that?
<wereHamster> I doubt that very much. THough there are about four or five different gems which do that through various ways
evantravers [evantravers!~textual@fw.luckie.net] has joined #ruby
<banisterfiend> oh ok
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
Utkarsh [Utkarsh!~quassel@li118-209.members.linode.com] has joined #ruby
luxurymo_ [luxurymo_!~luxurymod@pool-96-246-51-32.nwrknj.fios.verizon.net] has joined #ruby
bluOxigen [bluOxigen!ssf@unaffiliated/bluOxigen] has joined #ruby
matth25 [matth25!~matthew@cgp.ctc.biz] has joined #ruby
p0y [p0y!~p0y@125.212.56.5] has joined #ruby
colint [colint!~ColinT@64.9.146.239] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<crankycoder> http://pastebin.com/9fxFjKLV can anyone see what i'm doing wrong in my debugger that makes Time behave weirdly?
<crankycoder> the iso8601 method is missing for some reason
negaduck [negaduck!~negaduck@91.206.116.254] has joined #ruby
enikar [enikar!~gil@cl-140.mrs-01.fr.sixxs.net] has joined #ruby
gearaholic [gearaholic!~gearaholi@c-71-238-98-243.hsd1.mi.comcast.net] has joined #ruby
Aristata [Aristata!~Adium@adsl-75-22-18-64.dsl.chcgil.sbcglobal.net] has joined #ruby
jwmann [jwmann!~Adium@modemcable242.110-201-24.mc.videotron.ca] has joined #ruby
jwmann [jwmann!~Adium@modemcable242.110-201-24.mc.videotron.ca] has joined #ruby
<negaduck> how to insert result of a function to view in sinatra using erb?
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
<Aristata> <%= function %>
<Aristata> negaduck: ^
jgrimes_ [jgrimes_!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
<negaduck> Aristata: thanks
<Aristata> np
p0y_ [p0y_!~p0y@125.212.56.5] has joined #ruby
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
shevy [shevy!~shevy@213-33-12-54.adsl.highway.telekom.at] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
fractastical [fractastical!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
fridim_ [fridim_!~fridim@2a01:e35:2ece:f2d0:223:4eff:fe6c:c754] has joined #ruby
Aristata [Aristata!~Adium@adsl-75-22-18-64.dsl.chcgil.sbcglobal.net] has quit [#ruby]
Aristata [Aristata!~Adium@adsl-75-22-18-64.dsl.chcgil.sbcglobal.net] has joined #ruby
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
axl__ [axl__!~axl@216-43-114-19.ip.mcleodusa.net] has joined #ruby
axl___ [axl___!~axl@173-11-52-113-Minnesota.hfc.comcastbusiness.net] has joined #ruby
xhr [xhr!~xhr@86.120.180.180] has joined #ruby
looopy [looopy!~looopy@static-71-166-231-15.washdc.east.verizon.net] has joined #ruby
p0y [p0y!~p0y@125.212.56.5] has joined #ruby
ceej [ceej!~anonymous@cpe-72-190-40-203.tx.res.rr.com] has joined #ruby
theRoUS [theRoUS!KenCoar@nat/redhat/x-sdhqzpdcdxudevqf] has joined #ruby
theRoUS [theRoUS!KenCoar@apache/committer/coar] has joined #ruby
jgarvey [jgarvey!~jgarvey@cpe-174-097-248-211.nc.res.rr.com] has joined #ruby
Morkel [Morkel!~Morkel@xdsl-87-78-205-136.netcologne.de] has joined #ruby
sandelius [sandelius!~textual@90-231-202-62-no214.tbcn.telia.com] has joined #ruby
codefriar [codefriar!~codefriar@ip-200.it.rdu.bandwidth.com] has joined #ruby
dekroning [dekroning!~dekroning@541B64A0.cm-5-4b.dynamic.ziggo.nl] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
nowthatsamatt [nowthatsamatt!~nowthatsa@rrcs-71-43-23-18.se.biz.rr.com] has joined #ruby
mduarte [mduarte!~mduarte@141.0.34.138] has joined #ruby
ryh [ryh!~ryh@host-174-45-115-181.bzm-mt.client.bresnan.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
mmokrysz [mmokrysz!~mmokrysz@pdpc/supporter/student/mmokrysz] has joined #ruby
Hellojere [Hellojere!~Hellojere@89.7.90.160] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
looopy_ [looopy_!~looopy@c-68-34-92-100.hsd1.md.comcast.net] has joined #ruby
dasfugufish [dasfugufish!~Adium@68-170-39-205.mammothnetworks.com] has joined #ruby
fridim_ [fridim_!~fridim@2a01:e35:2ece:f2d0:223:4eff:fe6c:c754] has joined #ruby
Knodi [Knodi!~Knodi@c-68-43-246-216.hsd1.mi.comcast.net] has joined #ruby
matth25 [matth25!~matthew@cgp.ctc.biz] has quit ["Linkinus - http://linkinus.com"]
TheShadowFog [TheShadowFog!~TheShadow@ool-1826fa3a.dyn.optonline.net] has joined #ruby
kf8a [kf8a!~kf8a@187.sub-174-252-246.myvzw.com] has joined #ruby
seejohnrun [seejohnrun!~john@ip-160-79-101-2.autorev.intellispace.net] has joined #ruby
burgestrand1 [burgestrand1!~burgestra@62.65.124.23] has joined #ruby
Hounth [Hounth!~hounth@85-171-201-48.rev.numericable.fr] has joined #ruby
Sailias_ [Sailias_!~jonathan@CPE0018f85e576d-CM001bd7aaaf96.cpe.net.cable.rogers.com] has joined #ruby
g0bl1n [g0bl1n!~prokter@a213-22-27-14.cpe.netcabo.pt] has joined #ruby
xhr [xhr!~xhr@86.120.180.180] has joined #ruby
freenodiz [freenodiz!~IceChat77@unaffiliated/freenodiz] has joined #ruby
philcrissman [philcrissman!~philcriss@206.57.45.116] has joined #ruby
pen [pen!~pen@g1pc2n249.g1.ntu.edu.tw] has joined #ruby
<freenodiz> why there's 2 channels? ruby and ruby-lang?
workmad3 [workmad3!~workmad3@cspool114.cs.man.ac.uk] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
_md [_md!~mduarte@141.0.34.138] has joined #ruby
<freenodiz> well,nvm ,this one seems to have more ppl :),thus it should be better :P
stringoO [stringoO!~JLstring@CPE001346cbe31b-CM00111ae502a8.cpe.net.cable.rogers.com] has joined #ruby
<Aristata> freenodiz: Flawless logic :p
<freenodiz> Aristata:flawless....
<musee> lol
negaduck [negaduck!~negaduck@91.206.116.254] has joined #ruby
joeyk [joeyk!~joeyk@unaffiliated/zer0python] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
bikr [bikr!~bikr@173-162-84-73-miami.hfc.comcastbusiness.net] has joined #ruby
mikeycgto [mikeycgto!~mikeycgto@ool-4571cba8.dyn.optonline.net] has joined #ruby
mikeycgto [mikeycgto!~mikeycgto@pdpc/supporter/active/mikeycgto] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<bikr> Question, how do I do error handling in Ruby? If I for example, accept input from a user to play a playlist in itunes, and the playlist provided doesn't exist, instead of itunes ignoring the request, the ruby app crashes
<bikr> any ideas?
<shevy> bikr the basic element is to use begin; rescue
<shevy> which is simple and works
lkba [lkba!~AndChat@dwb19.neoplus.adsl.tpnet.pl] has joined #ruby
<shevy> however, in your example, I would argue it is better to check whether the playlist exists, even before using begin/rescue, as that is even easier
dotnull [dotnull!~dot_null@office.t8webware.com] has joined #ruby
v0n [v0n!~v4n@2607:fad8:4:0:224:d7ff:feb0:42e8] has joined #ruby
<freenodiz> some if conditional,i guess...
<Aristata> class PlaylistNotFoundError < StandardError; end
<Aristata> rescue PlaylistNotFoundError
<Aristata> I think
GSpotAssassin [GSpotAssassin!u4086@gateway/web/irccloud.com/x-sdofqpazxibsivyp] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<burgestrand1> check for playlist existence, it’s a bad idea to raise an exception if it’s not an exceptional case (like control flow issues)
<burgestrand1> bikr: ^
<bikr> hmm
<bikr> didn't realize we could do that
<bikr> i'll do some research to figure out how to check if the playlist exists first
<bikr> Thanks @all :)
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
scr1bbles [scr1bbles!~scribbles@babel.sn0wcrash.info] has joined #ruby
thecreators [thecreators!~rskagy@cpe-65-27-201-203.cinci.res.rr.com] has joined #ruby
james_cotterill [james_cotterill!~james_cot@89.238.149.34] has joined #ruby
theRoUS [theRoUS!KenCoar@nat/redhat/x-pgkfvvqaugoxrbdi] has joined #ruby
theRoUS [theRoUS!KenCoar@apache/committer/coar] has joined #ruby
dark3rdre4ms [dark3rdre4ms!~Ethan@unaffiliated/eth4n] has joined #ruby
TheShadowFog [TheShadowFog!~TheShadow@ool-1826fa3a.dyn.optonline.net] has joined #ruby
nari [nari!~nari@p62e324.totrnt01.ap.so-net.ne.jp] has joined #ruby
<Aristata> bikr: Out of curiosity what resource are you looking at and what are you doing? I didn't know there was a ruby interface to itunes, sounds interesting
Indian_ [Indian_!~Indian@unaffiliated/londonmet050] has joined #ruby
ckrailo [ckrailo!~ckrailo@208.86.167.247] has joined #ruby
<bikr> I'm using rb-appscript
<bikr> it = Appscript.app("iTunes")
<bikr> it.playlists[userAction.strip].play
xhr [xhr!~xhr@94.177.39.155] has joined #ruby
rushed [rushed!~rushed@cpe-70-116-11-35.austin.res.rr.com] has joined #ruby
<Aristata> bikr: Hey that's pretty neat!
<Aristata> I may have to play with it in my free time
cousine [cousine!~cousine@196.221.61.89] has joined #ruby
macmartine [macmartine!~macmartin@069-064-227-254.pdx.net] has joined #ruby
norex [norex!~quassel@41-133-178-25.dsl.mweb.co.za] has joined #ruby
Doctor7 [Doctor7!1899c816@gateway/web/freenode/ip.24.153.200.22] has joined #ruby
keyword [keyword!~Adium@190.176.176.219] has joined #ruby
<Doctor7> Hello All! I have a question on the Ruby on Rails Tutorial by Michael Hartl. I am in Chapter 4 doing the exercises. 4.5.1 to be exact. First is there a place to find the solutions to these exercises? If not, anyone got some time to help me on 4.5.1?
d2dchat [d2dchat!~d2dchat@173-167-14-1-michigan.hfc.comcastbusiness.net] has joined #ruby
Doctor7 [Doctor7!1899c816@gateway/web/freenode/ip.24.153.200.22] has quit [#ruby]
<catphish> if you'll excuse the moderate level of spamming: http://therubygame.com/
mr_the_shadow [mr_the_shadow!~mr_the_sh@70-89-14-189-jax-fl.hfc.comcastbusiness.net] has joined #ruby
ank [ank!~ank@c-67-172-16-188.hsd1.pa.comcast.net] has joined #ruby
<catphish> i got my sandbox working
eldariof [eldariof!~CLD@81.200.24.162] has joined #ruby
hydrozen [hydrozen!~textual@modemcable110.38-37-24.static.videotron.ca] has joined #ruby
quest88 [quest88!~quest88@c-98-207-205-137.hsd1.ca.comcast.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<hydrozen> what does $* represent exactly?
RomD`` [RomD``!~Roman@nrbg-4dbfd847.pool.mediaWays.net] has joined #ruby
<catphish> $* Command line arguments given for the script sans args.
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<catphish> basically ARGV
thatryan [thatryan!~thatryan@c-24-4-167-46.hsd1.ca.comcast.net] has joined #ruby
Manhose [Manhose!~Manhose@193.136.33.133] has joined #ruby
jwmann [jwmann!~Adium@modemcable242.110-201-24.mc.videotron.ca] has joined #ruby
p0y_ [p0y_!~p0y@125.212.56.5] has joined #ruby
mikeg [mikeg!~mglenney@nat-uh-admins.apollogrp.edu] has joined #ruby
Jake232 [Jake232!~textual@5e04ad56.bb.sky.com] has joined #ruby
DrShoggoth [DrShoggoth!~prakwtf@68-188-73-250.static.stls.mo.charter.com] has joined #ruby
LiquidInsect [LiquidInsect!~billabney@173-228-63-32.dsl.static.sonic.net] has joined #ruby
fractastical_ [fractastical_!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
jergason [jergason!~jergason@208.97.56.66] has joined #ruby
pootpoot [pootpoot!~pootpoot@38.108.250.130] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
nuba [nuba!~nuba@pauleira.com] has joined #ruby
Natch| [Natch|!~natch@178.73.216.50] has joined #ruby
wilmoore [wilmoore!~wilmoore@70-89-165-49-ISTS-co.hfc.comcastbusiness.net] has joined #ruby
james_cotterill [james_cotterill!~james_cot@89.238.149.34] has joined #ruby
<srid> i have a utility module named Foo::Bar, but it gets verbose to use functions from this module. eg: Foo::Bar.doThis(Foo::Bar.getThat(Foo::Bar.findIt)) -- how would I simplify it?
<srid> in python, I can simply do "from foo.bar import dothis, getthat, findit"
ceej [ceej!~anonymous@cpe-72-190-40-203.tx.res.rr.com] has joined #ruby
<shevy> srid, you can do "include Foo"
<shevy> without the quotes
<shevy> then you can omit the Foo:: namespacing
<srid> i was doing require "foo/bar". i will try include now.
<shevy> with require you load the files
<shevy> but that is not related to include, you include a module (often enough a namespace)
<shevy> require 'your_module'
<shevy> include YourModule
<srid> now I get - uninitialized constant Foo::Bar (NameError)
<freenodiz> catphish,fuck yeahhhh!!! http://therubygame.com/ keep going with the spam
<shevy> you probably did not require it
<srid> note that those functions are wrapped in class << self
<srid> shevy: i did both require and include
<shevy> srid, in such examples it may be best to make example code
friskd [friskd!~friskd@71-95-209-242.static.mtpk.ca.charter.com] has joined #ruby
<catphish> freenodiz: we got bored and thought that might be fun :)
<shevy> or perhaps I can make example code, a moment
<freenodiz> FUN is keyword for a happy programmer :)
<catphish> lol
sonkei [sonkei!~sonkei@d14-69-26-171.try.wideopenwest.com] has joined #ruby
Lord-Harlot [Lord-Harlot!~Serenity@adsl-87-102-126-62.karoo.KCOM.COM] has joined #ruby
mxweas_ [mxweas_!~max@c-71-226-112-145.hsd1.az.comcast.net] has joined #ruby
<srid> shevy: there was a typo in my code; now the error message is different. here's what the code looks like https://gist.github.com/1486867
<shevy> hmm
<shevy> did you try
<shevy> include Foo
<shevy> too?
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<shevy> not entirely sure how the class << self resolves
<srid> class << self is essentially same as def self.dothis
<shevy> kk
<srid> `include Foo` in `module Foo`? :)
<srid> ruby modules confuse me (being a python programmer). any good resource to clarify it?
<srid> blog post or something
<shevy> well
<shevy> the part about:
<shevy> EventMachine.run do
<shevy> yeah
<shevy> try include Foo for a moment
<shevy> that code confuses me, can't we work on my example :P
<srid> there is also a class defined immediately after the .run do line
<shevy> hmm
<shevy> ohhhh
<shevy> rather than:
<shevy> Foo::Bar.dothis
<shevy> you want to do...
<shevy> dothis
<srid> no, nevermind. there is no class
<srid> yea
<shevy> let me try to make that with my example
JStoker [JStoker!jstoker@unaffiliated/jstoker] has joined #ruby
<srid> i am able to do "Bar.doThis" which is better, though not idea
<srid> l
<srid> freenodiz: thanks
<freenodiz> kk,welcome
bier [bier!~bier@p54A5BB59.dip.t-dialin.net] has joined #ruby
bier|tp [bier|tp!~bier@p54A5BB59.dip.t-dialin.net] has joined #ruby
<srid> also, it seems that I cannot def a function on the fly and use it in the same block
<srid> inside EventMachine.run for example
<srid> this is why I was forced to define my temporary functions in a separate module (Foo.bar)
eywu [eywu!~Adium@205-170-107-4.dia.static.qwest.net] has joined #ruby
<srid> def'ing a func on a the fly is useful when i'm in prototype mode
<freenodiz> srid,that post seems very long and rich in information,i bet you gonna find many answers in there
<srid> yea, i'm reading it
fractastical [fractastical!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
<shevy> yeah I am a bit stumped
<shevy> def self.foo
Sonderblade [Sonderblade!~Bjorn@fw.soderbergpartners.se] has joined #ruby
<shevy> I don't seem to be able to drop the Bar:: resolution at all
<shevy> sorry srid
<shevy> right now I have no idea how to turn from Foo::Bar.dothis to dothis within a class residing in a module
Helius [Helius!~Adium@93-35-233-230.ip57.fastwebnet.it] has joined #ruby
<srid> heh, don't apologize! its a pleasure to discuss these things even if we couldn't find a resolution
p0y [p0y!~p0y@125.212.56.5] has joined #ruby
<Zal> srid ruby modules are like abstract mixin classes. What python calls modules are more like ruby's "gems"
<catphish> wow, our ruby game had loads of responses
<shevy> I think I solved something similar only via a wrapper function
<shevy> like in that class, define a dothis method
<shevy> which calls Foo::Bar.dothis
<shevy> but also ...
<shevy> if the class is in that module namespace, I dont think you have to use Foo::
fractastical [fractastical!~jdietz@93.104.92.232] has joined #ruby
dbernar1 [dbernar1!~dbernar1@205-200-13-84.static.mtsallstream.net] has joined #ruby
p0y_ [p0y_!~p0y@125.212.56.5] has joined #ruby
<dbernar1> I'm writing a thor script, and if I give it a required argument, I can't run it by itself on the command line any more to get a list of available tasks. Does anyone know what the deal with that is?
davidcelis [davidcelis!~david@70-89-180-6-smc-or.hfc.comcastbusiness.net] has joined #ruby
<srid> Zal: by rugy's "gems" - are you referring to the installable rubygem packages (eg: gem install net-ssh)?
<freenodiz> I think you guys just have to forget python and just think ruby from the base,sometimes it's harder to mimic one language into the other,rather than starting from zero
adambeynon [adambeynon!~adambeyno@212.183.128.180] has joined #ruby
<Zal> srid, yes, there seems to be no distinction between (what python calls) packages and modules. Both are "gems" in ruby.
<Zal> I may be oversimplifying the package part though
<srid> one difference between py's pkg and mod is that a pkg can contain submodule (foo.bar), where as a module cannot
<Zal> srid, hardest switches for me so far: remembering to type "end", and strings are mutable.
dasfugufish [dasfugufish!~Adium@71-213-26-228.slkc.qwest.net] has joined #ruby
thone [thone!~thone@g226034078.adsl.alicedsl.de] has joined #ruby
* srid wish emacs's paredit automatically inserted `end`
kuadrosx [kuadrosx!~quassel@186.87.191.80] has joined #ruby
pcboy [pcboy!~pcboy@ad035171.dynamic.ppp.asahi-net.or.jp] has joined #ruby
h4mz1d [h4mz1d!~hamfz@99-0-57-199.lightspeed.tsclal.sbcglobal.net] has joined #ruby
io_syl [io_syl!~io_syl@unaffiliated/steph021] has joined #ruby
<srid> from that blog post - "What Ruby calls "'foo'[0]", Python calls "ord('foo'[0])". What Python calls "'foo'[0]", Ruby calls "'foo'[0,1]" or "'foo'[0].chr"."
<srid> that seems false.
nekid [nekid!nekid@115.242.53.101] has joined #ruby
<srid> "foo"[0] in ruby returns "f" - as does python
ikaros [ikaros!~ikaros@studpool-wlan-75-120.fs.fbi.h-da.de] has joined #ruby
<Zal> srid, I noticed that too. Seems like normal string character indexing to me.
<Zal> maybe an older version of Ruby did that?
<Zal> "foo"[0].ord returns an ordinal though
<nekid> ? that's normal right?
<Zal> nekid, apparently so, but the article we're reading claims otherwise.
<nekid> link me?
<nekid> im on 1.9.2 is it a 1.9.3 thing?
<Zal> I dunno, I'm on 1.9.1
Pcboy___ [Pcboy___!~pcboy@y233083.dynamic.ppp.asahi-net.or.jp] has joined #ruby
<Mon_Ouie> srid: That's from 1.8.7
<Mon_Ouie> In 1.8 "foo"[0] is an integer
austinbv [austinbv!~austinbv@rrcs-24-73-203-202.se.biz.rr.com] has joined #ruby
andywww [andywww!~andy@cpc2-scun4-0-0-cust229.12-3.cable.virginmedia.com] has joined #ruby
Cervajz [Cervajz!~Cervajz@opensuse/member/Cervajz] has joined #ruby
<andywww> hi, i'm really struggling to get to the content string in this XML file using nokogiri. I wondered if someone might be able to help me out?
adeponte [adeponte!~adeponte@67.110.253.162.ptr.us.xo.net] has joined #ruby
<andywww> the namespaces are causing me all kinds of problems
<srid> which ruby (1.9) book would you recommend for a python programmer? it should be concise (not verbose) and straight to the point.
<nekid> pickaxe
<nekid> is bread & butter i hear
<nekid> just dl pdf it's indexed well, you can click on stuff you want to read
maletor [maletor!~maletor@74.115.25.139] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
fractastical [fractastical!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
zommi [zommi!~quassel@HSI-KBW-078-042-009-093.hsi3.kabel-badenwuerttemberg.de] has joined #ruby
adeponte [adeponte!~adeponte@67.110.253.162.ptr.us.xo.net] has joined #ruby
Araxia [Araxia!~Araxia@173-164-68-213-Oregon.hfc.comcastbusiness.net] has joined #ruby
tvw [tvw!~tv@e176008254.adsl.alicedsl.de] has joined #ruby
n8ji [n8ji!~n8ji@c-24-20-239-11.hsd1.or.comcast.net] has joined #ruby
<Zal> srid, the ruby koans online were pretty useful to me.
Mahoek [Mahoek!~Mahoek@ip51ceb6d4.adsl-surfen.hetnet.nl] has joined #ruby
<srid> i'll get back to all this learning stuff tomorrow; for now, i must get back to progressing on the ruby websockets/eventmachine project at work ...
<srid> (rewrite of a clojure project, actually. clojure was so much fun)
<davidcelis> srid: The Well-Rounded Rubyist
<davidcelis> srid: Or, Metaprogramming Ruby
craigglennie [craigglennie!~craigglen@173-167-99-61-sfba.hfc.comcastbusiness.net] has joined #ruby
<srid> davidcelis: doesn't the later require ruby knowledge?
<srid> or, is it similar to diveintopython?
<davidcelis> I hear the book recommended to beginner Rubyists fairly often
<davidcelis> As a way to learn Ruby
freenodiz [freenodiz!~IceChat77@81-178-201-205.dsl.pipex.com] has joined #ruby
freenodiz [freenodiz!~IceChat77@unaffiliated/freenodiz] has joined #ruby
josh_ [josh_!~josh@74-95-43-126-Oregon.hfc.comcastbusiness.net] has joined #ruby
Jrz [Jrz!~jrz@d152222.upc-d.chello.nl] has joined #ruby
armdale [armdale!~a@24.52.227.6] has joined #ruby
andrewhl [andrewhl!~andrew@24-246-15-43.cable.teksavvy.com] has joined #ruby
apok [apok!~apok@c-107-3-149-167.hsd1.ca.comcast.net] has joined #ruby
<nekid> I'm supposed to get
<nekid> Defined in One
<srid> [1, 2, 3].map(&Math.sqrt) # this doesn't work, why?
<srid> # ArgumentError: wrong number of arguments (0 for 1)
<srid> works for &puts, though
TheShadowFog [TheShadowFog!~TheShadow@ool-1826fa3a.dyn.optonline.net] has joined #ruby
mduarte [mduarte!~mduarte@141.0.34.138] has joined #ruby
apucacao [apucacao!~apucacao@thelevel.com] has joined #ruby
keyword [keyword!~Adium@190.176.185.104] has joined #ruby
td123 [td123!~tom@archlinux/trusteduser/td123] has joined #ruby
mxweas_ [mxweas_!~max@c-71-226-112-145.hsd1.az.comcast.net] has joined #ruby
kenichi [kenichi!~kenichi@c-24-20-239-11.hsd1.or.comcast.net] has joined #ruby
paissad [paissad!~paissad@89-92-16-151.hfc.dyn.abo.bbox.fr] has joined #ruby
ascarter [ascarter!~ascarter@216.243.14.210] has joined #ruby
iocor [iocor!~textual@unaffiliated/iocor] has joined #ruby
Lord-Harlot [Lord-Harlot!~Serenity@adsl-87-102-126-62.karoo.KCOM.COM] has joined #ruby
fractastical [fractastical!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
perryh [perryh!~root@unaffiliated/perry753] has joined #ruby
wyhaines [wyhaines!~wyhaines@65.39.118.15] has joined #ruby
<robert_> banisterfiend: the dl module is broken in Ruby 1.8.7; I'm trying to compile from source, and I'm getting all sorts of compiler errors. :/
<Aristata> robert_: Maybe have a look into rvm
Mohan [Mohan!~nixh0st@unaffiliated/mohan] has joined #ruby
<robert_> hm
<nekid> anyone know how to default tabbing in scite to 2 spaces?
<davidcelis> Depends on your editor.
<Mon_Ouie> He said it was scite…
PhilK [PhilK!~PhilK@2001:470:1f05:c99:21f:d0ff:fe84:e3ca] has joined #ruby
<davidcelis> I thought that was a typo of some word
<davidcelis> Never heard of Scite
<Mon_Ouie> It's capitalized in a weird way
<Mon_Ouie> SciTE
<davidcelis> lol
<nekid> damn, anyone know a word editor which I can default it, or has it as default already
Tuxist [Tuxist!~quassel@dyndsl-091-096-124-187.ewe-ip-backbone.de] has joined #ruby
<Zal> nekid, I'd be surprised if any editor could NOT do that
luckyruby [luckyruby!~luckyruby@rrcs-24-129-162-10.se.biz.rr.com] has joined #ruby
<S0lign0c> hi
apok [apok!~apok@c-107-3-149-167.hsd1.ca.comcast.net] has joined #ruby
SegFaultAX|work [SegFaultAX|work!~mkbernard@173.228.45.162] has joined #ruby
eywu [eywu!~Adium@205-170-107-4.dia.static.qwest.net] has joined #ruby
<S0lign0c> I have write a ls -l command in Ruby. Can you see what is wrong ? is there a way to print for 644 rw-r--r-- ?
adamkittelson [adamkittelson!~adamkitte@50.0.132.2] has joined #ruby
amerine [amerine!~mturner@67.204.184.82] has joined #ruby
xissburg_ [xissburg_!~xissburg@187.3.1.32] has joined #ruby
ianbrandt [ianbrandt!~ianbrandt@99-111-99-153.uvs.sndgca.sbcglobal.net] has joined #ruby
luckyruby [luckyruby!~luckyruby@rrcs-24-129-162-10.se.biz.rr.com] has joined #ruby
<davidcelis> nekid: What's yer OS
thatryan [thatryan!~thatryan@c-24-4-167-46.hsd1.ca.comcast.net] has quit ["Linkinus - http://linkinus.com"]
<davidcelis> nekid: You could always switch to vim. that lets you do it
<catphish> who ran sleep(3)
<catphish> lol
<catphish> *wrong room
xissburg_ [xissburg_!~xissburg@187.3.1.32] has joined #ruby
guns [guns!~guns@c-98-228-72-208.hsd1.il.comcast.net] has joined #ruby
<shevy> S0lign0c, what is world_readable?
kenperkins [kenperkins!~textual@174-24-164-49.tukw.qwest.net] has joined #ruby
<S0lign0c> shevy: world_readable? get permissions of a file
voodoofish430 [voodoofish430!~mtorres@208.76.2.200] has joined #ruby
tar_ [tar_!~tar@d118-75-81-132.try.wideopenwest.com] has joined #ruby
<S0lign0c> and sprintf("%o", perm) change for unix system 420 -> 644
eywu [eywu!~Adium@205-170-107-4.dia.static.qwest.net] has joined #ruby
spinagon [spinagon!~rippa@109-161-73-144.pppoe.yaroslavl.ru] has joined #ruby
ascarter [ascarter!~ascarter@216.243.14.210] has joined #ruby
quest88 [quest88!~quest88@12.181.53.99] has joined #ruby
hadees [hadees!~hadees@rrcs-71-41-203-94.sw.biz.rr.com] has joined #ruby
pandora17 [pandora17!~pandora17@p508D509F.dip.t-dialin.net] has joined #ruby
shadoi [shadoi!~Adium@2001:5a8:4:68e1:aded:68ca:5df0:6b88] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
Russell^^ [Russell^^!~Russell^^@88.97.51.87] has joined #ruby
gearaholic [gearaholic!~gearaholi@c-71-238-98-243.hsd1.mi.comcast.net] has joined #ruby
remink [remink!~remink@unaffiliated/remink] has joined #ruby
<remink> hi guys
KinkyKamikaze [KinkyKamikaze!~KinkyKami@seattle244.riseup.net] has joined #ruby
<S0lign0c> hi
apok_ [apok_!~apok@c-107-3-149-167.hsd1.ca.comcast.net] has joined #ruby
<S0lign0c> Can i have permissions of file directly like that rw-r--r-- in ruby ?
keyword [keyword!~Adium@190.176.185.104] has quit [#ruby]
<gearaholic> I have a ruby script that uploads all files in a dir to rackspaces cloud storage. Everything works perfectly when I run it manually on the server. But it needs to be executed from a java app. When i run the java code it executes the script. but it only uploads 1 file not all 10. any ideas?
<shevy> S0lign0c if you modify File, sure
yekta [yekta!~yekta@nat-165-91-14-245.tamulink.tamu.edu] has quit [#ruby]
<ReinH> gearaholic: well, does it raise any errors?
<ReinH> we can't know why it magically doesn't work but if you give us enough info we might be able to help
<gearaholic> not that i have been able to find
remink [remink!~remink@unaffiliated/remink] has quit [#ruby]
<S0lign0c> shevy: just for display, i want to take permission of file and show it like unix chmod tools. is not important.
<gearaholic> The ruby process for that script does stay running
<shevy> S0lign0c it's not hard
kenichi [kenichi!~kenichi@c-24-20-239-11.hsd1.or.comcast.net] has joined #ruby
<ReinH> gearaholic: you need to instrument things to see what's going on
<ReinH> throw some puts or p statements in there
<shevy> permissions = ('%o' % File.stat(file).mode)[-3,3]
<shevy> where file is your given file
havenn [havenn!~skipper@pool-72-67-31-69.lsanca.fios.verizon.net] has joined #ruby
<S0lign0c> shevy: i have write a method str_perm for that http://pastie.org/3027444
<S0lign0c> shevy: i just want rw-rxr--- like that
<S0lign0c> but thank
<shevy> yeah it's a lot of code for something that should be simple
<shevy> but as long as it does what you need
<shevy> btw use str << rather than +=
<S0lign0c> shevy: yes i will change for your code
<S0lign0c> shevy: i'am using a String buffer
kirun [kirun!~kirun@78-86-154-194.zone2.bethere.co.uk] has joined #ruby
hoonda [hoonda!55abc199@gateway/web/freenode/ip.85.171.193.153] has joined #ruby
<hoonda> Hi
wmoxam_ [wmoxam_!~wmoxam@76.9.195.38] has joined #ruby
<hoonda> some1 can explain me the assert_performance_linear method ?
mrsolo [mrsolo!~mrsolo@64.125.181.73] has joined #ruby
eignerchris [eignerchris!~eignerchr@c-24-20-239-11.hsd1.or.comcast.net] has joined #ruby
<shadoi> S0lign0c: you know they added string perm support in 1.9.3 right?
<S0lign0c> shadoi: no, i was searching in File class
<S0lign0c> shadoi: ok thank
bafilius [bafilius!~lee@wsip-174-75-64-190.sb.sd.cox.net] has joined #ruby
<S0lign0c> shadoi: i want to get r-- from a file, not change permission :D
<shadoi> Ah, sorry, misread
zastaph [zastaph!~uid@unaffiliated/zastaph] has joined #ruby
pootpoot [pootpoot!~pootpoot@38.108.250.130] has quit [#ruby]
<S0lign0c> so, i've write a dirty method with a big switch to change 400 to r------
<Zal> is it big?
<S0lign0c> Zal: not very, with seven cases.
abdul [abdul!bari_72@78.90.253.31] has joined #ruby
dhodgkin [dhodgkin!~dhodgkin@cpe-76-179-199-112.maine.res.rr.com] has joined #ruby
<shevy> hmm
<shevy> 8/5 in python returns 1.6
<Zal> shevy, only in python3
<shevy> oh
<shevy> nice catch
abdul [abdul!bari_72@78.90.253.31] has quit [#ruby]
headius [headius!~headius@71-210-151-185.mpls.qwest.net] has joined #ruby
<Zal> shevy, if you want integer division in python, use 8//5 (works in python2 and python3)
dark3rdre4ms [dark3rdre4ms!~Ethan@unaffiliated/eth4n] has joined #ruby
negaduck [negaduck!~negaduck@213.141.130.13] has joined #ruby
<Zal> (now back to your regularly scheduled Ruby)
wmoxam_ [wmoxam_!~wmoxam@69-196-160-133.dsl.teksavvy.com] has joined #ruby
wmoxam [wmoxam!~wmoxam@pdpc/supporter/active/wmoxam] has joined #ruby
dhodgkin [dhodgkin!~dhodgkin@cpe-76-179-199-112.maine.res.rr.com] has joined #ruby
dhodgkin [dhodgkin!~dhodgkin@cpe-76-179-199-112.maine.res.rr.com] has joined #ruby
sepp2k [sepp2k!~sexy@g224101132.adsl.alicedsl.de] has joined #ruby
cylence [cylence!~cylence@64-71-24-18.static.wiline.com] has joined #ruby
QaDeS [QaDeS!~mklaus@frbg-5d84fe49.pool.mediaWays.net] has joined #ruby
billy_ran_away [billy_ran_away!~billy_ran@173-167-194-14-ip-static.hfc.comcastbusiness.net] has joined #ruby
ascarter [ascarter!~ascarter@209.119.253.66] has joined #ruby
keyword [keyword!~Adium@190.176.185.104] has joined #ruby
<keyword> anyone knows an alternative for select method for array?
kaneda [kaneda!~kaneda@5ad75508.bb.sky.com] has joined #ruby
<spinagon> what do you want of it?
<keyword> something more faster
Norex [Norex!~nicholas@41-133-178-25.dsl.mweb.co.za] has joined #ruby
<keyword> select is slow for big array
avitzurel [avitzurel!~avitzurel@212.179.244.22] has joined #ruby
mikepack [mikepack!~mikepack@c-174-51-77-22.hsd1.co.comcast.net] has joined #ruby
smooth_p [smooth_p!~smooth_p@115.114.59.182] has joined #ruby
<smooth_p> hey in a tcpsocket, how can control the flush
<billy_ran_away> Can anyone help me with my class/module thing?
<smooth_p> using sock.write, sock.puts seems to flush the data instantly
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<billy_ran_away> I'm trying to write something for use with Rails, but I need help with the Ruby more than Rails…
pootpoot [pootpoot!~pootpoot@38.108.250.130] has joined #ruby
<billy_ran_away> I'm trying to have a maskable attribute, that is a string that is made up of masks, the masks are just methods to be run against an object, I need to be able to provide an array of those masks, and both the masked and unmasked string.
<billy_ran_away> Additionally when I'm setting the string with the masks "unmasked" I want to try and preserve the masks.
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
_debo [_debo!~marco.deb@cpc18-enfi16-2-0-cust743.hari.cable.virginmedia.com] has joined #ruby
<billy_ran_away> I've got code up here http://pastie.org/3027735 along with the behavior I'm looking for here: http://pastie.org/3027735
<billy_ran_away> I meant at the bottom
<billy_ran_away> Not two different pasties : )
<billy_ran_away> Anyone care to take a look and tell me what I'm doing wrong?
Yani [Yani!~yani@77-85-65-16.btc-net.bg] has joined #ruby
TheShadowFog [TheShadowFog!~TheShadow@ool-1826fa3a.dyn.optonline.net] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
Sailias_ [Sailias_!~jonathan@CPE0018f85e576d-CM001bd7aaaf96.cpe.net.cable.rogers.com] has joined #ruby
g0bl1n [g0bl1n!~prokter@a213-22-27-14.cpe.netcabo.pt] has joined #ruby
vladyn [vladyn!~vlado@214-125.thezone.bg] has joined #ruby
<shevy> billy_ran_away, seems too much code to grasp with one glancer alone
<shevy> *glance
<billy_ran_away> shevy: Okay, well I appreciate you looking nonetheless. : )
nanoyak [nanoyak!~nanoyak@50-0-164-69.dsl.dynamic.sonic.net] has joined #ruby
bluOxigen [bluOxigen!ssf@unaffiliated/bluOxigen] has joined #ruby
<csmrfx> billy_ran_away: divide and conquer
Spockz [Spockz!~Spockz@21pc198.sshunet.nl] has joined #ruby
<csmrfx> divide your problem down to subproblems you can define clearly in english language and couple of lines of pastie
<csmrfx> billy_ran_away: and thats not a suggestion
dv310p3r [dv310p3r!~dv310p3r@host-208-68-238-122.biznesshosting.net] has joined #ruby
<billy_ran_away> csmrfx: Okay thanks
<csmrfx> yep that way ppl will have no prob helping you
d2dchat [d2dchat!~d2dchat@d14-69-12-25.try.wideopenwest.com] has joined #ruby
Sliker [Sliker!~ponies@31.185.225.248] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
dankest [dankest!~dankest@wsip-174-75-64-190.sb.sd.cox.net] has joined #ruby
n8ji_ [n8ji_!~n8ji@c-24-20-239-11.hsd1.or.comcast.net] has joined #ruby
Stormbytes [Stormbytes!~storm@ool-4572b631.dyn.optonline.net] has joined #ruby
<shevy> hehe
bdrewery [bdrewery!bryan@unaffiliated/bdrewery] has joined #ruby
daniel_hinojosa [daniel_hinojosa!~danno@c-68-35-182-153.hsd1.nm.comcast.net] has joined #ruby
nekid [nekid!nekid@115.242.125.151] has joined #ruby
<srid> something about EventMachine.popen annoys me: http://eventmachine.rubyforge.org/EventMachine.html#M000491
robbkidd [robbkidd!896461f2@gateway/web/freenode/ip.137.100.97.242] has joined #ruby
<srid> i am forced to create module Handler for handling data from the process
<srid> but since EM.system is being called from within a function, when I defined this Handler inside the function, ruby is complaining "module definition in method body (SyntaxError)"
<srid> how else would I define the handler?
adamkittelson [adamkittelson!~adamkitte@50.0.132.2] has joined #ruby
<srid> here's my code: https://gist.github.com/1487561
mocker_ [mocker_!~mocker@72.165.148.230] has joined #ruby
dfamorato [dfamorato!~dfamorato@host-67-23-71-110.biznesshosting.net] has joined #ruby
__main__ [__main__!~main@adsl-99-173-15-158.dsl.pltn13.sbcglobal.net] has joined #ruby
rramsden [rramsden!~rramsden@s64-180-62-209.bc.hsia.telus.net] has joined #ruby
WhiteHorse [WhiteHorse!~WhiteHors@201.208.150.8] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
jergason [jergason!~jergason@208.97.56.66] has joined #ruby
<nlew> Does anyone have any insight into the 1.9.3 change that makes this code deadlock? http://pastie.org/3027895
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<guns> nlew: works for me on 1.9.3
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<samuelkadolph> Maybe traps were moved to a background thread and it deadlocks writing to $stdout
Manhose [Manhose!~Manhose@a94-132-167-54.cpe.netcabo.pt] has joined #ruby
<nlew> guns: It's sporadic, for me. It's a deadlock when writing.
<samuelkadolph> guns: It can break in 1.9.3
<nlew> samuelkadolph: That was exactly my thought. Was just wondering if anyone knew for sure.
apok [apok!~apok@c-107-3-149-167.hsd1.ca.comcast.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<nlew> I have a test that traps HUP with an expectation and calls some code that should hope
<nlew> And most of the time, it just dies with SIGHUP. Very rarely, it works.
<nlew> should HUP, not should hope*
dr_bob [dr_bob!~dr_bob@p5DC4EECE.dip.t-dialin.net] has joined #ruby
<nlew> although THAT code also fails on 1.9.2, but what I pastied doesn't
Guest24286 [Guest24286!~awesome@212.62.202.84.customer.cdi.no] has joined #ruby
looopy [looopy!~looopy@static-71-166-231-15.washdc.east.verizon.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<guns> nlew: I would be curious to see your code
negaduck_ [negaduck_!~negaduck@213.141.130.13] has joined #ruby
<samuelkadolph> Gotta love concurrency, printing a list of threads prevents the deadlock
dfamorato [dfamorato!~dfamorato@host-67-23-71-110.biznesshosting.net] has joined #ruby
<samuelkadolph> Actually it's probably because the kernel interrupts with the HUP while ruby locked $stdout with the puts
<guns> samuelkadolph: How's that? Does that serialize the thread execution for a crucial moment?
<samuelkadolph> guns: Slows down ruby enough
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<guns> I'm embarassed to say I've used `sleep 0.1` in a Thread spawning loop to accomplish the same thing
<guns> yuck
jrist [jrist!~jrist@184-96-222-92.hlrn.qwest.net] has joined #ruby
<samuelkadolph> nlew: I would say synchronize your trap callbacks or avoid locking any IO
<nlew> controlled_run essentially just calls the block, then Process.kill(:HUP, $PID)
mickn [mickn!~mickn@unaffiliated/mickn] has joined #ruby
<guns> cloning the repo to view in vim, although samuelkadolph is probably right - IO locking is usually the problem
<samuelkadolph> Nah, it is the problem
<samuelkadolph> It's the only way it could deadlock
<nlew> It's the cause of the deadlock
<nlew> In the sample code. But not the cause of the signal not being trapped in my test.
<guns> maybe a un threadsafe logger?
<samuelkadolph> nlew: Then the is probably code trapping HUP after you trap it
<nlew> oh oh oh, of course
skrewler [skrewler!~skrewler@209.213.206.58] has joined #ruby
<nlew> no, maybe not, hmm
<samuelkadolph> Such is the plight of trapping signals, only one callback at a time
<nlew> my thought is that it's restoring the default handler in the ensure
<nlew> and if signal handling happens in another thread, perhaps the default handler is being restored before the signal is caught
<samuelkadolph> It's not
<nlew> but that doesn't actually make sense
<samuelkadolph> Make sure that code is blocking so the ensure isn't running
Hounth [Hounth!~hounth@212-198-135-229.rev.numericable.fr] has joined #ruby
<samuelkadolph> Until after the HUP is trapped
<guns> ah, Signal.trap is itself async then?
<nlew> hmm I removed the ensure and it passes reliably
<samuelkadolph> guns: No
<samuelkadolph> The method is synchronous and installs a new handler for the trapped signal
<guns> well then that's not his problem
<samuelkadolph> And whenever the kernel sends the signal, the block will be run
<samuelkadolph> No matter where you are with other code
<samuelkadolph> That's why it's dangerous to do almost anything in a trap because you can deadlock so easily
robacarp [robacarp!robacarp@nat/sparkfun/x-gzbdsmeedhoivmpe] has joined #ruby
<samuelkadolph> Using IO is a huge no-no
<nlew> That makes perfect sense
<nlew> But doesn't explain the behavior I'm seeing
<samuelkadolph> It does for the puts deadlock
<nlew> Yeah, for that, absolutely
<samuelkadolph> If you aren't trapping the HUP then you aren't the registered callback anymore
_md [_md!~mduarte@cpc4-finc13-2-0-cust568.4-2.cable.virginmedia.com] has joined #ruby
<samuelkadolph> You need to see when controlled_run is returning because if it's before the HUP is sent then your ensure will restore the previous callback
<guns> that's right; the ensure block needs to be synchronous with the trap callback
<samuelkadolph> That makes no sense in the context
aleksi [aleksi!~aleksi@176.57.74.133] has joined #ruby
<enroxorz> hey guys. I am wracking my brain on this one and i might be messing up. I need to put a break before every $ taht is in a variable. I have this, but it only does the first. how can i do it to each $ in the string? if(arg2.include?('$')): arg2.insert(0,"\\") end
<enroxorz> i mean, i can loop through the string char by char but that doesnt seem efficient...
<samuelkadolph> enroxorz: Use gsub
<enroxorz> damn. thanks
rickmasta [rickmasta!~rickmasta@pool-108-21-213-102.nycmny.fios.verizon.net] has joined #ruby
<guns> sure it is. he wants `target.some_method` to be run on SIGHUP, but the ensure block restores the `old_handler` before the process receives the signal
mocker [mocker!~mocker@72.165.148.230] has joined #ruby
<samuelkadolph> guns: Yes but that's nothing to do with synchronous vs asynchronous. signals are special cases and fit into neither.
<nlew> Really, the handler that makes sure my expectation is satisfied should restore the old handler
<nlew> Or not, even.
<samuelkadolph> It should be when the test is done
<guns> samuelkadolph: Can you explain further? Signal handling is by its nature asynchronous.
<nlew> With an after to restore it. Though then the test would fail sporadically
<nlew> Rather than dying sporadically
<guns> nlew: looks like controlled_run is sending HUP to $PID then restoring the HUP handler before the process receives the signal
<samuelkadolph> guns: Signals are more the kernel telling the process to "STOP EVERYTHING AND DO THIS NOW" rather than the process sleeping or polling for asynchronous events
<guns> samuelkadolph: right, async via interrupts
<enroxorz> samuelkadolph thanks man - if(arg2.include?('$')): arg2.gsub(/\$/,"\\$")
<samuelkadolph> enroxorz: There is no point in checking with include? before using gsub
<samuelkadolph> And why would you replace \$ with \$?
<enroxorz> in the regex $ is a special character, so i have to break it when i look for it...
<samuelkadolph> Oh right, those / and not '
<samuelkadolph> You can use a string instead of a regexp
<enroxorz> hmm. let me fire up irb again
geekbri [geekbri!~geekbri@c-50-133-179-169.hsd1.ma.comcast.net] has joined #ruby
<samuelkadolph> "$".gsub("$", "\\$") # => "\\$"
<enroxorz> awesome! Thanks
LittleBill902 [LittleBill902!~smith@c-71-197-102-219.hsd1.ca.comcast.net] has joined #ruby
<rippa> '$'.gsub('$', '\$') # => "\\$"
<samuelkadolph> Death to single quote strings!
Axsuul [Axsuul!~Axsuul@75-140-75-52.dhcp.mtpk.ca.charter.com] has joined #ruby
stephenjudkins [stephenjudkins!~stephen@68.178.19.17] has joined #ruby
mocker [mocker!~mocker@72.165.148.230] has joined #ruby
mmokrysz [mmokrysz!~mmokrysz@pdpc/supporter/student/mmokrysz] has joined #ruby
<v0n> hey,
<v0n> case sth; when Array then do_sth(); end will match if sth == [] for example, but what if you want to check if the value _is_ Array? i.e. sth = Array
cjk101010 [cjk101010!~ckruse@painkiller.defunced.de] has joined #ruby
<samuelkadolph> v0n: when Class; if stm <= Array; end; end
<robacarp> I'm working with proc bindings and I'm trying to sort out if there is a way to inject objects into the scope. Eval gives the ability to inject objects that can be converted to/from strings but object data doesn't really fit this paradigm. What am I missing?
bbttxu_ [bbttxu_!~adam@24-178-215-34.static.ftwo.tx.charter.com] has joined #ruby
<robacarp> v0n: you could do case sth.class; when Array then do_sth(); end
<samuelkadolph> No you can't
<samuelkadolph> Array === Array # => false
catphish [catphish!~charlie@2001:9d8:2005:12::3] has joined #ruby
tar_ [tar_!~tar@cpe-98-28-26-98.columbus.res.rr.com] has joined #ruby
dekroning [dekroning!~dekroning@541B931D.cm-5-4c.dynamic.ziggo.nl] has joined #ruby
looopy [looopy!~looopy@static-71-166-231-15.washdc.east.verizon.net] has joined #ruby
<robacarp> hmm. Array == Array #=> true
skrewler [skrewler!~skrewler@209.213.206.58] has joined #ruby
<samuelkadolph> And that has nothing to do with case
<robacarp> okay, my bad, calm down.
aleksi [aleksi!~aleksi@176.57.74.133] has quit [#ruby]
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<v0n> hum, it's gonna be tricky if I want to allow multiple synonym such as String, :string, etc. I should better force a convention, symbol for instance.
looopy_ [looopy_!~looopy@c-68-34-92-100.hsd1.md.comcast.net] has joined #ruby
<guns> robacarp: well there's Marshal.load for non-Proc data. Sounds like you really want a Lisp though
pencilcheck [pencilcheck!~pen@wl054.cc.ntu.edu.tw] has joined #ruby
<v0n> or I can maybe do a case on sth.to_s.downcase
pen_ [pen_!~pen@g1pc2n249.g1.ntu.edu.tw] has joined #ruby
alek_b [alek_b!~alek_b@99-10-120-63.lightspeed.sndgca.sbcglobal.net] has joined #ruby
keyword [keyword!~Adium@190.176.185.104] has quit [#ruby]
Morkel [Morkel!~Morkel@xdsl-87-78-205-136.netcologne.de] has joined #ruby
flip_digits [flip_digits!~textual@c-76-122-14-228.hsd1.fl.comcast.net] has joined #ruby
<robacarp> guns: Marshal.load might work, thanks for the tip.
jgrimes [jgrimes!~jg@cpe-071-070-140-012.nc.res.rr.com] has joined #ruby
mocker [mocker!~mocker@72.165.148.230] has joined #ruby
robyurkowski [robyurkowski!~robyurkow@64.254.250.82] has joined #ruby
<Creeture> Anybody know if there's an IRC channel for the god gem?
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
dv310p3r [dv310p3r!~dv310p3r@216.199.155.226.nw.nuvox.net] has joined #ruby
Quintus_q [Quintus_q!~quintus@cl-2329.cgn-01.de.sixxs.net] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
dyer_ [dyer_!~dyer@c-174-49-86-106.hsd1.ga.comcast.net] has joined #ruby
dyer_ [dyer_!~dyer@unaffiliated/dyer] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
ceej [ceej!~anonymous@cpe-72-190-40-203.tx.res.rr.com] has joined #ruby
<dyer_> Question is there anything like intert for Array that doesnt overwrite the array?
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<dyer_> I want a new copy of the array when the value inserted, and to leave the existing one intact
TheTFEF [TheTFEF!JS@cpe-173-88-110-115.columbus.res.rr.com] has joined #ruby
<samuelkadolph> dyer_: dup the array first
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
hydrozen [hydrozen!~textual@modemcable110.38-37-24.static.videotron.ca] has joined #ruby
mkscrg [mkscrg!~mkscrg@pool-108-41-134-165.nycmny.fios.verizon.net] has joined #ruby
<dyer_> samuelkadolph,I have to be missing something basic here
cableray [cableray!~cableray@75-145-121-174-Colorado.hfc.comcastbusiness.net] has joined #ruby
<nlew> dyer_: Variables in Ruby are references, so you're just making a new variable that refers to the same object.
<samuelkadolph> That's just assigning temp to the same object a is assigned to
<nlew> dyer_: You actually want temp = a.dup to make a new copy
<samuelkadolph> dyer_: I meant the Array#dup method
<cableray> how would I check what YAML engine ruby is using?
<dyer_> cool
<dyer_> thanks
ikaros [ikaros!~ikaros@dslb-084-059-073-057.pools.arcor-ip.net] has joined #ruby
<cableray> I'm getting some weird inconsistencies across two dev machines when using vcr. I think they may have different yaml engines.
<samuelkadolph> cableray: YAML will be an alias for Psych in 1.9 and YAML::ENGINE.yamler will be "psych"
dfamorato [dfamorato!~dfamorato@host-67-23-71-110.biznesshosting.net] has joined #ruby
<cableray> yaml::ENGINE.yamler gives a uninitialized constant Object::YAML error when i run that line in irb
<samuelkadolph> Then you are using 1.8 and yaml will only be syck
cyri_ [cyri_!~cyri_@jem75-1-87-88-118-80.dsl.sta.abo.bbox.fr] has joined #ruby
<cableray> No, i'm using ruby-1.9.2-p180
<samuelkadolph> Then require "yaml"
<cableray> oh, duh.
tomdebenning_ [tomdebenning_!~tomdebenn@12.208.167.194] has joined #ruby
closedbracket [closedbracket!~closedbra@smtp.goodmortgage.com] has joined #ruby
looopy [looopy!~looopy@c-68-34-92-100.hsd1.md.comcast.net] has joined #ruby
<Aristata> lolz
<Aristata> I was going to say that skimming by here but I have to many irc's open
frogstarr78 [frogstarr78!~frogstarr@lan.viviotech.net] has joined #ruby
<samuelkadolph> Aristata: too*
<Aristata> yes too
<Aristata> on the second one anyway
n8ji [n8ji!~n8ji@c-24-20-239-11.hsd1.or.comcast.net] has joined #ruby
bosphorus [bosphorus!~bosphorus@85.97.1.24] has joined #ruby
byronb [byronb!~byron@c-24-18-227-118.hsd1.wa.comcast.net] has joined #ruby
mikepack [mikepack!~mikepack@c-174-51-77-22.hsd1.co.comcast.net] has joined #ruby
fractastical_ [fractastical_!~jdietz@ppp-93-104-92-232.dynamic.mnet-online.de] has joined #ruby
<cableray> samuelkadolph: Ok it is using syck on both machines. Could the versions be different?
<samuelkadolph> Don't use syck, it's broken.
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
<cableray> but to use psych, do I have to install libyaml and recompile ruby? or is there a better way?
frogstarr78 [frogstarr78!~frogstarr@lan.viviotech.net] has joined #ruby
<shevy> for ruby 1.9.3x you must have libyaml installed
<shevy> it specifically tells something along the lines of "blabla recompile with libyaml"
<samuelkadolph> cableray: First point was fixed back in April and delayed job is just bad coding on their part
<samuelkadolph> They force(d) the engine to be syck so it broke anything that was behaving properly
<cableray> ok. cool then.
mocker [mocker!~mocker@72.165.148.230] has joined #ruby
geekbri [geekbri!~geekbri@c-50-133-179-169.hsd1.ma.comcast.net] has joined #ruby
Manhose [Manhose!~Manhose@a94-132-167-54.cpe.netcabo.pt] has joined #ruby
Jippi [Jippi!~jippignu@109.202.139.50] has joined #ruby
Manhose_ [Manhose_!~Manhose@a94-132-167-54.cpe.netcabo.pt] has joined #ruby
stephenjudkins [stephenjudkins!~stephen@67.139.75.158] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
WhiteHorse [WhiteHorse!~WhiteHors@201.208.150.8] has joined #ruby
Sailias_ [Sailias_!~jonathan@CPE0018f85e576d-CM001bd7aaaf96.cpe.net.cable.rogers.com] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
Mohan [Mohan!~nixh0st@unaffiliated/mohan] has joined #ruby
norex_ [norex_!~quassel@41-133-178-25.dsl.mweb.co.za] has joined #ruby
havenn [havenn!~skipper@pool-71-189-127-198.lsanca.fios.verizon.net] has joined #ruby
burgestrand [burgestrand!~burgestra@2.68.215.16.mobile.tre.se] has joined #ruby
<cableray> samuelkadolph: What about on jruby? do they have similar problems?
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
<samuelkadolph> They used the same syck implementation
<samuelkadolph> I haven't heard of any psyck problems with jruby though
<cableray> so you can use either yamler with jruby?
<samuelkadolph> You can use either with cruby or jruby with 1.9
Stormbytes [Stormbytes!~storm@ool-4572b631.dyn.optonline.net] has quit ["Linkinus - http://linkinus.com"]
<cableray> cool.
havenn [havenn!~skipper@pool-71-189-127-198.lsanca.fios.verizon.net] has joined #ruby
<geekbri> can you use - in ruby symbols? for example is :-mysymbol a valid symbol name?
<Aristata> yes
<geekbri> Aristata: is it necessary to escape it somehow?
mengu [mengu!~mengu@unaffiliated/mengu] has joined #ruby
<Tasser> geekbri, you can actually use any char
<dominikh> :"-foo"
<Aristata> though if you begin with a dash it's best to do :'-somethin'
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
<Aristata> I don't believe it works without the quotes
<geekbri> ah ok, so then everytime i refer to the symbol i should use quotes as well?
<Aristata> well, only if it begins with a dash,
<Aristata> and perhaps if there is a dash in it
<samuelkadolph> You need quotes if it has a dash in it
<Aristata> things like :hello, :goodbye are fine without quotes
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
<geekbri> ah ok, thanks everybody :)
dv310p3r [dv310p3r!~dv310p3r@host-208-68-238-122.biznesshosting.net] has joined #ruby
jbpros [jbpros!~jbpros@185.55-66-87.adsl-dyn.isp.belgacom.be] has joined #ruby
crescendo [crescendo!~eric@unaffiliated/crescendo] has joined #ruby
thatryan [thatryan!~thatryan@c-24-4-167-46.hsd1.ca.comcast.net] has joined #ruby
<thatryan> can somone point me to a good rails tutorial?
asobrasil [asobrasil!~asantioli@palpatine.privatedns.com] has quit [#ruby]
<deryl> railstutorial.org
<thatryan> thanks!
_debo [_debo!~marco.deb@cpc18-enfi16-2-0-cust743.hari.cable.virginmedia.com] has joined #ruby
Natch| [Natch|!~natch@178.73.216.50] has joined #ruby
<deryl> welcome
codefriar [codefriar!~codefriar@ip-200.it.rdu.bandwidth.com] has joined #ruby
<gener1c> if im scraping a page
<gener1c> and its messages are injected using js
<gener1c> is there a way to get the js array that stores them using nokogiri?
havenn [havenn!~skipper@pool-71-189-127-198.lsanca.fios.verizon.net] has joined #ruby
<gener1c> doc.css('script').each {|script| script.content}
<samuelkadolph> Nokogiri is an XML parser, not a javascript parser.
<samuelkadolph> You can definitely get the text of a script tag
<gener1c> yeah i know
<gener1c> so how do i get the data
<gener1c> is there a way with mech?
<samuelkadolph> .text? Like any other text in an element
<gener1c> yeah
<gener1c> but i cant find anywhere in the script where it gets the data in the array
<gener1c> i think its ajax
<samuelkadolph> Then it's not a ruby question
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
<gener1c> what . sure it is
<samuelkadolph> Use firefox or webkit dev console to set breakpoints and monitor network activity
<gener1c> humz
igel [igel!~igel@77-56-69-135.dclient.hispeed.ch] has joined #ruby
mocker [mocker!~mocker@72.165.148.230] has joined #ruby
<igel> I want to use TextMate as an irb frontend. I want to use irb without ever having to look at it. How do I go about that?
<samuelkadolph> igel: That doesn't make much sense. How would textmate replace your terminal?
<samuelkadolph> It's a text editor and doesn't behave in the same way
workmad3 [workmad3!~workmad3@84.45.226.85] has joined #ruby
g0bl1n [g0bl1n!~prokter@a213-22-27-14.cpe.netcabo.pt] has joined #ruby
<igel> samuelkadolph: well, when I type something in irb, irb spits a line back out, right? I can show that line in textmate.
<igel> Then I press apple-z, and it goes away again.
<samuelkadolph> It prints the result from calling inspect on the line it evaluated
<samuelkadolph> You can do that with p obj or puts obj.inspect
bbttxu_ [bbttxu_!~adam@pool-71-96-208-205.dfw.dsl-w.verizon.net] has joined #ruby
<igel> Right … so I'd have to make my own irb-server-ish thing.
<samuelkadolph> Oh I think I get what you mean.
adeponte [adeponte!~adeponte@67.110.253.162.ptr.us.xo.net] has joined #ruby
<samuelkadolph> You'll want to write a bundle command that evals your current line and replaces it with the result of calling ruby
<igel> samuelkadolph: That is built into TextMate. But it doesn't remember variables from the last execution.
<igel> I want to store stuff between executions :)
<samuelkadolph> Ah
stkowski [stkowski!~stkowski@ns25.8x8.com] has joined #ruby
<igel> samuelkadolph: So, I probably want some process running in the background. Then, when I type stuff in textmate, that will run some script in a new interpreter each time. Those new interpreters have to connect to the same server, hand it over the input, and come back with the output.
otters [otters!~incluye@LO1-ESR-74-215-187-208.fuse.net] has joined #ruby
<igel> I could try out these named pipes for once :)
<samuelkadolph> ruby -rsocket -e 'TCPServer.new(5555).tap { |s| loop { c = s.accept; begin; c.puts(eval(c.gets).inspect); c.close; rescue; end } }'
<samuelkadolph> And echo "$TM_SELECTED_TEXT" | nc localhost 5555 in a TextMate command
<igel> samuelkadolph: You are awesome :)
<igel> But that isn't really safe. Now anybody in my WLAN can run stuff on my machine.
<samuelkadolph> It doesn't work for something like just "abc" but 'puts "Hi"' returns nil
<samuelkadolph> igel: It's a proof of concept :P
<igel> samuelkadolph: I said it, and I'll repeat it, you're awesome :)
<samuelkadolph> Show as tooltip is pretty cool
<igel> samuelkadolph: Well, I'm a smalltalker deep inside, so what I'd like is insert as text, and immmediately select that text.
<igel> Then, you just press DEL to get rid of it agian.
<igel> *again.
<igel> But yea, tooltip comes close :)
<samuelkadolph> Show as HTML would work for bigger stuff
<igel> Yup :)
<samuelkadolph> I'm kinda confused over why echo "a" | nc localhost 5555 doesn't work
<srid> would anyone recommend a ruby project that I can use to understand what good ruby code looks like? not a single ruby script, but an entire modular project
dasfugufish [dasfugufish!~Adium@174-27-233-214.slkc.qwest.net] has joined #ruby
<samuelkadolph> Oh duh
<envygeeks> is there a way to mixin after the instance is created or must it be declared before the instance is even created?
otters [otters!~incluye@LO1-ESR-74-215-187-208.fuse.net] has joined #ruby
freenodiz [freenodiz!~IceChat77@unaffiliated/freenodiz] has joined #ruby
jergason [jergason!~jergason@208.97.56.66] has joined #ruby
apok_ [apok_!~apok@c-107-3-149-167.hsd1.ca.comcast.net] has joined #ruby
jensn [jensn!~Jens@c-83-233-145-148.cust.bredband2.com] has joined #ruby
colint [colint!~ColinT@69.80.96.36] has joined #ruby
otters [otters!~incluye@LO1-ESR-74-215-187-208.fuse.net] has joined #ruby
skrewler [skrewler!~skrewler@209.213.206.58] has joined #ruby
looopy [looopy!~looopy@static-71-166-231-15.washdc.east.verizon.net] has joined #ruby
mocker [mocker!~mocker@72.165.148.230] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
adeponte [adeponte!~adeponte@67.110.253.162.ptr.us.xo.net] has joined #ruby
looopy [looopy!~looopy@static-71-166-231-15.washdc.east.verizon.net] has joined #ruby
freenodiz [freenodiz!~IceChat77@81-178-201-205.dsl.pipex.com] has joined #ruby
freenodiz [freenodiz!~IceChat77@unaffiliated/freenodiz] has joined #ruby
<catphish> wow therubygame.com is way more popular than i imagined
<banister`garden> catphish: your site?
headius [headius!~headius@71-210-151-185.mpls.qwest.net] has joined #ruby
<gener1c> is there a way to scan for only unicode characters?
<gener1c> (ones that arnt in ascii
havenn [havenn!~skipper@pool-71-189-127-198.lsanca.fios.verizon.net] has joined #ruby
<catphish> yeah, a quick one-day project, hoping we can use it to generate interest in ruby
<gener1c> huh?
<catphish> gener1c: you could convert each char to its integer code
<banister`garden> catphish: it's pretty nice work
<catphish> and test its > 255
<catphish> thanks banister`garden
<gener1c> i am talking about hebrew characters
<gener1c> i want to catch all the hebrew characters in a string using regex
<gener1c> but i cant find something like
<gener1c> \w+
<gener1c> just for unicode chars
<catphish> hmm, not sure it'll be that easy
<catphish> you may need to loop though each char and examine it
<catphish> ie string.each_char do |c|
<gener1c> omg
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
<catphish> your god?
<gener1c> lol
zomgbie [zomgbie!~jesus@85-127-169-153.dynamic.xdsl-line.inode.at] has joined #ruby
<gener1c> is there a way to match negativly?
<gener1c> like grep -v
JStoker [JStoker!jstoker@unaffiliated/jstoker] has joined #ruby
<catphish> you can match characters negatively
<catphish> ie /[^a-z]/
jbpros [jbpros!~jbpros@185.55-66-87.adsl-dyn.isp.belgacom.be] has joined #ruby
Brozilla [Brozilla!~Brozilla@ip11-49-212-87.adsl2.static.versatel.nl] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
iamjarvo [iamjarvo!~Adium@c-71-230-13-201.hsd1.nj.comcast.net] has joined #ruby
<envygeeks> my favorite regex
<envygeeks> strip it all!
<iamjarvo> any good libraries to read pdfs? trying to extract data from a bunch of pdfs and makea csv
<envygeeks> iamjarvo: If I remember right there are bindings for libpoppler for ruby, I know debian has a package for it http://packages.debian.org/squeeze/libpoppler-glib-ruby
savage- [savage-!~savage-@209.118.197.220] has joined #ruby
codefriar [codefriar!~codefriar@cpe-098-026-012-134.nc.res.rr.com] has joined #ruby
<iamjarvo> envygeeks: thanks. right now im using pdftohtml but it doesnt give the nodes useful names
hadees [hadees!~hadees@rrcs-71-41-203-94.sw.biz.rr.com] has joined #ruby
colint [colint!~ColinT@69-11-97-130.regn.static.sasknet.sk.ca] has joined #ruby
<srid> i just realized that foo.rb need not be wrapped in a "module" block
<srid> when not wrapped, `require foo` act's like C's "include" statement
<srid> which is probably how I should write utils.rb in ruby?
<Creeture> Any idea what Syslog.mask of 511 corresponds to?
skrewler [skrewler!~skrewler@209.213.206.58] has joined #ruby
manizzle [manizzle!~manizzle@adsl-99-97-69-129.dsl.pltn13.sbcglobal.net] has joined #ruby
TheTFEF [TheTFEF!JS@cpe-173-88-110-115.columbus.res.rr.com] has joined #ruby
Cervajz [Cervajz!~Cervajz@opensuse/member/Cervajz] has joined #ruby
n8ji [n8ji!~n8ji@c-24-20-239-11.hsd1.or.comcast.net] has joined #ruby
Brozilla [Brozilla!~Brozilla@ip11-49-212-87.adsl2.static.versatel.nl] has joined #ruby
cousine [cousine!~cousine@196.221.61.89] has joined #ruby
stephenjudkins [stephenjudkins!~stephen@67.139.75.158] has joined #ruby
<aces1up> if i have an array of objects, with the objects being different, maybe of up to 3 different classes, how could i do a find_all on that array to perform a different find depending on the class? or is this even a good idea?
pantsman [pantsman!~pantsman@pdpc/supporter/active/pantsman] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
seivan [seivan!~seivan@cm242.eta204.maxonline.com.sg] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
burgestrand [burgestrand!~burgestra@h-163-174.a155.priv.bahnhof.se] has joined #ruby
ikaros [ikaros!~ikaros@dslb-084-059-073-057.pools.arcor-ip.net] has joined #ruby
blueadept [blueadept!~blueadept@adsl-065-082-224-002.sip.msy.bellsouth.net] has joined #ruby
blueadept [blueadept!~blueadept@unaffiliated/blueadept] has joined #ruby
mxweas_ [mxweas_!~max@c-71-226-112-145.hsd1.az.comcast.net] has joined #ruby
jbhewitt [jbhewitt!~jbhewitt@c122-108-214-224.rochd4.qld.optusnet.com.au] has joined #ruby
hadees [hadees!~hadees@72-48-91-73.dyn.grandenetworks.net] has joined #ruby
wyhaines [wyhaines!~wyhaines@242.sub-97-163-81.myvzw.com] has joined #ruby
Aristata [Aristata!~Adium@c-67-167-205-42.hsd1.il.comcast.net] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby
mc_mac [mc_mac!~chatzilla@98.156.61.61] has joined #ruby
dbgster [dbgster!~dbgster@CPE0013f7b7170c-CM0013f7b71708.cpe.net.cable.rogers.com] has joined #ruby
<mc_mac> any body have a solution... When I tail the output of a file it shows nothing until my loop dies. I want to see output in a file everytime file.puts "something" is called...
mmokrysz [mmokrysz!~mmokrysz@pdpc/supporter/student/mmokrysz] has joined #ruby
<burgestrand> mc_mac: file.flush
<burgestrand> Do it after your puts
<mxweas_> What's the best way to get a DateTime object into a mysql datetime field?
<burgestrand> mc_mac: file.sync = true should make it auto-flush if I remember the documentation right but I’ve had mixed results
cjs226 [cjs226!~cjs226@99-61-65-242.lightspeed.austtx.sbcglobal.net] has joined #ruby
<mc_mac> You guys are awesomeful again.
Aristata [Aristata!~Adium@c-67-167-205-42.hsd1.il.comcast.net] has joined #ruby
dyer [dyer!~dyer@unaffiliated/dyer] has joined #ruby
statbot2 [statbot2!~nodebot@68-190-59-142.dhcp.mtgm.al.charter.com] has joined #ruby