apeiros changed the topic of #ruby to: Ruby 2.0.0-p247: http://ruby-lang.org (Ruby 1.9.3-p448) || Paste >3 lines of text on http://gist.github.com || this channel is logged at http://irclog.whitequark.org, other public logging is prohibited
<pontiki> I'd say OptionParse is the big one
<bnagy> trollop is nice
<bnagy> the stdlib one sux
<pontiki> many other packages use it: thor, rake, methodone, etc
Andrevan has joined #ruby
Andrevan has joined #ruby
Andrevan has quit [Changing host]
LaPetiteFromage has quit [Quit: LaPetiteFromage]
pwh has quit [Quit: pwh]
Lewix has joined #ruby
<existensil> I like OptionParse
duggiefresh has quit [Remote host closed the connection]
glen1 has joined #ruby
beilabs has quit [Ping timeout: 264 seconds]
<ccolorado> Thanks, ill take a look.
dtcrshr has quit [Quit: poff]
glen1 has left #ruby ["Leaving"]
<existensil> trollop looks awesome too... just never did enough parsing to feel I needed to look beyond stdlib
jamesaanderson has joined #ruby
<pontiki> i can't wait until we're like CPAN, with 100 different command line option parsers
mgorbach has quit [Ping timeout: 268 seconds]
duggiefresh has joined #ruby
dayepa has quit [Quit: dayepa]
dayepa has joined #ruby
digitalcake has joined #ruby
bradhe has joined #ruby
BrianJ has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
<digitalcake> is there a way to have rvm set the system's ruby verison? #!/usr/bin/ruby is pointing to 1.8 in osx even though rvm is set up correctly and has a different default.
peregrine81 has joined #ruby
jmc-be has joined #ruby
peregrine81 has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
mercwithamouth has quit [Ping timeout: 264 seconds]
jmc-be has quit [Client Quit]
beilabs_ has joined #ruby
<digitalcake> nm
<bnagy> if you're about to do a 'system' rvm install you really want to reconsider imho
<bnagy> but using env instead of hardcoded ruby bin path will work with a normal rvm install
<bnagy> #!/usr/bin/env ruby
cam`_ has joined #ruby
dnyy has joined #ruby
razi has joined #ruby
vlad_starkov has joined #ruby
ccolorado has quit [Ping timeout: 245 seconds]
DanKnox is now known as DanKnox_away
mercwithamouth has joined #ruby
nari has quit [Ping timeout: 264 seconds]
iliketur_ has quit [Quit: zzzzz…..]
jtgiri_ has joined #ruby
vlad_starkov has quit [Ping timeout: 245 seconds]
razi has quit [Ping timeout: 264 seconds]
alekst has joined #ruby
postmodern has joined #ruby
Emmanuel_Chanel has quit [Quit: Leaving]
snovak has joined #ruby
quoin has joined #ruby
duggiefresh has quit [Remote host closed the connection]
Emmanuel_Chanel has joined #ruby
snovak has quit [Ping timeout: 264 seconds]
quoin has quit [Ping timeout: 264 seconds]
Ripp__ has quit [Quit: Ripp__]
Ripp__ has joined #ruby
Nisstyre-laptop is now known as nisstyre
bradhe has quit [Remote host closed the connection]
Ripp___ has joined #ruby
Ripp__ has quit [Read error: Connection reset by peer]
staafl has quit [Ping timeout: 240 seconds]
ccolorado has joined #ruby
ccolorado has quit [Client Quit]
Andrevan has quit [Quit: WeeChat 0.4.2-rc1]
bradhe has joined #ruby
andrew has joined #ruby
theows has quit [Ping timeout: 260 seconds]
andrew is now known as Guest44664
endash has quit [Quit: endash]
bradhe has quit [Remote host closed the connection]
Guest44664 has quit [Client Quit]
azcodex has quit [Remote host closed the connection]
sambao21 has joined #ruby
mercwithamouth has quit [Ping timeout: 264 seconds]
Andrevan has joined #ruby
machuga|away is now known as machuga
theows has joined #ruby
dhruvasagar has joined #ruby
sirupsen has joined #ruby
krz has joined #ruby
krz has joined #ruby
krz has quit [Changing host]
mike4_ has joined #ruby
<mike4_> how can i spoof my ip inside ruby?
pwh has joined #ruby
Quashie has quit [Ping timeout: 264 seconds]
xpirator has joined #ruby
<bnagy> build the packet, drop it onto the wire at layer 2
<bnagy> you can get to a raw socket via Socket
postmodern has quit [Quit: Leaving]
Ox6abe has quit [Remote host closed the connection]
bradhe has joined #ruby
Ox6abe has joined #ruby
hackerpreneur has quit [Quit: Need instant coding help? --> www.airpair.com]
bradhe has quit [Remote host closed the connection]
mercwithamouth has joined #ruby
sevenseacat has joined #ruby
Ox6abe has quit [Ping timeout: 261 seconds]
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
osvico has joined #ruby
tkuchiki has joined #ruby
duggiefresh has joined #ruby
krz has quit [Quit: krz]
krz has joined #ruby
krz has joined #ruby
randomdrake has joined #ruby
<sam113101> guys, sinatra vs padrino?
iamjarvo has joined #ruby
jamesaanderson has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
bradhe has joined #ruby
<Andrevan> sinatra
theows has quit [Ping timeout: 264 seconds]
<shevy> I have never heard of padrino
<sam113101> amazing, you've just discovered a new web framework
<sam113101> because of me ;p
<shevy> existensil what do you like about OptionParse?
nari has joined #ruby
<zets> isn't padrino just built on top of sinatra core
<shevy> sam113101 yeah but there could be 100000 more, the thing is to find *good* ones
<Andrevan> padrino has serializers in it right
krz has quit [Client Quit]
<Andrevan> it's like sinatra for making a web service API
<Andrevan> what are you doing?
krz has joined #ruby
krz has joined #ruby
krz has quit [Changing host]
krz has quit [Client Quit]
cooldman224 has joined #ruby
<Andrevan> anyway, start with sinatra and you can add the padrino modules one by one if you need them
<sam113101> really?
krz has joined #ruby
krz has joined #ruby
krz has quit [Changing host]
youcallme has joined #ruby
cody-- has quit [Quit: Computer has gone to sleep.]
mercwithamouth has quit [Ping timeout: 260 seconds]
<sam113101> sounds like a good plan
yacks has quit [Ping timeout: 260 seconds]
ixti has quit [Ping timeout: 245 seconds]
gtrak has left #ruby ["http://quassel-irc.org - Chat comfortably. Anywhere."]
duracrisis has joined #ruby
duracrisis has joined #ruby
krz has quit [Quit: krz]
krz has joined #ruby
krz has joined #ruby
krz has quit [Changing host]
krz has quit [Client Quit]
hamakn has quit [Remote host closed the connection]
greenride has left #ruby [#ruby]
hamakn has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
theows has joined #ruby
iamjarvo has quit [Remote host closed the connection]
iamjarvo has joined #ruby
alpaca_taichou has joined #ruby
hamakn has quit [Ping timeout: 245 seconds]
iliketur_ has joined #ruby
Davey has quit [Quit: Computer has gone to sleep.]
alpaca_taichou has quit [Remote host closed the connection]
alpaca_taichou has joined #ruby
krz has joined #ruby
krz has quit [Client Quit]
locriani has joined #ruby
krz has joined #ruby
snovak has joined #ruby
alekst has quit [Quit: Leaving...]
quoin has joined #ruby
Davey has joined #ruby
snovak has quit [Ping timeout: 264 seconds]
krz has quit [Quit: krz]
quoin has quit [Ping timeout: 276 seconds]
hamakn has joined #ruby
dkamioka has joined #ruby
jtgiri_ has quit [Quit: jtgiri_]
maletor has joined #ruby
dkamioka has quit [Ping timeout: 248 seconds]
krz has joined #ruby
iliketur_ has quit [Quit: zzzzz…..]
rickmasta has quit [Quit: Leaving...]
Gue______ has joined #ruby
rickmasta has joined #ruby
endash has joined #ruby
gr33n7007h has quit [Ping timeout: 260 seconds]
Gue______ has left #ruby [#ruby]
iliketur_ has joined #ruby
nisstyre has quit [Quit: Leaving]
Domon has joined #ruby
dancardamore has joined #ruby
Klotho1 has joined #ruby
yacks has joined #ruby
vlad_starkov has joined #ruby
theows has left #ruby [#ruby]
jtgiri_ has joined #ruby
<pontiki> yeah, padrino includes sinatra
araujo has quit [Read error: Connection reset by peer]
<pontiki> it's basically rails lite
araujo has joined #ruby
krz has quit [Quit: krz]
krz has joined #ruby
Nisstyre-laptop has joined #ruby
cody-- has joined #ruby
krz has quit [Client Quit]
vlad_starkov has quit [Ping timeout: 264 seconds]
krz has joined #ruby
krz has quit [Client Quit]
seyha has joined #ruby
Nisstyre-laptop has quit [Read error: Connection reset by peer]
maletor has quit [Quit: Computer has gone to sleep.]
ttt has joined #ruby
Catie has quit [Read error: Operation timed out]
danman has quit [Quit: danman]
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
yacks has quit [Read error: Operation timed out]
krz has joined #ruby
cyong has joined #ruby
duggiefresh has quit [Remote host closed the connection]
Nisstyre-laptop has joined #ruby
alpaca_taichou has quit [Remote host closed the connection]
Bosox20051 has quit [Remote host closed the connection]
Bosox20051 has joined #ruby
jtgiri_ has quit [Quit: jtgiri_]
nanoxd has quit [Ping timeout: 264 seconds]
iliketur_ has quit [Quit: zzzzz…..]
krz has quit [Quit: krz]
danman has joined #ruby
pen has quit [Remote host closed the connection]
nanoxd has joined #ruby
canthelp has joined #ruby
pwh has quit [Quit: pwh]
iamjarvo has quit [Read error: Connection reset by peer]
iamjarvo has joined #ruby
bricker`LA has joined #ruby
jarin has joined #ruby
dkamioka has joined #ruby
Pandee has quit [Ping timeout: 256 seconds]
tealmage has quit [Remote host closed the connection]
bricker has joined #ruby
hardbit has joined #ruby
canthelp has left #ruby ["Ex-Chat"]
ryandeussing has joined #ruby
duggiefresh has joined #ruby
Ripp___ has quit [Quit: Ripp___]
radic_ has joined #ruby
snovak has joined #ruby
asop has joined #ruby
Nisstyre-laptop has quit [Ping timeout: 276 seconds]
seyha has quit [Ping timeout: 245 seconds]
quoin has joined #ruby
radic__ has quit [Ping timeout: 245 seconds]
snovak has quit [Ping timeout: 240 seconds]
Nisstyre-laptop has joined #ruby
quoin has quit [Ping timeout: 245 seconds]
rcosta has quit [Remote host closed the connection]
okinomo has joined #ruby
germanstudent has quit [Ping timeout: 256 seconds]
butblack has joined #ruby
iamjarvo has quit [Remote host closed the connection]
iamjarvo has joined #ruby
IceDragon has quit [Quit: Space~~~]
yacks has joined #ruby
seyha has joined #ruby
Stygia has quit [Remote host closed the connection]
dkamioka has quit [Remote host closed the connection]
DanKnox_away is now known as DanKnox
michalkozminski has quit [Ping timeout: 245 seconds]
michalkozminski has joined #ruby
postmodern has joined #ruby
pr0ggie has joined #ruby
iamjarvo has quit [Ping timeout: 240 seconds]
krz has joined #ruby
krz has joined #ruby
krz has quit [Changing host]
butblack has left #ruby [#ruby]
kung has quit [Quit: Bye!]
yfeldblum has quit [Ping timeout: 256 seconds]
vlad_starkov has joined #ruby
Rym has joined #ruby
seyha has quit [Quit: Lost terminal]
krz has quit [Quit: krz]
sirupsen has quit [Quit: sirupsen]
Fezzler has joined #ruby
krz has joined #ruby
krz has joined #ruby
krz has quit [Changing host]
Rym_ has quit [Ping timeout: 260 seconds]
Sphen has joined #ruby
Nisstyre-laptop has quit [Read error: Operation timed out]
tealmage has joined #ruby
Sphen has left #ruby ["WeeChat 0.3.7"]
vlad_starkov has quit [Ping timeout: 276 seconds]
sailias has quit [Ping timeout: 240 seconds]
germanstudent has joined #ruby
asop has quit [Quit: Leaving]
jamesaanderson has joined #ruby
pwh has joined #ruby
devoldmx has joined #ruby
tealmage has quit [Ping timeout: 264 seconds]
macmartine has joined #ruby
ehaliewicz has joined #ruby
devoldmx3 has quit [Ping timeout: 264 seconds]
DanKnox is now known as DanKnox_away
dodosan has quit [Remote host closed the connection]
bradhe has quit [Read error: Connection reset by peer]
dodosan has joined #ruby
hakunin has joined #ruby
devoldmx3 has joined #ruby
jp- has quit [Quit: OK, I believe you… but my tommy gun don't]
peregrine81 has quit []
devoldmx has quit [Ping timeout: 240 seconds]
Tectonic has joined #ruby
dorei has quit []
thesheff17 has quit [Remote host closed the connection]
browndawg has joined #ruby
thesheff17 has joined #ruby
devoldmx3 has quit [Read error: Connection reset by peer]
devoldmx has joined #ruby
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
kung has joined #ruby
r0bglees0n has quit [Ping timeout: 256 seconds]
shadoi has quit [Quit: Leaving.]
macmartine has quit [Quit: Computer has gone to sleep.]
cooldman224 has quit [Remote host closed the connection]
yfeldblum has joined #ruby
snovak has joined #ruby
kizzx2 has joined #ruby
kizzx2 has quit [Max SendQ exceeded]
quoin has joined #ruby
kizzx2 has joined #ruby
snovak has quit [Ping timeout: 245 seconds]
quoin has quit [Ping timeout: 240 seconds]
maroloccio has quit [Quit: WeeChat 0.4.0]
Fezzler has quit [Quit: Leaving]
digitalcake has quit [Quit: Leaving.]
gr33n7007h has joined #ruby
bluOxigen has joined #ruby
macmartine has joined #ruby
MiguelGD has quit [Ping timeout: 245 seconds]
jtgiri_ has joined #ruby
macmartine has quit [Client Quit]
sayan has joined #ruby
iliketur_ has joined #ruby
vlad_starkov has joined #ruby
endash has quit [Quit: endash]
rodacato has quit [Remote host closed the connection]
eka has quit [Quit: Computer has gone to sleep.]
brianpWins has joined #ruby
randomautomator has quit [Ping timeout: 260 seconds]
gstamp has joined #ruby
jamesaanderson has joined #ruby
danman has quit [Quit: danman]
tealmage has joined #ruby
duracrisis has quit [Ping timeout: 260 seconds]
ccbn has quit [Quit: Page closed]
Klotho1 has quit [Ping timeout: 260 seconds]
tealmage has quit [Ping timeout: 245 seconds]
vlad_starkov has quit [Remote host closed the connection]
parzo has joined #ruby
Lewix has quit [Changing host]
Lewix has joined #ruby
mrsolo has joined #ruby
Guest4936 has joined #ruby
<Guest4936> hy
duggiefresh has quit [Remote host closed the connection]
Bry8Star{T2 has quit [Ping timeout: 240 seconds]
Guest4936 has left #ruby [#ruby]
RichardBaker has joined #ruby
gr33n7007h has quit [Ping timeout: 256 seconds]
randomautomator has joined #ruby
Domon has quit [Remote host closed the connection]
waj has joined #ruby
Domon has joined #ruby
waj has left #ruby [#ruby]
duracrisis has joined #ruby
Bry8Star{T2 has joined #ruby
Rym has quit [Ping timeout: 245 seconds]
stevechiagozie has quit [Quit: Computer has gone to sleep.]
Catie has joined #ruby
okinomo has quit [Quit: Lost terminal]
Domon has quit [Ping timeout: 256 seconds]
snovak has joined #ruby
quoin has joined #ruby
iliketur_ has quit [Quit: zzzzz…..]
jtgiri_ has quit [Quit: jtgiri_]
duracrisis has quit [Ping timeout: 256 seconds]
snovak has quit [Ping timeout: 240 seconds]
quoin has quit [Ping timeout: 248 seconds]
lukec has quit [Quit: lukec]
okinomo has joined #ruby
cyong has quit [Quit: Leaving.]
pwh has quit [Quit: pwh]
cyong has joined #ruby
Targen has joined #ruby
randym_ has quit [Quit: Connection closed for inactivity]
cads has quit [Ping timeout: 264 seconds]
vxxr9 has quit [Quit: leaving]
fridim_ has quit [Ping timeout: 260 seconds]
manmandar has joined #ruby
kobain has quit [Remote host closed the connection]
kobain has joined #ruby
manmandar has left #ruby [#ruby]
jrhorn424 has joined #ruby
bigmac_ has joined #ruby
bigmac_ has quit [Client Quit]
ryandeussing has quit [Remote host closed the connection]
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
randomau_ has joined #ruby
cads has joined #ruby
i8igmac has quit [Ping timeout: 260 seconds]
DanKnox_away is now known as DanKnox
kilophoton has quit [Ping timeout: 260 seconds]
randomautomator has quit [Ping timeout: 256 seconds]
mary5030 has quit [Remote host closed the connection]
browndawg has quit [Read error: Operation timed out]
Tectonic has quit []
intuxicated has joined #ruby
codecop has joined #ruby
browndawg has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
gr33n7007h has joined #ruby
blueOxigen has joined #ruby
jonahR has quit [Quit: jonahR]
cads has quit [Ping timeout: 264 seconds]
bluOxigen has quit [Ping timeout: 276 seconds]
randomau_ has quit [Read error: Connection reset by peer]
randomautomator has joined #ruby
DonRichie has joined #ruby
kizzx2 has quit [Quit: Leaving.]
vlad_starkov has joined #ruby
noop has joined #ruby
mrsolo has joined #ruby
zendeavr is now known as zendeavor
vlad_starkov has quit [Remote host closed the connection]
postmodern has quit [Quit: Leaving]
postmodern has joined #ruby
tomzx_mac has quit [Ping timeout: 268 seconds]
sayan has quit [Quit: Leaving]
sayan has joined #ruby
freerobby has quit [Quit: Leaving.]
haxrbyte has joined #ruby
randomautomator has quit [Remote host closed the connection]
mayday_jay has joined #ruby
Domon has joined #ruby
browndawg has quit [Ping timeout: 245 seconds]
apeiros has joined #ruby
maroloccio has joined #ruby
mayday_jay has quit [Quit: c ya!]
mayday_jay has joined #ruby
nanoxd has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
cody-- has quit [Quit: Computer has gone to sleep.]
Bry8Star{T2_ has joined #ruby
Bry8Star{T2 has quit [Ping timeout: 240 seconds]
kobain has quit []
lfox has quit [Quit: ZZZzzz…]
DonRichie has quit [Quit: Verlassend]
okinomo has quit [Ping timeout: 256 seconds]
jtgiri_ has joined #ruby
snovak has joined #ruby
kizzx2 has joined #ruby
kizzx2 has quit [Max SendQ exceeded]
kizzx2 has joined #ruby
quoin has joined #ruby
kizzx2 has quit [Max SendQ exceeded]
kizzx2 has joined #ruby
heath has joined #ruby
lusory has quit [Ping timeout: 264 seconds]
snovak has quit [Ping timeout: 248 seconds]
nanoxd has joined #ruby
quoin has quit [Ping timeout: 245 seconds]
<heath> shouldn't that fill the hash with 6 empty hashes?
<sevenseacat> no - you're reassigning a blank hash to node on each iteration of the loop
browndawg has joined #ruby
<heath> yep
<heath> ty
kizzx2 has quit [Ping timeout: 256 seconds]
tobago has joined #ruby
<heath> take away line 5 and my reasoning was sound :P
<Lewix> heath: ya but it doesnt persist
mrsolo has quit [Quit: This computer has gone to sleep]
<heath> eh?
<heath> i think the only flay in the logic outside of overlooking line 5 is that it will only create 5 k,v pairs
<heath> s/flay/flaw
hackerpreneur has joined #ruby
tagrudev has joined #ruby
mmozuras has joined #ruby
lusory has joined #ruby
<apeiros> heath: I think your issue is not line 5. Your issue is that you use the same variable for storing the toplevel hash and iteration
relix has joined #ruby
ewnd9 has joined #ruby
<apeiros> do something like: `root = node = {}` in line 1 and replace line 8 with `root`
<Lewix> apeiros: 22:39 heath: shouldn't that fill the hash with 6 empty hashes?
ferdev has joined #ruby
ferdev has quit [Client Quit]
<Lewix> his issue might be both
<Lewix> her*
noop has quit [Ping timeout: 245 seconds]
digitalcake has joined #ruby
jhn has joined #ruby
<apeiros> Lewix: oh, yes, if he/she wants it in the toplevel and not nested
cyong has quit [Quit: Leaving.]
kizzx2 has joined #ruby
digitalcake has quit [Ping timeout: 245 seconds]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
randomdrake has quit [Quit: randomdrake]
Monie has joined #ruby
intuxicated has quit [Ping timeout: 240 seconds]
binw has quit [Read error: Connection reset by peer]
jijijij has joined #ruby
jijijij is now known as anderson
kilophoton has joined #ruby
zoee has joined #ruby
binw has joined #ruby
kilophoton has quit [Ping timeout: 245 seconds]
hackerpreneur has quit [Ping timeout: 245 seconds]
Lewix has quit [Remote host closed the connection]
mike4_ has quit [Remote host closed the connection]
Domon has quit [Remote host closed the connection]
Domon has joined #ruby
Domon has quit [Read error: Connection reset by peer]
Domon has joined #ruby
ayaz has joined #ruby
andikr has joined #ruby
heath was kicked from #ruby by apeiros [if you cross-post, you're required to tell so in all involved channels, thank you.]
intuxicated has joined #ruby
Macaveli has joined #ruby
freerobby has joined #ruby
s0ny123 has joined #ruby
wallerdev has quit [Quit: wallerdev]
browndawg has quit [Read error: Connection timed out]
browndawg has joined #ruby
pyrac has joined #ruby
vlad_starkov has joined #ruby
dodosan has quit [Remote host closed the connection]
mayday_jay has quit [Quit: c ya!]
freerobby has quit [Ping timeout: 276 seconds]
vlad_starkov has quit [Ping timeout: 256 seconds]
AndChat| has quit [Ping timeout: 260 seconds]
Banistergalaxy has joined #ruby
randomautomator has joined #ruby
fgo has joined #ruby
xcfox has joined #ruby
jtgiri_ has quit [Quit: jtgiri_]
browndawg has quit [Quit: Leaving.]
apeiros has joined #ruby
randomautomator has quit [Ping timeout: 245 seconds]
guns has joined #ruby
snovak has joined #ruby
parzo has quit [Ping timeout: 240 seconds]
apeiros has quit [Ping timeout: 264 seconds]
quoin has joined #ruby
Ripp__ has joined #ruby
snovak has quit [Ping timeout: 245 seconds]
quoin has quit [Ping timeout: 248 seconds]
ryandeussing has joined #ruby
dagobah has joined #ruby
iliketur_ has joined #ruby
Macaveli has quit [Quit: Computer has gone to sleep.]
sayan has quit [Ping timeout: 256 seconds]
Macaveli has joined #ruby
Macaveli has quit [Client Quit]
DrCode has quit [Remote host closed the connection]
Macaveli has joined #ruby
dEPz has joined #ruby
ryandeussing has quit [Ping timeout: 248 seconds]
bigkevmcd has quit [Quit: Ex-Chat]
aganov has joined #ruby
bigkevmcd has joined #ruby
guns has quit [Quit: guns]
ehaliewicz has quit [Ping timeout: 256 seconds]
hardbit has quit [Ping timeout: 245 seconds]
mmm has quit [Read error: Connection reset by peer]
DrCode has joined #ruby
V8Energy has quit [Ping timeout: 264 seconds]
digitalcake has joined #ruby
zorg24 has joined #ruby
mmm has joined #ruby
blaxter_ has joined #ruby
filipe has joined #ruby
youcallme has quit [Remote host closed the connection]
jeremyb_ has quit [Changing host]
jeremyb_ has joined #ruby
jprovazn has joined #ruby
jeremyb_ is now known as jeremyb
mayday_jay has joined #ruby
digitalcake has quit [Ping timeout: 245 seconds]
Domon has quit [Remote host closed the connection]
Domon has joined #ruby
graydot has joined #ruby
persand has joined #ruby
timonv has joined #ruby
Domon has quit [Ping timeout: 240 seconds]
obs has joined #ruby
RichardBaker has quit [Quit: RichardBaker]
mmozuras has quit [Quit: leaving]
Domon has joined #ruby
mmozuras has joined #ruby
nhhagen has quit [Ping timeout: 264 seconds]
nhhagen has joined #ruby
dankest has quit [Quit: Peace]
mmozuras has quit [Client Quit]
Domon has quit [Remote host closed the connection]
Domon has joined #ruby
mmozuras has joined #ruby
mmozuras has quit [Client Quit]
mmozuras has joined #ruby
crus` has quit [Ping timeout: 264 seconds]
crus has joined #ruby
Xeago has joined #ruby
sayan has joined #ruby
alup has joined #ruby
Domon has quit [Ping timeout: 264 seconds]
kaldrenon has joined #ruby
mklappstuhl has joined #ruby
apfelbox has joined #ruby
okinomo has joined #ruby
mrsolo has joined #ruby
mrsolo has quit [Client Quit]
mrsolo has joined #ruby
timonv has quit [Remote host closed the connection]
kaldrenon has quit [Ping timeout: 248 seconds]
timonv has joined #ruby
freerobby has joined #ruby
pootler has quit [Ping timeout: 260 seconds]
dangerousdave has joined #ruby
troessner has joined #ruby
vlad_starkov has joined #ruby
DrCode has quit [Remote host closed the connection]
mmozuras has quit [Quit: leaving]
apfelbox has quit [Read error: Operation timed out]
pootler has joined #ruby
mmozuras has joined #ruby
timonv_ has joined #ruby
apfelbox has joined #ruby
jonkri has joined #ruby
jonkri has joined #ruby
jonkri has quit [Changing host]
DrCode has joined #ruby
mmozuras has quit [Client Quit]
mmozuras has joined #ruby
apfelbox has quit [Remote host closed the connection]
freerobby has quit [Ping timeout: 246 seconds]
timonv has quit [Ping timeout: 276 seconds]
mmozuras has quit [Client Quit]
mmozuras has joined #ruby
kaspergrubbe has joined #ruby
apeiros has joined #ruby
mklappstuhl has quit [Remote host closed the connection]
fgo has quit [Remote host closed the connection]
mmozuras has quit [Client Quit]
kaspergrubbe has quit [Remote host closed the connection]
mmozuras has joined #ruby
kaspergrubbe has joined #ruby
mmozuras has quit [Client Quit]
colonolGron has joined #ruby
mmozuras has joined #ruby
vlad_starkov has quit [Ping timeout: 248 seconds]
lkba has quit [Ping timeout: 256 seconds]
Andrevan has quit [Quit: WeeChat 0.4.2-rc1]
graydog has joined #ruby
Gooder has joined #ruby
tesuji has joined #ruby
Davey has quit [Quit: Computer has gone to sleep.]
graydot has quit [Ping timeout: 256 seconds]
graydog is now known as graydot
cjk101010_ has quit [Quit: ZNC - http://znc.sourceforge.net]
cjk101010 has joined #ruby
emergion has joined #ruby
kaspergrubbe has quit [Remote host closed the connection]
decoponio has joined #ruby
SHyx0rmZ has quit [Quit: ネウロイを負かさなきゃならないね]
Coffers has joined #ruby
snovak has joined #ruby
dodosan has joined #ruby
marius has joined #ruby
dhruvasagar has quit [Read error: Operation timed out]
avril14th has joined #ruby
mmozuras has quit [Quit: leaving]
mmozuras has joined #ruby
quoin has joined #ruby
haxrbyte_ has joined #ruby
mmozuras has quit [Client Quit]
end_guy has quit [Remote host closed the connection]
mmozuras has joined #ruby
mmozuras has quit [Client Quit]
mmozuras has joined #ruby
end_guy has joined #ruby
himsin has joined #ruby
Quashie has joined #ruby
blaxter_ is now known as blaxter
user258467 has joined #ruby
mmozuras has quit [Client Quit]
snovak has quit [Ping timeout: 248 seconds]
mmozuras has joined #ruby
mmozuras has quit [Client Quit]
haxrbyte has quit [Ping timeout: 256 seconds]
jbpros has joined #ruby
quoin has quit [Ping timeout: 245 seconds]
graydot has quit [Read error: Connection reset by peer]
Koa has quit [Ping timeout: 264 seconds]
mmozuras has joined #ruby
iliketur_ has quit [Quit: zzzzz…..]
mmozuras has quit [Client Quit]
mmozuras has joined #ruby
apfelbox has joined #ruby
relix has joined #ruby
Monie_ has joined #ruby
gstamp has quit [Quit: Computer has gone to sleep.]
Monie has quit [Ping timeout: 245 seconds]
timonv_ has quit [Remote host closed the connection]
timonv has joined #ruby
ephemerian has joined #ruby
graydot has joined #ruby
Monie_ has quit [Client Quit]
lemonsparrow is now known as Guest67887
vlad_starkov has joined #ruby
Klotho1 has joined #ruby
jonkri has quit [Read error: Connection reset by peer]
claymore has joined #ruby
timonv has quit [Ping timeout: 256 seconds]
mmozuras has quit [Quit: leaving]
mmozuras has joined #ruby
jhn has quit [Quit: jhn]
jonkri has joined #ruby
digitalcake has joined #ruby
mmozuras has quit [Client Quit]
vlad_starkov has quit [Ping timeout: 256 seconds]
Macaveli has quit [Quit: Computer has gone to sleep.]
mmozuras has joined #ruby
GeissT has joined #ruby
vlad_starkov has joined #ruby
camilasan has joined #ruby
colonolGron has quit [Quit: ciao ciao]
fgo has joined #ruby
Macaveli has joined #ruby
dEPz has quit [Remote host closed the connection]
joonty has joined #ruby
dangerousdave has quit [Quit: Leaving...]
digitalcake has quit [Ping timeout: 256 seconds]
osvico has quit [Ping timeout: 248 seconds]
senayar has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
senayar has quit [Remote host closed the connection]
kaspergrubbe has joined #ruby
senayar has joined #ruby
dash_ has joined #ruby
parzo has joined #ruby
ewnd9 has quit [Ping timeout: 245 seconds]
fgo has quit [Ping timeout: 256 seconds]
mmozuras has quit [Quit: leaving]
gyzmodo has joined #ruby
Quashie has quit [Ping timeout: 240 seconds]
jonkri has quit [Ping timeout: 240 seconds]
vlad_starkov has quit [Read error: Connection reset by peer]
Monie has joined #ruby
Monie has quit [Client Quit]
Guest4936 has joined #ruby
mmozuras has joined #ruby
larissa has quit [Quit: Leaving]
allsystemsarego has joined #ruby
allsystemsarego has joined #ruby
Quashie has joined #ruby
blackmesa has joined #ruby
Spami has quit [Quit: This computer has gone to sleep]
freerobby has joined #ruby
msuszczy has joined #ruby
tonni has quit [Remote host closed the connection]
shaunbaker has joined #ruby
dangerousdave has joined #ruby
shaunbak_ has joined #ruby
dv_ has quit [Ping timeout: 246 seconds]
nhhagen has quit [Read error: Connection reset by peer]
Stygia has joined #ruby
nhhagen has joined #ruby
freerobby has quit [Ping timeout: 264 seconds]
nari has quit [Ping timeout: 245 seconds]
dash_ has quit [Quit: dash_]
altamic has joined #ruby
Iszak has joined #ruby
emergion has quit [Quit: Computer has gone to sleep.]
shaunbaker has quit [Ping timeout: 245 seconds]
jibi has joined #ruby
altamic has left #ruby [#ruby]
Lewix has joined #ruby
Lewix has quit [Changing host]
Lewix has joined #ruby
intuxicated_ has joined #ruby
kaspergr_ has joined #ruby
julweber has joined #ruby
fgo has joined #ruby
Lewix has quit [Remote host closed the connection]
funburn has joined #ruby
Guest4936 has quit [Ping timeout: 248 seconds]
brisbin has quit [Read error: Connection reset by peer]
brisbin has joined #ruby
intuxicated has quit [Ping timeout: 248 seconds]
haxrbyte has joined #ruby
kaspergrubbe has quit [Ping timeout: 248 seconds]
julweber has quit [Read error: Connection reset by peer]
<funburn> I've got a strange problem. I have the following csv parser https://gist.github.com/mtuckerb/b4fe8bf57dc11d63bdcc
blackmesa has quit [Ping timeout: 240 seconds]
dv_ has joined #ruby
julweber has joined #ruby
dhruvasagar has joined #ruby
<funburn> it properly creates a card for each of my 1800+ rows but always leaves "Asset_Title" blank
<funburn> gist updated
<funburn> If I used row_data[0] instead of row_data["Asset_Title"] all is well
haxrbyte_ has quit [Read error: Connection reset by peer]
<funburn> s/used/use/
<sevenseacat> so how have you tried debugging it
jlebrech has joined #ruby
<funburn> well I tried changing the case statement to if statements
intuxicated_ has quit [Ping timeout: 256 seconds]
<funburn> and obviously I tried using the column index (which worked)
Monie has joined #ruby
<sevenseacat> thats not debugging why the code you have causes problems
<funburn> I've done a lot of playing in irb
fgo has quit [Ping timeout: 260 seconds]
<sevenseacat> at which point does the asset title become blank?
<funburn> it seems to me that …
<funburn> oh
Monie has quit [Client Quit]
Domon has joined #ruby
<sevenseacat> are you meant to be saving a field on your Card model called asset title? because you arent
<funburn> nope never mind I thought I might be assigning instead of testing equallity
<funburn> nope the Card model has a module_name field
quoin has joined #ruby
<sevenseacat> right, so back to the original question
<sevenseacat> at what point is it becoming blank
<funburn> I believe it is never read, let me post an example
tonni has joined #ruby
<sevenseacat> you believe, or you can prove?
himsin has quit [Quit: himsin]
tatsuya_o has joined #ruby
marius has quit [Ping timeout: 256 seconds]
<funburn> okay, I updated the gist
<funburn> with a little irb test that i did
jonkri has joined #ruby
<funburn> all rows returned blank
<funburn> so unless I missed something fundamental, I think that proves that the csv isn't parsing that column by name for some reason
jonkri has quit [Max SendQ exceeded]
rdark has joined #ruby
Zai00 has joined #ruby
<sevenseacat> so whats in row_data
<funburn> when I use the index puts row_data[0] instead I get all the data
jonkri has joined #ruby
<funburn> should be the current row right?
wmoxam has quit [Ping timeout: 260 seconds]
tatsuya_o has quit [Remote host closed the connection]
<funburn> as a hash
<sevenseacat> you're the one with the code, you tell me
<funburn> that's what I'm telling you
tatsuya_o has joined #ruby
<funburn> I'm just trying not to be too smart
<sevenseacat> so show me
marius has joined #ruby
Es0teric has quit [Quit: Computer has gone to sleep.]
wmoxam has joined #ruby
<funburn> Land Access Induction,mtuckerb,Tucker,Bradford,Contractors,2013-04-15,Completed
quoin has quit [Ping timeout: 256 seconds]
<sevenseacat> um
<funburn> not what you were asking for?
<sevenseacat> well thats not a hash
<funburn> its class is CSV::Row
timonv has joined #ruby
<sevenseacat> so when i ask you whats in it, can you please tell me?
<funburn> there is more than one correct answer I guess
<funburn> I'm not trying to be dense
<sevenseacat> its a variable. it has a value. what is the value.
dangerousdave has quit [Quit: Leaving...]
<sevenseacat> also, what version of ruby is this
sh00tm3 has joined #ruby
sh00tm3 has left #ruby [#ruby]
<funburn> ruby 1.9.3p194
tchebb has quit [Read error: Operation timed out]
sergicles has joined #ruby
<funburn> it is the block value, not sure exactly what the correct term is
<funburn> line 1 of irb.rb
<sevenseacat> what is so hard about printing out the value and showing it to me
<sevenseacat> seriously
<funburn> I did
<sevenseacat> you showed me a string and then tried to tell me it has a class of CSV::Row
<shevy> I wanna show you my string
<shevy> sexily
intuxicated_ has joined #ruby
<funburn> If I say puts row_data that's what is output, not sure how else to satisfy your request
<funburn> really, I'm looking for help, not trying to be a douche, I just don't understand the question
timonv has quit [Remote host closed the connection]
adambeynon has joined #ruby
tchebb has joined #ruby
apfelbox_ has joined #ruby
<funburn> if I puts row_data.class I get CSV::Row??
<sevenseacat> well your code works here
<shevy> funburn most of the time using "pp" is best, pp your_variable
<sevenseacat> puts row_data['Asset_Title'] # => "Land Access Induction"
<shevy> I usually do: require 'pp'; pp foo; pp foo.class
graydot has quit [Quit: graydot]
[[thufir]] has joined #ruby
Bosox20051 has quit [Ping timeout: 248 seconds]
<funburn> that's interesting, If I do that I get nil
apfelbox has quit [Ping timeout: 246 seconds]
<sevenseacat> are you confusing the output value with the return value?
<shevy> p row_data
<sevenseacat> the return value of the foreach is nil
<funburn> no, I'm seeing eight thousand blank lines
<funburn> with => nil at the end
<funburn> so I guess technically I'm getting "" not nil
digitalcake has joined #ruby
dhruvasagar has quit [Ping timeout: 276 seconds]
wmoxam has quit [Ping timeout: 256 seconds]
dangerousdave has joined #ruby
<funburn> very weird. I tried the inspect method and got the same result as you
<funburn> but the final test still returns an empty string
wmoxam has joined #ruby
Banistergalaxy has quit [Ping timeout: 245 seconds]
himsin has joined #ruby
mikecmpbll has joined #ruby
Banistergalaxy has joined #ruby
zeel has joined #ruby
digitalcake has quit [Ping timeout: 256 seconds]
staafl has joined #ruby
keanehsiao has joined #ruby
theRoUS|sick has joined #ruby
chinkung has joined #ruby
aspiers_ has quit [Ping timeout: 260 seconds]
Lewix has joined #ruby
Lewix has joined #ruby
<funburn> oh I just tried pp, it is, in fact, outputting nil
kung has quit [Ping timeout: 240 seconds]
vikhyat has joined #ruby
kaspergrubbe has joined #ruby
graydot has joined #ruby
kaspergr_ has quit [Ping timeout: 245 seconds]
Lewix has quit [Ping timeout: 264 seconds]
[[thufir]] has quit [Ping timeout: 260 seconds]
aaronmcadam has joined #ruby
<funburn> tried changing the column header to just "Table", no love
jbpros has quit [Quit: jbpros]
dv_ has quit [Ping timeout: 276 seconds]
keanehsiao has quit [Quit: keanehsiao]
<matti> shevy: :)
quoin has joined #ruby
<shevy> matti die in a fire!!!
<shevy> oops sorry
<shevy> wrong idiom
<shevy> matti hi
quoin_ has joined #ruby
<workmad3> shevy: yeah, that's a typo I make all the time
<matti> I loce you too, shevy
<matti> ;)
dv_ has joined #ruby
vlad_starkov has joined #ruby
locriani has quit [Remote host closed the connection]
tobago has quit [Remote host closed the connection]
vikhyat_ has joined #ruby
shredding has joined #ruby
quoin has quit [Ping timeout: 240 seconds]
vikhyat has quit [Read error: Connection reset by peer]
BraddPitt has quit [Quit: Leaving]
freerobby has joined #ruby
jrhorn424 has quit [Quit: Textual IRC Client: www.textualapp.com]
JZTech101 has quit [Read error: Operation timed out]
dmyers_ has joined #ruby
eightbitraptor has joined #ruby
C0C0 has quit [Read error: Operation timed out]
JZTech101 has joined #ruby
dash_ has joined #ruby
C0C0 has joined #ruby
swordsmanz has quit [Read error: Operation timed out]
nanothief has quit [Read error: Connection reset by peer]
chxane has quit [Read error: Operation timed out]
dmyers has quit [Read error: Connection reset by peer]
dmyers_ is now known as dmyers
dEPz has joined #ruby
kpwz_ has quit [Read error: Operation timed out]
nanothief has joined #ruby
kpwz has joined #ruby
chxane has joined #ruby
framling has quit [Read error: Operation timed out]
lorn has quit [Read error: Operation timed out]
jrobeson has quit [Read error: Operation timed out]
swordsmanz has joined #ruby
<dEPz> is there any library/gem similar to CanCan for rails but more general? So I could define that calling some method is only possible if some conditions are met?
io_syl has quit []
jbpros has joined #ruby
intuxicated_ is now known as intuxicated
jrobeson has joined #ruby
freerobby has quit [Ping timeout: 256 seconds]
intuxicated has quit [Changing host]
intuxicated has joined #ruby
framling has joined #ruby
Alina-malina has quit [Read error: Connection reset by peer]
Alina-malina has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
lorn has joined #ruby
kaspergrubbe has quit [Ping timeout: 245 seconds]
sayan has quit [Ping timeout: 245 seconds]
Alina-malina has quit [Excess Flood]
vikhyat_ has quit [Remote host closed the connection]
Alina-malina has joined #ruby
dash_ has quit [Ping timeout: 245 seconds]
jbpros has quit [Quit: jbpros]
shaunbak_ has quit [Remote host closed the connection]
vikhyat has joined #ruby
kaspergrubbe has joined #ruby
<funburn> dEPz, might ask over in #rubyonrails
<dEPz> I want a general gem not necesarily for rails
fgo has joined #ruby
<funburn> I think I would try to write this as a before_filter
<dEPz> I'm sick of writing if something.state = "done" && current_user.role = "somerole" ....
Muz_ is now known as Muz
<dEPz> In general that is. Maybe I should just seperate that piece of code somehow? No sure.
<funburn> sounds like a perfect excuse to write a method to do it for you, or a class
wildroman has joined #ruby
Gooder has quit [Remote host closed the connection]
sayan has joined #ruby
fgo has quit [Ping timeout: 240 seconds]
vikhyat has quit [Remote host closed the connection]
<shevy> problem with the question is
narcan has quit [Quit: -[AppDelegate installMalware]: unrecognized selector sent to instance 0x156109c0]
<shevy> only those who know CanCan can answer it
nhhagen has quit [Ping timeout: 276 seconds]
snovak has joined #ruby
visof has joined #ruby
<shevy> otherwise one could always write a custom method to return logic flow... run_cleanup_tasks if all_conditions_are_met?
dash_ has joined #ruby
Cheos is now known as Clooth
snovak has quit [Ping timeout: 256 seconds]
timonv has joined #ruby
sevenseacat has quit [Quit: Leaving.]
<funburn> sevenseacat: check out the hidden character https://gist.github.com/mtuckerb/b4fe8bf57dc11d63bdcc
<funburn> oh forget it
<funburn> seriously, where did it go
Elhu has joined #ruby
jonkri has quit [Quit: jonkri]
emergion has joined #ruby
<funburn> when I edit the gist I see a tiny bullet looking character inside the " like " *Asset_Title"
pyrac has quit [Quit: pyrac]
JohnBat26 has joined #ruby
nfk has joined #ruby
keanehsiao has joined #ruby
nfk has quit [Changing host]
nfk has joined #ruby
lkba has joined #ruby
ewnd9 has joined #ruby
dash_ has quit [Ping timeout: 246 seconds]
<funburn> sevenseacat: found it!
<funburn> <U+FEFF>
tonni has quit [Remote host closed the connection]
jbpros has joined #ruby
Ninjex has joined #ruby
<Ninjex> Anyone willing to give their thoughts/ideas on a IRC bot I made in Ruby? I'm fairly newish to the programming game
digitalcake has joined #ruby
emergion has quit [Quit: Computer has gone to sleep.]
postmodern has quit [Quit: Leaving]
shaunbaker has joined #ruby
<shevy> paste code on a remote pastie ok
corpuscle has joined #ruby
<Ninjex> It's on github
zorg24 has quit [Ping timeout: 256 seconds]
<Ninjex> Too many files for a pastebin site
<shevy> does it work?
hogeo has joined #ruby
<Ninjex> Yes
<Ninjex> It has areas for an admin/mods/regular users
<Ninjex> Restricts access to commands based on that
soba has joined #ruby
<Ninjex> It uses regex to ban users in case they try something malicious, etc
<shevy> eh
<shevy> and you said you are fairly newish to programming :P
<Ninjex> Well, I started programming about a year and a half ago
digitalcake has quit [Ping timeout: 264 seconds]
<Ninjex> I consider that newish
<shevy> the code is a bit atypical
<shevy> you dont use classes much at all
soba has quit [Client Quit]
<Ninjex> I didn't see much use of classes in my code
<shevy> it's more like a procedural style of coding you use
<Ninjex> Where would they come in handy?
<Ninjex> Right
<shevy> Rbot.new( :host => 'freenode.net' )
<shevy> if you want to make use of it from other projects
<Ninjex> How is that any more efficient?
<Ninjex> Oh okay
<shevy> it is easier to reuse
<shevy> take the: def main(chan, nick, name)
<shevy> this seems to be defined on Object without any namespace
<shevy> so if another method with the same name resides there, you overwrote it
zarul has quit [Ping timeout: 260 seconds]
dodosan has quit [Remote host closed the connection]
<shevy> if 100 different people do the same, this makes using reusable ruby code not easily possible
seyha has joined #ruby
<shevy> most of the time it is best to put it into a namespace, like a module or class
<shevy> module Rbot; def main
Domon has quit [Remote host closed the connection]
<shevy> well
<shevy> in this example it would not work because you use @instance_variables
<Ninjex> Okay, so if I want to publish it for use for more people it's best to do something like classes
Domon has joined #ruby
<shevy> yes
staafl has quit [Ping timeout: 240 seconds]
jbpros has quit [Quit: jbpros]
<Ninjex> That all makes sense
<shevy> are you sure you are new to programming?
<shevy> you already organized your code in ways no newcomer would
<shevy> :P
Domon has quit [Read error: Connection reset by peer]
Domon__ has joined #ruby
<Ninjex> I seem to be getting that a lot lately. I have insomnia and stay up programming, hacking, etc, etc. I learned nearly 10 languages in this year and a half 0.o A lot of people call me a liar but I'm fine with that
dEPz has quit [Remote host closed the connection]
senayar_ has joined #ruby
senayar_ has quit [Read error: Connection reset by peer]
<workmad3> Ninjex: that just depends on what you call 'learned a language' ;)
razi has joined #ruby
<Ninjex> I also get that too workmad3
senayar_ has joined #ruby
<Ninjex> Basically my other code is as good as the ruby code above, I'm a bit more proficient at PHP though
<shevy> Ninjex well ok... thing is, a real newbie would not have any idea how to organize code, and you made a directory called functions/ and organized it inside of it
<workmad3> Ninjex: incidentally... having been learning for 18 months, that means you're no longer a newcomer
<shevy> yeah
chxane has quit [Quit: Leaving]
<shevy> you are a newbie version 1.2 at worst :P
<Ninjex> shevy: I took up learning Haskell and it made me think a lot differently on how I program
<shevy> someone on #gobolinux once told me that haskell may be too difficult for me
<Ninjex> Okay, I didn't say a noob just new(ish)
<shevy> he was right :(
<workmad3> Ninjex: especially if you've been really immersed in it (which it sounds like you are)
<Ninjex> I'll take that though
<Ninjex> Thanks :D
senayar has quit [Ping timeout: 245 seconds]
<Ninjex> Have you guys done any project euler challenges? I pass a lot of time on there
<workmad3> I've done some
<Ninjex> Awesome
<workmad3> I'm not brilliant at them though... I don't have the patience for that sort of maths :)
julweber has quit [Read error: Connection reset by peer]
Klotho1 has quit [Ping timeout: 248 seconds]
julweber has joined #ruby
Macaveli has quit [Ping timeout: 240 seconds]
<Ninjex> Yeah, it does get old after a while, but it still makes you think a lot. I just enjoy a good challenge.
vikhyat has joined #ruby
[[thufir]] has joined #ruby
<Ninjex> I completed one challenge for a site where I had to take a picture, analyse the pixels and reverse patterns with a decoder
sayan has quit [Ping timeout: 240 seconds]
apfelbox_ has quit [Read error: Connection reset by peer]
<Ninjex> That was probably the most interesting challenge so far
apfelbox has joined #ruby
<Ninjex> shevy: thanks for the review - I'll be back later on; getting tired
marcgg_ has joined #ruby
marcgg has quit [Ping timeout: 240 seconds]
Macaveli has joined #ruby
youcallme has joined #ruby
nhhagen has joined #ruby
seyha has quit [Quit: Lost terminal]
Catbuntu has joined #ruby
<Catbuntu> hi
tonni has joined #ruby
okinomo has quit [Quit: Lost terminal]
visof has quit [Ping timeout: 245 seconds]
nari has joined #ruby
seyha has joined #ruby
ryandeussing has joined #ruby
seyha has quit [Client Quit]
seyha has joined #ruby
persand has quit [Quit: persand]
locriani has joined #ruby
asterite has joined #ruby
apod has joined #ruby
okinomo has joined #ruby
asterite has quit [Client Quit]
freerobby has joined #ruby
kizzx2 has quit [Quit: Leaving.]
asterite has joined #ruby
ryandeussing has quit [Ping timeout: 240 seconds]
asterite has quit [Client Quit]
gyzmodo has quit [Ping timeout: 240 seconds]
asterite has joined #ruby
sjltaylor has joined #ruby
shaunbak_ has joined #ruby
freerobby has quit [Ping timeout: 245 seconds]
asterite has quit [Read error: Connection reset by peer]
asterite has joined #ruby
unixninja92 has quit [Ping timeout: 260 seconds]
unixninja92_ has joined #ruby
asterite has quit [Read error: Connection reset by peer]
tvw has joined #ruby
shaunbaker has quit [Ping timeout: 256 seconds]
thillux has joined #ruby
thillux has left #ruby [#ruby]
senayar_ has quit [Remote host closed the connection]
senayar has joined #ruby
wildroman has quit [Remote host closed the connection]
ewnd9 has quit [Remote host closed the connection]
mklappstuhl has joined #ruby
ewnd9 has joined #ruby
r4nd0m1 has joined #ruby
mercwithamouth has joined #ruby
kirun has joined #ruby
visof has joined #ruby
visof has quit [Changing host]
visof has joined #ruby
sjltaylor has quit [Remote host closed the connection]
relix has quit [Quit: Textual IRC Client: www.textualapp.com]
keanehsiao has quit [Quit: keanehsiao]
relix has joined #ruby
camilasan has quit [Ping timeout: 245 seconds]
<shevy> Catbuntu do you use ubuntu or ruby
blackmesa has joined #ruby
snovak has joined #ruby
locriani has quit [Ping timeout: 246 seconds]
anderson has quit [Quit: Leaving]
<Catbuntu> Debian and Perl || Python || Ruby lol
<Catbuntu> I can't choose
Squarepy has joined #ruby
sayan has joined #ruby
allanm has quit [Read error: Connection reset by peer]
theRoUS|sick has quit [Ping timeout: 260 seconds]
kaspergrubbe has quit [Remote host closed the connection]
sjltaylor has joined #ruby
snovak has quit [Ping timeout: 276 seconds]
rickmasta has quit [Quit: Leaving...]
jonkri has joined #ruby
jonkri has quit [Changing host]
jonkri has joined #ruby
mengu has joined #ruby
rdxc has joined #ruby
dachi has joined #ruby
<dachi> hi people. how r u guys?
jibi has quit [Ping timeout: 276 seconds]
browndawg has joined #ruby
nomenkun has joined #ruby
<Catbuntu> hi dachi
fixl has joined #ruby
<Catbuntu> Confused, I don't know whether to use Python or Perl or Ruby lol
wildroman has joined #ruby
aryaching has joined #ruby
digitalcake has joined #ruby
corpuscle has quit [Quit: WeeChat 0.4.1]
Domon__ has quit [Remote host closed the connection]
kaspergrubbe has joined #ruby
<dachi> Hey, use ruby :) look what some guy wrote at so about pythhon, I took a screenshot :)
Domon has joined #ruby
mklappstuhl has quit [Read error: Connection reset by peer]
sjltaylor has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mikecmpbll has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
mklappstuhl has joined #ruby
mikecmpbll has joined #ruby
shredding has quit [Quit: shredding]
digitalcake has quit [Ping timeout: 248 seconds]
jlebrech has quit [Ping timeout: 248 seconds]
jlebrech has joined #ruby
Domon has quit [Ping timeout: 260 seconds]
aryaching_ has joined #ruby
camilasan has joined #ruby
<Catbuntu> lol
<Catbuntu> I don't get it
aryaching has quit [Ping timeout: 264 seconds]
<apeiros> dachi: eh, yeah… that person sounds like a troll, though. and that's why he got 13 downvotes too…
<Catbuntu> what's wrong with Python?
<blackratdog> a python is a dangerous snake, but a ruby is a precious jewel ;-)
seyha has quit [Ping timeout: 256 seconds]
okinomo has quit [Ping timeout: 246 seconds]
aryaching_ has quit [Ping timeout: 246 seconds]
<Catbuntu> Ok let's be honest Python is pointless.
<Catbuntu> "Code is beautiful, easy to read." So is Ruby's, Perl's, C++'s and Java's if you write it well.
jibi has joined #ruby
<Catbuntu> Why the heck are there no access limits on Python? A variable with a leading _ only means "don't touch this" but you can touch it if you're a rebel.
<Catbuntu> lol
<Catbuntu> is there a "private" modifier in Ruby?
<Catbuntu> oh and also Python's package management sucks haha
BizarreCake has joined #ruby
<apeiros> Catbuntu: yes, see Module#private
<apeiros> it's more of an advice, though. easily circumvented
<apeiros> (and IMO that's ok - no need to handhold coders)
<Catbuntu> yeah I know
<Catbuntu> Now Debian is being annoying because GNOME Shell performs ugly with nvidia drivers :(
* Catbuntu is thinking about switching to another distro
<dachi> is debian as a server better than ubuntu 12 ?
<dachi> i've got ubuntu on my server
tealmage has joined #ruby
lupine has quit [Quit: If you see this, my dogfood was poisoned]
azcodex has joined #ruby
<dachi> apeiros hi :) i finally solved my issues that u helped me with, switched and tweaked selenium-webdirver instad of using net-http
<apeiros> ok
lupine has joined #ruby
dodosan has joined #ruby
browndawg has quit [Read error: Connection timed out]
ayaz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dachi has quit [Quit: Page closed]
sevenseacat has joined #ruby
ixti has joined #ruby
kaldrenon has joined #ruby
tealmage_ has joined #ruby
tealmage has quit [Read error: Connection reset by peer]
ixti has quit [Read error: Connection reset by peer]
dodosan has quit [Ping timeout: 276 seconds]
browndawg has joined #ruby
<shevy> Catbuntu use python or ruby, perl 5 is outdated compared to both
emergion has joined #ruby
kaldrenon has quit [Ping timeout: 246 seconds]
<shevy> Catbuntu code can always be difficult to read
<shevy> thing is for the same logic, perl code is by far the least readable among those three
emergion has quit [Max SendQ exceeded]
aspiers has joined #ruby
ixti has joined #ruby
emergion has joined #ruby
ixti has quit [Client Quit]
ixti has joined #ruby
emergion has quit [Client Quit]
sayan has quit [Read error: Connection reset by peer]
freerobby has joined #ruby
shark has left #ruby ["I blame nyu!"]
MiguelGD has joined #ruby
funburn has quit [Quit: funburn]
vineavip has joined #ruby
wudofyr has quit [Remote host closed the connection]
freerobby has quit [Ping timeout: 240 seconds]
nbrock has joined #ruby
nbrock has left #ruby [#ruby]
apod has quit []
wudofyr has joined #ruby
joonty has quit [Quit: WeeChat 0.4.1]
sayan has joined #ruby
<vineavip> Hello Folks! I need your advice with a Sinatra application. I have never approached thing like that and I'd love someone to help me understand how to do It. Specifically, I have a Sinatra App, where at some point external server posts to one of my routes with some data. I would like to process It and push to user who is at a different route, as soon as I get that post req.
Clooth has quit [Quit: Leaving...]
<Catbuntu> I'm about to install elementary OS.
thesheff17 has quit [Ping timeout: 276 seconds]
vlad_starkov has joined #ruby
<Catbuntu> But i'm lazy to set everything up *sigh*
tomzx_mac has joined #ruby
Ripp__ has quit [Quit: Ripp__]
<vineavip> In my scenario user gives input to my server A then I process it and send to the server X. After some time (like two minutes) server X calls server A on a different route with some data. I would like to push info from X server's callback to user.
<shevy> Catbuntu I use ruby to initialize everything I need on a new set up
Alina-malina has quit [Quit: Leaving]
Alina-malina has joined #ruby
pyrac has joined #ruby
<shevy> and currently yaml file for configuration... but need to change that as yaml forces me into UTF
mercwithamouth has quit [Ping timeout: 248 seconds]
graydog has joined #ruby
allanm has joined #ruby
graydot has quit [Ping timeout: 248 seconds]
graydog is now known as graydot
aryaching has joined #ruby
tk has joined #ruby
tk is now known as Guest94825
ixti has quit [Ping timeout: 246 seconds]
senayar_ has joined #ruby
senayar_ has quit [Remote host closed the connection]
senayar has quit [Read error: Connection reset by peer]
senayar has joined #ruby
hogeo has quit [Remote host closed the connection]
graydog has joined #ruby
graydot has quit [Ping timeout: 246 seconds]
graydog is now known as graydot
ayaz has joined #ruby
tobago has joined #ruby
mercwithamouth has joined #ruby
thesheff17 has joined #ruby
<vineavip> Am I on the wrong channel to ask for that kind of advice?
mayday_jay has quit [Remote host closed the connection]
JohnBat26 has quit [Read error: Connection reset by peer]
mklappstuhl has quit [Read error: Connection reset by peer]
mklappstuhl has joined #ruby
r0bglees0n has joined #ruby
<existensil> vineavip: sounds like maybe the post to your app from Server X should be stored somewhere, maybe a session, and be sent to the user on the next request. then the user's browser just needs to maybe do an ajax poll every few seconds while waiting for that data.
<existensil> conceptually much easier than doing actual push to the user. that is possible too, but involves either long polling or web sockets or something probably
shaunbak_ has quit [Remote host closed the connection]
rcosta has joined #ruby
<vineavip> existensil: do you think this is a good idea when there are different kinds of responses with varying time (from 30secs to 5 mins)?
ldnunes has joined #ruby
kenneth has joined #ruby
<existensil> vineavip: i don't know the specifics so don't know how appropriate that is, but its a common approach for sure
tealmage_ has quit [Remote host closed the connection]
<existensil> you could also not bother pushing anything to the user and just wait for them to refresh or load the next page or something. i don't know your app though.
tealmage has joined #ruby
JohnBat26 has joined #ruby
digitalcake has joined #ruby
fastov has joined #ruby
fastov has quit [Remote host closed the connection]
jmaister has joined #ruby
<vineavip> existensil: the app is nothing fancy so this approach should work, but I have another newbie question: I don't think I can store in session data from interaction with server X, not with client A. Is database only option?
dash_ has joined #ruby
persand has joined #ruby
<shevy> vineavip dunno, I am not using sinatra and dont do much web stuff save for .cgi, there is a #sinatra channel though
zarul has joined #ruby
chihhsin has quit [Ping timeout: 240 seconds]
Squarepy has quit [Remote host closed the connection]
chihhsin has joined #ruby
Catbuntu has quit [Quit: elementary]
tealmage has quit [Ping timeout: 248 seconds]
<existensil> vineavip: there are almost limitless ways you can store data. database is a common one, but maybe for the size and frequency of the data you could even get a way with a file, or maybe mongo or redis or some other store.
digitalcake has quit [Ping timeout: 256 seconds]
mengu has quit [Quit: This computer has gone to sleep]
<waxjar_> store it in Pi :D https://github.com/philipl/pifs
ryandeussing has joined #ruby
<avril14th> OK, I know it's cyphered language, but if you can understand, please answer: What is the discovered_api(???,'v3') to load when using google api gem in order to access gmail contacts?
apod has joined #ruby
cody-- has joined #ruby
<shevy> wat
lkba has quit [Ping timeout: 256 seconds]
aryaching has quit [Ping timeout: 256 seconds]
linux_noob_666 has quit [Remote host closed the connection]
<existensil> lol waxjar_
azcodex has quit [Remote host closed the connection]
vikhyat_ has joined #ruby
razi has quit [Ping timeout: 264 seconds]
blackmesa has quit [Quit: WeeChat 0.4.1]
azcodex has joined #ruby
yalue has joined #ruby
jamesaanderson has joined #ruby
vikhyat has quit [Read error: Network is unreachable]
jamesaanderson has quit [Client Quit]
jonathanwallace has joined #ruby
rcosta has quit [Remote host closed the connection]
AndChat| has joined #ruby
tabolario has joined #ruby
jkamenik has joined #ruby
krz has quit [Quit: krz]
shredding has joined #ruby
jkamenik has left #ruby [#ruby]
graydot has quit [Quit: graydot]
jibi has quit [Ping timeout: 245 seconds]
mklappstuhl has quit [Read error: Connection reset by peer]
vikhyat_ has quit [Ping timeout: 256 seconds]
mlpinit has joined #ruby
ixti has joined #ruby
[[thufir]] has quit [Quit: Leaving.]
KobraKao has joined #ruby
crankycoder has joined #ruby
fridim_ has joined #ruby
crankycoder has quit [Client Quit]
persand has quit [Quit: persand]
VTLob has joined #ruby
msuszczy has quit [Quit: leaving]
joonty has joined #ruby
jibi has joined #ruby
dash_ has quit [Quit: dash_]
eka has joined #ruby
rickmasta has joined #ruby
freerobby has joined #ruby
fridim_ has quit [Ping timeout: 246 seconds]
intuxicated has quit [Ping timeout: 240 seconds]
dash_ has joined #ruby
sumark_ has quit [Remote host closed the connection]
vineavip has quit [Ping timeout: 250 seconds]
sumark has joined #ruby
jibi has quit [Ping timeout: 248 seconds]
dash_ has quit [Client Quit]
jibi has joined #ruby
marius has quit [Quit: oh nooo]
apod has quit []
freerobby has quit [Ping timeout: 260 seconds]
senayar_ has joined #ruby
dp has joined #ruby
senayar_ has quit [Remote host closed the connection]
senayar_ has joined #ruby
senayar has quit [Read error: Connection reset by peer]
sjltaylo_ has joined #ruby
mark_locklear has joined #ruby
<dp> I'm trying to use Brett Terpstra's Slogger, but it's complaining that "No such file or directory - uuidgen". Where would I find this?
kobain has joined #ruby
<dp> nm, I found it
dp has left #ruby [#ruby]
jibi has quit [Ping timeout: 256 seconds]
<shevy> perhaps ftp://ftp.ossp.org/pkg/lib/uuid/uuid-1.6.2.tar.gz ?
cody-- has quit [Quit: Computer has gone to sleep.]
cody-- has joined #ruby
cody-- has quit [Client Quit]
maz-dev has joined #ruby
tabolario has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
michalkozminski has quit [Ping timeout: 245 seconds]
AndChat| has quit [Ping timeout: 245 seconds]
jamesaanderson has joined #ruby
intuxicated has joined #ruby
kaldrenon has joined #ruby
tkuchiki has quit [Remote host closed the connection]
jamesaanderson has quit [Client Quit]
jp- has joined #ruby
breakingthings has joined #ruby
wildroman has quit [Remote host closed the connection]
eightbitraptor has quit [Ping timeout: 240 seconds]
ryannielson has joined #ruby
alekst has joined #ruby
seyha has joined #ruby
geekbri has joined #ruby
brbcoding has joined #ruby
marcgg_ has quit [Remote host closed the connection]
marcgg has joined #ruby
dhruvasagar has joined #ruby
robbyoconnor has quit [Ping timeout: 260 seconds]
pygospa has joined #ruby
huoxito has joined #ruby
jbpros has joined #ruby
linux_noob_666 has joined #ruby
TheRealPygo has quit [Ping timeout: 264 seconds]
alepore has joined #ruby
apod has joined #ruby
shaunbaker has joined #ruby
\du has joined #ruby
platzhirsch has joined #ruby
<\du> hello! i am totally new in ruby, actually i am using it to create chef recipe ( opscode.com ), i should do a simple task that maybe will carry me an hour of research, i have a directory with files /20130821_foo.sql /20130991_foo.sql.. etc.. that is data_name.sql the name always is the same and the date change, i need get the name of the latest file
<\du> for sure there is a simple way to do it in ruby, somebody can help me or give some advice from where to search?
<\du> thanks
sjltaylo_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
srji has joined #ruby
razi has joined #ruby
fmcgeough has joined #ruby
michalkozminski has joined #ruby
<srji> https://gist.github.com/visualisierte/6495166 i have this little regexp for my irc bot. but i don't get the "STDOUT.puts 'Na na na!'"
spalenza has joined #ruby
<srji> it ssems, the if statement don't run
digitalcake has joined #ruby
<Xeago> \du: Have a look at the various API's ruby gives you, File, Dir et. al
<Xeago> it would than be a simple files.sort :)
<\du> Xeago, ok i was seeing it https://www.ruby-forum.com/topic/163093 i think that should work i will try it, use Dir and File
<\du> i see, thank you!
snath has quit [Ping timeout: 256 seconds]
mikecmpbll has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
jbpros has quit [Quit: jbpros]
wildroman has joined #ruby
claymore has quit [Ping timeout: 246 seconds]
digitalcake has quit [Ping timeout: 240 seconds]
<Xeago> \du: that solution doesn't sort by the name tho
rcosta has joined #ruby
roychri has joined #ruby
Ox6abe has joined #ruby
<\du> my name is always the same, date_samename.sql
<Xeago> yes, but that solution sorts by mtime, not by name
<roychri> Hello, I am trying to install yard, and I get "rake aborted; [("eval")] are not files"
<roychri> does that tell you anything?
<\du> Xeago, yes, see the last post
nbrock has joined #ruby
nbrock has left #ruby [#ruby]
<\du> the problem is that i am having the error: "undefined method `scan' for main:Object"
digitalcake has joined #ruby
Gooder has joined #ruby
<shevy> then the method does not exist in class Object
<roychri> maybe it would be worth nothing that I am trying to install yard from source, using "rake install"
<shevy> if it was defined in a file, that file has not been loaded
Banistergalaxy has quit [Ping timeout: 260 seconds]
sirupsen has joined #ruby
tealmage has joined #ruby
sirupsen has quit [Client Quit]
<workmad3> roychri: doing a 'rake install -t' and putting all the output in a gist would be helpful
<\du> i get it, i should add e.scan(.. (reference last post from here) https://www.ruby-forum.com/topic/163093
stevechiagozie has joined #ruby
<\du> just that is not working in give me the last name, i am playing with it to see what happen
Banistergalaxy has joined #ruby
jaynewst_ has quit [Remote host closed the connection]
AxonetBE has joined #ruby
elux has joined #ruby
jaynewst_ has joined #ruby
AxonetBE has quit [Remote host closed the connection]
lkba has joined #ruby
AxonetBE has joined #ruby
jbpros has joined #ruby
fixl has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
Uranio has joined #ruby
jaynewst_ is now known as jaynewstrom_
<roychri> workmad3: ok, I will put it in gist as soon as I can. Thanks
wildroman has quit [Remote host closed the connection]
jbpros has quit [Client Quit]
ttt has quit [Remote host closed the connection]
roychri has quit [Quit: And that's the way the cookie crumbles!]
jaynewstrom_ has quit [Remote host closed the connection]
jonathanwallace has quit [Ping timeout: 264 seconds]
zets has quit [Ping timeout: 268 seconds]
jaynewst_ has joined #ruby
rcosta has quit [Remote host closed the connection]
tealmage has quit [Ping timeout: 264 seconds]
iamjarvo has joined #ruby
claymore has joined #ruby
jaynewst_ has quit [Remote host closed the connection]
danman has joined #ruby
alup has quit [Quit: Leaving]
rcosta has joined #ruby
graydot has joined #ruby
msuszczy has joined #ruby
linux_noob_666 has quit [Remote host closed the connection]
graydot has quit [Client Quit]
<\du> i have it working :)
<\du> thanks
intuxicated_ has joined #ruby
asobrasil has joined #ruby
iamjarvo has quit [Remote host closed the connection]
krawchyk has joined #ruby
iamjarvo has joined #ruby
joshu has quit [Quit: Bye.]
jerius has joined #ruby
okinomo has joined #ruby
azcodex has quit [Read error: Connection reset by peer]
dhruvasagar has quit [Read error: Operation timed out]
atmosx has joined #ruby
rickmasta has quit [Quit: Leaving...]
razi has quit [Ping timeout: 256 seconds]
intuxicated has quit [Ping timeout: 256 seconds]
ewnd9 has quit [Ping timeout: 264 seconds]
digitalcake has left #ruby [#ruby]
rcosta has quit [Ping timeout: 256 seconds]
ewnd9 has joined #ruby
mikecmpbll has joined #ruby
wildroman has joined #ruby
razi has joined #ruby
freerobby has joined #ruby
wildroman has quit [Remote host closed the connection]
cody-- has joined #ruby
intuxicated_ has quit [Read error: Connection reset by peer]
jibi has joined #ruby
jaynewst_ has joined #ruby
yfeldblum has quit [Ping timeout: 276 seconds]
shaunbaker has quit [Remote host closed the connection]
tabolario has joined #ruby
wildroman has joined #ruby
lusory has quit [Ping timeout: 240 seconds]
gr33n7007h has quit [Ping timeout: 276 seconds]
snovak has joined #ruby
kpshek has joined #ruby
gr33n7007h has joined #ruby
pwh has joined #ruby
freerobby has quit [Ping timeout: 256 seconds]
asterite has joined #ruby
sailias has joined #ruby
pwh has quit [Client Quit]
anderson has joined #ruby
asterite has left #ruby [#ruby]
shaunbaker has joined #ruby
sweeper has joined #ruby
intuxicated has joined #ruby
jaynewst_ is now known as jaynewstrom_
rickmasta has joined #ruby
<sweeper> greetings. in the context of http://two.mongoid.org/docs/querying/scopes.html , what are those calls to scope and field called? like are they class attributes, class method calls on Mongoid::Documet, or what?
kpshek has quit [Read error: Connection reset by peer]
sambao21 has joined #ruby
unixninja92_ has quit [Ping timeout: 264 seconds]
GeissT has quit [Quit: MillBroChat AdIRC User]
lewiz has joined #ruby
<lewiz> Hi guys - is there a way to resume a "gem install" after I've made some changes to the Makefile? I think this is a native gem...
jprovazn has quit [Quit: Leaving]
sayan has quit [Ping timeout: 256 seconds]
jaynewstrom_ has quit [Remote host closed the connection]
lkba has quit [Ping timeout: 245 seconds]
jaynewst_ has joined #ruby
joshu has joined #ruby
JumpMast3r has joined #ruby
himsin has quit [Quit: himsin]
tomzx_mac has quit [Ping timeout: 246 seconds]
okinomo has quit [Ping timeout: 245 seconds]
seyha has quit [Quit: Lost terminal]
<atmosx> jesus, how much time for a conventional computer to factor 1.000.000 primes?
<apeiros> depends a lot on how efficient you implemented it
<workmad3> sweeper: they're method calls on the class
<workmad3> sweeper: that style is frequently called a 'class macro' though
polaco has joined #ruby
lfox has joined #ruby
okinomo has joined #ruby
lfox has quit [Client Quit]
lfox has joined #ruby
emanon_ has joined #ruby
<sweeper> workmad3: mappen to have an idea how I would call those macros after the class has been loaded? like if at runtime I wanted to add some scopes
blackratdog has quit [Quit: This computer has gone to sleep]
<sweeper> oh hmm
<sweeper> this may have worked...
<sweeper> har, it did, wewt
<workmad3> sweeper: this is ruby... it's all runtime
<workmad3> sweeper: so just re-open the class ;)
burlyscudd has joined #ruby
akells has joined #ruby
tkuchiki has joined #ruby
<sweeper> my main issue was the where clause, I could call User.scope, but the where clause needed to be User.where(), not just where()
<sweeper> got it now tho \o
<shevy> penis
<shevy> damn... wrong channel
Squarepy has joined #ruby
lukec has joined #ruby
Ox6abe has quit [Remote host closed the connection]
browndawg has quit [Quit: Leaving.]
AlSquire has joined #ruby
<sweeper> workmad3: thanks \o
gr33n7007h has quit [Changing host]
gr33n7007h has joined #ruby
hurrrtin has joined #ruby
<hurrrtin> Hey all, I could use some clarification on something. I've been working with Ruby for several years now, but something has always eluded me.
foobArrr has quit [Quit: bye]
<hurrrtin> class << self; self; end... If I understand it like I think I do, this simply makes instance.self return the singleton name of the class instead of the super. Is that right?
codecop has quit [Remote host closed the connection]
<hurrrtin> or, the name of the singleton class/instance rather
okinomo has quit [Ping timeout: 256 seconds]
ffranz has joined #ruby
wmoxam_ has joined #ruby
foobArrr has joined #ruby
intuxicated has quit [Ping timeout: 264 seconds]
BillCriswell has joined #ruby
jprovazn has joined #ruby
RORgasm_ has joined #ruby
atmosx has quit [Quit: Lost in trance]
r4nd0m1 has quit [Ping timeout: 260 seconds]
r4nd0m1 has joined #ruby
Targen_ has joined #ruby
Ox6abe has joined #ruby
Targen has quit [Ping timeout: 260 seconds]
tobago has quit [Remote host closed the connection]
RORgasm has quit [Ping timeout: 260 seconds]
okinomo has joined #ruby
Ox6abe has quit [Remote host closed the connection]
peregrine81 has joined #ruby
dkamioka has joined #ruby
RORgasm_ has quit [Ping timeout: 245 seconds]
<apeiros> hurrrtin: it itself returns the singleton class
<apeiros> hurrrtin: before `sc = obj.singleton_class` (which came with 1.9), `sc = (class << obj; self; end)` was the way to get the singleton class.
jlast has joined #ruby
peregrine81 has quit [Client Quit]
vlad_starkov has quit [Remote host closed the connection]
tealmage has joined #ruby
quoin_ has quit [Remote host closed the connection]
jlebrech has quit [Ping timeout: 240 seconds]
quoin has joined #ruby
Coolhand has quit [Remote host closed the connection]
mklappstuhl has joined #ruby
VTLob has quit [Quit: VTLob]
quoin has quit [Ping timeout: 260 seconds]
choi0hun has joined #ruby
MrThePlague has joined #ruby
MrThePlague has joined #ruby
mmitchell has joined #ruby
tealmage has quit [Ping timeout: 276 seconds]
burlyscudd has quit [Read error: Operation timed out]
RORgasm_ has joined #ruby
<hurrrtin> apeiros: So it's just for referential correctness; not necessarily of any operating usefulness right?
jbpros has joined #ruby
RORgasm_ has quit [Read error: Connection reset by peer]
v0n has joined #ruby
RORgasm has joined #ruby
ttt has joined #ruby
ixti has quit [Read error: Connection reset by peer]
rodacato has joined #ruby
<hurrrtin> but this: `sc = (class << obj; self; end)` is different than `class << self; self; end`. Same function?
intuxicated has joined #ruby
pentameter has joined #ruby
razi has quit [Read error: Connection reset by peer]
lukec has quit [Quit: lukec]
jbpros has quit [Client Quit]
RORgasm has quit [Read error: Connection reset by peer]
razi has joined #ruby
AxonetBE has quit [Quit: Leaving.]
lkba has joined #ruby
mansi has joined #ruby
ayaz has quit [Quit: Textual IRC Client: www.textualapp.com]
AxonetBE has joined #ruby
AxonetBE has left #ruby [#ruby]
theRoUS|sick has joined #ruby
ttt has quit [Ping timeout: 256 seconds]
V8Energy has joined #ruby
wmoxam_ has quit [Quit: leaving]
RORgasm has joined #ruby
bean has joined #ruby
shaunbaker has quit [Remote host closed the connection]
\du has left #ruby ["Hasta la vista Baby!"]
hurrrrtin has joined #ruby
hurrrtin has quit []
hurrrrtin has left #ruby [#ruby]
rcosta has joined #ruby
mklappstuhl has quit [Remote host closed the connection]
choi0hun has quit [Remote host closed the connection]
hurrrrtin has joined #ruby
rodacato has quit [Read error: Connection reset by peer]
freerobby has joined #ruby
rodacato has joined #ruby
hurrrrtin has quit [Client Quit]
moura has joined #ruby
hurrrrtin has joined #ruby
theRoUS|sick has quit [Quit: Leaving]
mcat1 has joined #ruby
theRoUS|sick has joined #ruby
hurrrrtin has quit [Client Quit]
TIJ has joined #ruby
hurrrrtin has joined #ruby
theRoUS|sick has quit [Changing host]
theRoUS|sick has joined #ruby
tagrudev has quit [Read error: Connection reset by peer]
theRoUS|sick is now known as theRoUS
rodacato has quit [Remote host closed the connection]
nick645 has joined #ruby
zoee has quit [Quit: zoee]
rhys has joined #ruby
<TIJ> sdlkjf
mklappstuhl has joined #ruby
rickmasta has quit [Quit: Leaving...]
mumble has joined #ruby
hurrrrtin has quit [Quit: ThrashIRC v2.9 sic populo comunicated]
ixti has joined #ruby
VTLob has joined #ruby
shaunbaker has joined #ruby
tonni has quit [Remote host closed the connection]
intuxicated has quit [Ping timeout: 245 seconds]
rcosta has quit [Remote host closed the connection]
buibex has joined #ruby
jlebrech has joined #ruby
rcosta has joined #ruby
mklappstuhl has quit [Remote host closed the connection]
pyrac has quit [Quit: pyrac]
rcosta has quit [Remote host closed the connection]
mrsolo has joined #ruby
vlad_starkov has joined #ruby
troessner has quit [Quit: Leaving]
michaellynch has joined #ruby
Bry8Star{T2_ has quit [Ping timeout: 240 seconds]
kaspergr_ has joined #ruby
hurrrtin has joined #ruby
end_guy has quit [Ping timeout: 240 seconds]
kaspergrubbe has quit [Ping timeout: 245 seconds]
ghr has quit [Quit: Computer has gone to sleep.]
hurrrtin has quit [Client Quit]
TIJ has quit [Ping timeout: 246 seconds]
mikecmpbll has quit [Ping timeout: 248 seconds]
shaunbaker has quit [Remote host closed the connection]
hurrrtin has joined #ruby
optimusprimem has quit [Ping timeout: 245 seconds]
go|dfish has quit [Ping timeout: 264 seconds]
TIJ has joined #ruby
pyrac has joined #ruby
shaunbaker has joined #ruby
razi has quit [Ping timeout: 256 seconds]
nick645 has quit [Remote host closed the connection]
mikecmpbll has joined #ruby
pothibo has joined #ruby
Bry8Star{T2 has joined #ruby
AndChat- has joined #ruby
rickmasta has joined #ruby
wallerdev has joined #ruby
lkba has quit [Ping timeout: 246 seconds]
shaunbak_ has joined #ruby
jonathanwallace has joined #ruby
mary5030 has joined #ruby
carlyle has joined #ruby
DanKnox is now known as DanKnox_away
nisstyre has joined #ruby
<apeiros> hurrrtin: you said you did ruby for a couple of years, so I thought you'd understand an lvar assignment…
shaunbaker has quit [Ping timeout: 245 seconds]
<apeiros> hurrrtin: the construct had useful applications. the singleton class is an object and this way you can reference it.
dpritchett has joined #ruby
<apeiros> though, most who actually needed it would just define the adequate of todays Object#singleton_class using this construct, and then enjoy the nicer code.
marius has joined #ruby
<hurrrtin> apeiros: I do... I dunno why that particular snippet gives me such a hard time. I've never used it.
okinomo has quit [Quit: Lost terminal]
mgorbach has joined #ruby
<hurrrtin> Well in a nutshell, I think I have it.
Guest94825 has quit [Quit: ばいばい]
<hurrrtin> or get it.
<hurrrtin> I guess moreover, I'm curious why that's necessary at all. Except in a case, say like with activerecord, and you do something like `obj = find_by_foo_thing` and then obj.class returns FooThing
<hurrrtin> instead of ActiveRecord or what have you
<apeiros> I don't see the relation there
<apeiros> you do understand/know what the singleton class of an object is?
<hurrrtin> Because the finder would create a singleton
<hurrrtin> Yes
<apeiros> AR finders would not create singleton classes, no
Macaveli has quit [Quit: Computer has gone to sleep.]
<apeiros> no point in doing that
Kabaka has quit [Ping timeout: 240 seconds]
snath has joined #ruby
roninn has quit [Ping timeout: 264 seconds]
<hurrrtin> Ok, so if I make a class, and then mixin a singleton in that instance, the instance.class would be the singleton name or the super? The super right?
jibi has quit [Quit: .]
<apeiros> you can not mixin a singleton
<workmad3> hurrrtin: huh?
<apeiros> a singleton class is a *class*
<hurrrtin> K then I don't get it lol
<apeiros> you can't mixin classes.
<hurrrtin> Oh right
<hurrrtin> right
vlad_starkov has quit [Read error: Connection reset by peer]
justsee has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
mrsolo has quit [Quit: This computer has gone to sleep]
<ericwood> I'll mixin whatever I damn well please
michaellynch_ has joined #ruby
<apeiros> a singleton class is a class which "sits" between an object and it's "real" class
michaellynch has quit [Ping timeout: 248 seconds]
michaellynch_ is now known as michaellynch
<apeiros> x = "foo"; x.class # => String -- but x can have a singleton class
<hurrrtin> Unique to an instance of the real class tho, no?
<hurrrtin> ^ right
<apeiros> def x.my_own_method; "weeee!"; end
<apeiros> this method is stored in the singleton class
<workmad3> hurrrtin: each object has its own singleton class, yes
<waxjar_> you can mix in the Singleton module tho, to make a class a Singleton
<apeiros> and as of 1.9, you can do: `x.singleton_class` to get at that class
vlad_starkov has joined #ruby
<workmad3> waxjar_: yes, but Singleton is nothing to do with this sort of singleton_class ;)
<apeiros> >> x = "foo"; def x.weee; "weeee!"; end; x.singleton_class.instance_methods
<eval-in> apeiros => [:weee, :<=>, :==, :===, :eql?, :hash, :casecmp, :+, :*, :%, :[], :[]=, :insert, :length, :size, :bytesize, :empty?, :=~, :match, :succ, :succ!, :next, :next!, :upto, :index, :rindex, :replace, :clear, ... (https://eval.in/47501)
<hurrrtin> Which would in effect, make a single global-like class?
<apeiros> blurp, etoomanymethods :D
<waxjar_> i saw the word mixin, i thought maybe that was where the confusion came from.
<apeiros> >> x = "foo"; def x.weee; "weeee!"; end; x.singleton_class.instance_methods(false)
<eval-in> apeiros => [:weee] (https://eval.in/47502)
Davey has joined #ruby
<apeiros> what's a "global-like class"? and most likely: no, about the opposite
<apeiros> a singleton-class belongs to *exactly* one object
<hurrrtin> Ok I'm with you there.
<hurrrtin> Ok but so then, in laymans terms, what does class << self; self; end do? I know that it is defining a singleton for this instance, but I can't imagine why this is necessary.
wildroman has quit [Remote host closed the connection]
Kabaka has joined #ruby
gener1c has joined #ruby
<gener1c> will String.tr ever change to String.translate?
Joska has joined #ruby
optimusprimem has joined #ruby
optimusprimem has quit [Changing host]
optimusprimem has joined #ruby
<apeiros> hurrrtin: it's not *defining*, it's *returning* it
fmcgeough has quit [Ping timeout: 264 seconds]
<gener1c> i have lived a lie all this time and used .gsub("\w",hash) till i found out about tr
anteaya has joined #ruby
<apeiros> and in layman terms as I already said: exactly what Object#singleton_class does since 1.9
<hurrrtin> Wouldn't obj.class do the same exact thing then?
razi has joined #ruby
<workmad3> hurrrtin: no
<apeiros> hurrrtin: also, it's NOT a singleton. it's a singleton CLASS
<apeiros> big difference
Senjai has quit [Ping timeout: 260 seconds]
<hurrrtin> OHHHHHHH
<apeiros> hurrrtin: "".class # => String
<workmad3> hurrrtin: an object's singleton class is distinct from the object's class
tealmage has joined #ruby
<apeiros> String does NOT belong *exactly* to one object
<apeiros> it belongs to all strings
askhader has left #ruby [#ruby]
<apeiros> so totally not the same
tonni has joined #ruby
<workmad3> >> a = ""; a.class == a.singleton_class
<eval-in> workmad3 => false (https://eval.in/47503)
<apeiros> if you'd look at the ancestry, x.singleton_class < x.class < *x.ancestors
<workmad3> >> a = ""; a.singleton_class == a.singleton_class
<eval-in> workmad3 => true (https://eval.in/47504)
<workmad3> >> a = ""; b = ""; b.singleton_class == a.singleton_class
<eval-in> workmad3 => false (https://eval.in/47505)
<workmad3> >> a = ""; b = ""; b.class == a.class
<eval-in> workmad3 => true (https://eval.in/47506)
wildroman has joined #ruby
randomdrake has joined #ruby
maz-dev has quit [Remote host closed the connection]
Senjai has joined #ruby
Senjai has quit [Changing host]
Senjai has joined #ruby
shredding has quit [Quit: shredding]
Joska_ has joined #ruby
tesuji has quit [Ping timeout: 245 seconds]
jefflyne2 has quit [Ping timeout: 245 seconds]
Joska has quit [Ping timeout: 276 seconds]
pyrac has quit [Quit: pyrac]
Ox6abe has joined #ruby
dhruvasagar has joined #ruby
roninn has joined #ruby
<hurrrtin> So then class Foo; end; class Foo; def self.what_am_i; class << self; self; end; end; end. Now Foo.self would yield 'Foo' ??
<apeiros> der is no Foo.self
<hurrrtin> oops I mean Foo.what_am-i
end_guy has joined #ruby
<apeiros> no, it would not
<hurrrtin> lol
<apeiros> def self.what_am_i; self; end
<apeiros> that would return Foo
pyrac has joined #ruby
<apeiros> but `def self.what_am_i` is defining a method in Foo's singleton_class
tealmage has quit [Ping timeout: 246 seconds]
<apeiros> a 'class method' is technically an instance method of the singleton class of said class
<apeiros> e.g. Time.at - `at` is a class method of class "Time". `at` is an instance method of the singleton class of class "Time"
Uranio has quit [Quit: while you reading this, a kitty dies]
tjad has joined #ruby
<hurrrtin> Ok I follow that. So how would I use the class << self; self; end in regards to Time, and what would it yield?
Pent has joined #ruby
<gener1c> so a singleton class is a monkeypatched instance of the original class that sits between that apecific object and the original class?
apod has quit []
Uranio has joined #ruby
Ox6abe_ has joined #ruby
kaspergr_ has quit [Remote host closed the connection]
Ox6abe has quit [Ping timeout: 245 seconds]
<apeiros> hurrrtin: we're just repeating what was said half a dozen times…
yfeldblum has joined #ruby
<apeiros> (class << Time; self; end) == Time.singleton_class
<hurrrtin> I'm sorry- I don't wanna frustrate you. I dunno why I can't put my finger on this.
razi has quit [Ping timeout: 276 seconds]
<apeiros> and that stems from the simple truth that classes are objects
<apeiros> >> Time.is_a?(Time.singleton_class)
<eval-in> apeiros => true (https://eval.in/47507)
pyrac has quit [Ping timeout: 245 seconds]
<apeiros> >> x = "foobar"; x.is_a?(x.singleton_class)
<eval-in> apeiros => true (https://eval.in/47508)
jtgiri_ has joined #ruby
razi has joined #ruby
nisstyre has quit [Quit: Leaving]
<apeiros> >> a = "foobar"; x="foobar"; a.is_a?(x.singleton_class)
<eval-in> apeiros => false (https://eval.in/47509)
TuuX has joined #ruby
ssvo has quit [Ping timeout: 256 seconds]
justsee has left #ruby [#ruby]
wesside has quit [Ping timeout: 268 seconds]
askhader has joined #ruby
<askhader> Have any of you encountered a bundle error like this before: https://gist.github.com/sorter/0bfd925a5761a0f1e839 ?
<hurrrtin> askhader: sudo apt-get install libjson-dev (or something like that)
cody-- has quit [Quit: Computer has gone to sleep.]
baroquebobcat has joined #ruby
<apeiros> askhader: not related to bundler. your problem is to install the gem itself.
m8 has joined #ruby
m8 has quit [Changing host]
m8 has joined #ruby
<apeiros> try a plain `gem install -v1.7.7 json`
<apeiros> I wouldn't wonder if it was an issue with you using ruby 1.8 (which is A *ancient* and B no longer supported)
jdolitsky1 has joined #ruby
mcat1 has quit [Remote host closed the connection]
alex__c2022 has joined #ruby
<apeiros> alternatively it might be what hurrrtin said - missing headers/libs
fmcgeough has joined #ruby
julweber has quit [Remote host closed the connection]
jbpros has joined #ruby
srji has quit [Quit: leaving]
rickmasta has quit [Quit: Leaving...]
yfeldblum has quit [Ping timeout: 260 seconds]
aganov has quit [Remote host closed the connection]
sjltaylor has joined #ruby
KobraKao has quit [Ping timeout: 245 seconds]
Catbuntu has joined #ruby
<Catbuntu> boo
rickmasta has joined #ruby
razi has quit [Ping timeout: 256 seconds]
jbpros_ has joined #ruby
dhruvasagar has quit [Ping timeout: 245 seconds]
buibex has quit [Remote host closed the connection]
brianpWins has quit [Ping timeout: 245 seconds]
razi has joined #ruby
crunch-choco has joined #ruby
jbpros has quit [Read error: Connection reset by peer]
sarkis has joined #ruby
browndawg has joined #ruby
Monie has joined #ruby
tylersmith has quit [Remote host closed the connection]
hogeo has joined #ruby
pel_daniel has joined #ruby
tylersmith has joined #ruby
jefflyne2 has joined #ruby
jbpros_ is now known as jbpros
sevenseacat has quit [Quit: Leaving.]
dash_ has joined #ruby
Tricon has joined #ruby
tylersmith has quit [Ping timeout: 264 seconds]
cody-- has joined #ruby
go|dfish has joined #ruby
rcosta has joined #ruby
io_syl has joined #ruby
carraroj has joined #ruby
peregrine81 has joined #ruby
ner0x has joined #ruby
tvw has quit []
Coolhand has joined #ruby
emanon_ has quit [Remote host closed the connection]
himsin has joined #ruby
himsin has quit [Client Quit]
cody-- has quit [Client Quit]
jbpros has quit [Ping timeout: 256 seconds]
vikhyat has joined #ruby
vikhyat has quit [Read error: Connection reset by peer]
jbpros has joined #ruby
vikhyat has joined #ruby
rickmasta has quit [Quit: Leaving...]
stef1a has joined #ruby
rippa has joined #ruby
rickmasta has joined #ruby
mzdravkov1 has joined #ruby
khismetix has joined #ruby
enebo has joined #ruby
<stef1a> does anyone know if there's a regex difference 2.0.0p195 and 2.0.0p247?
zarubin has joined #ruby
cody-- has joined #ruby
mzdravkov1 is now known as mzdravkov
MrZYX|off is now known as MrZYX
tvw has joined #ruby
<apeiros> stef1a: shouldn't. what's the cause for the question?
apfelbox has quit [Remote host closed the connection]
<apeiros> oh, and if "somebody" knows, then the CHANGELOG
<mzdravkov> Have anyone here used sequel orm
tvw has quit [Client Quit]
apfelbox has joined #ruby
<apeiros> mzdravkov: don't ask metaquestions.
carraroj has quit [Read error: Operation timed out]
<stef1a> apeiros: production uses 247, local uses 195, and the regex that causes certain items to be underlined (with html span tags) works locally doesn't work in production
tkuchiki has quit [Remote host closed the connection]
<stef1a> can't view the logs atm (which i'm trying to figure out how to do), but i can see the results
<apeiros> (well, you're free to - but it's to your own disadvantage)
tvw has joined #ruby
hackerpreneur has joined #ruby
jbpros has quit [Ping timeout: 260 seconds]
hackerpreneur has quit [Max SendQ exceeded]
<apeiros> stef1a: ok, interesting. tried running it locally with 247?
<mzdravkov> Ok, sorry: My question is how can I check if there is such database when connecting to some db (I can use db = Sequel.connect(...); db.tables and catch the exception, but isn't there some better way)
<stef1a> apeiros: nope!
<apeiros> mzdravkov: iirc Sequel has db.exists?
rickmasta has quit [Client Quit]
jbpros has joined #ruby
<apeiros> mzdravkov: check the docs on it, e.g. on rdoc.info or locally via ri/yri
<apeiros> or `gem server`
lukec has joined #ruby
browndawg has quit [Ping timeout: 246 seconds]
<Morrolan> s/gem/yard/
Nogbit has joined #ruby
<Morrolan> Unless gem's server serves documentation, too?
<apeiros> stef1a: well, I guess that's what I'd do. if you can switch locally between 247 and 195 (should be easy with rvm or similar) and the behavior changes, then it's reasonable to assume it's due to the ruby version
<apeiros> Morrolan: it does
vlad_starkov has quit [Read error: Connection reset by peer]
<Morrolan> Heh, I see.
<apeiros> did for >7y now ;-)
<apeiros> but yes, yard server too, I guess
<apeiros> I really need a 'canned answers'-bot
jbpros has quit [Client Quit]
<pontiki> o/
vlad_starkov has joined #ruby
apfelbox has quit [Ping timeout: 246 seconds]
<Morrolan> By the time I started using a local documentation server, I've already moved to yard. (Weak defense, I know, I know :P)
<Morrolan> And yes, bots which provide certain factoids are a great help in some channels. :)
Monie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<apeiros> acceptable reason IMO :)
hackerpreneur has joined #ruby
hackerpreneur has quit [Max SendQ exceeded]
emanon_ has joined #ruby
hackerpreneur has joined #ruby
hackerpreneur has quit [Max SendQ exceeded]
emanon_ has quit [Read error: Connection reset by peer]
hackerpreneur has joined #ruby
browndawg has joined #ruby
hackerpreneur has quit [Max SendQ exceeded]
emanon_ has joined #ruby
Karak has joined #ruby
Karak has left #ruby [#ruby]
emanon_ has quit [Remote host closed the connection]
marcgg has quit [Ping timeout: 245 seconds]
mansi has quit [Read error: Connection reset by peer]
JumpMast3r has quit [Quit: JumpMast3r]
mansi has joined #ruby
locriani has joined #ruby
mansi has quit [Read error: Connection reset by peer]
shaunbak_ has quit [Remote host closed the connection]
kobain has quit []
mansi has joined #ruby
d2dchat_ has joined #ruby
mrsolo has joined #ruby
* apeiros commutes
robbyoconnor has joined #ruby
nari has quit [Ping timeout: 246 seconds]
apeiros has quit [Remote host closed the connection]
stef1a has quit [Remote host closed the connection]
sr78ger has joined #ruby
stef1a has joined #ruby
DaniG2k has joined #ruby
<DaniG2k> sup guys
buibex has joined #ruby
shaunbaker has joined #ruby
iamjarvo has quit [Read error: Connection reset by peer]
brianpWins has joined #ruby
iamjarvo has joined #ruby
geggam_ has joined #ruby
utkarsh has quit [Changing host]
utkarsh has joined #ruby
tabolario has quit [Ping timeout: 245 seconds]
<utkarsh> I don't suppose the ISO standard of Ruby is available for free anywhere?
mumble has quit [Ping timeout: 240 seconds]
<stef1a> Does anyone know why this regex script might work in 2.0.0p195 (local, GUI) but not 2.0.0p247 (remote server, no GUI)? http://pastie.org/pastes/8311174/text
BlueShark has quit [Quit: Leaving.]
BlueShark has joined #ruby
RichardBaker has joined #ruby
filipe has quit [Remote host closed the connection]
tealmage has joined #ruby
quoin has joined #ruby
kobain has joined #ruby
Squarepy has quit [Remote host closed the connection]
tabolario has joined #ruby
<Morrolan> stef1a: Could you reproduce it locally?
jtgiri_ has quit [Quit: jtgiri_]
<stef1a> Morrolan: it works in p195 locally but i'm not planning to re-install rvm and go through the process of getting all my gems, etc. for p247
<Morrolan> How's that an issue?
<stef1a> Morrolan: ?
Monie has joined #ruby
<stef1a> Morrolan: my remote uses p247
zeade has joined #ruby
Voodoofish430 has joined #ruby
<Morrolan> I'm unsure about how Ruby is handling regex under the hood. But it might be a good idea to make sure it's an issue of Ruby, and not of the environment.
<stef1a> the script works locally but does not work remotely
vlad_starkov has quit [Read error: Connection reset by peer]
hogeo has quit [Remote host closed the connection]
rickmasta has joined #ruby
gr33n7007h has quit [Ping timeout: 260 seconds]
<stef1a> Morrolan: i suspect it might be due to root path, actually.
<stef1a> not sure though
vlad_starkov has joined #ruby
Coffers has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
tjad has quit [Ping timeout: 245 seconds]
SHyx0rmZ has joined #ruby
razi has quit [Ping timeout: 264 seconds]
<pontiki> how is it failing, stef1a ?
tealmage has quit [Ping timeout: 245 seconds]
lfox has quit [Quit: ZZZzzz…]
Nogbit has left #ruby [#ruby]
<stef1a> pontiki: in the web-page generated locally, the desired items are underlined. in the web-page generated remotely, the desired items are not.
ssvo has joined #ruby
<pontiki> can you please give both sets of input?
vlad_starkov has quit [Remote host closed the connection]
gusnasis has joined #ruby
woolite64 has quit [Quit: Leaving]
<pontiki> and actually, both sets of output would be helpful as well
woolite64 has joined #ruby
<stef1a> pontiki: okay... one moment
marius has quit [Quit: oh nooo]
ssvo_ has joined #ruby
kilophoton has joined #ruby
dagobah has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
ssvo has quit [Ping timeout: 245 seconds]
razi has joined #ruby
carlyle has quit [Remote host closed the connection]
JohnBat26 has quit [Ping timeout: 245 seconds]
Andrevan has joined #ruby
timonv has quit [Remote host closed the connection]
maletor has joined #ruby
stef1a has quit [Read error: Operation timed out]
wildroman has quit [Remote host closed the connection]
swordsmanz has quit [Ping timeout: 246 seconds]
Nanuq has quit [Ping timeout: 245 seconds]
mumble has joined #ruby
[Rickmasta] has joined #ruby
ixti has quit [Ping timeout: 256 seconds]
dhruvasagar has joined #ruby
woolite64 has quit [Quit: Leaving]
Nanuq has joined #ruby
dankest has joined #ruby
hamakn has quit [Remote host closed the connection]
gr33n7007h has joined #ruby
hamakn has joined #ruby
mercwithamouth has quit [Ping timeout: 245 seconds]
_JamieD_ has joined #ruby
stef1a has joined #ruby
rickmasta has quit [Ping timeout: 245 seconds]
marius has joined #ruby
kaspergrubbe has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
gr33n7007h has quit [Client Quit]
sepp2k has joined #ruby
[Rickmasta] has quit [Ping timeout: 264 seconds]
jtgiri_ has joined #ruby
Pent has quit [Quit: Pent]
Tuxist has joined #ruby
mansi has quit [Remote host closed the connection]
hamakn has quit [Ping timeout: 245 seconds]
mansi has joined #ruby
unixninja92 has joined #ruby
Targen_ has quit [Ping timeout: 256 seconds]
ixti has joined #ruby
sambao21 has joined #ruby
sambao21 has quit [Client Quit]
mansi has quit [Read error: Connection reset by peer]
mansi has joined #ruby
kaspergrubbe has quit [Ping timeout: 245 seconds]
mansi has quit [Remote host closed the connection]
jbpros has joined #ruby
mikecmpbll has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
sjltaylor has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mansi has joined #ruby
julweber has joined #ruby
Spami has joined #ruby
Spami has joined #ruby
DaniG2k has quit [Quit: leaving]
quoin has quit [Ping timeout: 256 seconds]
Pent has joined #ruby
jbpros has quit [Client Quit]
vlad_starkov has joined #ruby
wildroman has joined #ruby
wildroman has quit [Read error: Connection reset by peer]
Macaveli has joined #ruby
apeiros has joined #ruby
catdog123 has joined #ruby
shaunbaker has quit [Remote host closed the connection]
wildroman has joined #ruby
visof has quit [Remote host closed the connection]
blackratdog has joined #ruby
iamjarvo has quit [Remote host closed the connection]
iamjarvo has joined #ruby
jonathanwallace has quit [Ping timeout: 240 seconds]
ssvo_ is now known as ssvo
julweber has quit [Ping timeout: 245 seconds]
sambao21 has joined #ruby
blackratdog1 has quit [Ping timeout: 264 seconds]
atmosx has joined #ruby
rcosta has quit [Remote host closed the connection]
Coolhand has quit [Remote host closed the connection]
robbyoconnor has quit [Ping timeout: 240 seconds]
lfox has joined #ruby
dhruvasagar has quit [Ping timeout: 256 seconds]
iamjarvo has quit [Ping timeout: 245 seconds]
Nanuq has quit [Ping timeout: 245 seconds]
Kabaka has quit [Remote host closed the connection]
razi has quit [Ping timeout: 264 seconds]
centr0 has joined #ruby
diegoviola has joined #ruby
Nanuq has joined #ruby
youcallme has quit [Remote host closed the connection]
andikr has quit [Remote host closed the connection]
<diegoviola> how do i get odd/even numbers from an array, like (1..100).select{|x| x % 2 == 0} #=> i get par from this, but why do i get odd/even when i divide that by 3?
<diegoviola> sorry for the n00b question
Stygia has quit [Remote host closed the connection]
bean has quit [Quit: Computer has gone to sleep.]
Kabaka has joined #ruby
<Morrolan> Because multiples of 3 can be odd as well as even?
<Morrolan> 3 is odd, 6 is even, 9 is odd, 12 is even, ...
<diegoviola> right
<diegoviola> so
<apeiros> diegoviola: hu? what?
<diegoviola> what is that == 0 at the end of it?
<Morrolan> diegoviola: What exactly are you trying to do? :)
<Morrolan> Hmm, are you familiar with modulo operations?
anderson has quit [Quit: Leaving]
<apeiros> it compares the result of (x % 2) with zero
bluenemo has joined #ruby
<catdog123> diegoviola: you could do (1..100).select { |x| x.even? }
bluenemo has quit [Changing host]
bluenemo has joined #ruby
* pontiki wonders if stef1a figured out their issue
jlast_ has joined #ruby
jlast_ has quit [Remote host closed the connection]
<diegoviola> just want to get the odd numbers out of the array
<diegoviola> thanks
camilasan has quit [Remote host closed the connection]
mikepack has joined #ruby
mikepack_ has joined #ruby
mikepack has quit [Read error: Connection reset by peer]
<catdog123> (1..100).select { |x| x.odd? }
tatsuya_o has quit [Remote host closed the connection]
<diegoviola> thanks
<apeiros> I think by "out" he meant "removed"
RichardBaker has quit [Quit: RichardBaker]
nwertman has joined #ruby
<apeiros> ambiguous phrasing, though
AntelopeSalad has quit [Ping timeout: 245 seconds]
TIJ has quit [Ping timeout: 240 seconds]
<diegoviola> yeah
<diegoviola> sorry about that
<catdog123> ah ha. gotcha!
lukec has quit [Quit: lukec]
maz-dev has joined #ruby
senayar has joined #ruby
Pent has quit [Quit: Pent]
robbyoconnor has joined #ruby
jlast has quit [Ping timeout: 264 seconds]
claymore_ has joined #ruby
spider-mario has joined #ruby
vlad_starkov has quit [Read error: Connection reset by peer]
bean has joined #ruby
spider-mario has quit [Remote host closed the connection]
companion is now known as Companion
chrisja has joined #ruby
parzo_ has joined #ruby
parzo_ has quit [Remote host closed the connection]
rcosta has joined #ruby
spider-mario has joined #ruby
ssvo_ has joined #ruby
claymore has quit [Ping timeout: 245 seconds]
T__T has joined #ruby
senayar_ has quit [Ping timeout: 256 seconds]
vlad_starkov has joined #ruby
senayar has quit [Ping timeout: 240 seconds]
ssvo has quit [Ping timeout: 240 seconds]
<sam113101> can I generate a gemfile?
iliketur_ has joined #ruby
<pontiki> from what?
alepore has quit [Quit: This computer has gone to sleep]
Koa has joined #ruby
<sam113101> from a bunch of .rb files
buibex has quit [Remote host closed the connection]
robbyoconnor has quit [Quit: Konversation terminated!]
<sam113101> something that would check teh requires and check if it's a gem
zeel has left #ruby [#ruby]
buibex has joined #ruby
<sam113101> because I just "gem install" them and forget
TIJ has joined #ruby
<Morrolan> What in cases where there's more than one gem which provides the files you require?
RichardBaker has joined #ruby
<pontiki> and what about cases where you need a specific version
<Morrolan> In addition I don't think there's there a convenient way to find out which gems provide which files. You'd have to have a copy of all gems locally.
<sam113101> I'd edit the generated gemfile manually
<pontiki> anyway, i'm all for writing tools that let one engage in their laziness
<pontiki> so if you come up with one, awesome
<Morrolan> I'd probably just `ls` my local gem directory, and look what's in there. :)
<sam113101> pontiki: so I take it there's nothing that does what I want currently?
<pontiki> sam, you can google and grep as well as anyone else
<waxjar_> don't gemsets solve the problem?
<pontiki> i don't know of one, and i'm not going to go look
stonevil has joined #ruby
<pontiki> no, waxjar_ -- gemsets use the Gemfile, they don't create it
<cout> morrolan: correct, esp since some files are generated, and there's no way to know from a given gem spec what files will be generated
Senjai has quit [Ping timeout: 245 seconds]
codecop has joined #ruby
<sam113101> love you guys
<waxjar_> a gemset is a set of gems, which you can just upload with the rest of your app
buibex has quit [Ping timeout: 276 seconds]
<pontiki> waxjar_: true, but sam113101's request is for something to create a Gemfile
<cout> maybe I didn't scroll back far enough to understand the original question
Elhu has quit [Quit: Computer has gone to sleep.]
stonevil has left #ruby [#ruby]
<Morrolan> cout: Create a gemfile based on the `require`s in your code.
Elhu has joined #ruby
Elhu has quit [Client Quit]
Zolo has joined #ruby
<cout> I thought the seattlerb guys had something to do that
moura has quit [Quit: Computer has gone to sleep.]
<cout> I just use globs in my gemfile
<cout> spec file I mean
<cout> ok I still misunderstood the question
<pontiki> the .gemspec file? yeah, different than Gemfile, I think...
<cout> now I understand
<pontiki> for sam113101's question
<pontiki> idk
Zolo has quit [Remote host closed the connection]
DonRichie has joined #ruby
kaldrenon has quit [Remote host closed the connection]
Ox6abe_ has quit [Remote host closed the connection]
cody-- has quit [Quit: Computer has gone to sleep.]
RichardBaker has quit [Ping timeout: 276 seconds]
jlast has joined #ruby
stef1a has quit [Ping timeout: 264 seconds]
kaldrenon has joined #ruby
stef1a has joined #ruby
kaldrenon has quit [Remote host closed the connection]
kaldrenon has joined #ruby
claymore_ has quit [Read error: Operation timed out]
Eiam has quit [Quit: ╯°□°)╯︵ǝpouǝǝɹɟ]
<askhader> Can I control what version of ruby is run with bundler?
lukec has joined #ruby
zacts has quit [Read error: Connection reset by peer]
<existensil> askhader: I don't think so
headius has joined #ruby
<pontiki> no, you can control what version can be run
<apeiros> askhader: with newer gemfile version you can
nomenkun has quit [Remote host closed the connection]
<existensil> really? awesome
<apeiros> common way to do it is to use a .ruby-version file, though
<pontiki> but you control which version *is* run
_JamieD_ has quit [Quit: _JamieD_]
<existensil> yeah, i use .ruby-version+.ruby-gemset
<askhader> What's the syntax for that look like?
<apeiros> oh, well, details. true - askhader - you can only require a ruby version
<apeiros> you can't make it automatically be run with that ruby version
tealmage has joined #ruby
<existensil> if rvm you can just generate one: rvm rvmrc create 2.0.0@my_gemset --ruby-version
twoism has joined #ruby
<workmad3> you can put 'ruby "2.0.0" ' in the Gemfile (since bundler 1.2, iirc), but yeah, that just exits out if a different ruby version is in use, it doesn't switch to said ruby version
<apeiros> a .ruby-version file paired with a ruby version manager which interprets it however will enable automatic switching.
iamjarvo has joined #ruby
KobraKao has joined #ruby
c0rn has joined #ruby
Targen has joined #ruby
miza has joined #ruby
tylersmith has joined #ruby
zacts has joined #ruby
miza has left #ruby [#ruby]
dodosan has joined #ruby
stkowski has joined #ruby
jlast has quit [Remote host closed the connection]
Eiam has joined #ruby
devoldmx has quit [Ping timeout: 245 seconds]
jlast has joined #ruby
DanKnox_away is now known as DanKnox
KobraKao has quit [Ping timeout: 276 seconds]
jlast has quit [Remote host closed the connection]
ehaliewicz has joined #ruby
jlast has joined #ruby
TIJ has quit [Quit: Konversation terminated!]
tealmage has quit [Ping timeout: 276 seconds]
dodosan has quit [Ping timeout: 245 seconds]
Lewix has joined #ruby
Lewix has joined #ruby
Macaveli has quit [Quit: Computer has gone to sleep.]
alex__c2022 has quit [Quit: alex__c2022]
kobain has quit []
lukec has quit [Quit: lukec]
apfelbox has joined #ruby
lukec has joined #ruby
Aryasam has joined #ruby
twoism has quit [Read error: Connection reset by peer]
bean has quit [Quit: Computer has gone to sleep.]
twoism has joined #ruby
ksh has quit [Quit: ksh]
interactionjaxsn has joined #ruby
catdog123 has quit [Remote host closed the connection]
claymore_ has joined #ruby
Lewix has quit [Ping timeout: 276 seconds]
jonathanwallace has joined #ruby
apfelbox has quit [Ping timeout: 256 seconds]
marius has quit [Quit: oh nooo]
carraroj has joined #ruby
tvw has quit []
carraroj has quit [Client Quit]
DanKnox is now known as DanKnox_away
Ox6abe has joined #ruby
bean has joined #ruby
IceDragon has joined #ruby
alex__c2022 has joined #ruby
wildroman has quit [Remote host closed the connection]
khismetix has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
carlyle has joined #ruby
gyre007 has joined #ruby
mieczyk has joined #ruby
quoin has joined #ruby
claymore_ has quit [Quit: Leaving]
claymore has joined #ruby
goodcodeguy has joined #ruby
yxhuvud2 has joined #ruby
reset has joined #ruby
yxhuvud has quit [Ping timeout: 259 seconds]
alepore has joined #ruby
razi has joined #ruby
mzdravkov has left #ruby [#ruby]
alepore has quit [Client Quit]
hamakn has joined #ruby
_JamieD_ has joined #ruby
xcfox has quit [Quit: Ухожу я от вас (xchat 2.4.5 или старше)]
s0ny123 has quit [Quit: Lost terminal]
obs has quit [Quit: Konversation terminated!]
samsagaz has joined #ruby
<samsagaz> hi guys
<samsagaz> exist some GUI/IDE that have internal console/terminal to test the script? :)
xsdg has joined #ruby
mercwithamouth has joined #ruby
sayan has joined #ruby
Es0teric has joined #ruby
vlad_starkov has quit [Read error: Connection reset by peer]
ixti has quit [Read error: Connection reset by peer]
hamakn has quit [Ping timeout: 248 seconds]
ewnd9 has quit [Ping timeout: 256 seconds]
DanKnox_away is now known as DanKnox
havenwood has joined #ruby
ixti has joined #ruby
tonni has quit [Remote host closed the connection]
vlad_starkov has joined #ruby
stef1a has quit [Remote host closed the connection]
aaronmcadam has quit [Quit: Leaving...]
stef1a has joined #ruby
mercwithamouth has quit [Ping timeout: 256 seconds]
optimusprimem has quit [Read error: Connection reset by peer]
Gillo has joined #ruby
codecop has quit [Read error: Operation timed out]
aaronmcadam has joined #ruby
Zai00 has quit [Quit: Zai00]
<eka> samsagaz: paid… RubyMine
<Eiam> samsagaz: sublime + pry
vlad_starkov has quit [Remote host closed the connection]
<Eiam> but i guess thats not internal
<eka> nope
Aryasam has quit [Quit: Bye]
<Eiam> boom,
<Eiam> is now =)
<eka> great
ssvo has joined #ruby
<Eiam> god this is amazing
<Eiam> installing now =)
<eka> still I prefer vim :>P
<Eiam> then I'd have to learn vim =)
dangerousdave has quit [Read error: Connection reset by peer]
reset has quit [Quit: Leaving...]
<eka> has no terminal embedded though
<apeiros> there's also emacs
<eka> there is also emacs
dangerousdave has joined #ruby
<eka> *flame war*
<apeiros> has a couple of additional features, like a built-in OS
nemesit|znc has quit [Ping timeout: 240 seconds]
<eka> apeiros: OS or language?
<apeiros> OS
<Eiam> I'd learn emacs before vim
<apeiros> I jest. but still.
<eka> apeiros: how is thatL
<eka> ?
<Eiam> simply because I'm very interested in lisp like languages
<Eiam> and still need to finish SICP
catdog123 has joined #ruby
Gooder has quit [Ping timeout: 276 seconds]
<eka> apeiros: I mean… emacs can control the machine hardware without using the real OS kernel? how is that it's like an OS?
<eka> apeiros: you went too far
<apeiros> eka: I was kidding
<eka> ok
dangerousdave has quit [Client Quit]
<Eiam> you can build an OS on top of an OS..
<Eiam> vmware?
<eka> thought so, but coming from you I was doubting
<apeiros> lol, because I'm such a humorless sadsack? :D
<apeiros> s'ok, I probably am ;-)
<eka> apeiros: cause you are always in the mood
<eka> ;)
sr78ger has quit [Quit: Qui]
ssvo has quit [Ping timeout: 260 seconds]
<pontiki> it's a common dig on emacs: "The OS that thinks it's an Editor/ The Editor that thinks it's an OS"
mercwithamouth has joined #ruby
Ox6abe has quit [Remote host closed the connection]
goodcodeguy has quit [Read error: Connection reset by peer]
VTLob has quit [Remote host closed the connection]
<eka> pontiki: you should see a psychiatrist, it's called eliza
Bosox20051 has joined #ruby
<apeiros> maybe the OS and emacs should talk with eliza
<eka> not turing complete though
dangerousdave has joined #ruby
jaimef has quit [Excess Flood]
nwertman has quit [Remote host closed the connection]
reset has joined #ruby
Tricon has quit [Quit: Bye!]
Tricon has joined #ruby
<pontiki> it's called doctor
jaimef has joined #ruby
<eka> it's based on eliza ;)
<pontiki> yes, but it's called doctor
sambao21 has quit [Quit: Computer has gone to sleep.]
bluenemo has quit [Remote host closed the connection]
quoin has quit [Ping timeout: 245 seconds]
moted has quit [Quit: moted]
moted has joined #ruby
shadoi has joined #ruby
nemesit|znc has joined #ruby
cody-- has joined #ruby
senayar has joined #ruby
sambao21 has joined #ruby
kenneth has quit [Quit: kenneth]
seoNinjaWarrior has quit [Ping timeout: 264 seconds]
Ox6abe has joined #ruby
codecop has joined #ruby
allsystemsarego has quit [Quit: Leaving]
<eka> pontiki: the command in doctor… it's called eliza ;) http://www.csee.umbc.edu/courses/471/papers/emacs-doctor.shtml
fomatin has joined #ruby
<eka> *is
fomatin has quit [Max SendQ exceeded]
catdog123 has quit [Read error: Connection reset by peer]
<pontiki> eka: ;;; Commentary:
<pontiki> ;; The single entry point `doctor', simulates a Rogerian analyst using
<pontiki> ;; phrase-production techniques similar to the classic ELIZA demonstration
<pontiki> ;; of pseudo-AI.
catdog123 has joined #ruby
IcyDragon has joined #ruby
locriani has quit [Remote host closed the connection]
goodcodeguy has joined #ruby
Pent has joined #ruby
IceDragon has quit [Ping timeout: 245 seconds]
<apeiros> wow, and there I thought the flame war would be about the editors, not the built-in accessories
* apeiros goes get some popcorn
<pontiki> eliza is but one of the personalities
<pontiki> it also has rms and zippy
nwertman has joined #ruby
julweber has joined #ruby
blackmesa has joined #ruby
jlebrech has quit [Quit: Konversation terminated!]
dodosan has joined #ruby
fomatin has joined #ruby
rcosta has quit [Remote host closed the connection]
_JamieD_ has quit [Quit: _JamieD_]
cody-- has quit [Quit: Computer has gone to sleep.]
brunoro has joined #ruby
yfeldblum has joined #ruby
hackerpreneur has joined #ruby
hackerpreneur has quit [Max SendQ exceeded]
rdark has quit [Quit: leaving]
hackerpreneur has joined #ruby
hackerpreneur has quit [Max SendQ exceeded]
hackerpreneur has joined #ruby
hackerpreneur has quit [Max SendQ exceeded]
peregrine81 has quit []
helperguy has joined #ruby
helperguy has quit [Max SendQ exceeded]
helperguy has joined #ruby
helperguy has quit [Max SendQ exceeded]
Monie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
_JamieD_ has joined #ruby
helperguy has joined #ruby
helperguy has quit [Max SendQ exceeded]
peregrine81 has joined #ruby
tealmage has joined #ruby
Elhu has joined #ruby
helperguy has joined #ruby
helperguy has quit [Max SendQ exceeded]
TuuX has quit [Remote host closed the connection]
Voodoofish430 has quit [Quit: Leaving.]
nemesit|znc has quit [Ping timeout: 248 seconds]
<samsagaz> thanks
Monie has joined #ruby
nemesit|znc has joined #ruby
<samsagaz> just sublime dont work under freebsd i think :(
<askhader> When bundle install runs out of memory, what are my options?
browndawg has left #ruby [#ruby]
adambeynon has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
tafryn has joined #ruby
<apeiros> askhader: laugh hysterically and run around with your arms waving?
<Eiam> damnit redis
<Eiam> y u no love me
<apeiros> askhader: depends, I think one case where memory usage goes high is dependency resolution. try to narrow down required versions and specify that in the gemfile
<askhader> Capitol idea!
huoxito has quit [Quit: Leaving]
azcodex has joined #ruby
<tafryn> I'm running into a weird problem with libxml-ruby. One of the populated nodes in my xml file returns "" when I attempt to read it's contents with xmlReader.node.content. However, xmlReader.expand.content correctly shows the contents of the node. Also, after running xmlReader.expand.content, xmlReader.node.content starts working. Does anyone know what might be causing this?
tealmage has quit [Ping timeout: 276 seconds]
apfelbox has joined #ruby
chairabanta has joined #ruby
s0ny123 has joined #ruby
kindjal has joined #ruby
dkamioka has quit [Remote host closed the connection]
Banistergalaxy has quit [Ping timeout: 276 seconds]
Klotho1 has joined #ruby
apfelbox has quit [Ping timeout: 256 seconds]
Monie_ has joined #ruby
YaNakilon has quit [Ping timeout: 276 seconds]
brunoro has quit [Quit: WeeChat 0.4.0]
headius has quit [Ping timeout: 276 seconds]
<bricker`work> I'm using `rand(36**10).to_s(36)` to generate a random string - however, I would like to mix in some capital letters (this method only produces lower-case letters) - what would be the best way to achieve this?
Voodoofish430 has joined #ruby
mengu has joined #ruby
altivec has joined #ruby
altivec has quit [Client Quit]
dkamioka has joined #ruby
kenneth has joined #ruby
Monie has quit [Quit: Textual IRC Client: www.textualapp.com]
<apeiros> bricker`work: Array.new(size) { Alphabet.sample }.join('')
<apeiros> also take a look at SecureRandom
<apeiros> maybe it has something that works for you
YaNakilon has joined #ruby
pwh has joined #ruby
<bricker`work> apeiros: cool! Thanks.
<bricker`work> apeiros: SecureRandom.urlsafe_base64 is perfect, thanks
Xeago has joined #ruby
timonv has joined #ruby
kindjal has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
headius has joined #ruby
Ripp__ has joined #ruby
Bosox20051 has quit [Remote host closed the connection]
sambao21 has quit [Quit: Computer has gone to sleep.]
sambao21 has joined #ruby
nemesit|znc has quit [Ping timeout: 245 seconds]
Tuxist has quit [Remote host closed the connection]
dangerousdave has quit [Quit: Leaving...]
stef1a has quit [Ping timeout: 256 seconds]
BraddPitt has joined #ruby
Quashie_ has joined #ruby
nemesit|znc has joined #ruby
reset has quit [Quit: Leaving...]
stef1a has joined #ruby
vlad_starkov has joined #ruby
solidoodlesuppor has joined #ruby
endash has joined #ruby
<platzhirsch> I want to run group_by on an array, where the grouping attribute is an array of groups. This has the result that a key will be an array of groups, but what I want is that the strings of these groups are used as a key (resulting in duplicate values of course). Any idea how I can resolve this?
reset has joined #ruby
nhhagen_ has joined #ruby
Quashie has quit [Ping timeout: 264 seconds]
<Morrolan> Do you, ahum, have sample inputs and outputs? :P
<Morrolan> Maybe it's just me, but I can't really follow you.
nhhagen_ has quit [Remote host closed the connection]
Monie_ has quit [Quit: Textual IRC Client: www.textualapp.com]
nhhagen_ has joined #ruby
<eka> pontiki: you win
robbyoconnor has joined #ruby
<platzhirsch> Morrolan: yeah, probably poorly explained
ixti has quit [Ping timeout: 276 seconds]
VTLob has joined #ruby
nhhagen has quit [Disconnected by services]
Monie has joined #ruby
nhhagen_ is now known as nhhagen
Banistergalaxy has joined #ruby
RichardBaker has joined #ruby
r0bby_ has joined #ruby
vikhyat has quit [Remote host closed the connection]
Collin has joined #ruby
<platzhirsch> input = [ { id: 1, groups: ['A', 'B'] }, { id: 2 groups: ['B']}, { id: 3, groups: ['C'] } ] now I want to group these Hashes based on their groups. With input.group_by { |doc| doc[:groups] } I get: { ['A', 'B'] => { id: 1, groups: ['A', 'B'] }, ['B'] => { id: 2 groups: ['B']}, ['C'] => { id: 3, groups: ['C'] } }
<platzhirsch> but what I want to get instead is: { 'A' => [ { id: 1 ...} ], 'B' => [ { id: 1 ... }, { id: 2 ... } ], 'C' => [ { id: 3 ... } ] }
Quashie_ is now known as Quashie
sayan has quit [Ping timeout: 240 seconds]
iliketur_ has quit [Quit: zzzzz…..]
<Morrolan> Oh, I see.
jaynewst_ has quit [Read error: Connection reset by peer]
<platzhirsch> maybe I just have to construct it myself, I was just hoping there is a shortcut
robbyoconnor has quit [Ping timeout: 256 seconds]
Klotho1 has quit [Ping timeout: 246 seconds]
<Morrolan> I'd convert each input which has more than one group to multiple inputs with one group each, then group by, then remove duplicates.
rcosta has joined #ruby
<Morrolan> But there's probably a more elegant solution.
jaynewst_ has joined #ruby
<platzhirsch> Ah cool, well that's a definitely a start for me :)
iliketur_ has joined #ruby
julweber has quit [Remote host closed the connection]
iliketur_ has quit [Client Quit]
* Morrolan fires up pry
quoin has joined #ruby
alvaro_o has joined #ruby
zets has joined #ruby
r0bby_ has quit [Ping timeout: 264 seconds]
Monie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rcosta has quit [Remote host closed the connection]
havenwood has quit [Remote host closed the connection]
ehaliewicz has quit [Remote host closed the connection]
DanKnox is now known as DanKnox_away
yalue has quit [Quit: Leaving]
havenwood has joined #ruby
<Morrolan> `input.map { |i| i[:groups].map { |group| i.merge({ :groups => group }) } }.flatten.group_by { |hash| hash[:groups] }`
r4nd0m1 has quit []
<Morrolan> (Split it up into multiline blocks for readability, only did it this way because of pry)
<Morrolan> And stay around for a little while, chances are there's better ways to do it.
julweber has joined #ruby
<platzhirsch> Morrolan: yeah, brilliant... I just wanted to start :D
<Morrolan> >> input = [{:id=>1, :groups=>["A", "B"]}, {:id=>2, :groups=>["B"]}, {:id=>3, :groups=>["C"]}]; input.map { |i| i[:groups].map { |group| i.merge({ :groups => group }) } }.flatten.group_by { |hash| hash[:groups] }
<eval-in> Morrolan => {"A"=>[{:id=>1, :groups=>"A"}], "B"=>[{:id=>1, :groups=>"B"}, {:id=>2, :groups=>"B"}], "C"=>[{:id=>3, :groups=>"C"}]} (https://eval.in/47531)
DanKnox_away is now known as DanKnox
Macaveli has joined #ruby
Macaveli has quit [Client Quit]
akells has quit [Remote host closed the connection]
ibiwan has joined #ruby
havenwood has quit [Read error: Connection reset by peer]
<Morrolan> If you want to keep the original groups inside the resulting arrays for each group_by'd key, there's some more work involved, I think.
<ibiwan> good morning. I'm trying to get an install of Dashing running (just the basic sample) and it seems like the best way to go about that is via rbenv. I have rbenv installed, but it's not using the ~/.rbenv shim for "gem" so I'm getting permissions errors when I try to install and run gems
Macaveli has joined #ruby
havenwood has joined #ruby
havenwood has quit [Read error: Connection reset by peer]
c0rn has quit [Quit: Computer has gone to sleep.]
havenwood has joined #ruby
pairup has joined #ruby
Gillo has quit [Remote host closed the connection]
<ibiwan> $ rbenv which gem: /usr/bin/gem $which gem: /home/vagrant/.rbenv/shims/gem
pwh has quit [Quit: pwh]
<ibiwan> I've already run rbenv rehash, no change.
fomatin has quit [Quit: Computer has gone to sleep.]
jonahR has joined #ruby
stef1a has quit [Ping timeout: 240 seconds]
stef1a has joined #ruby
tjad has joined #ruby
blueOxigen has quit [Ping timeout: 245 seconds]
dangerousdave has joined #ruby
<platzhirsch> Morrolan: yes, thought so
chinkung has quit [Read error: Connection reset by peer]
alexju has joined #ruby
chinkung has joined #ruby
RichardBaker has quit [Quit: RichardBaker]
vikhyat has joined #ruby
<Morrolan> Storing the original groups somewhere (e.g. in a hash, using the input's ID as key) should allow to look them up after the group_by is done.
brtdv has joined #ruby
<apeiros> dear god
<apeiros> use proper classes
* Morrolan snrks
<apeiros> it doesn't hurt, I promise!
<Morrolan> It's probably time to do that. :P
stef1a_ has joined #ruby
Monie has joined #ruby
<Morrolan> But it's hard to resist a chance to chain a few high-level functions. ;)
stef1a has quit [Ping timeout: 245 seconds]
enebo has quit [Quit: enebo]
dangerousdave has quit [Read error: Connection reset by peer]
Dave-_ has joined #ruby
c0rn has joined #ruby
buibex has joined #ruby
cascalheira has joined #ruby
cascalheira has quit [Client Quit]
cascalheira has joined #ruby
cascalheira has quit [Client Quit]
cascalheira has joined #ruby
pskosinski has joined #ruby
senayar has quit [Remote host closed the connection]
fenicks has joined #ruby
d2dchat_ has quit [Remote host closed the connection]
Ox6abe has quit [Remote host closed the connection]
jtgiri_ has quit [Quit: jtgiri_]
c0rn has quit [Quit: Computer has gone to sleep.]
ssvo has joined #ruby
stef1a_ has quit [Remote host closed the connection]
stef1a has joined #ruby
quoin has quit [Ping timeout: 245 seconds]
max has joined #ruby
max is now known as Guest1432
carlyle has quit [Remote host closed the connection]
Gillo has joined #ruby
<platzhirsch> yep, total obfuscation to the win
<Guest1432> Hello! What is the fastest solution to integrate MongoDB to Sinatra app so that I can store a json directly (not as a string, preserving the structure)??
agjacome has joined #ruby
<Morrolan> JSON *is* a string.
rcosta has joined #ruby
Dreamer3 has quit [Read error: Connection reset by peer]
Hanmac has joined #ruby
ssvo has quit [Ping timeout: 246 seconds]
iamjarvo_ has joined #ruby
iamjarvo_ has quit [Remote host closed the connection]
<Hanmac> banisterfiend: what do you think about "Gravity Falls" did you watch it?
iamjarvo has quit [Read error: Connection reset by peer]
apfelbox has joined #ruby
iamjarvo has joined #ruby
BizarreCake has quit [Ping timeout: 240 seconds]
jtgiri_ has joined #ruby
staafl has joined #ruby
decoponio has quit [Quit: Leaving...]
ryannielson has quit [Quit: ryannielson]
<Guest1432> Morrolan: I know but I was inprecise. I want to recognise this string as a JSON in particular. That's why I want to store It as a Mongo Document
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
<Guest1432> I'd love to have no schema, because the data I will be inputing will be various
tjad has quit [Ping timeout: 260 seconds]
_JamieD_ has quit [Quit: _JamieD_]
mumble has quit [Quit: WeeChat 0.4.0]
apfelbox has quit [Ping timeout: 246 seconds]
mumble has joined #ruby
c0rn has joined #ruby
<goodcodeguy> Guest1432: using the mongodb gem it should be as simple as selecting the collection and just using coll.insert(json_string)
<Guest1432> goodcodeguy: thank you, indeed are you a good guy!
Guest1432 has quit [Quit: Page closed]
fomatin has joined #ruby
Tricon has quit [Quit: Leaving...]
fomatin has quit [Max SendQ exceeded]
Elhu has quit [Quit: Computer has gone to sleep.]
Tricon has joined #ruby
ehaliewicz has joined #ruby
rcosta has quit [Remote host closed the connection]
dangerousdave has joined #ruby
Dave-_ has quit [Read error: Connection reset by peer]
c0rn has quit [Client Quit]
_JamieD_ has joined #ruby
Speed has joined #ruby
pwh has joined #ruby
lukec has quit [Quit: lukec]
mmitchell has quit [Remote host closed the connection]
buibex has quit [Remote host closed the connection]
MrThePlague has quit [Ping timeout: 256 seconds]
mmitchell has joined #ruby
mlpinit_ has joined #ruby
mumble has quit [Quit: WeeChat 0.4.0]
Catbuntu has quit [Quit: eOS is da best nigga]
r0bby_ has joined #ruby
Joska_ has quit [Quit: Joska_]
robbyoconnor has joined #ruby
Tricon has quit [Quit: Leaving...]
failshell has joined #ruby
MrThePlague has joined #ruby
MrThePlague has joined #ruby
MrThePlague has quit [Changing host]
Emmanuel_Chanel has quit [Ping timeout: 264 seconds]
rickmasta has joined #ruby
_JamieD_ has quit [Quit: _JamieD_]
mlpinit has quit [Ping timeout: 248 seconds]
dmyers has quit [Quit: dmyers]
snovak has quit [Ping timeout: 248 seconds]
Tricon has joined #ruby
colonolGron has joined #ruby
buibex has joined #ruby
jrhorn424 has joined #ruby
Emmanuel_Chanel has joined #ruby
kvirani has joined #ruby
gener1c has quit [Remote host closed the connection]
failshell has quit [Remote host closed the connection]
r0bby_ has quit [Ping timeout: 245 seconds]
failshell has joined #ruby
platzhirsch1 has joined #ruby
platzhirsch has quit [Ping timeout: 245 seconds]
robustus has quit [Ping timeout: 264 seconds]
Uranio has quit [Quit: while you reading this, a kitty dies]
ehaliewicz has quit [Read error: Connection reset by peer]
_JamieD_ has joined #ruby
bean has quit [Quit: Computer has gone to sleep.]
vlad_starkov has quit [Remote host closed the connection]
fmcgeough has quit [Quit: fmcgeough]
Elhu has joined #ruby
dawkirst has quit [Ping timeout: 260 seconds]
ehaliewicz has joined #ruby
timonv has quit [Remote host closed the connection]
robustus has joined #ruby
intuxicated has joined #ruby
Koa has quit [Ping timeout: 240 seconds]
postmodern has joined #ruby
AndChat- has quit [Quit: Bye]
kilophoton has quit [Ping timeout: 264 seconds]
Naoe-Kanno has joined #ruby
lkba has joined #ruby
jonkri has quit [Quit: jonkri]
bean has joined #ruby
mlpinit_ has quit [Remote host closed the connection]
SHyx0rmZ has quit [Ping timeout: 246 seconds]
freerobby has quit [Quit: Leaving.]
freerobby has joined #ruby
mlpinit has joined #ruby
KobraKao has joined #ruby
pwh has quit [Quit: pwh]
Collin has quit [Ping timeout: 260 seconds]
tabolario has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
iliketur_ has joined #ruby
ryandeussing has quit [Remote host closed the connection]
RichardBaker has joined #ruby
ryandeussing has joined #ruby
brianpWins has quit [Quit: brianpWins]
optimusprimem has joined #ruby
spalenza has quit [Remote host closed the connection]
snovak has joined #ruby
jonahR has quit [Quit: jonahR]
pwh has joined #ruby
kilophoton has joined #ruby
lukec has joined #ruby
brianpWins has joined #ruby
mlpinit has quit [Remote host closed the connection]
jonahR has joined #ruby
sepp2k has quit [Quit: Leaving.]
jonahR has quit [Client Quit]
pwh has quit [Client Quit]
dawkirst has joined #ruby
travish has joined #ruby
<eka> goodcodeguy: isn't as col.insert(hash_here) ?
milardovich has joined #ruby
colonolGron has quit [Ping timeout: 240 seconds]
mary5030 has quit [Ping timeout: 276 seconds]
<banisterfiend> Morrolan you know pry can gist things and add things to clipboard right?
geekbri has quit [Remote host closed the connection]
lukec has quit [Quit: lukec]
V8Energy has quit []
dodosan has quit [Remote host closed the connection]
<Morrolan> banisterfiend: I did not. :o
<banisterfiend> Morrolan let me show u bb
<Morrolan> Well, clipboard probably wouldn't have worked, I was connected to a VPS via putty, and used pry on there. But gist sounds useful. :)
<eka> banisterfiend: how is that? I want to know too.
pkrnj has joined #ruby
<goodcodeguy> eka: not sure what you are asking
<Hanmac> banisterfiend: huhuhuh
dancardamore has quit [Read error: Operation timed out]
<eka> goodcodeguy: I was just saying that instead of a json_object, you pass a hash instead?
<Morrolan> banisterfiend: Heh, nice.
<eka> banisterfiend: you need any plugin or that comes with pry?
<banisterfiend> eka need to install the 'jist' gem
enebo has joined #ruby
<banisterfiend> eka but pry will tell u do that when you try to 'gist'
<eka> banisterfiend: nice to know… thanks
<Hanmac> banisterfiend: did you watch "Gravity Falls" yet?
<banisterfiend> hanmac no u
Trufax is now known as rafer
Elhu has quit [Quit: Computer has gone to sleep.]
colonolGron has joined #ruby
<Hanmac> banisterfiend: you should watch it … and i warn you from the triangle ,P
atmosx has quit [Remote host closed the connection]
atmosx has joined #ruby
<goodcodeguy> eka: you're right :)
tealmage has joined #ruby
Elhu has joined #ruby
Elhu has quit [Client Quit]
<banisterfiend> hanmac why a triangle po
Lewis has joined #ruby
Lewis is now known as Lewix
azcodex has quit [Ping timeout: 246 seconds]
<Hanmac> banisterfiend: thats a secret :P i want you to watch it so i say something mystic to get your attention ;P
Lewix has quit [Changing host]
Lewix has joined #ruby
hashpuppy has joined #ruby
quoin has joined #ruby
carraroj has joined #ruby
maveonair has joined #ruby
AntelopeSalad has joined #ruby
<banisterfiend> hanmac are you flirting with me?
Aryasam has joined #ruby
<atmosx> banisterfiend: are you wearing a bra?
robbyoconnor has quit [Ping timeout: 245 seconds]
<Hanmac> ;P
<atmosx> does that suppose to mean "Yes, I do honey!" ?
<banisterfiend> atmosx buy more expensive binoculars and answer it yourself po
<atmosx> banisterfiend: I'm Greek, I have no money whatsoever.
<eka> what 'po' stands for?
<atmosx> banisterfiend: hence, new binocolous is not option.
tealmage has quit [Ping timeout: 240 seconds]
<banisterfiend> eka the red teletubbie
<eka> the what? where? which?
reset has quit [Quit: Leaving...]
_JamieD_ has quit [Quit: _JamieD_]
framling has quit [Quit: Lost terminal]
<hashpuppy> going blank... how can i convert a Hash of String -> List to a Hash of String -> String, where I get the first element of each list (assuming there will always be one)
framling has joined #ruby
<eka> that's po?
<eka> ok
<hashpuppy> Hash[a.group_by{|x| x.description}.map{|k, v| [k, v.first]}]
mmlac-bv has joined #ruby
<eka> are they a kind of satanist cult trying to brainwash the toddlers?
<Hanmac> banisterfiend: watch this cartoon and you will understand why you should be prepared about the triangle ;P
<eka> hanmac: anyway online to see that cartoon? (now I'm interested) :P
travish has left #ruby [#ruby]
headius has quit [Ping timeout: 245 seconds]
jprovazn has quit [Quit: Odcházím]
<Hanmac> eka, ask youtube it should have the episodes online ;P
<eka> nice guy youtube
mando has joined #ruby
randomautomator has joined #ruby
mando has quit [Remote host closed the connection]
mando has joined #ruby
<atmosx> hashpuppy: why would you want to convert a hash to a string?
<hashpuppy> i don't
colonolGron has quit [Ping timeout: 256 seconds]
<hashpuppy> I want Hash[String, List[String]] => Hash[String, String]
apfelbox has joined #ruby
jdolitsky1 has quit [Quit: Leaving.]
colonolGron has joined #ruby
tealmage has joined #ruby
<apeiros> hashpuppy: a.group_by{|x| x.description} implies a is an Array, not a Hash
ahuman has quit [Quit: No Ping reply in 180 seconds.]
ahuman_ has joined #ruby
faulkner has quit [Ping timeout: 264 seconds]
<apeiros> also, what `List`? an Array?
arusso has quit [Ping timeout: 245 seconds]
<hashpuppy> yeah, i probably could of excluded that part for this example
<hashpuppy> it is an array that I convert to a hash. it's that hash that i want to conver
<hashpuppy> apeiros: Array. sorry
DylanJ has quit [Ping timeout: 260 seconds]
arusso has joined #ruby
marius has joined #ruby
<apeiros> hashpuppy: got example input/output which is reproducable? i.e., with which one can try?
faulkner has joined #ruby
dpritchett has quit [Ping timeout: 245 seconds]
dodosan has joined #ruby
apfelbox has quit [Ping timeout: 246 seconds]
<Hanmac> eka did you find the first "GravityFalls" episode? ;P
<banisterfiend> NSFL http://imgur.com/a/YLiY2
kirun has quit [Quit: Client exiting]
<eka> hanmac: yes… but taking ages to download via bt
<eka> banisterfiend: and that's because of?
<banisterfiend> eka it says
<banisterfiend> cow head stuck in tree, soft bits eaten by dogs/coyotes over night :)
<Hanmac> eka thats why maybe YT is your friend (PS: i also loaded it as bt, but i did it in longer time)
nomenkun has joined #ruby
tealmage has quit [Ping timeout: 276 seconds]
jibi has joined #ruby
<eka> hanmac: didn't found the full episode on YT though
<eka> looking again
<eka> banisterfiend: I meant… why on earth you posted that here
axsuul has joined #ruby
<banisterfiend> eka thought it was a little bit interesting
<eka> ah ok
<eka> :P
<Hanmac> hm you are right, yt has deleted many … hm maybe i ask you later when bt is finsh
<banisterfiend> eka i wanted to share the horror
<banisterfiend> :)
<eka> hanmac: will take a day
<Hanmac> eka i needed more time with my older internet ;P
carraroj has quit [Quit: Konversation terminated!]
Monie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Hanmac> eka & banisterfiend there is the opening : http://www.youtube.com/watch?v=X2DUpDxFJyg … it would be good if you watched it later with frame-per-frame ;P
brbcoding has quit []
sambao21 has quit [Quit: Computer has gone to sleep.]
banghouse2 has joined #ruby
arusso has quit [Ping timeout: 240 seconds]
cody-- has joined #ruby
michael_mbp has quit [Ping timeout: 264 seconds]
lancepantz has quit [Ping timeout: 264 seconds]
dawkirst has quit [Read error: Operation timed out]
antulik-afk has quit [Ping timeout: 264 seconds]
rcs has quit [Ping timeout: 260 seconds]
epochwolf has quit [Ping timeout: 264 seconds]
<eka> hanmac: so at 30fps you want me to look at 1200 frames?
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
lukec has joined #ruby
Companion is now known as companion
dash_ has quit [Quit: dash_]
<shevy> I want more ruby
<shevy> more sexy ruby
zz_michael_mbp has joined #ruby
faulkner has quit [Ping timeout: 256 seconds]
<atmosx> hail shevy
zz_michael_mbp is now known as michael_mbp
<shevy> hey atmosx are you at university again?
jso_ is now known as jso
DrForr has quit [Ping timeout: 260 seconds]
arusso has joined #ruby
alex__c2022 has quit [Quit: alex__c2022]
faulkner has joined #ruby
mlpinit has joined #ruby
DrForr has joined #ruby
sambao21 has joined #ruby
rcs has joined #ruby
<Hanmac> eka, ok the picture you need to see is not in this opening, but in the episodes … you will notice what imean ;P
c0rn has joined #ruby
lancepantz_ has joined #ruby
epochwolf has joined #ruby
lancepantz_ is now known as lancepantz
antulik-afk has joined #ruby
<platzhirsch1> Morrolan: Chaining up higher-level functions is always pretty, it nearly feels like you are a great functional programming expert,... nearly.... ._.
<eka> hanmac: found another source… dding faster
vlad_starkov has joined #ruby
<atmosx> shevy: yes
<atmosx> I passed analytical chem II and phytochemistry
<atmosx> and pharmacology I
jonahR has joined #ruby
tonni has joined #ruby
<atmosx> it's going okay.
beilabs_ has quit [Ping timeout: 264 seconds]
quoin has quit [Ping timeout: 248 seconds]
hashpuppy has quit [Quit: hashpuppy]
<shevy> cool
milardovich has quit [Read error: Connection reset by peer]
dash_ has joined #ruby
relix has joined #ruby
buibex has quit [Remote host closed the connection]
alex__c2022 has joined #ruby
dmerrick has joined #ruby
<atmosx> yeap
pothibo has quit [Quit: pothibo]
<atmosx> I'm off to bed
<atmosx> nighty
thomasvs has quit [Excess Flood]
<sweeper> so you're studying to be walter white, basically?
thomasvs has joined #ruby
thomasvs has quit [Changing host]
thomasvs has joined #ruby
stef1a has quit [Ping timeout: 245 seconds]
ixti has joined #ruby
Xeago has quit [Remote host closed the connection]
stef1a has joined #ruby
atmosx has quit [Quit: Lost in trance]
kilophoton has quit [Ping timeout: 264 seconds]
<onewheelskyward> I had a coworker tell me they majored in chem in college so they could make LSD.
mark_locklear has quit [Ping timeout: 256 seconds]
<onewheelskyward> He then wrote the chemical composition of it on the whiteboard from memory.
azcodex has joined #ruby
kilophoton has joined #ruby
funburn has joined #ruby
headius has joined #ruby
<xybre> Man I've known or heard of lots of people like that.
tabolario has joined #ruby
maveonair has quit [Quit: Lost terminal]
dawkirst has joined #ruby
<Hanmac> i may remember the formulars for nuclear fusion, that does not mean i can combine atoms with my fingers ;P
Aryasam has quit [Quit: Bye]
<xybre> You can't? I thought everyone could do that.
Aryasam has joined #ruby
Monie has joined #ruby
<onewheelskyward> I just did it.
Davey has quit [Quit: Computer has gone to sleep.]
KobraKao has quit [Remote host closed the connection]
beilabs_ has joined #ruby
dodosan has quit [Remote host closed the connection]
krawchyk has quit [Remote host closed the connection]
Hanmac has quit [Quit: Leaving.]
snovak has quit [Remote host closed the connection]
crunch-choco has quit [Quit: leaving]
snovak has joined #ruby
headius has quit [Ping timeout: 240 seconds]
jtgiri_ has quit [Quit: jtgiri_]
Collin has joined #ruby
snovak has quit [Remote host closed the connection]
iliketur_ has quit [Quit: zzzzz…..]
mary5030 has joined #ruby
Kabaka has quit [Ping timeout: 240 seconds]
spider-mario has quit [Remote host closed the connection]
iamjarvo_ has joined #ruby
stef1a has quit [Ping timeout: 248 seconds]
Ch3ck_ has joined #ruby
theRoUS has quit [Ping timeout: 245 seconds]
stef1a has joined #ruby
chairabanta has quit [Quit: Leaving...]
stef1a has quit [Client Quit]
Ox6abe has joined #ruby
s0ny123 has quit [Quit: leaving]
snovak has joined #ruby
iamjarvo has quit [Ping timeout: 276 seconds]
Ch3ck_ has left #ruby ["Leaving"]
iamjarvo_ has quit [Ping timeout: 256 seconds]
Koa has joined #ruby
kaspergrubbe has joined #ruby
zarubin has quit [Ping timeout: 246 seconds]
iliketur_ has joined #ruby
kaldrenon has quit [Remote host closed the connection]
dash_ has quit [Quit: dash_]
sailias has quit [Ping timeout: 245 seconds]
kaldrenon has joined #ruby
Kabaka has joined #ruby
jdeeburke has joined #ruby
jbpros has joined #ruby
vikhyat has quit [Remote host closed the connection]
geekbri has joined #ruby
tatsuya_o has joined #ruby
dkamioka has quit [Remote host closed the connection]
funburn has quit [Quit: funburn]
Ripp__ has quit [Quit: Ripp__]
bean has quit [Quit: Computer has gone to sleep.]
kaldrenon has quit [Ping timeout: 245 seconds]
Aryasam has quit [Quit: Bye]
vlad_starkov has quit [Remote host closed the connection]
Aryasam has joined #ruby
Aryasam has quit [Client Quit]
jdeeburke has quit [Quit: Leaving.]
jdeeburke has joined #ruby
dkamioka has joined #ruby
Michael has joined #ruby
phantasm66 has joined #ruby
Michael is now known as Guest93309
mmlac-bv has quit [Quit: mmlac-bv]
geekbri has quit [Read error: Operation timed out]
catdog123 has quit [Ping timeout: 240 seconds]
jdolitsky1 has joined #ruby
Es0teric has quit [Remote host closed the connection]
machuga is now known as machuga|away
Ripp__ has joined #ruby
nomenkun has quit [Remote host closed the connection]
codecop has quit [Remote host closed the connection]
goodcodeguy has quit [Quit: Lost terminal]
rezzack has joined #ruby
geekbri has joined #ruby
geekbri has quit [Remote host closed the connection]
pwh has joined #ruby
bean has joined #ruby
ldnunes has quit [Quit: Leaving]
phantasm66 has quit [Quit: *poof*]
iliketur_ has quit [Quit: zzzzz…..]
<Andrevan> you can't make LSD very easily since it has controlled precursors
jeffreyio2 has quit [Read error: Connection reset by peer]
dodosan has joined #ruby
ner0x has quit [Quit: Leaving]
devoldmx has joined #ruby
burlyscudd has joined #ruby
mmitchell has quit [Ping timeout: 276 seconds]
seich| has quit [Ping timeout: 260 seconds]
apfelbox has joined #ruby
platzhirsch1 has quit [Quit: Leaving.]
seich- has joined #ruby
dbugger has joined #ruby
jp- has quit [Quit: OK, I believe you… but my tommy gun don't]
jdeeburke has quit [Quit: Leaving.]
jdeeburke has joined #ruby
jdeeburke has quit [Max SendQ exceeded]
<dbugger> Hi guys. Im trying to install a project on an Ubuntu system, but when I do "bundle install" I meet this error. Can someone help me please solve it? http://paste.laravel.com/PyM
jdeeburke has joined #ruby
jdeeburke has quit [Max SendQ exceeded]
kvirani has quit [Remote host closed the connection]
jdeeburke has joined #ruby
<bean> dbugger: "sudo apt-get install build-essential"
kvirani has joined #ruby
<dbugger> bean, it is already installed
mikepack_ has quit [Remote host closed the connection]
<bean> dbugger: oh right, you need the "dev" package for whatever ruby version you have
<bean> apt-get install ruby1.8-dev
<bean> etc
nemesit|znc has quit [Ping timeout: 260 seconds]
gyre007 has quit [Ping timeout: 245 seconds]
apfelbox has quit [Ping timeout: 245 seconds]
<dbugger> bean, also installed
jlast has quit [Remote host closed the connection]
PandaSan has joined #ruby
kvirani has quit [Remote host closed the connection]
kvirani_ has joined #ruby
PandaSan has left #ruby [#ruby]
jlast has joined #ruby
Monie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
T__T is now known as T_T
Gillo has quit [Remote host closed the connection]
huoxito has joined #ruby
interactionjaxsn has quit [Remote host closed the connection]
nari has joined #ruby
tylersmith has quit [Remote host closed the connection]
iliketur_ has joined #ruby
interactionjaxsn has joined #ruby
tylersmith has joined #ruby
jtgiri_ has joined #ruby
thesheff17_ has joined #ruby
<bean> dbugger: are you're sure its the right one for the ruby version you're using?
zarubin has joined #ruby
thesheff17 has quit [Disconnected by services]
thesheff17_ is now known as thesheff17
breakingthings has quit []
T_T has quit []
geggam_ has quit [Remote host closed the connection]
macro1 has joined #ruby
interactionjaxsn has quit [Ping timeout: 240 seconds]
byprdct has joined #ruby
tylersmith has quit [Ping timeout: 245 seconds]
byprdct has quit [Max SendQ exceeded]
T_T has joined #ruby
<dbugger> bean, good call. Im using 1.9.3p194
pr0ggie has quit [Ping timeout: 264 seconds]
<bean> so you probably need ruby1.9-dev
cody-- has quit [Quit: Computer has gone to sleep.]
<dbugger> bean, the problem is that the only package available is 1.9.1-dev
<dbugger> will that work?
<bean> should
<dbugger> even if one is 19.3 and the other 1.9.1?
<bean> 1.9.1-dev is just a meta package that refers to the 1.9 line of ruby on ubuntu
<bean> its dumb but thats how it works
<dbugger> Ok, ill try<
quoin has joined #ruby
<MrZYX> 1.9.1 is the ABI version of the 1.9 series
cody-- has joined #ruby
<dbugger> What is ABI?
<bean> ^
<bean> Application Binary Interface
<dbugger> I see. I am running the install. Fingers crossed
kayloos has joined #ruby
DrCode has quit [Remote host closed the connection]
pairup has quit [Read error: Connection reset by peer]
byprdct has joined #ruby
<dbugger> Wonderful! You guys rock!
byprdct has quit [Max SendQ exceeded]
Flashmasterson1 has joined #ruby
<bean> np
byprdct has joined #ruby
<dbugger> Thanks guys
michaellynch has quit [Quit: michaellynch]
BillCriswell has quit [Remote host closed the connection]
mieczyk has quit [Quit: Wychodzi]
pr0ggie has joined #ruby
greenride has joined #ruby
freerobby has quit [Quit: Leaving.]
DrCode has joined #ruby
samsagaz has quit [Remote host closed the connection]
randomdrake has quit [Quit: randomdrake]
danman has quit [Quit: danman]
m_3 has quit [Remote host closed the connection]
claymore has quit [Quit: Leaving]
jbpros has quit [Quit: jbpros]
maz-dev has quit [Remote host closed the connection]
failshell has quit [Ping timeout: 256 seconds]
randomdrake has joined #ruby
azcodex has quit [Ping timeout: 245 seconds]
osvico has joined #ruby
ixti has quit [Read error: Connection reset by peer]
shadoi has quit [Quit: Leaving.]
shadoi has joined #ruby
Guest93309 has quit [Remote host closed the connection]
ixti has joined #ruby
nemesit|znc has joined #ruby
<Flashmasterson1> how do i register an rvm nickname/username?
ibiwan has left #ruby [#ruby]
fcahoon has joined #ruby
oseifrimpong has joined #ruby
<oseifrimpong> hello guys
tealmage has joined #ruby
<oseifrimpong> hello guys
thoraxe_ is now known as thoraxe
cody-- has quit [Quit: Computer has gone to sleep.]
volty has joined #ruby
zarubin has quit [Remote host closed the connection]
rickmasta has quit [Read error: Connection reset by peer]
colonolGron has quit [Quit: leaving]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<volty> hi, a simple tone generator ?
<MrZYX> mmh, sox?
rickmasta has joined #ruby
quoin has quit [Ping timeout: 245 seconds]
SHyx0rmZ has joined #ruby
ixti has quit [Ping timeout: 240 seconds]
ixti_ has joined #ruby
<volty> MrZYX: thx, now looking at it, i remember i was generating data and writing to /dev/psp (or /dev/audio) but 1) no direct access now to those devices 2) can't remember in what lang i was doing that
peregrine81 has quit []
ehc has joined #ruby
<MrZYX> sox is virtually everywhere installed, so it might be a good fit
Naoe-Kanno has quit [Ping timeout: 240 seconds]
zarubin has joined #ruby
jefflyne2 has quit [Ping timeout: 264 seconds]
twoism has quit [Remote host closed the connection]
twoism has joined #ruby
twoism has quit [Read error: Connection reset by peer]
jdeeburke has quit [Quit: Leaving.]
twoism has joined #ruby
jdeeburke has joined #ruby
fcahoon has quit [Quit: Leaving]
Ox6abe has quit [Remote host closed the connection]
azcodex has joined #ruby
bean has quit [Quit: Computer has gone to sleep.]
Michael has joined #ruby
m_3 has joined #ruby
kaspergrubbe has quit [Remote host closed the connection]
Michael is now known as Guest10724
mmlac-bv has joined #ruby
MrZYX is now known as MrZYX|off
jerius has quit [Ping timeout: 240 seconds]
jdeeburke has quit [Ping timeout: 245 seconds]
enebo has quit [Quit: enebo]
apeiros has quit [Remote host closed the connection]
pairup has joined #ruby
kaspergrubbe has joined #ruby
Ox6abe_ has joined #ruby
Tricon has quit [Quit: Linkinus - http://linkinus.com]
MrZYX|off is now known as MrZYX
vlad_starkov has joined #ruby
mansi has quit [Remote host closed the connection]
mansi has joined #ruby
asobrasil has left #ruby [#ruby]
solidoodlesuppor has quit [Remote host closed the connection]
kayloos has quit [Remote host closed the connection]
erry has left #ruby [#ruby]
rdxc has quit [Quit: Textual IRC Client: www.textualapp.com]
alex__c2022 has quit [Quit: alex__c2022]
mlpinit has quit [Remote host closed the connection]
vlad_starkov has quit [Ping timeout: 276 seconds]
mansi has quit [Ping timeout: 245 seconds]
snovak has quit [Remote host closed the connection]
mlpinit has joined #ruby
kvirani_ has quit [Remote host closed the connection]
kvirani has joined #ruby
pentameter has quit [Read error: Connection reset by peer]
tjbiddle has joined #ruby
kvirani has quit [Read error: Connection reset by peer]
kvirani_ has joined #ruby
alexju has quit [Ping timeout: 264 seconds]
Flashmasterson1 has quit [Quit: Leaving.]
mlpinit has quit [Remote host closed the connection]
pwh has quit [Quit: pwh]
snath has quit [Ping timeout: 276 seconds]
lusory has joined #ruby
snovak has joined #ruby
elux has quit [Quit: Leaving...]
DylanJ has joined #ruby
hurrrtin has quit [Quit: Leaving.]
apfelbox has joined #ruby
Ox6abe_ has quit [Remote host closed the connection]
duggiefresh has joined #ruby
snovak has quit [Remote host closed the connection]
nomenkun has joined #ruby
Davey has joined #ruby
gusnasis has quit [Quit: Computer has gone to sleep.]
joast has quit [Quit: Leaving.]
Guest10724 has quit [Remote host closed the connection]
joast has joined #ruby
byprdct has quit [Read error: Connection reset by peer]
apfelbox has quit [Ping timeout: 246 seconds]
klaut has joined #ruby
narcan has joined #ruby
nomenkun has quit [Ping timeout: 276 seconds]
kaspergrubbe has quit [Remote host closed the connection]
zacts has quit [Quit: leaving]
carlyle has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
rads has joined #ruby
nari has quit [Ping timeout: 260 seconds]
dankest has quit [Quit: dankest]
klaut has quit [Remote host closed the connection]
ewnd9 has joined #ruby
ewnd9 has quit [Remote host closed the connection]
diegoviola has quit [Ping timeout: 245 seconds]
VTLob has quit [Quit: VTLob]
ewnd9 has joined #ruby
jefflyne2 has joined #ruby
mikepack has joined #ruby
kvirani_ has quit [Remote host closed the connection]
kvirani has joined #ruby
diegoviola has joined #ruby
brtdv has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
RORgasm has quit [Remote host closed the connection]
tealmage has quit [Remote host closed the connection]
dv_ has quit [Ping timeout: 256 seconds]
mary5030 has quit [Ping timeout: 256 seconds]
kvirani_ has joined #ruby
kvirani has quit [Read error: Connection reset by peer]
tylersmith has joined #ruby
tylersmith has quit [Ping timeout: 256 seconds]
pkrnj has quit [Quit: Computer has gone to sleep.]
sambao21 has quit [Ping timeout: 245 seconds]
tomzx_mac has joined #ruby
jaimef has quit [Excess Flood]
kilophoton has quit [Ping timeout: 256 seconds]
ixti_ has quit [Ping timeout: 248 seconds]
sambao21 has joined #ruby
kaspergrubbe has joined #ruby
nari has joined #ruby
parzo has quit [Ping timeout: 260 seconds]
maz-dev has joined #ruby
jaimef has joined #ruby
mmlac-bv has quit [Quit: mmlac-bv]
Anarch has joined #ruby
ixti_ has joined #ruby
quoin has joined #ruby
snovak has joined #ruby
zacts has joined #ruby
nari has quit [Ping timeout: 245 seconds]
m8 has quit [Quit: Sto andando via]
Michael has joined #ruby
Michael is now known as Guest85185
mikepack has quit [Remote host closed the connection]
tatsuya_o has quit [Remote host closed the connection]
maz-dev has quit [Remote host closed the connection]
ewnd9 has quit [Remote host closed the connection]
snovak has quit [Ping timeout: 248 seconds]
gstamp has joined #ruby
jonahR has quit [Quit: jonahR]
staafl has quit [Read error: Connection reset by peer]
eldios has joined #ruby
sailias has joined #ruby
<eldios> hey guys.. I'm trying to read *one* character via commandline with ruby 2.0.0
<eldios> any hint?
<eldios> I was trying "choice = getc"
<eldios> though that's not working unfortunately
ner0x has joined #ruby
ixti_ has quit [Ping timeout: 245 seconds]
<MrZYX> try STDIN.getc
twoism has quit [Read error: Connection reset by peer]
<eldios> let's see
<shevy> it wants enter too though
ixti_ has joined #ruby
twoism has joined #ruby
Bira has joined #ruby
funburn has joined #ruby
funburn has quit [Client Quit]
funburn has joined #ruby
dangerousdave has quit [Ping timeout: 264 seconds]
oseifrimpong has quit [Ping timeout: 250 seconds]
emergion has joined #ruby
razi has quit [Ping timeout: 248 seconds]
mando has quit [Remote host closed the connection]
<havenwood> eldios: require 'io/console'; choice = STDIN.getch
rhys has quit [Quit: Leaving]
<eldios> mm yes getc works though it requires Enter
<eldios> I think I'll need the io/console
GeissT has joined #ruby
<eldios> let's try again with that
<eldios> works
<eldios> thanks guys ^_^
<eldios> thanks havenwood
fridim_ has joined #ruby
dmerrick_ has joined #ruby
allanm_ has joined #ruby
havenn has joined #ruby
sarkis has quit [Ping timeout: 264 seconds]
tjbiddle_ has joined #ruby
havenn is now known as havenwood_
dodosan_ has joined #ruby
tonni_ has joined #ruby
rodasc has joined #ruby
Davey_ has joined #ruby
neonlex has joined #ruby
dmerrick has quit [Read error: Connection reset by peer]
allanm has quit [Read error: Connection reset by peer]
havenwood has quit [Read error: Connection reset by peer]
Davey has quit [Read error: Connection reset by peer]
tonni has quit [Read error: Connection reset by peer]
a13x212 has quit [Read error: Connection reset by peer]
dodosan has quit [Read error: Connection reset by peer]
mrsolo has quit [Read error: Connection reset by peer]
tjbiddle has quit [Read error: Connection reset by peer]
crodas has quit [Quit: Disconnecting from stoned server.]
mrsolo has joined #ruby
tjbiddle_ is now known as tjbiddle
mroth has quit [Ping timeout: 256 seconds]
brjannc has quit [Ping timeout: 256 seconds]
ckrailo has quit [Ping timeout: 256 seconds]
samuelkadolph has quit [Ping timeout: 256 seconds]
jezen has joined #ruby
quoin has quit [Ping timeout: 264 seconds]
havenwood_ is now known as havenwood
a13x212 has joined #ruby
Guest85185 has quit [Read error: Connection reset by peer]
dankest has joined #ruby
jibi has quit [Quit: .]
pel_daniel has left #ruby [#ruby]
freerobby has joined #ruby
NedsFlam has joined #ruby
Nex7 has quit [Ping timeout: 256 seconds]
pwh has joined #ruby
samuelkadolph has joined #ruby
Nex7 has joined #ruby
brjannc has joined #ruby
jtgiri_ has quit [Quit: jtgiri_]
dankest has quit [Client Quit]
danman has joined #ruby
dbugger has quit [Quit: Leaving]
neonlex has quit []
<shevy> wheee
ephemerian has left #ruby [#ruby]
apeiros has joined #ruby
<Collin> Keeping in mind that I'm not very good at Ruby: I have a native extension with a function 'encode' takes a block, which should return a string of data to be encoded. The block will be called over and over, until the Ruby code alerts that there is no more data to encode. Is a block the right thing to use here?
kaspergrubbe has quit [Remote host closed the connection]
<shevy> huh
<shevy> havenwood, when using this with cursor keys, subsequent calls to STDIN.getch seem to get the last char
<shevy> like arrow up:
<shevy> "\e"
<shevy> "["
<shevy> "A"
<shevy> very strange, as if it is silently buffered somewhere
<shevy> Collin why not use an argument to a method?
kvirani_ has quit [Remote host closed the connection]
<Collin> shevy: I'm not sure what you mean
gyre007 has joined #ruby
kvirani has joined #ruby
<Collin> I'm doing something like: Encoder::encode() { input.read(32) }
MrThePlague has quit [Remote host closed the connection]
<shevy> where from comes input
<Collin> Anywhere
<shevy> no, I mean in your case
nettoweb has joined #ruby
<Collin> I have no case, it's a library. I just need the Ruby code to provide something I can call to get the next piece of data.
<shevy> if you put that code you just showed for ruby to evaluate, it would fail
reset has joined #ruby
<Collin> Probably, I don't write Ruby :(
sailias has quit [Ping timeout: 276 seconds]
<shevy> yes, I assume in your code you have a class or module called Encode
<shevy> and a method to it called encode
c0rn has quit [Quit: Computer has gone to sleep.]
apeiros has quit [Ping timeout: 246 seconds]
<Collin> Yes, I have a module Encoder and a method encode
seoNinjaWarrior has joined #ruby
ukd1 has joined #ruby
<shevy> but in the example you gave, I have no idea what the "input." is
<volty> so the problem is how to call the passed block
<Collin> I can call the passed block from native code, but I'm wondering if a block for this is un-Ruby-like
<shevy> ok, the code would not fail
<shevy> but it would not be evaled
<Collin> Or if there is something that makes more sense
<seoNinjaWarrior> I'm making changes to a file i required in IRB. Is there a way to reload it so I don't' have to close out of IRB, reopen, and require again?
<shevy> Collin every method in ruby optionally accepts a block
<havenwood> seoNinjaWarrior: Pry is great for such things: http://pryrepl.org/
tabolario has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<shevy> in your example, you do not seem to eval your block Collin
<shevy> seoNinjaWarrior you could do: load 'foo.rb' where foo.rb is the name
<shevy> or you can define a bunch of extra methods in your .irbrc file
<volty> shevy: input doesn't matter, he needs to call the block and get back what it returns (a stream)
ehaliewicz has quit [Remote host closed the connection]
apfelbox has joined #ruby
pairup has quit [Quit: I'm asleep.]
ehc has quit [Quit: ehc]
<shevy> volty ok from where does he get input?
<volty> can block be called from c?
jtgiri_ has joined #ruby
<Collin> Yes, I can yield from C
<shevy> most likely, there must be a method that does it
lfox has quit [Quit: ZZZzzz…]
<volty> { myarray.next(30) } { source[0..200] }
dv_ has joined #ruby
robbyoconnor has joined #ruby
kvirani has quit [Ping timeout: 276 seconds]
<volty> whatever, he needs to return an array ov values to c
<Collin> But my primary question is 'Does using a block like this to get the next piece of input make sense to a Ruby programmer?'
tjbiddle_ has joined #ruby
c0rn has joined #ruby
<shevy> to me your code makes no sense
<volty> for me it makes sense, given that you return the "input" in a proper structure for the c part to handle
Koa has quit [Ping timeout: 260 seconds]
<shevy> 2 people, 2 different replies ;)
<shevy> beware of the time when you ask 2 people and get 5 replies
<onewheelskyward> That's a low average for #ruby
<volty> :) i like his approach
<shevy> most are probably idling to power here
nettoweb has quit [Quit: nettoweb]
<shevy> one day we will crack the 1000 idlers here
<Collin> Alright, I'll stick with this, then
freerobby has quit [Quit: Leaving.]
<shevy> #perl is at 650
<shevy> #python at 1297 ... :(
<Collin> I was just afraid using something like the IO (is that what it's called?) object would be more Ruby-like
<volty> Collin: it's perfect if you can implement it well, quite universal
snovak has joined #ruby
ixti_ has quit [Read error: Connection reset by peer]
predator217 has joined #ruby
apfelbox has quit [Ping timeout: 246 seconds]
tjbiddle has quit [Ping timeout: 240 seconds]
tjbiddle_ is now known as tjbiddle
<volty> you can call whatever IO (and ELSE) from you block - more universal
<volty> just implement it this way and (think and) change later
DonRichie has quit [Read error: Connection reset by peer]
tjad has joined #ruby
<shevy> hehe
<shevy> I like that you put the part think in ()
<volty> a case: let's say you have another extension where the input comes from ... ok? with that block you can adjust the output on-the-fly, otherwise you have to implement an IO object
<shevy> you see Collin, you should sometimes (think) too
<volty> ahah
cody-- has joined #ruby
DonRichie has joined #ruby
snovak has quit [Read error: Operation timed out]
<volty> no no, implement block, and later an io TOO - the best, for the best, for both of us :)
carlyle has quit [Remote host closed the connection]
ixti_ has joined #ruby
predator117 has quit [Ping timeout: 268 seconds]
<volty> another argument in favor of block is : STEP BY STEP (chi va piano va sano e va lontano - italian)
kilophoton has joined #ruby
gusnasis has joined #ruby
<Collin> Ah, I just ran into a problem, that being that I actually need to pass two blocks
<volty> what's the sense of idling beyond being a measure of respective language idlers ? :)
<Collin> One to retrieve data from Ruby, and one to pass processed data back to Ruby
<Collin> It's not possible to give two blocks, is it?
<volty> yes, it is
<MrZYX> not two blocks, but you can pass two procs or a block and a proc
<volty> def (params, &b1, &b2)
<volty> MrZYX is more precise
<Collin> I see, so &b1 and &b2 are procs
alekst has quit [Quit: Leaving...]
<MrZYX> that's just a syntax error, no matter if defining or calling a method
<volty> collin, how about only a block with a param signaling if input / ouput ?
<Collin> I could also do that, if it makes sense
<MrZYX> when defining it &b captures a block as proc, when calling &b passes a proc as block
ixti_ has quit [Read error: Connection reset by peer]
rburton- has joined #ruby
<shevy> oh man
ffranz has quit [Quit: Leaving]
<MrZYX> I'd say do a class, store both procs inside it
ixti_ has joined #ruby
<Collin> Hm, seems I can't get procs in native code
<Collin> I guess I'll have to go with a block with an in/out flag, regardless
<MrZYX> then you can have an API like encoder = Encoder.new; encoder.input do stuff; end; encoder.output do stuff; end; encoder.do_it_already
<MrZYX> and also accept the procs as argument to initialize etc
<MrZYX> an in out flag just makes the calling code unreadable as hell
<MrZYX> even requiring the caller to subclass would be a better option IMO
duggiefresh has quit [Remote host closed the connection]
gusnasis has quit [Ping timeout: 256 seconds]
tylersmith has joined #ruby
zeade has quit [Quit: Leaving.]
ehc has joined #ruby
ryandeussing has quit [Remote host closed the connection]
<volty> case in; when :in ...; when :out ... end // - let him refactor after - make sure all is running properly - maybe he leaves that block (with in/out) as a choice
<volty> i like blocks! God, i like them!
<volty> :)
<Collin> Is a proc actually a class?
<Collin> I see a Proc class, but I'm not sure if that's what you guys are talking about
<Collin> Er, an instance of a class
ics has joined #ruby
<jezen> hey guys, first night of playing with ruby
<MrZYX> pretty much everything in ruby is an object, thus has a class, but that's not what I'm referring to
<MrZYX> I'm saying you should make your API a class, not only a single method
elux has joined #ruby
<jezen> when creating a file, I know I can do f = File.new('filename.ext', 'w')
dkamioka has quit [Remote host closed the connection]
<jezen> but why can’t I do f = File.new('dir/filename.ext', 'w')?
<volty> jezen: good for you :)
<volty> jezen: probably because there' s no such a 'dir'
jp- has joined #ruby
<MrZYX> jezen: what exception are you getting?
<jezen> the directory already exists
<volty> or you have no rights there
stewart_ has joined #ruby
Nisstyre-laptop has joined #ruby
tealmage has joined #ruby
<pontiki> can you create the file outside of ruby?
jaimef has quit [Excess Flood]
<pontiki> touch dir/filename.ext
<jezen> I have rights to the directory
<jezen> I can create it manually
<jezen> I don’t get an exception at runtime
<pontiki> then there is no reason you can't do it with ruby
<jezen> hmm
<jezen> :/
Nisstyre-laptop is now known as nisstyre
<MrZYX> everybody, why do let him get away with not showing the exception? ;)
<pontiki> if you paste *real* code, maybe someone can help
<volty> jezen: check your wd
<jezen> MrZYX: There is no exception thrown :)
<jezen> I think I’ve realised the problem
<volty> (first night with ruby .... and risking to remain virgin ....)
<jezen> my ruby code is ok
<MrZYX> then "doesn't work" is a very bad problem description ;)
<jezen> but Jekyll is removing the file after I’ve created it
<stewart_> how does ruby determine the order of the array returned by Module.constants?
<jezen> I’m trying to write a file generator for Jekyll
<volty> maybe he just didn't run his script :)
sergicles has quit [Quit: sergicles]
<jezen> my script ran
<shevy> stewart_ hmm good question... I would say most important entries come first
<pontiki> good hacking
<Eiam> hmm
<jezen> as I said, it worked if I didn’t try running it in the subdir
<stewart_> shevy: I am not sure about that because it seems to change from system to system
michaellynch has joined #ruby
<shevy> hmm
<shevy> my first entries are: [:Object, :Module, :Class, :BasicObject, :Kernel,
<Eiam> is there a better way of mapping an object into a hash aside from Hash[[1,2,3,4].map {|a,b| [a,b]}] ?
<Eiam> i dunno why I find myself doing this fairly regularly
michaellynch has quit [Client Quit]
tealmage has quit [Ping timeout: 245 seconds]
<pontiki> each_cons(2), maybe, dunno if that's "better" or not
<Eiam> or even just [1,2,3,4].map{|a,b| [a,b]}.flatten
<shevy> Eiam you want to create {1=>nil, 2=>nil, 3=>nil, 4=>nil} ?
<Eiam> shevy: no, [1=>2,3=>4]
Davey_ is now known as Davey
<shevy> hmm but your code gave me this...
<Eiam> [{1=>2},{3=>4}]
<shevy> anyway
<shevy> Hash[*1,2,3,4] # => {1=>2, 3=>4}
<shevy> oh
<shevy> in an array
<MrZYX> I think you can save the splat
<stewart_> shevy: so we have a namespace for all of our systems models however that list of models seems to return an a different order form system to system. These models are included via a script that loops all files in a folder… I wonder if constants are returned in the order that they where included in which would be determined by the order that ruby iterates over files in the original include script
<Eiam> yeah, usually I've got an array, that i end up mapping then converting back into a Hash after a flatten or other weird stuff
<shevy> [Hash[*1,2,3,4]] # => [{1=>2, 3=>4}]
<shevy> oh yes
<Eiam> whenever I start slamming down.blah.blah.blah i feel like I've gone wrong
<shevy> [Hash[1,2,3,4]] # => [{1=>2, 3=>4}]
<shevy> no
<shevy> I am still wrong...
<havenwood> >> Hash[1,2,3,4]
<eval-in> havenwood => {1=>2, 3=>4} (https://eval.in/47544)
<havenwood> Eiam: ^ no need to map
<Boohbah_> >> a="5\nKernel\nMicrocontroller\nRegister\nMemory\nOperator".split[1..-1];$;="";puts a.map!{|m|m+" "*(a.map(&:size).max-m.size)}.map(&:split).transpose.map(&:join)
<eval-in> Boohbah_ => KMRMO ... (https://eval.in/47545)
jaimef has joined #ruby
<Eiam> havenwood: not the greatest example but I am mutating the data first, but I am mutating it to put it into a hash
<shevy> Eiam I realized that whenever possible I want to make the data structures as simple as possible... if only to make my brain have to work less hard
<Boohbah_> how can i golf it down? :)
<Eiam> it just so happens there doesn't seem to be a mutate into Hash
<Eiam> like.. map hash
<volty> stewart_: why do you feel need to wonder? something specific?
<Eiam> maybe .inject({})
<shevy> ok let me understand it again
<shevy> you need:
<shevy> from 1,2,3,4 to [{1=>2},{3=>4}]
<shevy> yes ?
iliketur_ has quit [Quit: zzzzz…..]
<shevy> "1,2,3,4" to [{1=>2},{3=>4}] ?
eldios has left #ruby ["http://quassel-irc.org - Chat comfortably. Anywhere."]
<Eiam> I need to take a subset of data thats already stored in an array, pull out that data, and make it into a Hash instead
<Eiam> I think array.inject({}) is made for that
<Boohbah_> does nobody want to golf with me? :)
[[thufir]] has joined #ruby
<shevy> I hate golfing
hamakn has joined #ruby
<jezen> I can golf js
<shevy> I'd have to find out what ;$; means
<Eiam> shevy: yes, your example is one way of phrasing in a small way what I find myself doing
<jezen> but I don’t anymore since I became a disgusting hipster and started everything in coffeescript
unixninja92 has quit [Quit: unixninja92]
hamakn has quit [Read error: Connection reset by peer]
* Boohbah_ threatens to go to #perl
<Boohbah_> shevy: $; is the input field separator
jrhorn424 has quit [Quit: Textual IRC Client: www.textualapp.com]
<Eiam> .inject or map + Hash[]
hamakn has joined #ruby
<Boohbah_> i feel like the max() part in the middle could be shorter
<Eiam> i feel slightly less weird now
<volty> Eiam: why don't you give us an example of input and expected output ?
unixninja92 has joined #ruby
nhhagen has quit [Remote host closed the connection]
<shevy> we have that volty
<shevy> "1,2,3,4" to [{1=>2},{3=>4}]
nhhagen has joined #ruby
<Eiam> well, %w{1 2 3 4} yeah
<shevy> I fail at the part inside the []
<volty> but he was talking about 'subsets'
pkrnj has joined #ruby
<shevy> yes... 2 entries become a hash
<Eiam> volty: that just over complicates the example
hamakn has quit [Remote host closed the connection]
<Boohbah_> shevy: i set $; to empty string so i can do map(&:split) later to split on empty string
hamakn has joined #ruby
ryandeussing has joined #ruby
pkrnj has quit [Client Quit]
unixninja92_ has joined #ruby