fflush changed the topic of #ruby to: Ruby 1.9.3-p194: http://ruby-lang.org || Paste > 3 lines of text on pastebin.com
irleif has quit [Client Quit]
macmartine has quit [Quit: Computer has gone to sleep.]
verto is now known as verto|off
bmxpert1 has quit [Remote host closed the connection]
lggr has joined #ruby
Goles has quit [Ping timeout: 245 seconds]
v0n has joined #ruby
hotovson_ has quit [Remote host closed the connection]
chrishunt has quit [Ping timeout: 244 seconds]
Trioke has joined #ruby
ddv has quit [Ping timeout: 240 seconds]
bbttxu_ has joined #ruby
gh has joined #ruby
greenarrow has quit [Quit: IRC is just multiplayer notepad]
ffranz has quit [Ping timeout: 240 seconds]
wpaulson has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
gregorg_taf has joined #ruby
gregorg_taf has quit [Read error: Connection reset by peer]
vitoravelino is now known as vitoravelino`afk
<Spooner> blazes816 (And thus aces1up) I think you meant: server_data = @settings.each_with_object({}) {|(var, var_args), data| data[var] = var_args[:value] }
hotovson has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
ddv has joined #ruby
<blazes816> Spooner: good call sir, thanks
Synthead has quit [Quit: p33 ba115]
`gregorg` has quit [Ping timeout: 256 seconds]
<Spooner> blazes816 It is an hour too late, so not terribly useful, but I am bored ;)
freakazoid0223 has quit [Read error: Connection reset by peer]
gh has quit [Quit: gh]
hsbt_away is now known as hsbt
nari has quit [Read error: Operation timed out]
gregorg_taf has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
lggr has joined #ruby
Tearan has quit [Quit: Sleepy Badger....]
rburton- has quit [Quit: Linkinus - http://linkinus.com]
Lady_Blue_33 has joined #ruby
timonv has quit [Remote host closed the connection]
hotovson has quit [Ping timeout: 245 seconds]
carlyle has joined #ruby
BSaboia has joined #ruby
<Trioke> Super noob question, but is there any difference to defining a class method with the "self." keyword as opposed to not using that keyword?
Guedes has quit [Disconnected by services]
DGuedes is now known as Guedes
Guedes has quit [Changing host]
Guedes has joined #ruby
Guedes0 has joined #ruby
whowantstolivefo has quit []
<waxjar> not using self. defines an instance method
<Spooner> Trioke : If you mean the difference between "class << self; def x" and "def self.x" then there is no difference.
lggr has quit [Ping timeout: 256 seconds]
Lady_Blue_33 has left #ruby [#ruby]
AuroraX has quit [Quit: Leaving]
jeffreybaird has joined #ruby
roadt has joined #ruby
lggr has joined #ruby
judd7_ has joined #ruby
carlyle has quit [Remote host closed the connection]
thunderstrike has joined #ruby
BSaboia has quit [Quit: Fui embora]
bricker has quit [Ping timeout: 260 seconds]
judd7_ has quit [Client Quit]
verto|off is now known as verto
judd7 has quit [Ping timeout: 245 seconds]
<Trioke> Spooner: Actually, I had what waxjar answered in mind. Thanks to both of you, though :).
gmci has quit [Ping timeout: 260 seconds]
d2dchat has quit [Remote host closed the connection]
dpk has quit []
ffranz has joined #ruby
nateberkopec has joined #ruby
blazes816 has quit [Quit: blazes816]
lggr has quit [Ping timeout: 260 seconds]
whaley has joined #ruby
manizzle_ has quit [Ping timeout: 260 seconds]
ryanf has joined #ruby
lggr has joined #ruby
thunders_ has joined #ruby
nwertman has quit [Quit: nwertman]
gmci has joined #ruby
thunderstrike has quit [Ping timeout: 255 seconds]
thunders_ has quit [Client Quit]
thunderstrike has joined #ruby
ckrailo has quit [Quit: Computer has gone to sleep.]
werdnativ has quit [Ping timeout: 256 seconds]
lggr has quit [Ping timeout: 255 seconds]
dagnachewa has quit [Remote host closed the connection]
havenn has joined #ruby
jerrad has quit [Quit: Linkinus - http://linkinus.com]
Xeago has quit [Remote host closed the connection]
kringa has joined #ruby
cascalheira has quit [Quit: Linkinus - http://linkinus.com]
dmiller has joined #ruby
lggr has joined #ruby
dagnachewa has joined #ruby
arietis has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
dmiller_ has quit [Ping timeout: 252 seconds]
Bosma has quit [Quit: leaving]
yshh_ has quit [Remote host closed the connection]
tothehilt has joined #ruby
manizzle_ has joined #ruby
fflush has joined #ruby
lggr has quit [Ping timeout: 264 seconds]
samuel02 has joined #ruby
hgf has quit [Quit: hgf]
slainer68 has joined #ruby
`brendan has joined #ruby
mmitchell has joined #ruby
JonnieCache has joined #ruby
hgf has joined #ruby
dagnachewa has quit [Quit: Leaving]
crankycoder is now known as vng|afk
sent-hil has joined #ruby
lggr has joined #ruby
nateberkopec has quit [Quit: Linkinus - http://linkinus.com]
Foxandxss has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
samuel02 has quit [Ping timeout: 246 seconds]
slainer68 has quit [Ping timeout: 260 seconds]
STyler has quit [Quit: STyler]
nitti has joined #ruby
mmitchell has quit [Ping timeout: 245 seconds]
ffranz has quit [Ping timeout: 260 seconds]
zeromodu_ has joined #ruby
horofox has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
yshh has joined #ruby
JonnieCache has quit [Ping timeout: 276 seconds]
cakehero has quit [Quit: Computer has gone to sleep.]
kaawee has quit [Quit: Konversation terminated!]
zeromodulus has quit [Ping timeout: 248 seconds]
nitti has quit [Ping timeout: 256 seconds]
reset has quit [Quit: Leaving...]
vitoravelino`afk is now known as vitoravelino
lggr has joined #ruby
jeffreybaird has quit [Quit: jeffreybaird]
fflush has quit [Quit: Colloquy for iPad - http://colloquy.mobi]
Spooner has quit [Ping timeout: 245 seconds]
freezway has joined #ruby
<freezway> is there a way to split a string in two at a specified position?
jeff_sebring has joined #ruby
<freezway> like hello.splitFunc(3) -> ["hel", "lo"]
triskt has joined #ruby
cakehero has joined #ruby
thunderstrike has quit [Ping timeout: 256 seconds]
tiripamwe has quit [Ping timeout: 240 seconds]
rakunHo has joined #ruby
<waxjar> #slice does that, i believe
<sent-hil> freezway: "hello".byteslice(0..3)
<waxjar> nope, don't listen to me :p
fermion has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
stopbit has quit [Quit: Leaving]
<sent-hil> AFAIK slice! removes the specified chars
<sent-hil> you can use #split to split at a specified letter
Asher has quit [Read error: Connection reset by peer]
Asher1 has joined #ruby
Asher1 has quit [Client Quit]
Asher has joined #ruby
<sent-hil> "hello".split('e') #=> ['h', 'llo']
<sent-hil> ofcourse that removes the specified letter
rabidpraxis has joined #ruby
lggr has quit [Ping timeout: 244 seconds]
<freezway> sent-hil, i need to split at a specific spot
<freezway> and there will be repeats
<freezway> im splitting a 16bit binary # into two 8 bit binary #'s
ryanlecompte has quit [Remote host closed the connection]
nwertman has joined #ruby
codeFiend has joined #ruby
lggr has joined #ruby
<waxjar> if the length of the string is always the same, you could do something like first, second = string[0..8], string[9..16]
brianpWins has joined #ruby
marienz has quit [Remote host closed the connection]
gry has quit [Remote host closed the connection]
<whaley> or something like first, second = s[0..n], s[n+1..s.size]
<whaley> assuming n isn't larger than s.size, I think
<freezway> true, was hoping for some handier (i just started learning ruby, not familiar with 90% of the functions) but i guess these nothing handy for that
<whaley> (basically waxjar's answer)
gry has joined #ruby
<heftig> when it's acceptable to modify the original string, slice!
freakazoid0223 has joined #ruby
<heftig> prefix = str.slice!(0,8)
<heftig> will slice the first 8 characters into prefix, leaving the rest in str
mmitchell has joined #ruby
<waxjar> if you're going to assign it to a variable, you don't need the bang version right?
cbuxton has joined #ruby
rabidpraxis has quit [Remote host closed the connection]
<heftig> waxjar: the return value of the bang version isn't unimportant
<heftig> str = "foobar"; prefix = str.slice!(0,3); afterwards, prefix is "foo" and str is "bar"
lggr has quit [Ping timeout: 240 seconds]
jenrzzz has quit [Ping timeout: 240 seconds]
Asher1 has joined #ruby
punkrawkR has quit [Read error: Connection reset by peer]
<waxjar> ash, clever. i expected it to just return nil
AlbireoX`Laptop has joined #ruby
<waxjar> *aah
cakehero has quit [Quit: Computer has gone to sleep.]
lggr has joined #ruby
tiripamwe has joined #ruby
|Monie| has joined #ruby
sent-hil has quit [Remote host closed the connection]
shadoi has quit [Ping timeout: 245 seconds]
seanyo has joined #ruby
cbuxton has quit [Quit: Leaving.]
frogprince has quit []
reset has joined #ruby
hgf has left #ruby [#ruby]
quest88 has joined #ruby
rabidpraxis has joined #ruby
Jamone has quit [Ping timeout: 260 seconds]
cxz has quit [Ping timeout: 260 seconds]
Monie has joined #ruby
Monie has joined #ruby
Monie has quit [Changing host]
irleif has joined #ruby
werdnativ has joined #ruby
cxz has joined #ruby
Asher has quit [*.net *.split]
dakine has quit [*.net *.split]
AlbireoX has quit [*.net *.split]
|Monie| has quit [Ping timeout: 244 seconds]
lggr has quit [Ping timeout: 245 seconds]
cardoni has joined #ruby
lggr has joined #ruby
marcux has quit [Ping timeout: 246 seconds]
dakine has joined #ruby
fyolnish_ has quit [Remote host closed the connection]
mxweas has joined #ruby
tothehilt has quit [Remote host closed the connection]
adkron has quit [Quit: leaving]
mrsolo has quit [Quit: Leaving]
jlwestsr has joined #ruby
<freezway> my friend showed me a way to quickly create an array of numbers from a to b, sorta like (a..b) whats the syntax for that
zeromodulus has joined #ruby
cbuxton has joined #ruby
zeromodu_ has quit [Ping timeout: 256 seconds]
<bperry> freezway: x = [1.99]
<bperry> er
SegFaultAX|work has quit [Quit: leaving]
<bperry> x = [1..99]
<bperry> should result in [1, 2, 3, 4....99]
lggr has quit [Ping timeout: 276 seconds]
<bperry> [] is array in ruby
<freezway> hmm not working
<bperry> x = [] is an empty array
<bperry> what doe sit give you?
<freezway> if I say
fmcgeough has quit [Quit: fmcgeough]
<freezway> puts [1..8] its displays 1..8
<freezway> erm [1..8]
<bperry> hmm
lggr has joined #ruby
<freezway> i thinks its an array of size 1
<elektronaut> (1..99).to_a maybe?
<freezway> cuz [1..99].size gives me 1
tjbiddle has quit [Ping timeout: 245 seconds]
<freezway> tried that
Lemon|mbp has left #ruby [#ruby]
wedtm is now known as wedtm|away
<elektronaut> (1..8).to_a => [1, 2, 3, 4, 5, 6, 7, 8]
<elektronaut> 1..8 is a Range object
xjiujiu_ has joined #ruby
<freezway> ah, thank you
<bperry> ah sorry
joeycarmello has joined #ruby
rabidpraxis has quit [Remote host closed the connection]
cakehero has joined #ruby
rabidpraxis has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
jeffreybaird has joined #ruby
dmiller has quit [Ping timeout: 246 seconds]
jrist-afk is now known as jrist
dmiller has joined #ruby
whaley has quit [Remote host closed the connection]
postmodern has joined #ruby
lggr has joined #ruby
slainer68 has joined #ruby
cardoni has quit [Quit: cardoni]
artnez has quit [Quit: artnez]
rabidpraxis has quit [Ping timeout: 260 seconds]
jeff_sebring has quit [Quit: Leaving]
dblandin has left #ruby [#ruby]
dblandin has joined #ruby
<mercwithamouth> is there a gem to set up a basic ruby project for you?
SpeedTheory2 is now known as RyanD
Orcris has quit [Ping timeout: 245 seconds]
slainer68 has quit [Ping timeout: 265 seconds]
nitti has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
dblandin has left #ruby [#ruby]
dblandin has joined #ruby
mikepack has quit [Remote host closed the connection]
dblandin has quit [Quit: dblandin]
nitti has quit [Ping timeout: 256 seconds]
lggr has joined #ruby
mmitchell has quit [Remote host closed the connection]
Jello_Raptor has joined #ruby
kringa has quit [Ping timeout: 260 seconds]
<Jello_Raptor> there has got to be a better way to generate a set of rake tasks from a file lists than this http://pastebin.com/yANKiBjr
<Jello_Raptor> other than the obvious simplifications, is ther anything better than just using eval?
justsee has joined #ruby
ttt has joined #ruby
Ruler_Of_Heaven_ has quit [Ping timeout: 256 seconds]
pipopopo has joined #ruby
netrealm has quit [Ping timeout: 276 seconds]
fyolnish_ has joined #ruby
cbuxton has quit [Quit: Leaving.]
jenrzzz has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
CaptainJet has quit []
pipopopo has quit [Ping timeout: 240 seconds]
kpshek has joined #ruby
pipopopo has joined #ruby
lggr has joined #ruby
nari has joined #ruby
mikepack has joined #ruby
Jake232 has quit [Quit: Computer has gone to sleep.]
<Jello_Raptor> :w
<Jello_Raptor> \leave
Jello_Raptor has left #ruby [#ruby]
kpshek has quit [Ping timeout: 246 seconds]
triskt has quit [Ping timeout: 256 seconds]
lggr has quit [Ping timeout: 240 seconds]
BadLarry has quit [Ping timeout: 246 seconds]
aknagi has quit [Ping timeout: 260 seconds]
BadLarry has joined #ruby
lggr has joined #ruby
GoGoGarrett has joined #ruby
<GoGoGarrett> I know i've seen it before, is there a way to dynamically assign variables in ruby? Isn't it something like send("attribute=", 1)
Takehiro_ has joined #ruby
apok has quit [Ping timeout: 240 seconds]
swarley has joined #ruby
jeffreybaird has quit [Quit: jeffreybaird]
iori has joined #ruby
adeponte has quit [Remote host closed the connection]
vaxgeek has quit [Read error: Connection reset by peer]
tjbiddle has joined #ruby
sorbo_ has joined #ruby
seanyo has quit [Read error: Connection reset by peer]
Trioke has quit [Ping timeout: 260 seconds]
lggr has quit [Ping timeout: 255 seconds]
marknyc has joined #ruby
rabidpraxis has joined #ruby
alecchen has joined #ruby
radic has quit [Disconnected by services]
radic_ has joined #ruby
lggr has joined #ruby
ffranz has joined #ruby
locriani has quit [Remote host closed the connection]
<swarley> 1 + 1 = 3
aknagi has joined #ruby
<swarley> (1.4).round + (1.4).round == (2.8).round
jeffreybaird has joined #ruby
wmoxam has quit [Quit: leaving]
<swarley> Not true but whatever
<swarley> 1.4 + 1.4 = 2.8
<swarley> Round them all and you get 1 + 1 = 3
skaczor has quit [Ping timeout: 240 seconds]
Takehiro_ has quit [Remote host closed the connection]
sent-hil has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
The5thWall has joined #ruby
samuel02 has joined #ruby
kn330 has quit [Ping timeout: 256 seconds]
lggr has joined #ruby
aknagi has quit [Quit: Leaving]
beefsupreme has joined #ruby
samuel02 has quit [Ping timeout: 265 seconds]
iamjarvo has joined #ruby
bjeanes has joined #ruby
starship has quit [Killed (holmes.freenode.net (Nickname regained by services))]
drago757 has joined #ruby
Guest21929 has joined #ruby
CaptainKnots has joined #ruby
CaptainKnots has quit [Changing host]
CaptainKnots has joined #ruby
justsee has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 240 seconds]
bbttxu_ has quit [Quit: bbttxu_]
lggr has joined #ruby
slainer68 has joined #ruby
RJ3000_ has quit [Ping timeout: 246 seconds]
Takehiro_ has joined #ruby
sorbo_ has quit [Quit: sorbo_]
nitti has joined #ruby
Takehiro_ has quit [Remote host closed the connection]
slainer68 has quit [Ping timeout: 260 seconds]
lggr has quit [Ping timeout: 245 seconds]
Cool_Fire has joined #ruby
<Cool_Fire> Hello
xpen has joined #ruby
alvaro_o has quit [Quit: Ex-Chat]
savage- has joined #ruby
<Cool_Fire> Does anyone know a way how to change what Readline tab-completes depending on the rest of the line?
havenn has quit [Remote host closed the connection]
<Cool_Fire> I want to to tab complete commands, but once a command is on the input line, I want it to tab complete arguments to that command.
flip_digits has joined #ruby
baroquebobcat has joined #ruby
lggr has joined #ruby
nitti has quit [Ping timeout: 245 seconds]
kringa has joined #ruby
_Luis_Carlos_ has joined #ruby
tiripamwe has quit [Ping timeout: 245 seconds]
jakk_ is now known as jakk
kringa has quit [Read error: Connection reset by peer]
kringa has joined #ruby
ElderFain has joined #ruby
justsee has joined #ruby
cibs has joined #ruby
jakk has left #ruby [#ruby]
krz has joined #ruby
AMfish has joined #ruby
ElderFain_ has quit [Ping timeout: 272 seconds]
codeFiend has quit [Ping timeout: 256 seconds]
JonnieCache has joined #ruby
codeFiend has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
_7894 has joined #ruby
<_Luis_Carlos_> asdad
_Luis_Carlos_ has left #ruby ["Saliendo"]
Beoran has quit [Read error: Operation timed out]
Monie has quit [Ping timeout: 244 seconds]
uris has joined #ruby
lggr has joined #ruby
Gal3rielol has joined #ruby
swarley has quit []
mmitchell has joined #ruby
Guedes has quit [Ping timeout: 276 seconds]
philcrissman has joined #ruby
kringa has quit [Ping timeout: 260 seconds]
mmitchell has quit [Ping timeout: 245 seconds]
drago757 has quit [Quit: drago757]
brianpWins has quit [Read error: Connection reset by peer]
brianpWins has joined #ruby
bigmcq77 has quit [Quit: Textual IRC Client: www.textualapp.com]
lggr has quit [Ping timeout: 272 seconds]
nwertman has quit [Quit: nwertman]
ElderFain_ has joined #ruby
ElderFain has quit [Read error: Connection reset by peer]
jgrevich has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
bigmcq77 has joined #ruby
drule is now known as darule
tiripamwe has joined #ruby
savage- has quit [Quit: .]
hadees has quit [Quit: hadees]
wpaulson has joined #ruby
wpaulson has quit [Client Quit]
Beoran has joined #ruby
artnez has joined #ruby
ryanlecompte has joined #ruby
AMfish has quit [Ping timeout: 245 seconds]
BrianJ has joined #ruby
neurotech has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
duracrisis is now known as Guest69113
Guest69113 has quit [Killed (card.freenode.net (Nickname regained by services))]
Guest69113 has joined #ruby
xyzodiac has quit [Quit: Computer has gone to sleep.]
lggr has joined #ruby
jenrzzz has quit [Ping timeout: 245 seconds]
Spaceghost|cloud has joined #ruby
cxz has quit [Read error: Connection reset by peer]
marknyc has quit []
philcrissman has quit [Remote host closed the connection]
iamjarvo has quit [Ping timeout: 244 seconds]
lggr has quit [Ping timeout: 248 seconds]
bapa has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
nwertman has joined #ruby
verto is now known as verto|off
thinkclay has joined #ruby
lggr has joined #ruby
neurotech has quit [Remote host closed the connection]
flip_digits has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
x82_nicole has quit [Quit: Computer has gone to sleep.]
havenn has joined #ruby
cj3kim has joined #ruby
adeponte has joined #ruby
elsifaka has quit [Read error: Connection reset by peer]
elsifaka has joined #ruby
jeffreybaird has quit [Quit: jeffreybaird]
havenn has quit [Ping timeout: 245 seconds]
starship has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
iamjarvo has joined #ruby
JonnieCache has quit [Ping timeout: 244 seconds]
QKO has quit [Read error: Connection reset by peer]
havenn has joined #ruby
QKO has joined #ruby
lggr has joined #ruby
locriani has joined #ruby
joeycarmello has quit [Remote host closed the connection]
thinkclay has quit [Quit: Leaving.]
shiki has joined #ruby
Dreamer3 has quit [Quit: Leaving...]
codeFiend has left #ruby [#ruby]
RJ3000_ has joined #ruby
bbttxu_ has joined #ruby
sent-hil has quit [Remote host closed the connection]
slainer68 has joined #ruby
lggr has quit [Ping timeout: 252 seconds]
joeycarmello has joined #ruby
bbttxu_ has quit [Client Quit]
nitti has joined #ruby
slainer68 has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
RJ3000_ has quit [Ping timeout: 246 seconds]
kringa has joined #ruby
joeycarmello has quit [Remote host closed the connection]
nitti has quit [Ping timeout: 260 seconds]
codeFiend has joined #ruby
mercwithamouth has quit [Ping timeout: 252 seconds]
lggr has quit [Ping timeout: 256 seconds]
voodoofish430 has quit [Quit: Leaving.]
lggr has joined #ruby
horofox has quit [Quit: horofox]
wallerdev has joined #ruby
aeontech has joined #ruby
RJ3000_ has joined #ruby
iamjarvo has quit [Ping timeout: 260 seconds]
Synthead has joined #ruby
GoHuyGo has joined #ruby
codeFiend has quit [Ping timeout: 246 seconds]
aeontech is now known as codeFiend
lggr has quit [Ping timeout: 255 seconds]
starship has quit [Quit: WeeChat 0.3.2]
harushimo has joined #ruby
lggr has joined #ruby
reset has quit [Ping timeout: 240 seconds]
<harushimo> i'm back
jrist is now known as jrist-afok
jrist-afok is now known as jrist-afk
brianpWins has quit [Quit: brianpWins]
freezey has joined #ruby
c0rn_ has joined #ruby
justsee has quit [Quit: Leaving...]
<freezey> if i had data stored in a db as whatever0 - whatever50 .. and i wanted to create an array for all and do a var.foreach how would i create the array to read all of the data i have stored?
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
lggr has quit [Ping timeout: 272 seconds]
uris has quit [Quit: Lost terminal]
wedtm|away is now known as wedtm
lggr has joined #ruby
snorkdude has joined #ruby
snorkdude has quit [Remote host closed the connection]
samuel02 has joined #ruby
tiripamwe has quit [Ping timeout: 245 seconds]
tiripamwe has joined #ruby
peregrine81 has quit [Quit: Computer sleeping.]
lggr has quit [Ping timeout: 256 seconds]
samuel02 has quit [Ping timeout: 248 seconds]
gry has left #ruby ["Leaving"]
lggr has joined #ruby
fboudreau has joined #ruby
<harushimo> I need to preserve the word in the output. how would I do that
<harushimo> if I'm given that type of data set
<harushimo> I can probably use a downcase. method too
bluOxigen has joined #ruby
<havenn> harushimo: you can drop the quotes when you use %w: %w[Dad dad Dad] #=> ["Dad", "dad", "Dad"]
<harushimo> I didn't know thank you
c0rn_ has quit [Ping timeout: 272 seconds]
<harushimo> what if I want all them to be lower case word
<havenn> harushimo: %w[Dad dad Dad].map &:downcase #=> ["dad", "dad", "dad"]
burgestrand has quit [Quit: Leaving.]
Dreamer3 has joined #ruby
<harushimo> oh I shouldn't do it inside function
<harushimo> I'm calling combine anagram on it
c0rn_ has joined #ruby
<harushimo> forget it
<harushimo> I understand it now
lggr has quit [Ping timeout: 260 seconds]
syamajala has joined #ruby
<harushimo> since I passed it as a parameter, it is already changing
joofsh has quit [Remote host closed the connection]
lggr has joined #ruby
cakehero has quit [Quit: Computer has gone to sleep.]
nwertman has quit [Quit: nwertman]
<Cool_Fire> freezey: var = mySQLObject.query("SELECT `key` FROM invites WHERE `key` = '" + key + "'")
<Cool_Fire> I'm fairly sure you can foreach a mysql resultset
<freezey> Cool_Fire: yeah.. the data is coming from facter
lggr has quit [Ping timeout: 246 seconds]
<freezey> thats my only thing
<freezey> trying to figure out how i can do this
syamajala has quit [Remote host closed the connection]
<freezey> Cool_Fire: thanks though
gogiel has quit [Remote host closed the connection]
<bperry> whoa serious sql injection vuln there
<bperry> don't do that ever
<krz> with 'foo:a:bar:b:baz:c' how would i parse through this. so if i wanted the value for foo. it would return a. and for bar, it would return b. so forth
<bperry> or make sure key is sanitized :)
<Cool_Fire> Oh yeah, that's not in a script subject to unsanitized input :p
<bperry> krz: a b c are odd numbers in that if you break it up
v0n has quit [Ping timeout: 260 seconds]
<bperry> split on : and loop, when i %2 == 0 you have a, b , or c
mahmoudimus has quit [Quit: Computer has gone to sleep.]
bapa_ has joined #ruby
<bperry> er
lggr has joined #ruby
<bperry> er i%2 == 1
<freezey> yeah problem is i have another store grabbing data out of rb files and it created whatever0 - whatever50 and i need to pull that into a value
bapa has quit [Ping timeout: 244 seconds]
<krz> bperry: i need to get individual values. not all of them though
<bperry> then loop through each and put the values in a hash
beefsupreme has quit [Remote host closed the connection]
<bperry> and use the same modulus test to figure out what goes where
<Cool_Fire> krz: I would split the whole thing into an array and then Hash[*array_var]
<bperry> i%2 == 0 -> key
<bperry> i%2 == 1 -> value
<harushimo> do I need to change my %w to get expected result
<krz> hm good suggestions
<bperry> that might work too
hadees has joined #ruby
nitti has joined #ruby
Gal3rielol has left #ruby ["Textual IRC Client: http://www.textualapp.com/"]
hadees has quit [Client Quit]
<harushimo> any suggestions which route I should take
<Spaceghostc2c> The one less traveled.
<krz> all roads lead to rome. any route should be fine
<Cool_Fire> Both terrible advices :p
<bperry> bring a towel
<krz> the longer route, for the scenic view. otherwise what Spaceghostc2c said
<Spaceghostc2c> Cool_Fire: How would you know?
<harushimo> haha
<Cool_Fire> The one less traveled is probably less traveled for a good reason. And not all roads lead to Rome, and if they did, some routes would still be much longer and less pleasant than others.
nitti has quit [Ping timeout: 260 seconds]
rabidpraxis has quit [Remote host closed the connection]
<harushimo> I was thinking of a solution to my program
<harushimo> hehe
<krz> sometimes getting lost is fun
<harushimo> yeah it is
<harushimo> hehe
rabidpraxis has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
<Cool_Fire> It's usually not terribly productive though :p
<krz> i would suggest apple maps for getting lost
bapa_ has quit [Ping timeout: 276 seconds]
<harushimo> i was reading on the web apple is heavily recruiting ex google mappers
<harushimo> to create the map for them
<harushimo> I mean map app for them
<Cool_Fire> Lol, makes sense
<harushimo> it does
vitoravelino is now known as vitoravelino`afk
<harushimo> I'm struggling with this last part of my program
<harushimo> I don't know why
<Spaceghostc2c> Cool_Fire: How would you know if you only traveled the well-worn paths?
<harushimo> any guidance would be great
<Spaceghostc2c> How will you ever innovate or ever find something true to yourself if you only follow the popular agenda?
lggr has joined #ruby
quest88 has quit [Quit: quest88]
otters has quit [Ping timeout: 245 seconds]
<krz> harushimo: you can do it. stick with the program. your almost done with it. don't give up
rabidpraxis has quit [Ping timeout: 245 seconds]
<harushimo> I'm not
<harushimo> I did this
<krz> harushimo: its tough getting through AA. but your on your last stretch
<harushimo> I know
<harushimo> I can't get the expected results at all
<Cool_Fire> Spaceghostc2c: True, but how will you ever get ahead if you keep reinventing the wheel?
<Spaceghostc2c> Cool_Fire: I'm afraid that you've gone and failed the Frost test.
<harushimo> its really bugging me
<Spaceghostc2c> Cool_Fire: How can you reinvent a wheel that has not been traveled?
bapa has joined #ruby
<harushimo> do I need to change my grouping
<Cool_Fire> This is getting a little abstract now :p
irleif has quit [Quit: Computer has gone to sleep.]
<Spaceghostc2c> Cool_Fire: Just sayin'.
<Cool_Fire> I'm gonne go microwave some food instead.
<Cool_Fire> Anyway, you don't always have to travel a path to be able to know something about it
<Cool_Fire> You can gather information from others that have traveled it. And you can use binoculars and see at least part of the path and where it leads.
<krz> its like a rocking chair. it gives you something to do, but doesn't get you anywhere
<Cool_Fire> If your rocking chair doesn't go anywhere, you're not rocking hard enough :p
<Cool_Fire> Seriously though, I'm starving over here. bbl.
<krz> this ruby conversation was just starting to get fun
ananthakumaran has joined #ruby
<bperry> your face is starving
<krz> its ruby relevant right?
<krz> sometimes we make hard choices in ruby
<harushimo> krz: I give up
<harushimo> I'm done
<harushimo> I can't figure it out
joeycarmello has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
<krz> dont give up. throw your bottle away and stick with your AA class
<krz> stick with the program
<harushimo> oh man..this is a small bug to which I can't figure out
<harushimo> I have really looked at it
lggr has joined #ruby
<havenn> harushimo: what is the bug?
joeycarmello has quit [Ping timeout: 245 seconds]
<harushimo> it isn't giving my expected results
vitor-br has joined #ruby
<harushimo> I just found this
<harushimo> why is that happening?
ffranz has quit [Quit: Leaving]
wedtm is now known as wedtm|away
<bperry> why do you think the two LL's should be capped?
<bperry> nothing in your code lends to that
g-ram has joined #ruby
<harushimo> ok
tiripamwe has quit [Ping timeout: 256 seconds]
<harushimo> I'm downcaseing the letters
lggr has quit [Ping timeout: 240 seconds]
<harushimo> ok
<harushimo> why isn't putting the [["JeLLo"," jello"]]
<havenn> harushimo: In the original, it is "Jello" and you don't change it.
ananthakumaran has quit [Quit: Leaving.]
<harushimo> It should be have changed. that's my fault
<harushimo> I messed that test case up
<harushimo> I changed it and re ran the test
<harushimo> it is coming out as two seperate
Liothen has joined #ruby
lggr has joined #ruby
<harushimo> that is totally my fault
burgestrand has joined #ruby
<harushimo> I want to know where my thinking is going wrong
Banistergalaxy has joined #ruby
<bperry> welcome to being a programmer :)
<Banistergalaxy> Thx bperry
<Banistergalaxy> U2
GoHuyGo has quit [Quit: Leaving]
<bperry> no u
SmoothSage_ has joined #ruby
SmoothSage_ has quit [Read error: Connection reset by peer]
zmisc has joined #ruby
<harushimo> thank you
colinbm has joined #ruby
<harushimo> i thought meant me
tjbiddle has quit [Quit: tjbiddle]
SmoothSage has quit [Read error: Connection reset by peer]
<harushimo> I'm still working on this
<harushimo> I just want to what route I should change
\n is now known as nyuszika7h
<harushimo> havenn: I'm working on it here. do I need to change anything
zmisc has quit [Client Quit]
yxhuvud has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
SmoothSage has joined #ruby
colinbm has quit [Quit: colinbm]
lggr has joined #ruby
Banistergalaxy has quit [Ping timeout: 256 seconds]
awestroke has joined #ruby
red_ has joined #ruby
jenrzzz has joined #ruby
Banistergalaxy has joined #ruby
no_worries has quit [Remote host closed the connection]
tiripamwe has joined #ruby
hemanth has quit [Read error: Connection reset by peer]
ABK has joined #ruby
hemanth has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
g_bleezy has quit [Remote host closed the connection]
eldariof has joined #ruby
tagrudev has joined #ruby
lggr has joined #ruby
iori has quit [Remote host closed the connection]
Guest69113 has quit [Quit: Leaving]
justsee has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 252 seconds]
freezway has quit [Ping timeout: 245 seconds]
sagax has joined #ruby
fboudreau has quit [Ping timeout: 245 seconds]
The5thWall has quit [Quit: Zzzzzzzzzzzzz]
lggr has joined #ruby
mahmoudimus has joined #ruby
justsee has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
ananthakumaran has joined #ruby
BrianJ has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
nitti has joined #ruby
parzorep has joined #ruby
<parzorep> Hey all, is there an easy way I can convert a string like "July 24, 2012" to a date format?
JonnieCache has joined #ruby
luckyruby has joined #ruby
lggr has quit [Ping timeout: 265 seconds]
tiripamwe has quit [Quit: Leaving]
<krz> ['day:20121011:video:1:user:1', 'day:20121011:video:1:user:2', 'day:20121011:video:2:user:1'] how can i group by day and video?
<krz> so far I've tried: ['day:20121011:video:1:user:1', 'day:20121011:video:1:user:2', 'day:20121011:video:2:user:1'].group_by(&:downcase).map {|k,v| [k, v.length]}
nitti has quit [Ping timeout: 245 seconds]
<parzorep> bperry: Thanks, I didn't know strftime handled anything other than numbers from all the examples I looked at.
lggr has joined #ruby
<ryanlecompte> krz: something like this: a.group_by { |e| e.split(':').values_at(1,3) }
mahmoudimus has quit [Quit: Computer has gone to sleep.]
samuel02 has joined #ruby
AlbireoX has joined #ruby
<krz> interesting. thanks
<harushimo> alright everyone, I'm exhausted. I'm heading to bed
<harushimo> take care
AlbireoX`Laptop has quit [Read error: Connection reset by peer]
advorak has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
c0rn_ has quit [Quit: Computer has gone to sleep.]
Mon_Ouie has quit [Ping timeout: 245 seconds]
babinho_ has quit [Quit: leaving]
babinho has joined #ruby
babinho_ has joined #ruby
harushimo has quit [Quit: Leaving]
reset has joined #ruby
lggr has joined #ruby
babinho is now known as Guest67437
Guest67437 has quit [Killed (sturgeon.freenode.net (Nickname regained by services))]
babinho_ is now known as babinho
<krz> ryanlecompte: any reason why ['day:20121011:video:1:user:1', 'day:20121011:video:1:user:2', 'day:20121011:video:2:user:1'].group_by { |e| e.split(':').values_at(1,3) }[0] returns nil?
<krz> I'm trying to parse through the results
<ryanlecompte> krz: try that in an irb session
<ryanlecompte> krz: without the [0] at the end
<ryanlecompte> krz: #group_by returns a hash
dmiller has quit [Remote host closed the connection]
brianpWins has joined #ruby
monkegjinni has joined #ruby
emergion has joined #ruby
<krz> ryanlecompte: yea, but shouldn't i be able to get the first element in the hash with [0] ?
babinho_ has joined #ruby
<krz> hmmm actually not. might have to iterate via an .each
<ryanlecompte> krz: no, [0] will try to find an element with a key of 0
babinho has quit [Quit: leaving]
babinho_ is now known as babinho
cakehero has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
vitor-br has quit [Quit: Saindo]
a_a_g has joined #ruby
emergion has quit [Ping timeout: 256 seconds]
rippa has joined #ruby
cakehero has quit [Client Quit]
cakehero has joined #ruby
lggr has joined #ruby
aganov has joined #ruby
maesbn has joined #ruby
kyletcarey has quit [Ping timeout: 244 seconds]
lggr has quit [Ping timeout: 256 seconds]
prtksxna has joined #ruby
rostisla_ has joined #ruby
thinkclay has joined #ruby
thinkclay has quit [Remote host closed the connection]
stephenjudkins has quit [Quit: stephenjudkins]
hotovson has joined #ruby
mahmoudimus has joined #ruby
lggr has joined #ruby
maesbn has quit [Read error: Connection reset by peer]
maesbn has joined #ruby
tjbiddle has joined #ruby
xorgnak has joined #ruby
daniel_hinojosa has quit [Quit: Leaving.]
Morkel has joined #ruby
bapa has quit [Ping timeout: 256 seconds]
fixl has joined #ruby
xorgnak has quit [Read error: No route to host]
lggr has quit [Ping timeout: 276 seconds]
und3f has joined #ruby
xorgnak has joined #ruby
lggr has joined #ruby
Elhu has joined #ruby
bapa has joined #ruby
AMfish has joined #ruby
lggr has quit [Ping timeout: 272 seconds]
g-ram has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
ryanlecompte has quit [Remote host closed the connection]
lggr has joined #ruby
bapa has quit [Read error: Connection reset by peer]
bapa has joined #ruby
freezey has quit [Quit: freezey]
rippa has quit [Ping timeout: 260 seconds]
dmiller has joined #ruby
AMfish has quit [Ping timeout: 256 seconds]
awestroke has quit [Remote host closed the connection]
monkegjinni has quit [Ping timeout: 240 seconds]
zommi has joined #ruby
slainer68 has joined #ruby
lggr has quit [Ping timeout: 240 seconds]
Elhu has quit [Quit: Computer has gone to sleep.]
ryanf has quit [Ping timeout: 246 seconds]
workmad3 has joined #ruby
mikepack has quit [Remote host closed the connection]
tonini has joined #ruby
nitti has joined #ruby
lggr has joined #ruby
codeFiend has quit [Quit: codeFiend]
<shevy> krz positions like [0] or [5] usually are used for arrays, but hashes are more flexible and could use such keys too. arrays are simpler though, they are like a dumb container
slainer68 has quit [Ping timeout: 252 seconds]
Criztian has joined #ruby
nightfalcon has joined #ruby
monkegjinni has joined #ruby
jprovazn_away is now known as jprovazn
chussenot has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
dmiller has quit [Remote host closed the connection]
monkegjinni has joined #ruby
nitti has quit [Ping timeout: 245 seconds]
_mak has quit [Remote host closed the connection]
cj3kim has quit [Quit: This computer has gone to sleep]
_mak has joined #ruby
tjbiddle has quit [Quit: tjbiddle]
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
Asher1 has quit [Read error: Connection reset by peer]
Asher has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
parzorep has quit [Ping timeout: 276 seconds]
sqbell_ has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
Asher has quit [Client Quit]
monkegjinni has joined #ruby
Asher has joined #ruby
_mak has quit [Remote host closed the connection]
thone_ has joined #ruby
cj3kim has joined #ruby
lggr has joined #ruby
advorak has quit [Quit: Leaving]
Criztian has quit [Read error: Connection reset by peer]
JonnieCache has quit [Ping timeout: 240 seconds]
hadees has joined #ruby
arkiver has joined #ruby
thone has quit [Ping timeout: 245 seconds]
advorak has joined #ruby
monkegjinni has quit [Read error: No route to host]
workmad3 has quit [Ping timeout: 256 seconds]
monkegjinni has joined #ruby
ryanf has joined #ruby
timonv has joined #ruby
_mak has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
monkegjinni has quit [Read error: Connection reset by peer]
arkiver has quit [Client Quit]
monkegjinni has joined #ruby
Criztian has joined #ruby
chussenot has quit [Quit: chussenot]
lggr has joined #ruby
zigomir has joined #ruby
heftig has quit [Quit: leaving]
margle has joined #ruby
awestroke has joined #ruby
Jrz has joined #ruby
greenarrow has joined #ruby
dr_bob has joined #ruby
Sp4rKy_ is now known as Sp4rKy
rabidpraxis has joined #ruby
Sp4rKy has quit [Changing host]
Sp4rKy has joined #ruby
arturaz has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
Criztian_ has joined #ruby
advorak has quit [Quit: This computer has gone to sleep]
robustus has joined #ruby
Criztian has quit [Ping timeout: 260 seconds]
eldariof has quit []
Averna has joined #ruby
lggr has joined #ruby
rabidpraxis has quit [Ping timeout: 248 seconds]
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
dhruvasagar has joined #ruby
cakehero has quit [Quit: Computer has gone to sleep.]
lggr has quit [Ping timeout: 252 seconds]
chichou has joined #ruby
TomRone has quit [Ping timeout: 260 seconds]
Xeago has joined #ruby
Virunga has joined #ruby
Elhu has joined #ruby
lggr has joined #ruby
TomRone has joined #ruby
xbayrockx has joined #ruby
TomJ has quit [Quit: TomJ]
jck_true_ is now known as Jck_true
sspiff has joined #ruby
rakl has joined #ruby
piotr_ has joined #ruby
jlwestsr has quit [Ping timeout: 246 seconds]
nightfalcon has quit [Quit: Lost terminal]
Xeago has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 245 seconds]
Synthead has quit [Read error: Connection reset by peer]
arkiver has joined #ruby
justsee has quit [Quit: Leaving...]
Xeago has joined #ruby
lggr has joined #ruby
chussenot has joined #ruby
sepp2k has joined #ruby
chimay has joined #ruby
GoGoGarrett has quit [Read error: Connection reset by peer]
GoGoGarrett has joined #ruby
tjbiddle has joined #ruby
reset has quit [Quit: Leaving...]
KevinSjoberg has joined #ruby
chussenot has quit [Client Quit]
tjbiddle_ has joined #ruby
w2f2 has joined #ruby
xorgnak has quit [Excess Flood]
_7894 has quit [Read error: Connection reset by peer]
_7894 has joined #ruby
tjbiddle has quit [Ping timeout: 240 seconds]
tjbiddle_ is now known as tjbiddle
xbayrockx has quit [Ping timeout: 276 seconds]
lggr has quit [Ping timeout: 260 seconds]
chussenot has joined #ruby
sspiff has quit [Remote host closed the connection]
<rostisla_> hi
<rostisla_> tell me please - i can write this code *puts "MC975" 2475 * 1.05*
sspiff has joined #ruby
sspiff has quit [Changing host]
sspiff has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegji_ has joined #ruby
lggr has joined #ruby
<rostisla_> i need to ruby text output and thought the number
<rostisla_> ?
<havenn> rostisla_: Not sure what you're trying to do. If you want to print MC... and the result on separate lines: puts "MC975", 2475 * 1.05
davidcelis has quit [Ping timeout: 256 seconds]
nitti has joined #ruby
abionic has joined #ruby
<rostisla_> havenn ok i try now
mahmoudimus has quit [Quit: Computer has gone to sleep.]
ABK_ has joined #ruby
<rostisla_> havenn i need output to a single line
tjbiddle has quit [Quit: tjbiddle]
<havenn> rostisla_: puts "MC975 #{2475 * 1.05}"
<Xeago> rostisla_: follow a tutorial please
<rostisla_> havenn thanks
<Xeago> How do I get rid of the ugly $1 $2
<Xeago> if key.to_s.match(/(.*)_(#{matchers_in_regexp_form})$/)
<Xeago> grouped_params[$2.to_sym][$1.to_sym] = value
<Xeago> end
abionic has quit [Read error: Operation timed out]
<rostisla_> Xeago ok )
ABK has quit [Ping timeout: 260 seconds]
nitti has quit [Ping timeout: 245 seconds]
lggr has quit [Ping timeout: 245 seconds]
vlad_starkov has joined #ruby
_bart has joined #ruby
cj3kim has quit [Quit: This computer has gone to sleep]
jimeh has joined #ruby
lukaszk has joined #ruby
lggr has joined #ruby
xorgnak has joined #ruby
red_ has quit [Ping timeout: 260 seconds]
havenn has quit [Remote host closed the connection]
beiter has joined #ruby
cj3kim has joined #ruby
heftig has joined #ruby
xorgnak has quit [Remote host closed the connection]
Jork1 has joined #ruby
werdnativ has quit [Quit: werdnativ]
slainer68 has joined #ruby
xorgnak has joined #ruby
parzorep has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
cj3kim has quit [Client Quit]
timonv has quit [Remote host closed the connection]
apok has joined #ruby
bjhaid has joined #ruby
AlbireoX has quit [Remote host closed the connection]
<bjhaid> hi all I am using oci8 for direct connection to oracle, however my delete statements dont get commited, please can anyone help me out here, thanks
Xeago has quit [Remote host closed the connection]
AlbireoX has joined #ruby
lolmaus has joined #ruby
lggr has joined #ruby
luckyruby has quit [Remote host closed the connection]
colinbm has joined #ruby
xorgnak has quit [Ping timeout: 248 seconds]
AlbireoX has quit [Ping timeout: 240 seconds]
und3f has quit [Ping timeout: 245 seconds]
timonv has joined #ruby
hamed_r has joined #ruby
eldariof has joined #ruby
bjhaid has quit [Ping timeout: 245 seconds]
virtualentity has quit []
shiki has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 246 seconds]
haxrbyte has joined #ruby
colinbm has quit [Quit: colinbm]
robotmay has joined #ruby
lggr has joined #ruby
elaptics`away is now known as elaptics
margle has quit [Quit: Computer has gone to sleep.]
nemesit has joined #ruby
arkiver has quit [Quit: Leaving]
zii has quit [Read error: Connection reset by peer]
lggr has quit [Ping timeout: 256 seconds]
nilg has joined #ruby
zii has joined #ruby
frihd has joined #ruby
Banistergalaxy has quit [Ping timeout: 240 seconds]
monkegji_ has quit [Remote host closed the connection]
margle has joined #ruby
lggr has joined #ruby
Iszak has quit [Quit: User has gone to sleep.]
workmad3 has joined #ruby
Vainoharhainen has joined #ruby
Xeago has joined #ruby
keyvan has joined #ruby
keyvan has joined #ruby
keyvan has quit [Changing host]
haxrbyte has quit [Remote host closed the connection]
haxrbyte has joined #ruby
hoelzro|away is now known as hoelzro
Xeago has quit [Remote host closed the connection]
Iszak has joined #ruby
Xeago has joined #ruby
fantazo has quit [Remote host closed the connection]
monkegjinni has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
und3f has joined #ruby
thecreators has joined #ruby
M- has quit [Quit: This computer has gone to sleep]
lggr has joined #ruby
fantazo has joined #ruby
manouche has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
pskosinski has joined #ruby
wallerdev has quit [Quit: wallerdev]
monkegjinni has quit [Read error: No route to host]
monkegjinni has joined #ruby
und3f has quit [Ping timeout: 245 seconds]
frogprince has joined #ruby
skogis has joined #ruby
lggr has quit [Ping timeout: 244 seconds]
fantazo has quit [Remote host closed the connection]
<_bart> I do 'rvm use ruby-1.9.3-p194' in my ~/.zshrc file, is that bad?
<lukaszk> rvm use ruby-1.9.3 --default
elico has joined #ruby
<lukaszk> then you can get rid of that line from your zshrc
lggr has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
ryanf has quit [Quit: leaving]
elico has quit [Client Quit]
shiki has joined #ruby
Criztian_ has quit [Ping timeout: 256 seconds]
tvw has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
cezar has joined #ruby
cezar has quit [Client Quit]
monkegjinni has quit [Read error: Connection reset by peer]
matthewrobbins has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
monkegjinni has joined #ruby
nitti has joined #ruby
<_bart> lukaszk, thanks
lggr has joined #ruby
baphled has joined #ruby
<lukaszk> np
hatoishi has joined #ruby
Raboo has quit [Ping timeout: 245 seconds]
mbk_ has joined #ruby
Raboo has joined #ruby
nitti has quit [Ping timeout: 245 seconds]
und3f has joined #ruby
timmow has joined #ruby
shiki has quit [Remote host closed the connection]
Takehiro_ has joined #ruby
haxrbyte_ has joined #ruby
xorgnak has joined #ruby
haxrbyte has quit [Read error: Connection reset by peer]
tvw has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 252 seconds]
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
darthdeus has joined #ruby
headius has joined #ruby
haxrbyte_ has quit [Remote host closed the connection]
hvq has joined #ruby
headius has quit [Client Quit]
haxrbyte has joined #ruby
hvq has quit [Client Quit]
JonnieCache has joined #ruby
hvq has joined #ruby
lggr has joined #ruby
chussenot has quit [Quit: chussenot]
chussenot has joined #ruby
jcoglan has joined #ruby
vlad_starkov has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
hamed_r has quit [Quit: Leaving]
mxweas has quit [Remote host closed the connection]
adeponte has quit [Remote host closed the connection]
RudyValencia has quit [Quit: Hacked By Chinese!]
mxweas has joined #ruby
lggr has joined #ruby
becom33 has joined #ruby
<becom33> i was wondering is there are good cli frameworks with inbuild libs for http request , color outputs ..etc
xpen has quit [Remote host closed the connection]
thunderstrike has joined #ruby
<workmad3> becom33: there might be some with colour support, but I'd doubt any bother with http requests
<workmad3> becom33: because there are plenty of other libraries (and even plain net/http in the standard library) for http requests, so it's not something a CLI framework would need to concern itself with
lggr has quit [Ping timeout: 244 seconds]
<becom33> workmad3, what about good managements with modules and commands ?
und3f has quit [Ping timeout: 245 seconds]
<workmad3> becom33: I'd suggest you get this and read it, tbh - http://pragprog.com/book/dccar/build-awesome-command-line-applications-in-ruby
dr_bob has quit [Quit: Leaving.]
monkegjinni has quit [Read error: Connection reset by peer]
hsbt is now known as hsbt_away
monkegjinni has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
kjellski has joined #ruby
lggr has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
dr_bob has joined #ruby
monkegjinni has joined #ruby
nazty has quit [Ping timeout: 255 seconds]
<matthewrobbins> can anybody suggest why Digest::MD5.hexdigest(File.read("/path/to/myfile.mp4") might give me a different value on Windows (Ruby 1.9.2) - when I use it on a mac it is consistent with openssl md5 and windows raw openssl md5 also gives the same?
xjiujiu_ has quit [Read error: Connection reset by peer]
nodeman has joined #ruby
AMfish has joined #ruby
sqbell_ has quit [Quit: Lost terminal]
thunders_ has joined #ruby
thunderstrike has quit [Ping timeout: 245 seconds]
nazty has joined #ruby
slainer68 has quit [Remote host closed the connection]
<matled> matthewrobbins: maybe you need to open the file in binary mode on windows
lggr has quit [Ping timeout: 245 seconds]
slainer68 has joined #ruby
<matthewrobbins> malted - thanks that's great will give that a try
<matthewrobbins> s/malted/matled/
joeycarmello has joined #ruby
timonv has quit [Remote host closed the connection]
PapaSierra has joined #ruby
slainer6_ has joined #ruby
lggr has joined #ruby
<matled> matthewrobbins: I'm not sure where to find the documentation on File.read but from playing with the arguments it seems File.read(path, mode: "rb") should work
<matled> ah, it's defined on IO, not File
joeycarmello has quit [Remote host closed the connection]
timonv has joined #ruby
KevinSjoberg has quit [Quit: Computer has gone to sleep.]
slainer68 has quit [Ping timeout: 252 seconds]
monkegji_ has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
rakl has quit [Quit: sleeping]
dr_bob has quit [Quit: Leaving.]
monkegjinni has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
bapa has quit [Read error: Connection reset by peer]
tonini has quit [Remote host closed the connection]
monkegji_ has quit [Read error: Connection reset by peer]
bapa has joined #ruby
dr_bob has joined #ruby
und3f has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
shammancer has quit [Ping timeout: 246 seconds]
<_bart> I don't like how sublime text doesn't show mini file icons and folders like the project view op text mate does.
Takehiro_ has quit [Remote host closed the connection]
<workmad3> matthewrobbins: windows - the holdover to days when binary and text files are different :)
monkegjinni has quit [Read error: No route to host]
<matthewrobbins> matled ok yep just seeing that, thanks again IO.binread works
<matthewrobbins> and gives the value I want!
Guedes has joined #ruby
Guedes has quit [Changing host]
Guedes has joined #ruby
lggr has joined #ruby
<rking> _bart: Hrm. Screenshot or I assume you're talking about needless frills.
<workmad3> matthewrobbins: it's basically because a text file in windows uses crlf as a newline, which will mean binary information that happens to contain that ascii string will be read in differently if you read it as text
bapa has quit [Read error: Connection reset by peer]
bapa has joined #ruby
monkegjinni has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegji_ has joined #ruby
<matthewrobbins> workmad3 - thanks that's really useful, makes sense once you know ;-) thanks people
<workmad3> matthewrobbins: most things make sense once you know the history behind them :)
monkegji_ has quit [Read error: Connection reset by peer]
timonv has quit [Remote host closed the connection]
<workmad3> matthewrobbins: of course, to understand why 'crlf' is taken as a newline you need to go right the way back to typewriters :D
monkegjinni has joined #ruby
timonv has joined #ruby
<matthewrobbins> workmad3 - ha…funny just reading that on Wikipedia!
monkegjinni has quit [Read error: Connection reset by peer]
fermion has joined #ruby
samphippen has joined #ruby
<_bart> rking: also, it's useful when having .rb and .html files in one folder, it shows different mini-icons for those files.
Averna has quit [Quit: Leaving.]
lggr has quit [Ping timeout: 265 seconds]
monkegjinni has joined #ruby
monkegjinni has quit [Read error: No route to host]
Jrz has quit [Ping timeout: 245 seconds]
monkegjinni has joined #ruby
monkegji_ has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegji_ has quit [Read error: Connection reset by peer]
lggr has joined #ruby
nitti has joined #ruby
<rking> _bart: Pleh.
monkegjinni has joined #ruby
beiter has quit [Ping timeout: 260 seconds]
<rking> _bart: Shouldn't you be using the omnifindy thing?
<_bart> rking: in subl it's just text, text and more text.
<_bart> rking: no, I have a neat folder structure for a reason, using the omnifindy thing allows you to place files in places they shouldn't be because no-one without omnifind would find it.
maasha has joined #ruby
hotovson has quit [Remote host closed the connection]
Jrz has joined #ruby
F1skr has joined #ruby
<rking> Hrm. We're from two very different worlds on this one. ☺
<maasha> buhuhuhuu ;o( - this tree I am building is driving my nuts. There is a bug and it only presents itself when running with lots of data. Code is recursive and I hate debugging recursive code.
<rking> Thanks for going through the trouble of actually screenshotting. I was mostly talking aimless trash, but I'm glad I know exactly what you are talking about.
* maasha wonders what the Ruby debugger actually can do.
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
nitti has quit [Ping timeout: 245 seconds]
monkegjinni has quit [Read error: Connection reset by peer]
g0bl1n has joined #ruby
fyolnish_ has quit [Remote host closed the connection]
monkegjinni has joined #ruby
g0bl1n has quit [Changing host]
g0bl1n has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
elico has joined #ruby
<maasha> bah, I still need to isolate a subset of my data which causes the problem. But as soon as I pick records that give wrong results and run on those - no error >;o(
monkegjinni has joined #ruby
lggr has quit [Ping timeout: 252 seconds]
Trioke has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
<elektronaut> i find going for a walk is the best way to debug those kinds of problems
monkegjinni has joined #ruby
Villadelfia has quit [Read error: Operation timed out]
<maasha> elektronaut: I come here and whine :o/
<maasha> Any obvious bugs here? -> http://pastie.org/5034297
monkegjinni has quit [Read error: Connection reset by peer]
xpen has joined #ruby
SeySayux has quit [Ping timeout: 244 seconds]
monkegjinni has joined #ruby
<elektronaut> what's the error?
SeySayux has joined #ruby
manizzle_ has quit [Ping timeout: 244 seconds]
lggr has joined #ruby
mxweas has quit [Quit: Computer has gone to sleep.]
cascalheira has joined #ruby
<maasha> so some trees are not merged where they should be. this seems to be dependent of the order the trees are merged in.
<_bart> mass assignment of the variables in initialize!
dr_bob has quit [Quit: Leaving.]
Villadelfia has joined #ruby
<_bart> I don't see anything wrong
dr_bob has joined #ruby
uris has joined #ruby
<_bart> rking: I do think the editor itself (sublime) is way better than text mate. But it's just the project/folder view that bothers me.
<_bart> rking: np :)
vlad_starkov has quit [Remote host closed the connection]
<maasha> What about multiple references to the same node?
timonv has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 240 seconds]
vlad_starkov has joined #ruby
nemesit has quit [Quit: Linkinus - http://linkinus.com]
<elektronaut> list = flatten(child, list)
<elektronaut> shouldn't that be list += flatten(child, list) ?
fantazo has joined #ruby
<elektronaut> nevermind
nemesit has joined #ruby
<elektronaut> my head doesn't recurse properly without coffee
<workmad3> maasha: is there any reason you're tracking the level in the node, rather than letting that be derived by a recursive walk of the tree?
<maasha> workmad3: in fact the level is not the tree depth but rather a description of taxonomic classification (data)
lggr has joined #ruby
<workmad3> maasha: ah, right
<workmad3> maasha: so it's a TaxonomyNode :)
<shevy> damn glib
<maasha> workmad3: but you assumption is fair that something "level" and tree is the depth
<workmad3> maasha: any reason you couldn't 'merge' the trees by simply adding a new level of hierarchy?
Jork1 has quit [Quit: Jork1]
<maasha> workmad3: I have never tried to merge trees before. I searched around a bit and they common way seems to be flattening one tree and adding to another.
<workmad3> maasha: as that's normally the easiest way to merge trees :)
beiter has joined #ruby
<Xeago> just make a new root, and add both tree's as a child imo
<Xeago> as workmad3 says
<workmad3> maasha: it depends on whether it's a sorted tree though
monkegjinni has quit [Read error: Connection reset by peer]
Takehiro_ has joined #ruby
x0F has quit [Disconnected by services]
x0F_ has joined #ruby
rellin has quit [Quit: Nettalk6 - www.ntalk.de]
<maasha> workmad3: I dont quite get it ...
darule has quit []
x0F_ is now known as x0F
monkegjinni has joined #ruby
<workmad3> maasha: ok, once you've 'merged' the trees, what should you end up with?
marcux has joined #ruby
<workmad3> maasha: is the data going to be intermingled in some new sorted manner, or will you basically end up with the same two tree structures, but with a new node connecting the two?
Jork1 has joined #ruby
<maasha> workmad3: so it is an organism tree. the leves are domain/kingdom/phylum/class/order/family/genus/species. Some organisms have all levels - some only down to a partcular level.
Jork1 has quit [Client Quit]
<workmad3> maasha: right
<Xeago> s a node can have more than 1 parent node or what?
manizzle_ has joined #ruby
<Xeago> s/s/so
<maasha> workmad3: and I want the trees merged to keep count of how many different organisms were classified to what level.
chussenot has quit [Quit: chussenot]
monkegjinni has quit [Read error: No route to host]
<workmad3> maasha: so, if two trees need merging, are they going to 'match' to a certain point and then diverge completely?
heftig has quit [Ping timeout: 245 seconds]
Jork1 has joined #ruby
<workmad3> maasha: so they'd have the same domain, kingdom, phylum, but then a different class?
<maasha> workmad3: of in case of duplicate organisms they should match all they way through
lggr has quit [Ping timeout: 245 seconds]
<maasha> workmad3: but otherwise you are right.
hsbt_away is now known as hsbt
* Xeago lost track
<workmad3> maasha: right, so you need three things - first you need to compare two nodes
<workmad3> maasha: which will only match the data within the nodes
Trioke has quit [Ping timeout: 245 seconds]
<workmad3> maasha: then you need a tree equality to check if the trees are the same
chussenot has joined #ruby
monkegjinni has joined #ruby
<workmad3> maasha: and then you need a recursive merge function that will take two trees - it will recurse down until it is comparing at the same 'level'
heftig has joined #ruby
emergion has joined #ruby
<workmad3> maasha: and then, for each level it will see if it needs to recurse down to the next level, or if it needs to add the children from one tree to the other
hotovson_ has joined #ruby
<maasha> workmad3: or my suggestion. flatten all trees and add as new nodes to a master tree.
Takehiro_ has quit [Remote host closed the connection]
<workmad3> maasha: yes, but then you need to rebuild the entire tree again
lggr has joined #ruby
<workmad3> maasha: and that isn't always the easiest way (or even always possible)
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
dr_bob has quit [Quit: Leaving.]
<workmad3> maasha: I'd probably be tempted to put more behaviour into your node
timonv has joined #ruby
<workmad3> maasha: including making the 'flatten' operation a recursive operation of the tree
<workmad3> maasha: assuming you want to go down that rout
<workmad3> *route
<maasha> workmad3: certainly I have a bug. I am not sure if it is in the my merging.
alek_b has joined #ruby
<workmad3> maasha: and is the flattening going to be pre-order, in-order or post-order?
timonv has quit [Remote host closed the connection]
alek_b_ has quit [Ping timeout: 240 seconds]
hvq has quit [Ping timeout: 272 seconds]
<workmad3> maasha: whichever it is, your flatten can be simplified to 'class TaxNode; def flatten; @children.map(&:flatten).inject(&:+) + [self]'
<workmad3> maasha: and ignore in-order... because of your tree structure, you can only do pre-order or post-order
slainer6_ has quit [Remote host closed the connection]
nodeman has left #ruby [#ruby]
<workmad3> maasha: I'm too used to dealing with binary trees :)
<maasha> workmad3: It shows
<maasha> workmad3: what do you mean by in-/pre-/post-order?
lggr has quit [Ping timeout: 260 seconds]
<workmad3> maasha: it's ways of flattening trees
knirhs has quit [Read error: Connection reset by peer]
sgupta has joined #ruby
<workmad3> maasha: with a binary tree, pre-order flattens as 'current, left.flatten, right.flatten', in-order as 'left.flatten, current, right.flatten' and post as... well you get the idea ;)
alek_b_ has joined #ruby
<workmad3> maasha: with your n-ary tree, there isn't a place to do in-order, so you can do 'current, children.flatten' or 'children.flatten, current'
timonv has joined #ruby
lggr has joined #ruby
<maasha> workmad3: I ought to re-test my flattening.
<elektronaut> any tips for debugging SystemStackErrors? I'm not getting a useful backtrace at all
<maasha> I need to follow all full paths from root to leaf.
alek_b has quit [Ping timeout: 255 seconds]
hatoishi has quit [Quit: leaving]
uris has quit [Read error: Connection reset by peer]
<roadt> hi, how to convert hex to oct in ruby?
uris has joined #ruby
marcux has quit [Ping timeout: 276 seconds]
robotmay has quit [Ping timeout: 276 seconds]
hotovson_ has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 256 seconds]
kringa has quit [Ping timeout: 265 seconds]
`brendan has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
<workmad3> maasha: that's the advantage of relying on the tree structure
kaawee has joined #ruby
<workmad3> maasha: also, if you're going to add one to the other, you probably want an 'add' method on your node that is capable of adding a new node at the right level
keyvan has quit [Remote host closed the connection]
frederic has joined #ruby
<workmad3> maasha: because you could indeed to 'tree1.merge(tree2)' as 'tree2.flatten.each {|n| tree1.add(n)}'
irleif has joined #ruby
<workmad3> maasha: as long as your add method adds a node in the right place (and your flatten works pre-order)
<maasha> workmad3: I suspect my problem is merging branced trees
<workmad3> maasha: quite possibly :)
<workmad3> maasha: the key with trees is always to try and build from simple primitives, IMO
<workmad3> maasha: it's quite easy to write an add method with a tree
<workmad3> maasha: and it's quite easy to write a flatten method
<maasha> workmad3: as soon as you recurse you are on thin ice!
<maasha> workmad3: it is equally easy to write a wrong flatten method
<workmad3> maasha: nah, you're not on thin ice as long as you recurse with well known problems
lggr has joined #ruby
<maasha> if not easier
<workmad3> maasha: not if you do it simply and rely on your tree data structure
charliesome has joined #ruby
<workmad3> maasha: def flatten; [self] + @children.map(&:flatten).inject(&:+); end <-- that's an intuitively correct pre-order flatten method for your n-ary tree
<Xeago> maasha: by relying on primitive operations, you should end up with a divide&conquer solution
xaq has joined #ruby
<workmad3> maasha: it's not very efficient, I'll admit, but it's correct
frogprince_mac has joined #ruby
Jork1 has quit [Quit: Jork1]
xpen has quit [Remote host closed the connection]
<workmad3> maasha: and also, it will give you a flattened array that will always contain the parent node before child nodes
<workmad3> maasha: which is important for your add
timonv has quit [Remote host closed the connection]
<workmad3> maasha: your add is going to be more complicated in this situation, because you're going to need to incorporate knowledge of the taxonomic hierarchy into it
timonv has joined #ruby
marcux has joined #ruby
fyolnish has joined #ruby
marcux has quit [Client Quit]
<workmad3> maasha: because you'll basically need to go 'is this my parent level? if not, recurse down, otherwise add to the children here'
<workmad3> maasha: recursion is actually the much more solid way to think about trees... trying to think of trees iteratively leaves you on thin ice much more quickly than thinking of them recursively IMO ;)
<workmad3> maasha: which isn't really that surprising, seeing as they are a recursively defined data structure
<maasha> workmad3: but you are also used to trees :o)
<Xeago> maasha: could you gist your datastructure?
lggr has quit [Ping timeout: 240 seconds]
zigomir has quit [Remote host closed the connection]
<workmad3> maasha: sketch it out on paper ;)
<workmad3> maasha: trees are awesome in that they are really, really easy to sketch
<Xeago> share it afterwards ;)
<maasha> paper is good
<Xeago> also
hotovson_ has joined #ruby
<workmad3> maasha: because what I'm doing when discussing this is thinking through a sketch in my head... the only thing being 'used to trees' is giving me is a way to save real trees by not having to actually draw my sketch ;)
<Xeago> I would construct the count and scoring, in a second parse
<Xeago> when done merging
<workmad3> ^^ (although it's really a tree walk more than a parse)
<Xeago> in an additional step
<Xeago> :)
thunders_ has quit [Remote host closed the connection]
<JonnieCache> paper is by far the best software engineering tool
<workmad3> maasha: the other thing I learned about trees when I did them @ uni - don't try to optimise your code ;)
zz_chrismcg is now known as chrismcg
<workmad3> maasha: get the thing working
monkegjinni has quit [Read error: No route to host]
<workmad3> maasha: and then, if it doesn't perform well enough, work out what type of tree you have and go google exactly what algorithms work with that type of tree
lggr has joined #ruby
<maasha> workmad3: simple is good - and pretty optimal (and do let the compiler deal with end-tail recursion optimization)
<JonnieCache> in general you should never try and optimize code as you write it
<workmad3> maasha: yeah, and the simple recursively defined primitive operations you start with can be used for all sorts :)
KevinSjoberg has joined #ruby
<Xeago> How do I get rid of the ugly $1 $2?
<Xeago> if key.to_s.match(/(.*)_(#{matchers_in_regexp_form})$/)
<Xeago> grouped_params[$2.to_sym][$1.to_sym] = value
<Xeago> end
<maasha> Xeago: why ugly?
<workmad3> Xeago: by making it more complicated and having to iterate over the match array
<Xeago> maasha: because the origin of $1 and $2 is unclear
dr_bob has joined #ruby
<workmad3> Xeago: it isn't unclear though
<workmad3> Xeago: unless you expect your regex code to be maintained by someone who doesn't know regex
robotmay has joined #ruby
Nisstyre has quit [Ping timeout: 276 seconds]
<workmad3> Xeago: at which point you're kinda screwed anyway ;)
nitti has joined #ruby
<Xeago> this code is going to be maintained by a java guy
<workmad3> Xeago: you're kinda screwed anyway... :P
<Xeago> yea, I figured..
<maasha> Xeago: if $1, $2 etc are only used in the lines immediately after a regex then it is very clear to most people.
<workmad3> Xeago: in this situation, I'd add a comment
monkegjinni has joined #ruby
<workmad3> Xeago: one of the rare cases I'd add a code comment :)
freakazoid0223 has quit [Ping timeout: 240 seconds]
sgupta has quit [Read error: Connection reset by peer]
wedtm|away is now known as wedtm
Shrink has joined #ruby
Shrink has quit [Changing host]
Shrink has joined #ruby
tvw has joined #ruby
<workmad3> Xeago: something short and sweet, along the lines of '$1 and $2 are set up automatically and contain the contents of the two () deliminated match groups in the previous regular explession'
<workmad3> typo optional ;)
<workmad3> regular explessions...
lggr has quit [Ping timeout: 260 seconds]
nitti has quit [Ping timeout: 245 seconds]
ablew_ has quit [Ping timeout: 245 seconds]
monkegjinni has quit [Remote host closed the connection]
lggr has joined #ruby
xaq_ has joined #ruby
chussenot has quit [Quit: chussenot]
Virunga has quit [Remote host closed the connection]
y5wars has joined #ruby
xaq has quit [Read error: Connection reset by peer]
ablew has joined #ruby
Banistergalaxy has joined #ruby
whaley has joined #ruby
hemanth has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
Nisstyre has joined #ruby
hemanth has joined #ruby
bluenemo has joined #ruby
bluenemo has quit [Changing host]
bluenemo has joined #ruby
beiter has quit [Ping timeout: 255 seconds]
morozovm has joined #ruby
verto|off is now known as verto
lggr has joined #ruby
Axsuul has quit [Ping timeout: 260 seconds]
Guedes has quit [Ping timeout: 245 seconds]
slainer68 has joined #ruby
beiter has joined #ruby
emergion has quit [Quit: Computer has gone to sleep.]
AMfish has quit [Ping timeout: 240 seconds]
lggr has quit [Ping timeout: 252 seconds]
freeayu has joined #ruby
theRoUS has quit [Ping timeout: 244 seconds]
reinaldob has joined #ruby
mengu has joined #ruby
<JonnieCache> arent there other globals that are aliases of $1 and $2?
apok has quit [Quit: apok]
<awestroke> JonnieCache: you got ARGV, which is an array
ZubKonst has joined #ruby
lggr has joined #ruby
arietis has joined #ruby
<JonnieCache> or just assign the MatchData object and use that
<awestroke> ARGV.each{|a| p a}
<awestroke> oh regexp sorry
<awestroke> nvm
<JonnieCache> yeah isnt $1 the last regex match?
<JonnieCache> yes indeed it is. thought i was going mad there
pothibo has quit [Quit: pothibo]
ZubKonst_ has quit [Ping timeout: 246 seconds]
nari has quit [Ping timeout: 245 seconds]
ForevernadeAFK has joined #ruby
lggr has quit [Ping timeout: 272 seconds]
Nisstyre has quit [Read error: Operation timed out]
Forevernade has quit [Ping timeout: 256 seconds]
v0n has joined #ruby
timonv has quit [Remote host closed the connection]
rabidpraxis has joined #ruby
snorkdude has joined #ruby
rabidpraxis has quit [Read error: Connection reset by peer]
hemanth has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
colinbm has joined #ruby
larissa has joined #ruby
fermion has quit [Ping timeout: 276 seconds]
timonv has joined #ruby
y5wars has quit [Quit: y5wars]
elico has quit [Quit: elico]
haxrbyte has quit [Ping timeout: 245 seconds]
RJ3000_ has quit [Ping timeout: 265 seconds]
emergion has joined #ruby
colinbm has quit [Quit: colinbm]
lggr has quit [Ping timeout: 244 seconds]
jenrzzz has quit [Ping timeout: 255 seconds]
mgrayson has joined #ruby
lggr has joined #ruby
MikeyV27 has joined #ruby
xaq has joined #ruby
gogiel has joined #ruby
Nisstyre has joined #ruby
peregrine81 has joined #ruby
xaq_ has quit [Ping timeout: 244 seconds]
lggr has quit [Ping timeout: 248 seconds]
nitti has joined #ruby
snorkdude has quit [Remote host closed the connection]
Virunga has joined #ruby
phantasm66 has joined #ruby
kaawee has quit [Ping timeout: 276 seconds]
[Neurotic] has quit [Remote host closed the connection]
nitti_ has joined #ruby
lggr has joined #ruby
v0n has quit [Ping timeout: 252 seconds]
Virunga is now known as LennyLinux
nitti has quit [Ping timeout: 244 seconds]
emergion has quit [Quit: Computer has gone to sleep.]
lggr has quit [Ping timeout: 245 seconds]
tommyvyo has quit [Quit: Computer has gone to sleep.]
charliesome has quit [Quit: Textual IRC Client: www.textualapp.com]
nitti_ has quit [Remote host closed the connection]
Spooner has joined #ruby
nitti has joined #ruby
manizzle_ has quit [Remote host closed the connection]
rakunHo has quit [Remote host closed the connection]
lggr has joined #ruby
irleif has quit [Quit: Computer has gone to sleep.]
zii has quit [Ping timeout: 245 seconds]
becom33 has quit [Quit: Leaving]
greenarrow has quit [Read error: Connection reset by peer]
greenarrow has joined #ruby
mmitchell has joined #ruby
zii has joined #ruby
monkegjinni has quit [Read error: No route to host]
monkegjinni has joined #ruby
ltsstar has joined #ruby
Guedes0 is now known as Guedes
Guedes has quit [Quit: Saindo]
Guedes has joined #ruby
Foxandxss has joined #ruby
tommyvyo has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
mucker has joined #ruby
chimay has quit [Quit: WeeChat 0.3.9-rc1]
phantasm66 has quit [Quit: phantasm66]
lggr has joined #ruby
<krz> how would you classify increment and decrement?
<krz> volume?
<krz> up_or_down? inc_dec? anything better?
bluenemo has quit [Read error: Connection reset by peer]
mh` has joined #ruby
<JonnieCache> what do you mean?
<JonnieCache> i dont understand the question
<krz> i need to give it a word
<krz> dogs, cats = pets
<krz> increment, decrement = ?
freezway has joined #ruby
hotovson_ has quit [Remote host closed the connection]
hotovson has joined #ruby
<kalleth> louder, quieter
<kalleth> @krz
ForevernadeAFK has quit [Remote host closed the connection]
<kalleth> if referring to volume
<kalleth> :P
<Spooner> krz : Can't think of a good general word. Ah, specifically for volume - adjustments?
Takehiro has joined #ruby
<JonnieCache> asjutments, changes, modifications
kisoku has quit [Ping timeout: 246 seconds]
<JonnieCache> modulations
<JonnieCache> delta
mark_locklear has joined #ruby
bluenemo has joined #ruby
bluenemo has quit [Changing host]
bluenemo has joined #ruby
emergion has joined #ruby
beiter has quit [Quit: beiter]
gmci has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
mensvaga has joined #ruby
lggr has quit [Ping timeout: 265 seconds]
<krz> more for counters
<krz> :-)
dhruvasagar has quit [Ping timeout: 255 seconds]
xpen has joined #ruby
dhruvasagar has joined #ruby
lggr has joined #ruby
<matti> :)
<matti> lukaszk: :)
joschi- has quit [Quit: ZNC - http://znc.in]
joschi has joined #ruby
yshh has quit [Remote host closed the connection]
hvq has joined #ruby
ABK_ has quit [Ping timeout: 246 seconds]
dpk has joined #ruby
postmodern has quit [Quit: Leaving]
pothibo has joined #ruby
xaq has quit [Remote host closed the connection]
jlwestsr has joined #ruby
Paradox has quit [Ping timeout: 256 seconds]
lggr has quit [Ping timeout: 265 seconds]
marienz has joined #ruby
<mh`> delta is still used for counters
bapa has quit [Remote host closed the connection]
reuf has joined #ruby
lupine_85 has quit [Read error: Connection reset by peer]
lupine_85 has joined #ruby
Eplemosen has joined #ruby
xaq has joined #ruby
lggr has joined #ruby
Jork1 has joined #ruby
robotmay has quit [Read error: Connection reset by peer]
Paradox has joined #ruby
nwertman has joined #ruby
chussenot has joined #ruby
elspeth_ is now known as elspeth
xaq has quit [Read error: Connection reset by peer]
xaq has joined #ruby
Ethan has quit [Remote host closed the connection]
joshhunt has joined #ruby
joshhunt is now known as joshhh
lggr has quit [Ping timeout: 245 seconds]
<joshhh> Hey guys!
<_bart> invalid byte sequence in UTF-8 (ArgumentError)
<_bart> got # encoding: UTF-8 on top of the file
<_bart> :/
<matti> _bart: # -*- encoding: utf-8 -*-
<_bart> what's the ifference?
<matti> Works for me ;d
ABK_ has joined #ruby
<_bart> it's exactly the same?
robotmay has joined #ruby
frihd has quit [Quit: Leaving.]
<matti> _bart: Should be no difference, indeed.
rabidpraxis has joined #ruby
lggr has joined #ruby
<matti> _bart: There is a small bazillion things on SO on UTF8 and Ruby >= 1.9.x
xyzodiac has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
clocKwize has joined #ruby
ltsstar has quit [Quit: ltsstar]
krz has quit [Quit: krz]
gmurphey has quit [Ping timeout: 246 seconds]
monkegjinni has quit [Read error: No route to host]
monkegjinni has joined #ruby
nanderoo has joined #ruby
bapa has joined #ruby
fixl has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
elliot98 has joined #ruby
elliot98 has quit [Changing host]
elliot98 has joined #ruby
iamjarvo has joined #ruby
Andy1991 has joined #ruby
<Andy1991> Anyone looking for a job in Manchester city centre? PHP/Rails
tommyvyo_ has joined #ruby
vitoravelino`afk is now known as vitoravelino
Takehiro has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 256 seconds]
nari has joined #ruby
Takehiro has joined #ruby
whaley has quit [Remote host closed the connection]
krawchyk has joined #ruby
Takehiro has quit [Remote host closed the connection]
<Spooner> Andy1991 : Interesting place to advertise ;)
Takehiro has joined #ruby
<Andy1991> Great place to advertise?
<Muz> lolmanchester.
<Andy1991> I'm sure you have some great developers in here
<Muz> Also, PHP /and/ Rails? It's like two of the worst things in one place.
whaley has joined #ruby
<Andy1991> PHP and/or Rails
lggr has joined #ruby
<Spooner> That is significantly different.
<Andy1991> Indeed
<Spooner> Muz PHP and Rails would make sense. Legacy support for PHP and new development in Rails.
hvq has quit [Quit: Instantbird 1.2 -- http://www.instantbird.com]
<Andy1991> Spooner: Thats pretty much it
mmitchell has quit [Remote host closed the connection]
<Spooner> So it is _and_ then.
<Andy1991> Plus, CubeCart/Megento we support a lot
<Spooner> Or is it that you are taking on several people and you don't need them all to do everything? Just curious.
<Andy1991> Preferably, yes
<Andy1991> But I started here as a PHP developer
<Andy1991> And I'm learning rails on works time
Takehiro has quit [Ping timeout: 246 seconds]
GoGoGarrett has quit [Remote host closed the connection]
<Spooner> I'm within a commute of Manchester, not working, and I'm not desperate enough to relearn PHP or learn Rails :) I think this says something about my keenness to get off my arse again *coughs*
reisl has joined #ruby
whaley has quit [Remote host closed the connection]
larissa has quit [Read error: Operation timed out]
<Spooner> Andy1991 You are probably better off in #rubyonrails, if you haven't tried there.
<shevy> well you do use ruby
samphippen has joined #ruby
<shevy> so you aren't totally lazy
<Spooner> Shevy Not really. I use Ruby because I'm lazy. I write C extensions because I'm stupid ;)
<shevy> hehe
* Xeago needs a dynamic table of contents in javascript
<Cool_Fire> Ruby is like the laziest language ever xD
<_bart> if ruby was lazy it would know how to easily force encodings
lggr has quit [Ping timeout: 276 seconds]
Foxandxss has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
<Spooner> I'm lazy enough to be happy with the default encoding ;)
kisoku has joined #ruby
<Cool_Fire> I'm fairly sure you can just specify the encoding at the top of your .rb actually
<Andy1991> Thanks Spooner
wmoxam has joined #ruby
Andy1991 has left #ruby [#ruby]
<Spooner> shevy All I need to do is find someone to employ me to write gems that don't work properly and games that no-one plays and I'm set for life :D
lggr has joined #ruby
<_bart> Spooner: I'm always attacked by: in `downcase': invalid byte sequence in UTF-8 (ArgumentError)
ABK_ has quit [Read error: Connection reset by peer]
chrisramon has joined #ruby
<shevy> the encoding stuff really sucks
TomJ has joined #ruby
<Xeago> do you think 2.0 will fix that?
<chrisramon> hi, i need help with active merchant, I am using the version 1.3.1 and keep gettings this error NameError: uninitialized constant Object::ActiveMerchant
<Spooner> _bart : I'm not denying that Ruby encoding is painful. Just that I avoid needing it as much as I can.
cdzombak has joined #ruby
<Spooner> chrisramon : #rubyonrails is a better place to ask.
<heftig> i never had pain with encodings :p
<shevy> Xeago nope it will never be fixed, it will always remain a problem
<shevy> heftig because you use UTF right?
<heftig> usually
<shevy> yeah usually those who use UTF dont have problems
<Spooner> Matz argument is that the encodings are significantly easier for people that need them, even if they are more of a pain for people who largely don't need them.
<shevy> it's basically a subtle hint from the ruby devs to say "switch to UTF or stop using ruby"
<shevy> yeah he can be right
<shevy> still 1.8.7 gave me less issues, encoding problems which I simply never had at all when using 1.8.x :(
<_bart> Spooner: Like doing /query/i in regexp?
bapa has quit [Remote host closed the connection]
<_bart> Spooner: the case insensitivity is one way of avoiding downcast I've been thinking of
<shevy> my hope is that with "# Encoding: ASCII-8BIT" I can avoid all encoding problems
<_bart> downcase*
<Spooner> Yeah, but I expect people wanting to use Japanese, etc, in 1.8 cried a lot of tears.
<heftig> shevy: no, you just hide them
<shevy> but I dont have any problems!
<Spooner> _bart : Not really. I don't have a huge need to manipulate text that isn't mine.
bapa has joined #ruby
omry has joined #ruby
<_bart> Spooner: but I do, what do you think of that solution?
<shevy> people should give up on japanese :)
<Spooner> Probably a good one, yes, _bart.
rabidpraxis has quit [Remote host closed the connection]
<hoffmanc> 1.9 is better?
<shevy> how do you define "better"
lggr has quit [Ping timeout: 248 seconds]
<hoffmanc> AFA Japanese
emergion has quit [Quit: Computer has gone to sleep.]
<Spooner> That was the intention, yes, hoffmanc.
<shevy> I mean they invested 5 years into it, so I sure hope it is better than 1.8
kaawee has joined #ruby
<shevy> ruby is now the fastest scripting language!
<hoffmanc> amount of time spent is often not highly correlated with project success
<hoffmanc> shevy: that seems like a blanket statement
<Spooner> But we, I suspect, are mainly in the group who suffered with the addition of encoding in 1.9 (European/US types).
<hoffmanc> like it is faster at *everything*?
<shevy> hmm lua is faster but see here hoffmanc http://shootout.alioth.debian.org/u32/which-programs-are-fastest.php
linoj has joined #ruby
elico has joined #ruby
<shevy> depends on what is being tested, on that test ruby is faster than php python and perl
<hoffmanc> did they fix the unbearably small recursion depth?
<shevy> lua asskicks every other scripting language though
Jork1 has quit [Ping timeout: 245 seconds]
freezway has quit [Ping timeout: 245 seconds]
<hoffmanc> again, I think it depends on what you're doing
<Cool_Fire> If speeds is so critically important, you shouldn't be using a scripting language in the first place.
<shevy> well there is one test so far
<Spooner> hoffmanc : Pretty sure it still just says "stack ran out" when you run out of depth, with absolutely no indication where it ran out. That is more annoying than lack of depth for me.
elico has quit [Client Quit]
<hoffmanc> Spooner, yeah that is the lamest part of ruby IMHO
<Spooner> shevy : But vanilla Lua is about as bare bones as it gets. Comparing it to Ruby is not really fair.
<shevy> god the source code to those tests is horrible http://shootout.alioth.debian.org/u32/program.php?test=regexdna&lang=yarv&id=3
lggr has joined #ruby
<hoffmanc> I find the simplest solution to be recursive often
<shevy> wtf!
<Spooner> Yes, but that doesn't mean it is best if you have 10k stack recursions (No idea what the limit actually is).
<shevy> byte_acc <<= (8 - bit_num)
<shevy> what is <<=
<shevy> I've never seen that before
<hoffmanc> binary shift I think
<maasha> workmad3: my flatten is foobar. And I cant get yours to work
Asher has quit [Ping timeout: 256 seconds]
<shevy> hmm
<wmoxam> shevy: fast ruby code is ugly :(
fearoffish_ is now known as fearoffish
ggoo_26 has joined #ruby
<hoffmanc> haha, yeah
<Spooner> Mmm, that code also uses stuff like while x > 0 where any Rubyist would use an enumerator. Hardly "Ruby" code then.
<hoffmanc> but computers keep getting faster so who cares
<shevy> wmoxam yeah hmm
<shevy> wmoxam I wonder if beautiful ruby code can be fast too
<shevy> because if you use ugly ruby... you could well use C anyway
<Spooner> Though maybe while z > 0; z += 1; end is actually faster than using a block.
Neomex has joined #ruby
<wmoxam> shevy: This is a microbench mark
<Spooner> Blocks are pretty slow.
<shevy> fannkuch(n) <--- haha german speaking? :)
<wmoxam> shevy: you wouldn't use any code this code for any language really
<shevy> this cracks me up... how many Pfannkuchen to be seen ...
<wmoxam> shevy: it's jsut a straight up port of the Lua version
Takehiro has joined #ruby
<maasha> workmad3: http://pastie.org/5035107
a_a_g1 has joined #ruby
joofsh has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
morozovm has quit [Read error: Connection reset by peer]
yekta has joined #ruby
morozovm has joined #ruby
GoGoGarrett has joined #ruby
sailias has joined #ruby
ggoo_26 has left #ruby [#ruby]
a_a_g has quit [Read error: Connection reset by peer]
jeffreybaird has joined #ruby
<_bart> Spooner: BOOOM in `scan': invalid byte sequence in UTF-8 (ArgumentError)
<_bart> Spooner: using regexp to avoid the issue using /../i is not the way..
<Spooner> _bart : Meh.
RJ3000_ has joined #ruby
lggr has joined #ruby
jrist-afk is now known as jrist
v0n has joined #ruby
mercwithamouth has joined #ruby
mbk_ has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
Mon_Ouie has joined #ruby
SmoothSage_ has joined #ruby
SmoothSage has quit [Ping timeout: 245 seconds]
jasond has joined #ruby
xyzodiac has quit [Quit: Computer has gone to sleep.]
Apocalypse has quit [Ping timeout: 246 seconds]
nwertman has quit [Quit: nwertman]
yshh has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
NiteRain has joined #ruby
himsin has joined #ruby
_bart has quit [Ping timeout: 252 seconds]
jcaudle has joined #ruby
haxrbyte has joined #ruby
sterNiX has joined #ruby
sterNiX has joined #ruby
sterNiX has quit [Changing host]
jprovazn has quit [Quit: Leaving]
lggr has joined #ruby
Neomex has quit [Quit: Neomex]
Rydefalk_ has joined #ruby
Guest74267 has joined #ruby
Rydefalk has quit [Read error: Connection reset by peer]
dr_bob has quit [Quit: Leaving.]
gmurphey has joined #ruby
vitoravelino is now known as vitoravelino`afk
xyzodiac has joined #ruby
vitoravelino`afk is now known as vitoravelino
ottbot has joined #ruby
dr_bob has joined #ruby
nari has quit [Read error: Operation timed out]
lggr has quit [Ping timeout: 246 seconds]
kringa has joined #ruby
dr_bob has quit [Client Quit]
otters has joined #ruby
fantazo_ has joined #ruby
vng|afk is now known as vng
vng is now known as Guest32404
lggr has joined #ruby
Apocalypse has joined #ruby
fantazo has quit [Ping timeout: 260 seconds]
asobrasil has joined #ruby
xyzodiac has quit [Quit: Computer has gone to sleep.]
morozovm has quit [Read error: Connection reset by peer]
vaclavt has joined #ruby
morozovm has joined #ruby
hsbt is now known as hsbt_away
iamjarvo has quit [Ping timeout: 245 seconds]
lggr has quit [Ping timeout: 248 seconds]
beit has joined #ruby
fmcgeough has joined #ruby
uris has quit [Quit: leaving]
Guest21929 is now known as duracrisis
mmitchell has joined #ruby
mmitchell has quit [Remote host closed the connection]
mmitchell has joined #ruby
monkegjinni has quit [Read error: No route to host]
lggr has joined #ruby
monkegjinni has joined #ruby
Shrink has quit [Read error: Connection reset by peer]
Shrink has joined #ruby
thmzlt has joined #ruby
jlwestsr has quit [Ping timeout: 246 seconds]
justsee has joined #ruby
bbttxu_ has joined #ruby
a_a_g1 has quit [Quit: Leaving.]
ffranz has joined #ruby
jerius has joined #ruby
lggr has quit [Ping timeout: 240 seconds]
ananthakumaran has quit [Quit: Leaving.]
chrisramon has quit [Quit: chrisramon]
horofox has joined #ruby
nitti has quit [Remote host closed the connection]
cakehero has joined #ruby
lggr has joined #ruby
himsin has quit [Ping timeout: 260 seconds]
seoaqua has joined #ruby
kjellski has quit [Quit: This computer has gone to sleep]
invisime has joined #ruby
invisime has quit [Client Quit]
vaclavt has left #ruby [#ruby]
a1ph4g33k has joined #ruby
cloud|droid has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
<a1ph4g33k> good morning
theRoUS has joined #ruby
nateberkopec has joined #ruby
jlwestsr has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
reisl has quit [Quit: Leaving]
linoj has quit [Ping timeout: 252 seconds]
invisime has joined #ruby
<Iszak> Morning.
<rostisla_> hi
<invisime> good morning. :-)
lggr has joined #ruby
v0n has quit [Quit: Leaving]
samphippen has joined #ruby
_bart has joined #ruby
v0n has joined #ruby
mercwithamouth has quit [Quit: leaving]
nitti has joined #ruby
philcrissman has joined #ruby
linoj has joined #ruby
philcrissman has quit [Read error: Connection reset by peer]
philcrissman has joined #ruby
mercwithamouth has joined #ruby
carloslopes has joined #ruby
KevinSjoberg has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
Jork1 has joined #ruby
stopbit has joined #ruby
ScottNYC has joined #ruby
alek_b_ has quit [Ping timeout: 265 seconds]
Takehiro has quit [Remote host closed the connection]
Takehiro has joined #ruby
hsbt_away is now known as hsbt
reuf has quit [Quit: Leaving]
paolooo has joined #ruby
alek_b has joined #ruby
lggr has quit [Ping timeout: 276 seconds]
bbttxu_ has quit [Quit: bbttxu_]
<ScottNYC> does someone know how to fix this? gem install rails
<ScottNYC> /usr/share/ruby/psych.rb:203:in `parse': (<unknown>): mapping values are not allowed in this context at line 2 column 9 (Psych::SyntaxError)
vlad_starkov has quit [Remote host closed the connection]
<ScottNYC> from /usr/share/ruby/psych.rb:151:in `parse'
nitti has quit [Remote host closed the connection]
<ScottNYC> from /usr/share/ruby/psych.rb:127:in `load'
a1ph4g33k has quit [Quit: leaving]
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
fatninja has joined #ruby
lggr has joined #ruby
Takehiro has quit [Ping timeout: 252 seconds]
sagax has quit [Quit: Ухожу я от вас]
<awestroke> ScottNYC: ruby version?
PapaSierra has left #ruby [#ruby]
<ScottNYC> awestroke ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
jrist is now known as jrist-afk
<awestroke> gem --version ?
daniel_hinojosa has joined #ruby
g0bl1n has quit [Quit: Ex-Chat]
<ScottNYC> awestroke any gem commands result in = /usr/share/ruby/psych.rb:203:in `parse': (<unknown>): mapping values are not allowed in this context at line 2 column 9 (Psych::SyntaxError)
<ScottNYC> from /usr/share/ruby/psych.rb:203:in `parse_stream'
<ScottNYC> from /usr/share/ruby/psych.rb:151:in `parse'
<awestroke> ScottNYC: if you installed via rbenv or rvm, did you run rvm requirements or rbenv bootstrap-ubuntu-12.04 respectively?
bapa has quit [Read error: Operation timed out]
josh^ has quit [Remote host closed the connection]
chrishunt has joined #ruby
<ScottNYC> I didnt use rbenv or rvm,
<ScottNYC> I just installed ruby
<ScottNYC> to system
<awestroke> with apt-get?
<ScottNYC> yum
_bart has quit [Quit: _bart]
<awestroke> I have no knowledge of yum
<awestroke> good luck
justsee has quit [Quit: Leaving...]
lolmaus has quit []
<awestroke> (I do think you should get rbenv-installer and install ruby via that instead)
chimay has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
Guest74267 has quit [Quit: Konversation terminated!]
dhruvasagar has quit [Ping timeout: 255 seconds]
timonv has quit [Remote host closed the connection]
xyzodiac has joined #ruby
methoddk has quit [Ping timeout: 244 seconds]
xyzodiac has quit [Client Quit]
<shevy> anyone of you guys have helpful hints when rewriting a program?
bapa has joined #ruby
lggr has joined #ruby
<hoelzro> don't screw it up?
Freijo has quit [Remote host closed the connection]
dr_bob has joined #ruby
_mak_ has joined #ruby
sent-hil has joined #ruby
_mak_ has left #ruby [#ruby]
methoddk has joined #ruby
dr_bob has quit [Client Quit]
bbttxu_ has joined #ruby
asteve has joined #ruby
vlad_starkov has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 255 seconds]
voodoofish430 has joined #ruby
dr_bob has joined #ruby
hsbt is now known as hsbt_away
pricees has joined #ruby
nitti has joined #ruby
wpaulson has joined #ruby
<hoffmanc> anyone know how to tell the mock framework to not give a shit about what args are passed?
lggr has joined #ruby
nitti has quit [Remote host closed the connection]
Apocalypse has quit [Ping timeout: 246 seconds]
<centipedefarmer> which mock framework? passed to what?
AlbireoX has joined #ruby
<hoffmanc> centipedefarmer, MiniTest, and I realize that it makes use of === so I'm good
jrist-afk is now known as jrist
<hoffmanc> just didn't know how to use === myself ;P
dr_bob has quit [Client Quit]
chrishunt has quit [Ping timeout: 276 seconds]
tagrudev has quit [Remote host closed the connection]
_md has joined #ruby
Ankhers has joined #ruby
Apocalypse has joined #ruby
Apocalypse has quit [Changing host]
Apocalypse has joined #ruby
mercwithamouth has quit [Ping timeout: 256 seconds]
verto is now known as verto|off
lggr has quit [Ping timeout: 265 seconds]
Takehiro has joined #ruby
keppy has joined #ruby
seoaqua has quit [Ping timeout: 244 seconds]
monkegjinni has quit [Read error: Connection reset by peer]
Neomex has joined #ruby
lggr has joined #ruby
omry has quit [Read error: Connection reset by peer]
samphippen has quit [Quit: Computer has gone to sleep.]
sent-hil has quit [Remote host closed the connection]
sent-hil has joined #ruby
thmzlt has quit [Remote host closed the connection]
heftig has quit [Ping timeout: 245 seconds]
omry has joined #ruby
havenn has joined #ruby
monkegjinni has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
Rydefalk_ has quit [Read error: Connection reset by peer]
Rydefalk has joined #ruby
dr_bob has joined #ruby
Vert has joined #ruby
Takehiro has quit [Ping timeout: 248 seconds]
dr_bob has quit [Client Quit]
dnstbr has joined #ruby
lggr has quit [Ping timeout: 244 seconds]
timonv has joined #ruby
iamjarvo has joined #ruby
lggr has joined #ruby
jhchabran has joined #ruby
ttt has quit [Remote host closed the connection]
keppy has quit [Quit: Lost terminal]
Jrz has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
thmzlt has joined #ruby
lazyPower has joined #ruby
ananthakumaran has joined #ruby
jamesaxl has joined #ruby
xyzodiac has joined #ruby
lggr has quit [Ping timeout: 252 seconds]
timonv has quit [Remote host closed the connection]
no_worries has joined #ruby
mohits has joined #ruby
mohits has quit [Changing host]
mohits has joined #ruby
maesbn has quit [Remote host closed the connection]
Jake232 has joined #ruby
maesbn has joined #ruby
Guest44051 is now known as fred
lggr has joined #ruby
fred has quit [Changing host]
fred has joined #ruby
chrishunt has joined #ruby
dr_bob has joined #ruby
answer_42 has joined #ruby
maesbn has quit [Ping timeout: 245 seconds]
xaq has quit [Remote host closed the connection]
Shrink has quit [Read error: Connection reset by peer]
lggr has quit [Ping timeout: 240 seconds]
jamesaxl has quit [Read error: No route to host]
Shrink has joined #ruby
xpen has quit [Remote host closed the connection]
xpen has joined #ruby
theRoUS has quit [Ping timeout: 272 seconds]
nitti has joined #ruby
cj3kim has joined #ruby
cj3kim has quit [Changing host]
cj3kim has joined #ruby
timonv has joined #ruby
lggr has joined #ruby
cardoni has joined #ruby
samphippen has joined #ruby
cj3kim has quit [Client Quit]
thecreators has quit [Quit: thecreators]
jamesaxl has joined #ruby
freeayu has quit [Remote host closed the connection]
Takehiro has joined #ruby
chimay has quit [Quit: WeeChat 0.4.0-dev]
hsbt_away is now known as hsbt
krz has joined #ruby
mohits has quit [Read error: Connection reset by peer]
nitti has quit [Ping timeout: 256 seconds]
Agis__ has joined #ruby
Neomex has quit [Quit: Neomex]
lggr has quit [Ping timeout: 276 seconds]
Takehiro has quit [Ping timeout: 248 seconds]
timonv has quit [Remote host closed the connection]
hsbt has quit [Ping timeout: 256 seconds]
xpen has quit [Remote host closed the connection]
xpen has joined #ruby
JonnieCache has quit [Ping timeout: 246 seconds]
xpen_ has joined #ruby
lggr has joined #ruby
mahmoudimus has joined #ruby
mengu_ has joined #ruby
mengu has quit [Ping timeout: 246 seconds]
<rking> Cool. Somehow manages to be a server error: https://github.com/centipedefarmer
<centipedefarmer> wow, that's odd
<Mon_Ouie> Noticed the same with someone else: https://github.com/shirok
aganov has quit [Remote host closed the connection]
<rking> Hrm, but not everyone.
ffranz has quit [Ping timeout: 265 seconds]
xpen has quit [Ping timeout: 246 seconds]
ffranz has joined #ruby
morozovm has quit [Read error: Connection reset by peer]
<centipedefarmer> ok well it's comforting to see it's not just me
<centipedefarmer> in an odd way
theRoUS has joined #ruby
morozovm has joined #ruby
jfredee has joined #ruby
ffranz has quit [Client Quit]
<centipedefarmer> because then it might be temporary and they'll fix it soon. don't see anything on their twitter mentioning any current problems thio
<mh`> bye github
<mh`> its been fairly slow all night
pradeepto has quit [Changing host]
pradeepto has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
<centipedefarmer> it's all right rking i can promise i have nothing all that interesting up there anyway
lggr has joined #ruby
<rking> I was web searching it before I read any scrollback. I saw "centipedefarmer, MiniTest" in such close proximity I had to see what in the world it was (MiniTest is my new favorite test framework)
<centipedefarmer> oh i dont know much about minitest
SegFaultAX|work has joined #ruby
mahmoudimus has quit [Quit: Computer has gone to sleep.]
<rking> My deal is that RSpec is cool or whatever, but it does a really bad job of making a run-time tree, so it's painful to use within the REPL.
xyzodiac has quit [Quit: Computer has gone to sleep.]
hsbt_away has joined #ruby
Neomex has joined #ruby
Neomex has quit [Client Quit]
mando has joined #ruby
punkrawkR has joined #ruby
<rking> (The generated class/methods are really generic, and also if you re-load the test file, it doesn't cause the new code to run the next time.)
w2f2 has quit [Ping timeout: 256 seconds]
mneorr has joined #ruby
wpaulson has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
xbayrockx has joined #ruby
elsifaka has quit [Quit: Veloma e!]
xbayrockx has quit [Client Quit]
beit has quit [Quit: beit]
xyzodiac has joined #ruby
sspiff has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 246 seconds]
thedeadghost has quit [Ping timeout: 260 seconds]
burgestrand has quit [Quit: Leaving.]
mengu__ has joined #ruby
mengu_ has quit [Ping timeout: 245 seconds]
brianpWins has quit [Quit: brianpWins]
lggr has joined #ruby
chussenot has quit [Quit: chussenot]
Morkel has quit [Quit: Morkel]
irleif has joined #ruby
philcrissman has quit [Remote host closed the connection]
yekta has quit [Read error: Operation timed out]
mohits has joined #ruby
_mak has quit [Remote host closed the connection]
darthdeus has quit [Ping timeout: 240 seconds]
yekta has joined #ruby
skaczor has joined #ruby
timonv has joined #ruby
vitoravelino is now known as vitoravelino`afk
adeponte has joined #ruby
timonv has quit [Remote host closed the connection]
cloud|droid has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 246 seconds]
morozovm_ has joined #ruby
morozovm has quit [Read error: Connection reset by peer]
morozovm_ is now known as morozovm
freezey has joined #ruby
monkegjinni has quit [Ping timeout: 245 seconds]
monkegjinni has joined #ruby
adeponte has quit [Remote host closed the connection]
lggr has joined #ruby
ottbot has quit [Remote host closed the connection]
chussenot has joined #ruby
LennyLinux has quit [Remote host closed the connection]
xaq has joined #ruby
advorak has joined #ruby
clocKwize has quit [Remote host closed the connection]
advorak has quit [Client Quit]
sebastorama has joined #ruby
advorak has joined #ruby
philcrissman has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
dnstbr has quit [Quit: Computer has gone to sleep.]
timonv has joined #ruby
piotr_ has quit [Ping timeout: 260 seconds]
SegFaultAX|work has quit [Ping timeout: 256 seconds]
roychri has joined #ruby
xpen_ has quit [Ping timeout: 260 seconds]
Synthead has joined #ruby
heftig has joined #ruby
SegFaultAX|work has joined #ruby
lggr has joined #ruby
niklasb has joined #ruby
xpen has joined #ruby
<roychri> I made a standalone script that connect to redis. Works on my dev but in prod, it does not work. Cannot require redis library. When I do 'gem which redis' it says it does not exists. But I know it does, we have rails application which works fine. I found a lib/redis.rb somewhere (using locate). How can I have my standalone ruby script (not part of rails, that is why I ask here and not in #RoR) see those libraries too?
awestroke has quit [Remote host closed the connection]
<roychri> the error when I try to execute my script : `require': cannot load such file -- redis (LoadError)
<roychri> The error when I run gem which redis : ERROR: Can't find ruby library file or shared library redis
<sent-hil> how do i tell if my ruby has been built with gdb debug support?
<sent-hil> i installed via rvm, so prob. not methinks
<roychri> but it exists, when I do locate redis.rb it says /{obfuscated/path}/shared/bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis.rb
mneorr has quit [Remote host closed the connection]
<elaptics> roychri: are you prefixing your script with 'bundle exec'?
lupine_85 has quit [Excess Flood]
A124 has joined #ruby
Taranis has quit [Quit: leaving]
ttt has joined #ruby
<roychri> elaptics: nope. But I did not have to in my dev. I will try. Thank you!
<elaptics> roychri: that will be the problem I imagine
mikepack has joined #ruby
theRoUS has quit [Read error: Operation timed out]
rabidpraxis has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
vitoravelino`afk is now known as vitoravelino
<roychri> elaptics: Thanks.... I tried "bundle exec /tmp/copy_redis.rb" but I got "bundler: not executable: /tmp/copy_redis.rb" so I turned the file into executable "chmod 755 /tmp/copy_redis.rb" and I also added shebang at the top of the file "#!/bin/env ruby" but now I get "bundler: command not found: /tmp/copy_redis.rb" followed by "Install missing gem executables with `bundle install`"
mneorr has joined #ruby
horofox has quit [Quit: horofox]
morozovm has quit [Quit: morozovm]
ttt has quit [Ping timeout: 240 seconds]
lggr has joined #ruby
kringa has quit [Ping timeout: 272 seconds]
lupine_85 has joined #ruby
Xeago_ has joined #ruby
Xeago_ has quit [Remote host closed the connection]
SegFaultAX|work has quit [Ping timeout: 248 seconds]
yekta has quit [Quit: yekta]
mva3212 has quit [Remote host closed the connection]
nwertman has joined #ruby
<shevy> I. Hate. Rewrites!!!
<shevy> hoelzro well, something more along the way "how to make the rewrites smoother" or even better "how to avoid having to rewrite anything at all ever"
<elaptics> roychri: how is ruby installed on your production box?
<shevy> I am now at about 75% status, but the rest is so SLOW and TEDIOUS and BORING... it is unbearable...
mva3212 has joined #ruby
<rking> shevy: Refactoring » Rewriting
Xeago has quit [Ping timeout: 252 seconds]
xpen has quit [Remote host closed the connection]
mva3212 has quit [Remote host closed the connection]
<centipedefarmer> unless he's talking about Apache mod_rewrite rewrites
<shevy> but the existing code base sucks :)
ScottNYC has quit [Quit: Leaving]
<centipedefarmer> ok apparently not
<shevy> I couldn't bear looking at it anymore either hehehe
<shevy> code that makes you so angry, watching it forces you to scream, run out and randomly hit people
mva3212 has joined #ruby
<centipedefarmer> hey anyone have any off-the-cuff ideas why my MySQL server would be just randomly dying?
<roychri> elaptics: Oh nice!! :( You might be on to something. There is two versions! one which was installed using apt and the other one which seems to have been compiled (its in /usr/local/bin/).
<shevy> centipedefarmer mysql deserves a good, clean fast death
<centipedefarmer> yeah that seems to answer some other question entirely
lggr has quit [Ping timeout: 245 seconds]
<centipedefarmer> my apps on this server just seem to all lose connection to mysql all at once now and again
<centipedefarmer> it's a bit upsetting
Takehiro has joined #ruby
greenarrow has quit [Read error: Connection reset by peer]
davidcelis has joined #ruby
davidcelis has quit [Changing host]
davidcelis has joined #ruby
greenarrow has joined #ruby
<shevy> sounds like my cheap ISP... it disconnects me a lot from IRC
x82_nicole has joined #ruby
<centipedefarmer> well my web server and mysql are on the same physical server
<Spaceghostc2c> That's the first thing you generally separate on the road to webscale.
<shevy> hehe
thedeadghost has joined #ruby
<shevy> the road to webscale... sounds kinda inspirational
<centipedefarmer> sure. thanks for all the recopmmendations for things to do someday.
monkegjinni has quit [Ping timeout: 260 seconds]
<shevy> well so far you didn't give that much information!
matthewrobbins_ has joined #ruby
matthewrobbins_ has quit [Client Quit]
lggr has joined #ruby
dr_bob has left #ruby [#ruby]
<centipedefarmer> i have a few rails apps on a dedicated server, using mysql running on the same server. Lately they all seem to lose connection to mysql at once.
monkegjinni has joined #ruby
<centipedefarmer> also my boss is cheap and doesn't like paying for more servers.
xyzodiac has quit [Quit: Computer has gone to sleep.]
bapa has quit [Ping timeout: 240 seconds]
<centipedefarmer> we're moving to something more virtualized soon, but that's soon, not today.
<shevy> and there is no better pattern to see when or why they lose the connection suddenly? no fail pattern at all?
timonv has quit [Remote host closed the connection]
<centipedefarmer> i have no knowledge of any particular pattern at this time
hsbt_away has quit [Ping timeout: 265 seconds]
Takehiro has quit [Ping timeout: 248 seconds]
matthewrobbins has quit [Ping timeout: 244 seconds]
<centipedefarmer> so i'm looking for general things like, "mysql might go down if it gets more than x connections" or something
SegFaultAX|work has joined #ruby
chin-tastic has joined #ruby
hoelzro is now known as hoelzro|away
irleif has quit [Quit: Computer has gone to sleep.]
nateberkopec has quit [Quit: Linkinus - http://linkinus.com]
brianpWins has joined #ruby
Eplemosen has quit [Quit: Hexchat FTW! http://www.hexchat.org/]
irleif has joined #ruby
lggr has quit [Ping timeout: 272 seconds]
<workmad3> centipedefarmer: you're not going to find general things like that, I suspect
<workmad3> centipedefarmer: it's all very dependent on your setup and config
d2dchat has joined #ruby
<workmad3> centipedefarmer: and what it really points to is that you need a sysadmin of some form for this
<centipedefarmer> yeah. for which, refer to earlier comments on cheapness :D
ryanlecompte has joined #ruby
<centipedefarmer> all right, well thanks
SCommette has joined #ruby
sneakyness_wk has joined #ruby
SCommette has quit [Client Quit]
fatninja has quit []
SCommette has joined #ruby
carloslopes has quit [Quit: Leaving.]
<workmad3> centipedefarmer: which is cheaper? sysadmin? more servers? constant failures?
Iszak has quit [Quit: User has gone to sleep.]
lggr has joined #ruby
chussenot has quit [Quit: chussenot]
theRoUS has joined #ruby
<workmad3> centipedefarmer: chances are you (or your boss) is going to need to decide on one of them ;)
<workmad3> centipedefarmer: maybe two ;)
chichou has quit [Ping timeout: 245 seconds]
chichou has joined #ruby
Monie has joined #ruby
Monie has joined #ruby
Monie has quit [Changing host]
Fraeon has joined #ruby
blazes816 has joined #ruby
yshh has quit [Remote host closed the connection]
Jake232 has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
<centipedefarmer> yeah i've been down this road though. So far I've been pressured to constantly do more with less servers. when we have weird downtime/performance issues I am not capable of getting to the bottom of, we hire a random yahoo off elance who does nothing
<shevy> hehe
jfredee has quit [Remote host closed the connection]
<centipedefarmer> the clients whose stuff we have on this are mostly small businesses, pretty low traffic... but there's > 50 of them.
theRoUS has quit [Read error: Operation timed out]
Servidorv has joined #ruby
<centipedefarmer> and more new ones all the time!
<centipedefarmer> anyway, enough bellyachin'
hsbt_away has joined #ruby
<workmad3> centipedefarmer: look for a new job? :D
Nisstyre has quit [Ping timeout: 240 seconds]
<davidcelis> ^
<centipedefarmer> yeah, that's an ongoing project of mine :D
<lectrick> darn you, rubyconf, for starting on halloween and ending on my best friend's surprise 40th birthday party :/
lggr has quit [Ping timeout: 260 seconds]
<lectrick> I think I will go as "Ghost of _Why" on day 1 of the conf
<centipedefarmer> :D
roadt has quit [Ping timeout: 245 seconds]
Servidorv has quit [Client Quit]
rabidpraxis has quit [Remote host closed the connection]
lggr has joined #ruby
cantonic_ has joined #ruby
SegFaultAX|work has quit [Ping timeout: 265 seconds]
Servidorv has joined #ruby
tjbiddle has joined #ruby
tjbiddle has quit [Remote host closed the connection]
tjbiddle has joined #ruby
<shevy> hehe
<shevy> you need a t-shirt with a _whycat mascot
davidcelis has quit [Quit: K-Lined.]
cantonic has quit [Ping timeout: 245 seconds]
cantonic_ is now known as cantonic
STyler has joined #ruby
SegFaultAX|work has joined #ruby
krz has quit [Quit: krz]
margle has quit [Quit: Computer has gone to sleep.]
bricker has joined #ruby
adeponte has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
bluOxigen has quit [Ping timeout: 245 seconds]
Virunga has joined #ruby
zeromodulus has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
jeffreybaird has quit [Quit: jeffreybaird]
Nisstyre has joined #ruby
xaq has quit [Remote host closed the connection]
mahmoudimus has joined #ruby
jgrevich has joined #ruby
monkegjinni has quit [Ping timeout: 252 seconds]
knirhs has joined #ruby
Dawne has joined #ruby
LBRapid has joined #ruby
monkegjinni has joined #ruby
margle has joined #ruby
jeffreybaird has joined #ruby
rabidpraxis has joined #ruby
Shrink has quit [Ping timeout: 246 seconds]
awestroke has joined #ruby
lggr has quit [Ping timeout: 240 seconds]
sgupta has joined #ruby
knirhs has quit [Read error: Connection reset by peer]
Shrink has joined #ruby
Shrink has quit [Changing host]
Shrink has joined #ruby
<Synthead> how can I use the mysql gem to fetch a hash? I'd prefer to get the column names in the result
knirhs has joined #ruby
lggr has joined #ruby
sgupta has quit [Read error: Connection reset by peer]
eldarik has joined #ruby
mrsolo has joined #ruby
werdnativ has joined #ruby
Vainoharhainen has quit [Quit: Leaving...]
apok has joined #ruby
zeromodulus has joined #ruby
erichmenge has joined #ruby
<havenn> Synthead: Is your hash in a mysql db? Do you want to fetch mysql tables and return a hash?
slainer68 has quit [Remote host closed the connection]
<Synthead> havenn: fetch mysql rows as a hash
<havenn> Synthead: I'd recommend sequel gem: http://sequel.rubyforge.org/
emadb has joined #ruby
JonnieCache has joined #ruby
a_a_g has joined #ruby
emadb has left #ruby [#ruby]
<Synthead> havenn: I'm using the mysql gem for portability. can it do the aforementioned?
Shrink has quit [Ping timeout: 248 seconds]
Elhu has quit [Quit: Computer has gone to sleep.]
voodoofish430 has quit [Read error: Connection reset by peer]
lggr has quit [Ping timeout: 260 seconds]
sailias has quit [Quit: Leaving.]
joshman_ has joined #ruby
zommi has quit [Quit: Leaving.]
tvw has quit [Remote host closed the connection]
zeromodulus has quit [Ping timeout: 246 seconds]
voodoofish430 has joined #ruby
baphled has quit [Ping timeout: 245 seconds]
chrismcg is now known as zz_chrismcg
margle has quit [Quit: Computer has gone to sleep.]
horofox has joined #ruby
lukaszk is now known as lukaszk_afk
jerius has quit [Quit: Computer has gone to sleep.]
a_a_g has quit [Quit: Leaving.]
lggr has joined #ruby
heftig has quit [Quit: leaving]
stephenjudkins has joined #ruby
chin-tastic has quit [Ping timeout: 246 seconds]
rubious has joined #ruby
joshman_ has quit [Ping timeout: 276 seconds]
ananthakumaran has quit [Quit: Leaving.]
philcrissman has quit [Remote host closed the connection]
shevy has quit [Ping timeout: 248 seconds]
lggr has quit [Ping timeout: 256 seconds]
jo__ has joined #ruby
apok has quit [Remote host closed the connection]
sebastorama has quit [Quit: Computer has gone to sleep.]
jo__ has quit [Client Quit]
davidcelis has joined #ruby
davidcelis has quit [Changing host]
davidcelis has joined #ruby
lggr has joined #ruby
nitti_ has joined #ruby
iamjarvo has quit [Ping timeout: 245 seconds]
tommyvyo_ has quit [Quit: Computer has gone to sleep.]
Takehiro has joined #ruby
apok has joined #ruby
hsbt_away is now known as hsbt
monkegjinni has quit [Read error: Operation timed out]
chin-tastic has joined #ruby
reinaldob has quit [Remote host closed the connection]
maasha has quit [Ping timeout: 245 seconds]
monkegjinni has joined #ruby
workmad3 has quit [Ping timeout: 260 seconds]
apeiros_ has joined #ruby
irleif has quit [Quit: Computer has gone to sleep.]
tommyvyo_ has joined #ruby
tommyvyo_ has quit [Changing host]
tommyvyo_ has joined #ruby
Takehiro has quit [Ping timeout: 248 seconds]
hsbt has quit [Ping timeout: 246 seconds]
voodoofish4301 has joined #ruby
JonnieCache has quit [Ping timeout: 255 seconds]
voodoofish430 has quit [Read error: Connection reset by peer]
DrShoggoth has joined #ruby
Tearan has joined #ruby
RJ3000_ has quit [Ping timeout: 265 seconds]
lggr has quit [Ping timeout: 276 seconds]
DrShoggoth has quit [Max SendQ exceeded]
DrShoggoth has joined #ruby
Virunga_ has joined #ruby
havenn has quit [Remote host closed the connection]
shevy has joined #ruby
lggr has joined #ruby
lukaszk_afk has quit [Ping timeout: 245 seconds]
carloslopes has joined #ruby
Virunga has quit [Ping timeout: 246 seconds]
voodoofish4301 has quit [Read error: Connection reset by peer]
zenformatics1 has joined #ruby
voodoofish430 has joined #ruby
zenformatics has quit [Ping timeout: 260 seconds]
nateberkopec has joined #ruby
bluOxigen has joined #ruby
friskd has joined #ruby
Tearan has quit [Quit: Sleepy Badger....]
und3f1 has joined #ruby
und3f has quit [Read error: Connection reset by peer]
adamkittelson has joined #ruby
thedeadghost has quit [Ping timeout: 244 seconds]
sailias has joined #ruby
_md has quit [Quit: Leaving...]
Tearan has joined #ruby
lggr has quit [Ping timeout: 252 seconds]
samuel02 has quit [Remote host closed the connection]
slainer68 has joined #ruby
wpaulson has joined #ruby
chin-tastic has quit [Ping timeout: 240 seconds]
timmow has quit [Quit: is having a nap]
SmoothSage__ has joined #ruby
SmoothSage_ has quit [Ping timeout: 244 seconds]
hsbt_away has joined #ruby
asv has joined #ruby
bluOxigen has quit [Ping timeout: 260 seconds]
margle has joined #ruby
<fmcgeough> Having a problem with an Ubuntu system. require 'httparty' is complaining that it can't load openssl. but the usual suspects : openssl and libssl-dev are definitely installed.
lggr has joined #ruby
<apeiros_> fmcgeough: how did you install ruby? and have openssl & libssl-dev been installed at the time you installed ruby?
elaptics is now known as elaptics`away
<fmcgeough> with rvm. rvm install 1.9.3
cascalheira has quit [Ping timeout: 240 seconds]
rabidpraxis has quit [Remote host closed the connection]
Emmanuel_Chanel has quit [Read error: Connection reset by peer]
<fmcgeough> I believe openssl & libssl-dev were after the Ruby install
graft has joined #ruby
hemanth has joined #ruby
stkowski has joined #ruby
sepp2k has quit [Ping timeout: 245 seconds]
sepp2k has joined #ruby
zeromodu_ has joined #ruby
<graft> okay, so i need to take an array of pairs and turn it into a 1-d array, like => [ [1, 4], [2, 3], [3,9 ] => [ 0, 4, 3, 9 ], what's a good one-liner for this?
<apeiros_> fmcgeough: if it was after install, then ruby could not be compiled with ssl support
<apeiros_> fmcgeough: so I'd simply try to install it again. also check rvm's help pages. they contain infos about the common issues
<fmcgeough> apeiros_: OK. so I'm going to remove and reinstall. thanks so much.
<apeiros_> graft: I fail to see the logic in your example
Emmanuel_Chanel has joined #ruby
dmiller has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
<graft> apeiros_: the first number in the pair is the index in the final array
Tearan has quit [Quit: Sleepy Badger....]
<apeiros_> graft: and the 0 comes out of thin air?
<graft> apeiros_: sure
<graft> apeiros_: default value
<apeiros_> 0
<apeiros_> o0
<apeiros_> and what with [[1,9],[1,8]]?
<graft> wouldn't happen
<apeiros_> graft: also "sure, default value", and "first value is the index" - those things are *NOT* self evident.
jrist is now known as jrist-afk
monkegjinni has quit [Read error: No route to host]
wallerdev has joined #ruby
monkegjinni has joined #ruby
himsin has joined #ruby
SmoothSage_ has joined #ruby
cody-- has quit [Remote host closed the connection]
freerobby1 has joined #ruby
<apeiros_> h = Hash.new(0).merge(Hash[yourary]); h.values_at(*0..h.keys.max)
SmoothSage__ has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
<apeiros_> something like that might work
<freerobby1> Any thoughts on why this regex match would hang indefinitely on 1.8, 1.9 and jruby? https://gist.github.com/b3deafcd893b6747efbc
Virunga_ has quit [Remote host closed the connection]
<apeiros_> freerobby1: backtrack explosion
<apeiros_> ** is usually a bad idea
<graft> apeiros_: ah, that works nicely, thanks
<freerobby1> apeiros_: Interesting. So is it a too many permutations thing?
<freerobby1> apeiros_: In that too many things can match each of the (…)* pieces?
wpaulson has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
<yxhuvud> freerobby1
<yxhuvud> argh. still coming to grips with new irc client.
<apeiros_> freerobby1: yes
<apeiros_> most likely that's the reason
<freerobby1> Thanks you both.
<apeiros_> yxhuvud: beat it into submission
<yxhuvud> Basically, you need to rewrite it so that you actuallu try to consume characters instead of * magic
<bricker> What's the difference between modes a and a+ for IO? I'm looking at the docs but I don't get it.
centipedefarmer has quit [Quit: This computer has gone to sleep]
Guest32404 is now known as crankycoder
wallerdev has quit [Client Quit]
verto|off is now known as verto
<bricker> The only difference seems to be, "The file is in the append mode" (a), vs. "The file opens in the append mode" (a+)
<apeiros_> bricker: you can't read from a file opened in 'a' mode
<apeiros_> bricker: um, are you looking at the same docs as I do?
<bricker> apeiros_: ohhhh
<bricker> apeiros_: probably not
<apeiros_> http://pastie.org/5036448 - straight from ri
<bricker> apeiros_: I was readying an SO answer that I thought was copied from the docs :)
SmoothSage__ has joined #ruby
SmoothSage_ has quit [Ping timeout: 245 seconds]
Agis__ has quit [Quit: Agis__]
Tearan has joined #ruby
mohits has quit [Read error: Connection reset by peer]
Tearan has quit [Client Quit]
<yxhuvud> bricker: it is not impossible that it did. Docs in 1.8 lacked quite a lot.
wpaulson has joined #ruby
ElderFain_ is now known as ElderFain
lggr has quit [Ping timeout: 260 seconds]
<apeiros_> na, that part is afaik untouched since early 1.8 docs
<apeiros_> and yes, docs did lack and still do. sadly.
* apeiros_ remembers Kernel#select: see Kernel#select -- awesome sauce
cascalheira has joined #ruby
twoism has joined #ruby
bapa has joined #ruby
twoism has quit [Remote host closed the connection]
Agis__ has joined #ruby
Agis__ has quit [Client Quit]
<yxhuvud> I like the ones that returned the documentation from classes that extended the class but not the class documentation itself.
irleif has joined #ruby
<apeiros_> ah yes, and you didn't know the source…
lggr has joined #ruby
dmiller has quit [Remote host closed the connection]
k_89 has joined #ruby
Tearan has joined #ruby
robotmay has quit [Remote host closed the connection]
cardoni has quit [Quit: cardoni]
philcrissman has joined #ruby
chin-tastic has joined #ruby
twoism has joined #ruby
wallerdev has joined #ruby
wpaulson has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
dmiller has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
evilsushi has joined #ruby
evilsushi has quit [Changing host]
evilsushi has joined #ruby
ffranz has joined #ruby
chin-tastic has quit [Ping timeout: 248 seconds]
adeponte has quit [Remote host closed the connection]
mieko has quit [Ping timeout: 240 seconds]
chin-tastic has joined #ruby
lggr has joined #ruby
<bricker> How can I print to STDOUT without a newline? Trying to get inline dots like rspec
jgrevich_ has joined #ruby
sn0wb1rd has joined #ruby
thedeadghost has joined #ruby
Monie has quit [Quit: Quit]
williamcotton_ has joined #ruby
jgrevich has quit [Ping timeout: 245 seconds]
jgrevich_ is now known as jgrevich
williamcotton has quit [Read error: Connection reset by peer]
williamcotton_ is now known as williamcotton
daniel_- has joined #ruby
daniel_- has quit [Changing host]
daniel_- has joined #ruby
Monie has joined #ruby
Monie has quit [Changing host]
Monie has joined #ruby
<matti> bricker: print
F1skr has quit [Quit: WeeChat 0.3.9]
cdzombak has quit []
dberg_ has joined #ruby
niklasb has quit [Ping timeout: 245 seconds]
alvaro_o has joined #ruby
freerobby1 has left #ruby [#ruby]
Neomex has joined #ruby
<RubyPanther> bricker: sometimes you need to flush to keep it from being buffered
Neomex has quit [Client Quit]
lggr has quit [Ping timeout: 272 seconds]
twoism has quit [Remote host closed the connection]
monkegjinni has quit [Ping timeout: 240 seconds]
dberg_ has left #ruby [#ruby]
Russell^^ has joined #ruby
prtksxna has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
<bricker> RubyPanther: Can you expand on that?
monkegjinni has joined #ruby
<bricker> RubyPanther: I'll be writing about 340 dots to STDOUT, do you think flush will be necessary?
Takehiro has joined #ruby
hsbt_away is now known as hsbt
<Cool_Fire> bricker: If there's no newline, it may well be yes
<bricker> Cool_Fire: so what is the difference, if there is a newline or not?
<GeekOnCoffee> many things flush on a newline
<Cool_Fire> ^ that
<Cool_Fire> line buffering
<matti> bricker: STDOUT.sync = true
niklasb has joined #ruby
locriani_ has joined #ruby
<Cool_Fire> You can also STDOUT.flush when you need to
<RubyPanther> bricker: If you don't see any output, you either set .sync or call #flush
<matti> :)
blinkerror has joined #ruby
<RubyPanther> between the two you can control delivery if desired
havenn has joined #ruby
Takehiro has quit [Ping timeout: 245 seconds]
Mon_Ouie has quit [Read error: Connection reset by peer]
locriani has quit [Ping timeout: 244 seconds]
lggr has quit [Ping timeout: 246 seconds]
nitti_ has quit [Remote host closed the connection]
<apeiros_> don't use STDOUT, use $stdout (just as all in stdlib/core does)
<matti> I am always confused by STDOUT vs $stdout ;/
<matti> Its like having a twin brother who is not quite alike.
fermion has joined #ruby
<apeiros_> $stdout can be (and sometimes becomes) reassigned, STDOUT can't.
lggr has joined #ruby
Mon_Ouie has joined #ruby
<apeiros_> (you can reopen, but that'd affect both and is thus a bad idea, also you can't reopen to a ducky IO, like StringIO)
fermion has quit [Client Quit]
Virunga has joined #ruby
heftig has joined #ruby
adeponte has joined #ruby
<apeiros_> general rule of thumb is: use the $vars in this case, not the constants. keep the constants as a backup.
tommyvyo_ has quit [Read error: Connection reset by peer]
tommyvyo_ has joined #ruby
tommyvyo_ has quit [Changing host]
tommyvyo_ has joined #ruby
Tearan has quit [Quit: Sleepy Badger....]
bluenemo has quit [Ping timeout: 240 seconds]
icole has joined #ruby
Xeago has joined #ruby
<msch> apeiros_: i just reassign STDOUT. was easy: STDOUT = 5
lggr has quit [Ping timeout: 248 seconds]
hsbt is now known as hsbt_away
Tearan has joined #ruby
lucianosousa has joined #ruby
lggr has joined #ruby
Virunga has quit [Remote host closed the connection]
monkegjinni has quit [Remote host closed the connection]
<apeiros_> msch: a) you get a warning, b) try it in a method
<apeiros_> but of course, bad-ass lamer code is all toplevel and uses constants like globals.
<apeiros_> (and yes, assigning to a constant should raise, that ruby just warns is lame)
Virunga has joined #ruby
ffranz1 has joined #ruby
ffranz has quit [Ping timeout: 265 seconds]
palyer has joined #ruby
palyboy has quit [Read error: Connection reset by peer]
iamjarvo has joined #ruby
<shevy> apeiros_!!!!!
<shevy> you are back!
tommyvyo_ has quit [Read error: Connection reset by peer]
theRoUS has joined #ruby
<matti> shevy: He never left.
tommyvyo_ has joined #ruby
tommyvyo_ has quit [Changing host]
tommyvyo_ has joined #ruby
<shevy> he was like gone for FIVE WEEKS AT LEAST
margle has quit [Quit: Computer has gone to sleep.]
lggr has quit [Ping timeout: 246 seconds]
Takehiro has joined #ruby
havenn has quit [Remote host closed the connection]
frogprince_mac has quit [Quit: Bye!]
cardoni has joined #ruby
thecreators has joined #ruby
frogprince_mac has joined #ruby
reset has joined #ruby
omry has quit [Ping timeout: 245 seconds]
burgestrand has joined #ruby
lggr has joined #ruby
carloslopes has quit [Quit: Leaving.]
adeponte has quit [Remote host closed the connection]
chin-tastic has quit [Ping timeout: 246 seconds]
<davidcelis> name = "David Celis"; name[/ (?<surname>.+)$/, :surname] = "Smellis"; p name # => "David Smellis"
<davidcelis> cool story rubby
Tearan has quit [Quit: Sleepy Badger....]
<davidcelis> this 4 year-old MacBook segfaults when bundling via HTTPS...
lggr has quit [Ping timeout: 252 seconds]
jrist-afk is now known as jrist
peregrine81 has quit [Quit: Computer sleeping.]
peregrine81 has joined #ruby
lggr has joined #ruby
ziffa has joined #ruby
<ziffa> Hi all
<ziffa> I am installing rbenv
<ziffa> and for some reason the version is still showing as the old one
<ziffa> I[20:53:08] Rene Zammit: Installed rubygems-1.8.23 to /home/il-glanz/.rbenv/versions/1.9.3-p125
<ziffa> il-glanz@ubuntu:~/www/ruby-build$ rbenv rehash
<ziffa> il-glanz@ubuntu:~/www/ruby-build$ rbenv global 1.9.3-p25
<ziffa> il-glanz@ubuntu:~/www/ruby-build$
<ziffa> rbenv: version `1.9.3-p25' not installed
<ziffa> il-glanz@ubuntu:~/www/ruby-build$ rbenv global 1.9.3-p125
<ziffa> il-glanz@ubuntu:~/www/ruby-build$ ruby -v
<ziffa> ruby 1.8.7 (2011-06-30 patchlevel 352) [x86_64-linux]
reset has quit [Quit: Leaving...]
<ziffa> can somebody help me please?
<apeiros_> ziffa: you should read the topic in channels you join
sent-hil has quit [Remote host closed the connection]
<apeiros_> the topic of this one says: >3 lines into a pastebin service
rippa has joined #ruby
<ziffa> so what I should do
sent-hil has joined #ruby
sailias has quit [Ping timeout: 245 seconds]
mengu__ has quit [Quit: Konversation terminated!]
cascalheira has quit [Quit: Linkinus - http://linkinus.com]
chin-tastic has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
ffranz1 has quit [Quit: Leaving]
imami|afk is now known as banseljaj
davidcelis has quit [Quit: K-Lined.]
locriani_ has quit [Ping timeout: 252 seconds]
sagax has joined #ruby
lggr has joined #ruby
locriani has joined #ruby
Rydefalk has quit [Read error: Connection reset by peer]
Rydefalk_ has joined #ruby
chichou has quit [Remote host closed the connection]
stephenjudkins has quit [Quit: stephenjudkins]
harushimo has joined #ruby
<harushimo> here is question to everyone: what are getters and setters in ruby
<harushimo> I'm not understanding this concept at all
adeponte has joined #ruby
<yxhuvud> harushimo what's to udnerstand? They are methods.
<harushimo> I know they are methods
<GeekOnCoffee> harushimo: a setter sets a variable on a class, and a getter gets it
<harushimo> what is the difference? how do you invoke it
<GeekOnCoffee> sorry, on an object
<harushimo> if we some called class foo, @foo is the setter
<harushimo> correct me
<yxhuvud> @foo is the instance variable.
<harushimo> @foo = foo
<harushimo> this is instance variable is being set to the foo variable right
<GeekOnCoffee> if your instance @foo of object Foo has a variable bar, @foo.bar= is your setter and @foo.bar is your getter
miphe has joined #ruby
<yxhuvud> harushimo class Foo; def foo; @foo; end; def foo= bar; @foo = bar; end; end;
<yxhuvud> foo is a getter, foo= is the setter.
Neurotiquette has joined #ruby
<yxhuvud> and then you have convenience creation of tehm with attr_accessor and the like
<harushimo> okay
<Neurotiquette> How do I return a Time object that represents the time&date that is 3 days from current time today but at 9am?
lggr has quit [Ping timeout: 255 seconds]
<harushimo> alright
mxweas has joined #ruby
no_worries has quit [Remote host closed the connection]
Servidorv has quit [Quit: I used to think I was indecisive, but now I'm not too sure.]
Asher has joined #ruby
<harushimo> you can def foo = bar?
blazes816 has quit [Ping timeout: 240 seconds]
<harushimo> you can do def foo = bar?
blazes816 has joined #ruby
<thmzlt> Neurotiquette: Time.parse("#{(Date.today+3).to_s} 9:00")
<Neurotiquette> thmzIt: thank you! :)
<thmzlt> Neurotiquette: or just Time.parse("#{Date.today+3} 9:00")
<yxhuvud> harushimo: try it.
<harushimo> ok thanks
<Mon_Ouie> It should just be "foo=" instead "foo ="
no_worries has joined #ruby
lggr has joined #ruby
kaawee has quit [Ping timeout: 245 seconds]
frogprince_mac has quit [Quit: Leaving...]
hsbt_away is now known as hsbt
<harushimo> I get syntax error
<harushimo> did I do something wrong?
saschagehlich has joined #ruby
no_worries has quit [Remote host closed the connection]
<harushimo> I did this
<harushimo> I may have messed up on this
<blazes816> def foo_2=
<blazes816> is all that should be on that line
<thmzlt> harushimo: line 6, try "def foo_2=(bar)"
<blazes816> no
<blazes816> there, that's what I mean to type :)
<blazes816> thmzlt's got my back
<ziffa> HI all can someone help me please
<ziffa> I am installing rbenv latest version
<ziffa> though after installation, i am doing ruby -v and I am still getting and old version
<harushimo> oh okay
Arrendajo has joined #ruby
xyzodiac has joined #ruby
daniel_hinojosa has quit [Quit: Leaving.]
<harushimo> i'm still get the syntax error
irleif has quit [Quit: Computer has gone to sleep.]
Arrendajo has left #ruby [#ruby]
nitti has joined #ruby
Jork1 has quit [Quit: Jork1]
thedeadghost has quit [Ping timeout: 255 seconds]
adeponte has quit [Remote host closed the connection]
sebastorama has joined #ruby
lggr has quit [Ping timeout: 276 seconds]
jlwestsr has quit [Quit: Ex-Chat]
twoism has joined #ruby
ziffa has left #ruby [#ruby]
thedeadghost has joined #ruby
PragCypher has joined #ruby
lggr has joined #ruby
swarley has joined #ruby
bapa has quit [Ping timeout: 265 seconds]
nitti has quit [Ping timeout: 260 seconds]
nitti has joined #ruby
gmci has joined #ruby
twoism has quit [Ping timeout: 245 seconds]
<Spooner> harushimo : What is your code now?
Jork1 has joined #ruby
<harushimo> I'm trying getter and setter variables
<swarley> hello
<harushimo> I just fix the second function. I'm trying to return what is inside the second function
<Spooner> harushimo : I know, but your gist hasn't been updated with the suggestions other people made. Not sure where you fell down since then...
<harushimo> give me sec
<harushimo> I'm updating right now
* Spooner presses F5.
grubles has joined #ruby
<apeiros_> Spooner: you're supposed to help by magic, d'uh!
<swarley> maaaaaaaaaaaaaaaagiiiiiiccc
nanderoo has quit [Quit: Leaving.]
lggr has quit [Ping timeout: 276 seconds]
<apeiros_> isn't swarley barney's other name?
<Spooner> I am hoping that pressing F5 will just fix it ;)
<swarley> Yeah
<apeiros_> hi swarley! :D
<swarley> haaai
<harushimo> am I calling the foo object properly
bapa has joined #ruby
<apeiros_> harushimo: when you get exceptions, *always* paste them too
hsbt is now known as hsbt_away
Takehiro has quit [Remote host closed the connection]
<apeiros_> people are *not* mind readers, yknow?
<harushimo> sorry
<swarley> harushimo;
<swarley> there error there
<harushimo> let me update it
<thmzlt> harushimo: you are calling #foo_2 in the class Foo
<Spooner> harushimo : OK, completely different problem. You are calling _instance_ variables on a class.
<swarley> is that you're calling Foo.bar
<swarley> not Foo#bar
* apeiros_ guesses there is no syntax error…
<swarley> try Foo.new.bar
<apeiros_> just a NoMethodError
<swarley> Foo::Bar not Foo.bar my bad
emmanuelux has joined #ruby
Takehiro has joined #ruby
<swarley> ... Foo::bar
blazes816 has quit [Ping timeout: 252 seconds]
<apeiros_> Errno::ETOOMANYHELPERS
<swarley> force of habit to camel cas
daniel_- has quit [Ping timeout: 245 seconds]
<swarley> also, its easier to use attr_accessor when you're trying to do what you're doing
<Spooner> No, you mean "Foo.new.foo" and "Foo.new.foo_2 = 5".
<harushimo> @foo_2 = bar
<thmzlt> harushimo: I reccomendo you to watch the first episode of this: http://pragprog.com/screencasts/v-dtrubyom/the-ruby-object-model-and-metaprogramming
<harushimo> what does this do
xyzodiac has quit [Quit: Computer has gone to sleep.]
<swarley> its uh
<swarley> really confusing
<swarley> and probably isnt what you want
lggr has joined #ruby
<swarley> class Foo; attr_accessor :foo; end
<harushimo> okay
<thmzlt> *recommend
blazes816 has joined #ruby
<Spooner> swarley : However, there are plenty of times when you really don't want a plain accessor (though if harushimo is struggling with stuff like "@foo_2 = bar" it is probably what is wanted).
zeromodu_ has quit [Ping timeout: 245 seconds]
<swarley> Spooner; yeah, but attr_accessor is a good place to start investigating before you start a grand metaprogramming adventure
bapa has quit [Ping timeout: 245 seconds]
<harushimo> oh okay
adeponte has joined #ruby
joshman_ has joined #ruby
MikeyV27 has quit [Quit: MikeyV27]
<harushimo> lets not use the attr_accessor, its confusing me
<Spooner> swarley : No, I didn't mean that. I meant that you often want manual get/setters (e.g. if you want type checking or something to happen on set) so the answer isn't always "just use attr_*". Although here it is.
<swarley> ah
<harushimo> def foo=(a value)
<swarley> yeah, i mean its not always what you want
<swarley> but given the example
<harushimo> foo= is the setter correct
<swarley> attr_accessor is just a correct duplicate
<harushimo> okay
<swarley> harushimo; the error is that you are trying to call an object method on the class
<harushimo> there is
<harushimo> you are right
<harushimo> before I get into that error, let me understand this concept first
<harushimo> heh
<harushimo> e
<swarley> you need to create a new Foo object before you can call Foo#foo
<swarley> foo= is the setter
<swarley> because you are setting the value
<swarley> however
<harushimo> yes
<swarley> because you're doing @foo_2, you are getting and setting two different values
<harushimo> foo itself is the getter
<swarley> doing @foo_2 = bar
<harushimo> I shouldn't use instance variable their
<harushimo> I mean there
<swarley> you should
<swarley> but you should use @foo = bar
<swarley> not @foo_2
dblandin has joined #ruby
<swarley> if you're trying to get and set the same value
lggr has quit [Ping timeout: 260 seconds]
<harushimo> because I established @foo in my foo function
<harushimo> I'm trying to get and set the same value
<Spooner> harushimo : https://gist.github.com/3874985 - any clearer?
jmaya has joined #ruby
<swarley> hm, can you call a proc within itself?
<Spooner> Assuming you have a reference to it, you should be able to.
<swarley> damn
<Spooner> You just can't magically get a reference to it.
<harushimo> perfect
nwertman has quit [Quit: nwertman]
<harushimo> now I get it what its doing
Jork1 has quit [Quit: Jork1]
<swarley> i guess this works
<Spooner> harushimo : As said, attr_accessor is just saves you writing it all out.
<swarley> def factorial(x); if x < 1 then 1 else x * factorial(x-1) end; end
<Spooner> swarley : That isn't a proc, it is a method.
<swarley> i know
<harushimo> the infamous factorial program
<harushimo> I've seen twice in a couple of languages
<swarley> i'm settling
<swarley> i would have rather done it in a straight proc
Morkel has joined #ruby
lggr has joined #ruby
<harushimo> what do you mean straight proc
<swarley> proc { }
<blazes816> Proc.new{}
<harushimo> do you the proc initialization where you have attr_accessor
<Spooner> harushimo : It isn't the same thing. A proc is a sort of anonymous method, not a class.
rippa has quit [Ping timeout: 256 seconds]
daniel_hinojosa has joined #ruby
havenn has joined #ruby
<Spooner> harushimo : You might weant to work through this tutorial to get a better grasp of the Ruby basics: http://pine.fm/LearnToProgram/?Chapter=01
<Spooner> (obviously skip the bits you already know)
<Spooner> *want to work through
<havenn> harushimo: Have you gone through 'try ruby' yet?: http://tryruby.org/
workmad3 has joined #ruby
<havenn> harushimo: Or Ruby Koans onine?: http://koans.heroku.com/
<havenn> online**
frederic has quit [Remote host closed the connection]
<Spooner> The last thing to recommend newbies is a slice of why :/
lggr has quit [Ping timeout: 245 seconds]
locriani has quit [Ping timeout: 246 seconds]
nitti is now known as _nitti
<RubyPanther> I would recommend it as the first thing.
<Spooner> Unless they are happy with one-useful-fact-per-hour learning ;)
<havenn> Spooner: It was the first Ruby book I read. >.> MOAR FOXES!
<swarley> I think why is better reserved for more advanced programmers
<RubyPanther> Spooner: it is entirely up to the reader to stare at the foxes for an hour, or skip ahead to the code.
<swarley> As a refresher
mva3212 has quit [Remote host closed the connection]
<swarley> i wouldnt have understood _why as a noob
<Spooner> RubyPanther : Because a Ruby newbie would actually know that why is 99% fluff and which bits it is safe to skip? Nah.
<RubyPanther> His code is always wonderful. His old Hpricot is still compiling, even on Ruby 2, and that other one people use now is still maintained and doesn't compile on 2.0
<RubyPanther> Spooner: they don't need to, they just need to follow from one page to the next and try the examples
<Spooner> The quality of his code is pretty irrelevant to his teaching materials.
<waxjar> i learned ruby through why and some google-fu
<swarley> I thought he died?
<RubyPanther> They make it out of Dwemthy's Array alive and they're ready to do some metaprogramming
<workmad3> swarley: only digitally
<swarley> ah
<havenn> Spooner: Admittedly, I didn't read all of the foxes' banter - but I found parusing the code enjoyable and informative.
<workmad3> swarley: as far as anyone knows
[diecast] has left #ruby [#ruby]
<RubyPanther> No, he's fine, everybody knows
jmaya has quit [Quit: Colloquy for iPad - http://colloquy.mobi]
<RubyPanther> _why was a performance art character, that was discontinued. The human artist is fine.
<havenn> Anyone listen to the soundtrack while reading the book??
lggr has joined #ruby
<RubyPanther> havenn: I didn't while reading it, but I listen to it while I exercise
yxhuvud has quit [Ping timeout: 245 seconds]
<swarley> lol
blinkerror has quit [Ping timeout: 246 seconds]
jenrzzz has joined #ruby
<havenn> I like Chapter 2's song: "This book is made of rabbits and lemonade."
<RubyPanther> There is a live _why concert bootleg out there, from a concert at a Ruby convention I think
<swarley> rofl
ffranz has joined #ruby
<RubyPanther> That's how he was outed, somebody recognized his art on an album cover from an old band
kringa has joined #ruby
<Spooner> Never understood the wish for anonymity in someone who turned up to cons. Maybe if you are purely a digital presence, but he was rather a public figure *shrugs*
locriani has joined #ruby
<swarley> I'd love to be recognized
advorak has quit [Quit: Leaving]
<swarley> that would be amazing for me
<Spooner> (that is, name-anonymity, rather than knowing where he lives and other personal info).
wedtm is now known as wedtm|away
margle has joined #ruby
daniel_hinojosa has quit [Quit: Leaving.]
<havenn> Spooner: He wasn't anonymous, his name is just _why (his middle name, he didn't have a first or a last). Now _why's just somebody that Ruby used to know... Somebody!
niklasb has quit [Ping timeout: 276 seconds]
<swarley> he didnt have to cut us out
sn0wb1rd has quit [Quit: sn0wb1rd]
<workmad3> havenn: no, _why was his title. His name was _the_lucky_stiff :P
<swarley> act like ruby never happened and that it was nothing
<havenn> My sister's boyfriend's brother is name Chuck Trucktropolis, so _why isn't that odd really.
<swarley> but we don't even need him though
<swarley> now he's just somebody that wrote some code
TomRone has quit [Ping timeout: 260 seconds]
lggr has quit [Ping timeout: 246 seconds]
<Spooner> Not now, perhaps.
lushious has quit [Ping timeout: 252 seconds]
<Spooner> Though now we are led by Rails, not _why, we definitely lost something ;) (Although I don't rate his book for newbies, it was a beautiful thing).
<swarley> i dont know, i'd be lost without hpricot
sn0wb1rd has joined #ruby
<havenn> swarley: nokogiri
t0rc has joined #ruby
<swarley> I never got nokogiri to install on my last machine so i've never used it
<RubyPanther> He was generally disgruntled with the Ruby community, and having digging into his personal life wasn't worth the bother for what he was getting back.
<havenn> swarley: Write hpricot style syntax wrapper around nokogiri?
<swarley> hm
lushious has joined #ruby
TomRone has joined #ruby
<havenn> swarley: If I recall, the hpricot discontinuation page actually suggests that tact if you want to continue hpricot's legacy.
Aristata has joined #ruby
centipedefarmer has joined #ruby
asv has quit [Ping timeout: 252 seconds]
<swarley> its probably been done then?
<RubyPanther> I'm just still using hpricot, what is there to continue?
zeromodulus has joined #ruby
<Spooner> havenn yes, it does suggest that: https://github.com/hpricot/hpricot
lggr has joined #ruby
<RubyPanther> Why would a well-written parser need constant updating?
<bperry> nokogiri is definitely the way to go
<havenn> swarley: Not that I know of. If it has, let hpricot maintainers know so they can point to it!
<bperry> hpricot load sthe entire xml file into memory
<bperry> nokogiri is a stream based parser
<bperry> so it is a lot faster
<RubyPanther> hpricot still works fine in Ruby 2, nokogiri won't compile
<bperry> way better performance
<wmoxam> Is it just me or does ruby not have bitwise assignment operators?
<RubyPanther> which one is "maintained"
<swarley> wmoxam; it does
<Spooner> bperry : It doesn't matter. hpricot is like the Bible or Koran. You can't let go of it ;)
<havenn> nokogiri means saw in Japanese, the word sounds like th emeaning
<wmoxam> swarley: oh?
<swarley> yes
<RubyPanther> it just tastes so sweet
chin-tastic has quit [Ping timeout: 272 seconds]
thejoecarroll has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
<havenn> RubyPanther: nokogiri compiles fine for me in 2.0.0
mucker has quit [Quit: leaving]
<RubyPanther> havenn: that's good to know, I'll pull and try again
SmoothSage_ has joined #ruby
<Spooner> swarley : I don't think it does, although it does support some bitwise stuff (|, &, ~, etc). You can't do: x = 5; x[0] = 0; x == 4
SmoothSage__ has quit [Ping timeout: 245 seconds]
Goles has joined #ruby
<havenn> Anyone done a native Ruby SHA-3 yet? I say Phusion guys' C-extension but I'm curious what a pure Ruby implementation would look like.
<havenn> ^say^saw
<Spooner> wmoxam : What was it you wanted to do with bits?
skogis has quit [Ping timeout: 260 seconds]
<wmoxam> foo &= ~bar
<wmoxam> rather than foo = foo & bar
<thejoecarroll> hi folks. i'm relatively inexperienced with ruby, rails etc. can anyone please advise on the use of the bundle command and specifically how to manipulate and fix a broken dependency?
<wmoxam> :p
zeromodulus has quit [Ping timeout: 255 seconds]
<wmoxam> er, foo = foo & ~bar
<havenn> thejoecarroll: To bundle your bundle type 'bundle'. The gems you are bundling with bundle are in your 'Gemfile'.
<Spooner> wmoxam : foo &= ~bar works fine.
Goles has quit [Read error: Connection reset by peer]
<thejoecarroll> e.g. how can i change what version of therubyracer get's installed when i run bundle install --without production
<havenn> thejoecarroll: Edit your Gemfile.
<thejoecarroll> thanks havenn.
<wmoxam> Spooner: hrmm, must be a version >= 1.9 thing :p
<thejoecarroll> i'm working on an example rails app for a course i'm taking
<havenn> The proceeds of proceeds are no longer proceeds under the revised rule of proceeds.
<thejoecarroll> i already had a look at the gemfile
<workmad3> thejoecarroll: if you need a specific version, edit the Gemfile and add the version for it
lggr has quit [Ping timeout: 260 seconds]
<workmad3> thejoecarroll: then re-run 'bundle'
timonv has joined #ruby
<Aristata> Hello, having some issues with devise. I am calling sign_in(:patron, @patron) in my controller, but am getting redirected to the login screen after? Any ideas? I have it setup so that an ajax call creates the account, if the account is valid we are signing in the user and sending some json back saying things are ok. The javascript then reloads the page and the user is signed in!
<Aristata> However, something must be signing out the user or I should never get to a sign in page
<workmad3> thejoecarroll: if you just need to update it and no version is specified, then 'bundle update therubyracer'
krawchyk has quit [Remote host closed the connection]
<Spooner> wmoxam : Nope, works fine in 1.8.7 too (I checked in 1.9.3 originally).
<wmoxam> hrmm
<havenn> thejoecarroll: Bundler bundles your bundle with the command 'bundle'.
<wmoxam> oh, nm
<thejoecarroll> there's no version given in the gemfile, but for some reason bundle keeps trying to install an older broken version of therubyracer than the gem i've already successfully installed!
<wmoxam> I'm dumb
<workmad3> thejoecarroll: that's because the version will be locked inside the Gemfile.lock file
<havenn> thejoecarroll: It is probably a dependency for another gem in your Gemfile.
<Spooner> Aristata : #rubyonrails is probably better place to ask.
<workmad3> thejoecarroll: to unlock it, do what I just said with 'bundle update therubyracer'
<Aristata> i have it in there too, thanks
<swarley> can i have a link to the ruby 2.0 svn branch?
reset has joined #ruby
<thejoecarroll> ok, thanks workmad3 and havenn. i'll give those suggestions a try now
lggr has joined #ruby
<swarley> thanks
sneakyness__wk has joined #ruby
sneakyness_wk has quit [Read error: Connection reset by peer]
sneakyness__wk is now known as sneakyness_wk
beefsupreme has joined #ruby
sneakyness_wk has quit [Read error: Connection reset by peer]
sneakyness__wk has joined #ruby
sneakyness__wk is now known as sneakyness_wk
hsbt_away is now known as hsbt
<swarley> also
<swarley> is it usable?
<havenn> swarley: Yes. There are the odd compiled gems that wont compile, but definately usable.
reuf has joined #ruby
<thejoecarroll> i manually edited the Gemfile to require a specific (current) version of therubyrace and that fixed that… but then it turned out that an outdated version of uglifier was referenced there. then i tried running just 'bundle update' and that did the trick! easy when you know how :-) cheers folks!
<swarley> awesome
lggr has quit [Ping timeout: 246 seconds]
<havenn> thejoecarroll: 'bundle' is an alias to 'bundle update' but different than 'bundle upgrade'
<havenn> btw
<thejoecarroll> ok, good to know
adamkittelson has quit [Remote host closed the connection]
whowantstolivefo has joined #ruby
jfuentes has joined #ruby
<thejoecarroll> hmm, now 'rake db:migrate' fails, complaining 'cannot load such file -- sqlite3/sqlite3_native'
<thejoecarroll> i guess i can take this one to the rails room, though
JonnieCache has joined #ruby
mercwithamouth has joined #ruby
chin-tastic has joined #ruby
<havenn> thejoecarroll: Do you have "gem 'sqlite3-ruby'" in your Gemfile?
pricees has quit [Ping timeout: 246 seconds]
<digerati_> Codecademy.com has Ruby lessons now :)
<havenn> digerati_: Good ones??
lggr has joined #ruby
<digerati_> havenn: i believe all the stuff is intro lessons
<digerati_> they started with java
Chryson has joined #ruby
<digerati_> but now have expanded to other languages
<digerati_> its pretty neat :)
xyzodiac has joined #ruby
<swarley> i just bought the linux format code academy issue
<swarley> only had python and php in it
scx has joined #ruby
<scx> hello
linoj has quit [Ping timeout: 248 seconds]
hoelzro|away is now known as hoelzro
<workmad3> havenn: actually 'bundle' is an alias to 'bundle install'
JonnieCache has quit [Ping timeout: 246 seconds]
chin-tastic has quit [Ping timeout: 245 seconds]
<Spooner> swarley : Some Ruby there - http://www.codecademy.com/tracks/ruby
<havenn> workmad3: ^ Yes... I must need more coffee. I got my 'install', 'update', 'upgrade' confused!!
<thejoecarroll> no, havenn, it seems not. here's what i'm working with: https://github.com/saasbook/hw2_rottenpotatoes/blob/master/Gemfile
erichmenge has quit [Quit: Be back later]
<scx> I have 'libsomething.rb'. I want to run `st = new Something; st.do_st()` when i call ruby ruby libsomething.rb but dont create instance when i only 'require_relative libsomething'; how to do that?
otters has quit [Ping timeout: 246 seconds]
<Spooner> scx I'm not following you, sorry.
<havenn> workmad3: Sorry bout the disinformation. **Meant 'bundle' == 'bundle install' != 'bundle update' as you point out!!
<workmad3> thejoecarroll: it's not a good idea to run a blanket 'bundle update' btw... it's better to update specific gems, e.g. 'bundle update therubyracer uglifier ...'
<Spooner> Oh, no, I remember this problem. Yeah, don't rely on "libraries" that also create the class as an example ;)
lggr has quit [Ping timeout: 248 seconds]
<swarley> def bomb(); fork do; bomb(); end; end
mensvaga has quit [Quit: Leaving.]
daniel_- has joined #ruby
<thejoecarroll> bit late now, workmad3, but thanks for the tip :-)
<havenn> workmad3: Going between gem, brew, yum, apt-get, npm, pip, etc I forget the install versus bundle versus upgrade. >.>
daniel_- has quit [Changing host]
daniel_- has joined #ruby
<workmad3> thejoecarroll: you can always revert your Gemfile.lock back to pre-update and then do it properly ;)
<workmad3> havenn: ah yeah, np :) I always get 'brew update' and 'brew upgrade' messed up
RJ3000_ has joined #ruby
_nitti has quit [Remote host closed the connection]
LBRapid has quit [Quit: Farewell.]
<Spooner> scx Have you asked this question before (or am I confusing you with someone else?).
jenrzzz has quit [Ping timeout: 255 seconds]
eldarik has quit []
<Spooner> scx Right, put the instance creation lines inside "if $0 == __FILE__"
mgrayson has quit [Quit: mgrayson]
_nitti has joined #ruby
<scx> Spooner: ok, thanks
<Spooner> scx Sorry, someone else was asking recently how to avoid creating a new thing when loading someone else's file, not how to prevent the immediate code being run if you own the file.
hsbt is now known as hsbt_away
dv_ has quit [Ping timeout: 252 seconds]
lggr has joined #ruby
<Spooner> Scx Also, that isn't Ruby. You should use: st = Something.new
nwertman has joined #ruby
otters has joined #ruby
<Spooner> scx And it is "def initialize", not "def init"
<thejoecarroll> here's the trace results: http://pastebin.com/vR2T3S1i
k_89 has quit [Ping timeout: 245 seconds]
mark_locklear has quit [Remote host closed the connection]
dblandin has quit [Quit: dblandin]
lggr has quit [Ping timeout: 246 seconds]
no_worries has joined #ruby
possibilities has joined #ruby
<swarley> what are new features that are already present in ruby 2?
<waxjar> is there a preferred OS for running Ruby on?
<Spooner> swarley : It can compile hpricot ;)
answer_42 has quit [Read error: Operation timed out]
<possibilities> if a lib i'm using overrides one of my methods is there some way to call the overridden method?
<RubyPanther> swarley: the GC is fixed and COW works normally now
<Spooner> waxjar : OSX => hipster, Linux => beardie, Windows => idiot (I'm in the last camp)
<swarley> COW?
<canton7> copy on write
<swarley> LOL, mfw i have a beard
<RubyPanther> Copy-On-Write, the thing that makes OS-level memory sharing work well
robustus has quit [Quit: ZNC - http://znc.in]
<swarley> Linux OctaviasViolin 3.2.0-23-generic #36-Ubuntu SMP Tue Apr 10 20:39:51 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux
<bperry> I totally have a beard and run linux
<waxjar> Spooner: i should have said linux variant :P
<Spooner> possibilities : Nope.
<possibilities> Spooner: thank you! (:
<RubyPanther> The reason that, for example, mod_perl instances might have 50M shared and only 2-5M per instance
dblandin has joined #ruby
lggr has joined #ruby
<swarley> also
<RubyPanther> whereas in the Ruby work with current tools we would have like... 1M shared and 80M per instance
<Spooner> possibilities : It is just gone if someone else overwrites it. Really, they shouldn't though (either masking it with a module or using an alias-chain - or, ideally, not hacking your code).
Markvilla has joined #ruby
<swarley> is this branch stable to make install?
otters has quit [Ping timeout: 245 seconds]
gmurphey has quit [Ping timeout: 244 seconds]
mxweas has quit [Quit: Computer has gone to sleep.]
* thejoecarroll calling it a night (yawn)...
<possibilities> Spooner: yeah, i probably didn't ask the question well enough, i think if i got into the details it would be too annoying (:
syamajala has joined #ruby
<Spooner> possibilities : Yeah, probalby best to create a minimal example rather than explain the whole thing.
workmad3 has quit [Ping timeout: 260 seconds]
timonv has quit [Remote host closed the connection]
negev has joined #ruby
kirun has joined #ruby
<negev> hi, what modified is used with String#scan to match text on multiple lines? with perl regex's in php this is /s but that doesn't seem to work in ruby
<negev> s/modified/modifier
<swarley> swap
<swarley> String#sub
<Spooner> negev : /m is multiline
<negev> thanks
<swarley> s///
<Spooner> (if you mean "what makes . match newlines")
<possibilities> Spooner: thanks, we figured it out, i appreciate you trying to help the helpless
possibilities has quit [Remote host closed the connection]
Jamone has joined #ruby
<Spooner> possibilities : I'm just bored. You suck for not finding me a more meaty problem ;D
irleif has joined #ruby
lggr has quit [Ping timeout: 265 seconds]
<RubyPanther> https://gist.github.com/2600122 This is a 1.9.3 version with the new GC backported, and some other performance features
<swarley> Spooner; i'll issue you a challenge
<RubyPanther> That is the one I recommend for production
parzorep has quit [Quit: parzorep]
locriani has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
elux has joined #ruby
dblandin has quit [Quit: dblandin]
whowantstolivefo has quit [Quit: quit]
Monie has quit [Ping timeout: 244 seconds]
cmouse has joined #ruby
<cmouse> i have a problem with ruby's sqlite3 driver
<swarley> Spooner; make a better type insurance for methods than this https://gist.github.com/1b2ebb80e514196dd90d
<cmouse> it seems that it is not writing stuff into database under some conditions
<bperry> cmouse: that is probably a sqlite issue tbh :)
<swarley> i is a mutable variable
<cmouse> bperry: dunno.
<cmouse> bperry: the same code works when it's not run under webrick
SJr has quit [Excess Flood]
<bperry> yeah, locks are fun like that cmouse
<swarley> and you can do "args*" to get splats
<cmouse> bperry: :\
<swarley> use Mutex
<cmouse> bperry: would be really nice if it even gave exception or something
erichmenge has joined #ruby
kringa has quit [Ping timeout: 268 seconds]
<cmouse> bperry: but no, it just happily claims that data is safe & sound but when I look it up afterwards, it's not there
emmanuelux has quit [Remote host closed the connection]
<Spooner> swarley : What is wrong with what you have?
emmanuelux has joined #ruby
<Spooner> swarley : Apart from the fact it should be an ArgumentError?
<swarley> Spooner; i dont know, i just figured if you're bored i wouldnt say no to a better implementation
<swarley> ah, right
<apeiros_> cmouse: transactions which roll back maybe?
kringa has joined #ruby
<apeiros_> hard to telll without any useful information.
nazty has quit [Read error: Connection reset by peer]
nignaztic has quit [Quit: WeeChat 0.3.2]
margle has quit [Quit: Computer has gone to sleep.]
<Spooner> Hmm, no a TypeError (ArgumentError is for anything argumenty _except_ type ;D)
negev has quit [Quit: Lost terminal]
SJr has joined #ruby
<swarley> there fixed that
Morkel has quit [Quit: Morkel]
gks has joined #ruby
jcaudle has quit [Quit: jcaudle]
asteve has quit []
lggr has quit [Ping timeout: 260 seconds]
mrsolo has joined #ruby
chin-tastic has joined #ruby
<gks> hey guys, having a small issue with Bundler that I was hoping someone may have a suggestion for. The Gemfile has "gem "jekyll", :git => "git://github.com/mojombo/jekyll.git"" in it, when i try "bundler exec jekyll it says "git://github.com/mojombo/jekyll.git (at master) is not checked out. Please run `bundle install`" after running bundle install, it continues to say both
_nitti has quit [Remote host closed the connection]
<cmouse> :\
<cmouse> mutex did not help out
<swarley> hm i'll need to rework this a little bit
Goles has joined #ruby
tommyvyo_ has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
axl_ has quit [Quit: axl_]
lggr has joined #ruby
<Spooner> swarley : How do you initialize i in the block?
cardoni has quit [Quit: cardoni]
zeromodulus has joined #ruby
<swarley> Spooner; http://pastebin.com/ydLtqupt
<apeiros_> omg, what did I just read?
* apeiros_ needs some eyebleach.com
<swarley> its bad
<Spooner> swarley : while args.any? or until args.empty? - yeah, that is horridible ;)
<swarley> because i just butchered it
erichmenge has quit [Quit: Be back later]
margle has joined #ruby
adamkittelson has joined #ruby
rabidpraxis has joined #ruby
<Spooner> swarley : args = [args] unless args.is_a? Array ===> args = Array(args)
<apeiros_> args.any? is a broken replacement for !args.empty?
jasond has quit [Ping timeout: 246 seconds]
<swarley> It wasnt meant to be seen :p
<apeiros_> [false] <-- broken
<Spooner> apeiros_ : What is wrong with that?
sent-hil has quit [Remote host closed the connection]
<apeiros_> [false].any? # false
<apeiros_> ![false].empty? # => true
<Spooner> Oh, crap. Oops.
<apeiros_> not. the. same.
<Spooner> until args.empty? then :/
<swarley> also, define_method was define_singleton_method
sent-hil has joined #ruby
<swarley> i fucked it up though
<gks> no advice on the Bundler/Jekyll issue i posted above?
freezey has quit [Quit: freezey]
<swarley> because i forgot to put in the binding
bbttxu_ has quit [Quit: bbttxu_]
locriani has joined #ruby
<Spooner> The problem is that you end up instance_evalling it, which isn't going to act as you expect. The problem is that you are replacing raise ArgumentError, "Expected Integer" unless i.is_a? Integer with a lot of fundamental cheesing around ;)
zeromodulus has quit [Ping timeout: 260 seconds]
ltsstar has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
iamjarvo has quit [Ping timeout: 245 seconds]
fmcgeough has quit [Quit: fmcgeough]
<swarley> Spooner; like i said, it was essentially a joke :o
<swarley> :p*
<Spooner> Yeah, sorry.
tvw has joined #ruby
<swarley> neat in concept though!
etehtsea has joined #ruby
advorak has joined #ruby
advorak has quit [Client Quit]
lggr has joined #ruby
advorak has joined #ruby
sailias has joined #ruby
[Neurotic] has joined #ruby
tommyvyo has quit [Quit: Computer has gone to sleep.]
tommyvyo has joined #ruby
tvw has quit [Read error: Connection reset by peer]
zeromodu_ has joined #ruby
RORgasm has joined #ruby
twoism has joined #ruby
matthewrobbins has joined #ruby
<hotovson> f sdf slkdfj sdfkjsldkf sdf sdfsdf
<hotovson> sry
jgarvey has quit [Quit: Leaving]
hoelzro is now known as hoelzro|away
hsbt_away is now known as hsbt
sepp2k has quit [Remote host closed the connection]
twoism has quit [Remote host closed the connection]
ixti has joined #ruby
twoism has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
swarley has quit [Ping timeout: 260 seconds]
Jork1 has joined #ruby
apeiros_ has quit [Remote host closed the connection]
lggr has joined #ruby
rabidpraxis has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
advorak has quit [Quit: This computer has gone to sleep]
paolooo has quit [Quit: Page closed]
cantonic has quit [Read error: Connection reset by peer]
ebobby has joined #ruby
cantonic has joined #ruby
haxrbyte has quit [Remote host closed the connection]
kaawee has joined #ruby
invisime has quit [Quit: Leaving.]
lggr has quit [Ping timeout: 240 seconds]
otters has joined #ruby
kyletcarey has joined #ruby
mando has quit [Remote host closed the connection]
philcrissman has quit [Remote host closed the connection]
lggr has joined #ruby
mneorr has quit [Remote host closed the connection]
vitoravelino is now known as vitoravelino`afk
mneorr has joined #ruby
pettsson has joined #ruby
cardoni has joined #ruby
freezey has joined #ruby
kringa has quit [Ping timeout: 268 seconds]
TheFuzzball has quit [Read error: Operation timed out]
hsbt is now known as hsbt_away
maxmmurphy has joined #ruby
kringa has joined #ruby
und3f1 has quit [Quit: Leaving.]
snorkdude has joined #ruby
<cmouse> this is so bizarre, the sqlite3 database acts for all i can tell as if the data was inserted
peregrine81 has quit [Quit: Computer sleeping.]
<cmouse> but when the webrick process ends, the data is not written to disk
mando has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
jenrzzz has joined #ruby
irleif has quit [Quit: Computer has gone to sleep.]
twoism has quit [Ping timeout: 245 seconds]
<Spooner> cmouse Did you commit it rather than just insert it? I suspect the checks for insertion are using cached data, not data given to the DB.
<cmouse> db.transaction do |tx|
freezey_ has joined #ruby
irleif has joined #ruby
<cmouse> tx.execute("INSERT...")
<cmouse> end
<cmouse> that SHOULD commit, right?
Markvilla has quit [Read error: Connection reset by peer]
<Spooner> I would think so, yes (I don't use sqlite natively and when I did, it was via an ORM).
<cmouse> Spooner: how do you use it, then?
lggr has joined #ruby
bbttxu_ has joined #ruby
jfuentes has quit [Quit: jfuentes]
<Spooner> cmouse It was via ActiveRecord, though it was 2 years ago and I barely remember it.
<cmouse> k
jamjam has joined #ruby
<Spooner> cmouse It should push the data out though, at the end of a transaction.
<cmouse> yeah
<bricker> Will `ruby -v` tell me if I'm running REE?
Shipow has quit [Quit: Leaving...]
gks has quit [Quit: Linkinus - http://linkinus.com]
<cmouse> guess i have to run the webrick process in strace or something
<cmouse> can't think of anything else anymore
<Spooner> I'm not the best to ask.
freezey has quit [Ping timeout: 246 seconds]
freezey_ is now known as freezey
<cmouse> Spooner: this is really bizarre problem
<Spaceghostc2c> bricker: RUBYNot the worst, either.
<Spaceghostc2c> Crap.
<Spaceghostc2c> Spooner: Not the worst, either.
<Spooner> Spaceghostc2c: Thanks for the vote of confidence.
Markvilla has joined #ruby
emergion has joined #ruby
<Spaceghostc2c> bricker: Look at the RUBY_* constants.
<Spaceghostc2c> But yes.
<cmouse> ha
<cmouse> silly
ltsstar has quit [Quit: ltsstar]
matthewrobbins has quit [Quit: matthewrobbins]
stuartrexking has joined #ruby
<cmouse> it seems to lose access to it's journal
<Spooner> You were using a memory database?
flip_digits has joined #ruby
irleif has quit [Quit: Computer has gone to sleep.]
<cmouse> Spooner: no.
manizzle has joined #ruby
<Spooner> cmouse : See, you aren't as silly as you could have been if you'd used an in-memory DB.
emergion has quit [Client Quit]
lggr has quit [Ping timeout: 252 seconds]
timonv has joined #ruby
Virunga has quit [Remote host closed the connection]
<bricker> Spaceghostc2c: thanks
<Spaceghostc2c> bricker: Stay frosty.
cardoni has quit [Quit: cardoni]
lggr has joined #ruby
matthewrobbins has joined #ruby
freezey has quit [Quit: freezey]
aliencyborg has joined #ruby
cardoni has joined #ruby
Takehiro has quit [Remote host closed the connection]
wedtm|away is now known as wedtm
gmurphey has joined #ruby
margle has quit [Quit: Computer has gone to sleep.]
GoGoGarrett has quit [Remote host closed the connection]
havenn has quit [Remote host closed the connection]
jfuentes has joined #ruby
NiteRain has quit [Quit: KVIrc 4.1.3 Equilibrium http://www.kvirc.net/]
Ankhers has quit [Remote host closed the connection]
havenn has joined #ruby
Trioke has joined #ruby
rubious has quit [Quit: Linkinus - http://linkinus.com]
mando has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 245 seconds]
Orcris has joined #ruby
kirun has quit [Quit: Client exiting]
glyytchy has joined #ruby
mmitchell has quit [Ping timeout: 255 seconds]
freezey has joined #ruby
lggr has joined #ruby
mikepack has quit [Read error: Connection reset by peer]
mikepack has joined #ruby
_nitti has joined #ruby
alanp has joined #ruby
Eplemosen has joined #ruby
alanp_ has quit [Read error: Connection reset by peer]
saschagehlich has quit [Quit: saschagehlich]
axl_ has joined #ruby
digerati_ has quit [Ping timeout: 245 seconds]
lucianosousa has quit [Quit: lucianosousa]
timonv has quit [Remote host closed the connection]
digerati_ has joined #ruby
Tearan has joined #ruby
_nitti has quit [Ping timeout: 245 seconds]
nemesit has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 265 seconds]
kringa has quit []
awestroke has quit [Remote host closed the connection]
dblandin has joined #ruby
lggr has joined #ruby
uris has joined #ruby
Jellyg00se has quit [Read error: Connection reset by peer]
mando has joined #ruby
jfuentes has quit [Quit: jfuentes]
stuartrexking has quit [Quit: Leaving...]
cardoni has quit [Quit: cardoni]
RORgasm has quit [Remote host closed the connection]
dmiller has quit [Remote host closed the connection]
Jellyg00se has joined #ruby
stuartrexking has joined #ruby
dagnachewa has joined #ruby
freezway has joined #ruby
no_worries has quit [Remote host closed the connection]
sent-hil has quit [Remote host closed the connection]
jfuentes has joined #ruby
ryanf has joined #ruby
jfuentes has quit [Client Quit]
lggr has quit [Ping timeout: 260 seconds]
pskosinski has quit [Quit: A few unofficial Red Eclipse 1.3.1 (r4131) servers: http://altred.tk/toggle.rb (and no more global banning for saying that main dev is not very smart, what is truth anyway)]
SCommette has quit [Quit: SCommette]
jeffreybaird has quit [Quit: jeffreybaird]
sent-hil has joined #ruby
SegFaultAX|work has quit [Ping timeout: 260 seconds]
hsbt_away is now known as hsbt
hsbt is now known as hsbt_away
hsbt_away is now known as hsbt
aliencyborg has quit [Quit: Konversation terminated!]
Markvilla has quit [Quit: Computer has gone to sleep.]
freezey has quit [Quit: freezey]
lggr has joined #ruby
emmanuelux has quit [Remote host closed the connection]
horofox has quit [Ping timeout: 245 seconds]
elux has quit [Quit: Bye!]
horofox has joined #ruby
F1skr has joined #ruby
hsbt has quit [Ping timeout: 244 seconds]
mercwithamouth has quit [Ping timeout: 245 seconds]
hotovson has quit [Remote host closed the connection]
Takehiro has joined #ruby
hsbt has joined #ruby
Dreamer3 has quit [Quit: Computer has gone to sleep.]
horofox has quit [Client Quit]
jenrzzz has quit [Ping timeout: 260 seconds]
stopbit has quit [Quit: Leaving]
lggr has quit [Ping timeout: 246 seconds]
hotovson has joined #ruby
Takehiro has quit [Ping timeout: 272 seconds]
lggr has joined #ruby
SegFaultAX|work has joined #ruby
igabreu has joined #ruby
freezey has joined #ruby
freezey_ has joined #ruby
pskosinski has joined #ruby
hotovson has quit [Ping timeout: 240 seconds]
sent-hil has quit [Remote host closed the connection]
matthewrobbins has quit [Quit: matthewrobbins]
evilsushi has quit [Quit: Lost terminal]
bricker_ has joined #ruby
centipedefarmer has quit [Quit: This computer has gone to sleep]
Dreamer3 has joined #ruby
faen has quit [Ping timeout: 245 seconds]
bricker has quit [Ping timeout: 245 seconds]
lggr has quit [Ping timeout: 246 seconds]
justsee has joined #ruby
rabidpraxis has joined #ruby
freezey has quit [Ping timeout: 260 seconds]
freezey_ is now known as freezey
jrist is now known as jrist-afk
PragCypher has quit [Read error: Connection reset by peer]
flip_digits has quit [Read error: Connection reset by peer]
postmodern has joined #ruby
PragCypher has joined #ruby
WhereIsMySpoon_ is now known as WhereIsMySpoon
WhereIsMySpoon has quit [Changing host]
WhereIsMySpoon has joined #ruby
sterNiX has quit [Ping timeout: 260 seconds]
etehtsea has quit []
ebobby has quit [Quit: Lost terminal]
keyvan has joined #ruby
keyvan has quit [Changing host]
keyvan has joined #ruby
lggr has joined #ruby
dblandin has quit [Quit: dblandin]
faen has joined #ruby
Takehiro has joined #ruby
ixti has quit [Quit: So Long, and Thanks for All the Fish!]
Neurotiquette has quit [Remote host closed the connection]
mh` has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 245 seconds]
scx has quit [Ping timeout: 255 seconds]
chin-tastic has quit [Ping timeout: 246 seconds]
thmzlt has quit [Remote host closed the connection]
dblandin has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
mikepack has quit [Remote host closed the connection]
freeayu has joined #ruby
lggr has joined #ruby
GoGoGarrett has joined #ruby
r1ddl3r has joined #ruby
rakm has joined #ruby
h4mz1d has joined #ruby
freezey has quit [Quit: freezey]
dblandin has quit [Quit: dblandin]
samphippen has joined #ruby
jimeh has quit [Quit: bye]
nilg has quit [Remote host closed the connection]
lledet has quit [Quit: lledet]
pskosinski has quit [Quit: A few unofficial Red Eclipse 1.3.1 (r4131) servers: http://altred.tk/toggle.rb]
lggr has quit [Ping timeout: 245 seconds]
davidcelis has joined #ruby
davidcelis has quit [Changing host]
davidcelis has joined #ruby
zeromodulus has joined #ruby
zeromodu_ has quit [Ping timeout: 246 seconds]
Foxandxss has joined #ruby
lggr has joined #ruby
josh^ has joined #ruby
nateberkopec has quit [Quit: Linkinus - http://linkinus.com]
havenn has quit [Remote host closed the connection]
miphe has quit [Remote host closed the connection]
TomJ has quit [Quit: TomJ]
keyvan is now known as love_color_text_
uris has quit [Quit: Leaving]
Orcris has quit [Ping timeout: 245 seconds]
lggr has quit [Ping timeout: 265 seconds]
stkowski has quit [Quit: stkowski]
tommylommykins is now known as tommylommy2
jamjam has quit [Ping timeout: 245 seconds]
tommylommy2 is now known as tommylommykins
mrsolo_ has joined #ruby
nari has joined #ruby
scx has joined #ruby
<harushimo> I'm back
<harushimo> sorry for the long break
lggr has joined #ruby
mercwithamouth has joined #ruby
<harushimo> I'm working on a book problem which I'm a little stuck
mrsolo has quit [Ping timeout: 245 seconds]
hsbt is now known as hsbt_away
sneakyness_wk has quit [Quit: BQSS SQIT NIQQA QULL DA DQTR CUZ U SIQQA]
Jork1 has quit [Quit: Jork1]
palyer has quit []
palyboy has joined #ruby
bier has quit [Ping timeout: 240 seconds]
slainer68 has quit [Remote host closed the connection]
Russell^^ has quit [Quit: Russell^^]
_nitti has joined #ruby
<Spooner> harushimo : Working it out yourself for a while is always going to earn points.
<Spooner> harushimo : What's up?
<harushimo> thanks
lggr has quit [Ping timeout: 255 seconds]
<harushimo> I am working on it
<harushimo> let me code this other function
<harushimo> then we can go over it
<harushimo> I'm almost done
freezey has joined #ruby
Eplemosen has quit [Quit: Hexchat FTW! http://www.hexchat.org/]
Neurotiquette has joined #ruby
Forevernade has joined #ruby
havenn has joined #ruby
_nitti has quit [Ping timeout: 246 seconds]
<Spooner> harushimo : It is a method, not a function, in Ruby.
<Neurotiquette> Trying to use a Gem I installed via Bundler… (see https://github.com/ordinaryzelig/mongoid_to_csv/blob/master/lib/mongoid_to_csv.rb) … how do I use their lines? Do I need to add an include or a require to my controller or something? Coming from a PHP background
lggr has joined #ruby
freezey has quit [Client Quit]
<Spooner> Neurotiquette : You just: require "bundler/setup"; require "gem1"; require "gem2"
<harushimo> def something
<Spooner> Though I prefer: require "bundler"; Bundler.require :default
<harushimo> when you say def something is called a method
<Spooner> Yes, you are defining a method with 'def'
<havenn> harushimo: One def(ines) methods.
<Spooner> Not a function.
<harushimo> this is with in the class
<harushimo> what if you have no class defined, def something
<harushimo> its called a method
<Spooner> Yep.
<harushimo> I've being called them functions for years
<Spooner> Without a class defined, you are addin methods to the main Object.
<harushimo> oh man
<Spooner> They are functions in other languages. In Ruby they are methods.
<harushimo> thank you. I wasn't crazy
<Spooner> Not entirely, no :D
<harushimo> In python, we use classes. we define functions. In Ruby, we use classes or no classes, it is a called a method
<harushimo> okay
<harushimo> That is important
dmiller has joined #ruby
<Spooner> Well, you are never not using a class in Ruby. Without an explicit class, there is still one that you add methods on.
lggr has quit [Ping timeout: 252 seconds]
<harushimo> right
justsee has quit [Quit: Leaving...]
bier has joined #ruby
<Spooner> Neurotiquette did I answer you correctly or did I misunderstand the question?
<Neurotiquette> Spooner: Still getting undefined method `mongoid_to_csv' for #<Array:0x007ff94a9786c8>
<Neurotiquette> Spooner: Definitely see that the gem should be adding a method to Array object here
advorak has joined #ruby
advorak_ has joined #ruby
<Neurotiquette> Spooner: I added the require 'mongoid_to_csv' line to boot.rb since I see that's where my colleague added the requisite require 'bundler/setup' line
<Spooner> Neurotiquette : Yeah, it should be.
lggr has joined #ruby
Averna has joined #ruby
<harushimo> here my methods for class Dessert
<harushimo> I'm checking for if the dessert is less than 200, return true. If the person find the dessert delicious, return True
<Spooner> It is true/false, not True/False, in Ruby.
<harushimo> is my check okay inside my healthy function
<Spooner> Also, you aren't actually setting @name or @calories in #initialize
<harushimo> @name = name
<harushimo> ?
d2dchat has quit [Remote host closed the connection]
<Spooner> Yes, you need those.
<harushimo> okay
<harushimo> let me change that
<Spooner> At the moment, both are just nil.
mxweas has joined #ruby
<Neurotiquette> Spooner: Appreciate your helping me. If I give "require" a direct path to the rb file in the gem's directory under my .rvm folder in my controller it appears to work. lol.
<Neurotiquette> Spooner: Probably not quite production ready on that one :)
<Spooner> Neurotiquette Oh, I see. The problem was requiring the file, not the gems. Sorry, I missed entirely :/
h4mz1d has quit [Ping timeout: 265 seconds]
<Neurotiquette> Spooner: Well… I don't think I should have to require this file like this to make the gem work. Im confused. This is sloppy, we have 10+ gems in this project and I can't find an instance of him having to do this
<Spooner> No, you should just be able to require the gem by name.
<Spooner> Not sure of the gem structure, what is in your Gemfile or how it is required.
lggr has quit [Ping timeout: 252 seconds]
<Spooner> Neurotiquette : Should just be fine with: require 'mongoid_to_csv'
<Spooner> That statement would fail if it can't find the gem properly.
jenrzzz has joined #ruby
JonnieCache has joined #ruby
<Spooner> harushimo : Any more joy?
mxweas has quit [Quit: Computer has gone to sleep.]
lggr has joined #ruby
vitoravelino`afk is now known as vitoravelino
advorak_ has quit [Quit: This computer has gone to sleep]
advorak has quit [Quit: This computer has gone to sleep]
x82_nicole has quit [Quit: Computer has gone to sleep.]
<harushimo> it is always there
havenn has quit [Remote host closed the connection]
[1]hoffmanc has joined #ruby
<harushimo> apparently, I'm not setting and getting the variable properly
<Spooner> harushimo : Hmm?
<harushimo> I'm working on it
<harushimo> its a learning experience
<Neurotiquette> Spooner: OK well knowing that helps, thank you
<Spooner> Can't understand why it wouldn't be monkey-patching Array when required that way though. Magic indeed is afoot!
dmiller has quit [Remote host closed the connection]
niklasb has joined #ruby
hoffmanc has quit [Ping timeout: 256 seconds]
[1]hoffmanc is now known as hoffmanc
reuf has quit [Quit: Leaving]
manizzle has quit [Ping timeout: 256 seconds]
stephenjudkins has joined #ruby
<harushimo> any suggestions
<blazes816> harushimo: any code? gist please
<t0rc> I am using middleman and bundler, bundler uses gemspec. Middleman does not seem to like to do so. When I run middleman, with the dependency on "middleman" put in the gemspec, middleman cannot build the project, dies. If I add: gem "middleman" to the Gemfile (above gemspec line), it builds just fine.
<harushimo> sorry
<harushimo> I have it
<t0rc> It seems that there is some dependency between middleman and what is in the gemfile, or that at least middleman may be processing the gemfile. Or maybe I am completely wrong?
lggr has quit [Ping timeout: 252 seconds]
slainer68 has joined #ruby
<harushimo> it looks like initialize may be messed up
<Spooner> harushimo : Well, it doesn't say what you say it is saying.
<harushimo> ok
mando has quit [Remote host closed the connection]
icole has quit [Remote host closed the connection]
lggr has joined #ruby
<Spooner> I already told you it is true, not True, in Ruby.
<harushimo> am I messing up on the initialize method?
<Spooner> #initialize is fine.
Azure has quit [Excess Flood]
<harushimo> why is it saying dessert should be set and get
<harushimo> for name and calories
<Spooner> What you should do is show what code you are using to test (just put a few lines underneath, like p = Dessert.new "Pie", 1000; puts p.delicious?; puts p.healthy?
Azure has joined #ruby
mxweas has joined #ruby
<Spooner> Do you mean your exercise is saying that?
<harushimo> yeah
<harushimo> it isn't working
<Spooner> Because it sounded like you were saying Ruby was complaining about it.
<harushimo> it is the exercise
<harushimo> sorry
<harushimo> I didn't mean it like that
<harushimo> look at code and typing on irc
<harushimo> hehe
<harushimo> its a two part exercise
<Spooner> harushimo : It only doesn't work if you are testing it against the criteria. The code is fine (except the True/true bit and some sub-optimal code that we don't have to worry about yet).
stuartrexking has quit [Quit: Leaving...]
pettsson has quit [Read error: Connection reset by peer]
joast has quit [Quit: Leaving.]
digerati_ has quit [Ping timeout: 240 seconds]
<Spooner> harushimo : Yes, an exercise only you know the details of. Maybe share your specifications with us so we can help you attain them ;)
<harushimo> I am
<harushimo> when you told me to adjust True/true, it fixed two problem
<harushimo> s
digerati_ has joined #ruby
<harushimo> I'm working on this last part: should be able to set and get a dessert's name and calories
slainer68 has quit [Ping timeout: 265 seconds]
<Spooner> No, specifications, not the implementation (that is, show us the question).
<harushimo> what does that mean dessert should able to set and get a dessert's name and calories
<Spooner> Oh, I see. It is an automated tutorial?
<harushimo> threw ruby site
<harushimo> that is how I'm learning ruby
<Spooner> It means you should have getters and setters made for the two values, so they can be looked at and changed after the object has been created.
<Spooner> You do this with attr_accessor :name, :calories
lggr has quit [Ping timeout: 244 seconds]
<harushimo> where attr_accessor?
<harushimo> I should put that before the initialize method right
<Spooner> Usually put at the top of the class (that is, just before def initialize)
<harushimo> you and I were thinking the same thing
joast has joined #ruby
<harushimo> i was thinking of that
<harushimo> I remember you doing it in the foo example
CaptainJet has joined #ruby
<harushimo> let me look at the ruby doc on attr_accessor
<harushimo> I'm still a little weary on it
<harushimo> can we use the attr_accessor for a subclass too
<Spooner> Yes, the methods it creates are accessible in subclasses too.
manizzle has joined #ruby
lggr has joined #ruby
<Spooner> And that is what it does - magically creates two methods (foo and foo=) so you can change the @ivars
<harushimo> due to the fact, inheritance right
<Spooner> Yeah.
<harushimo> I'm getting use to this OOP concepts
thecreators has quit [Quit: thecreators]
<harushimo> I am give myself pat on the back
brianpWins has quit [Quit: brianpWins]
<harushimo> now I get inheritance
<harushimo> finally
<harushimo> sorry
<harushimo> I got a little carried away
daniel_hinojosa has joined #ruby
<Tarential> what's so difficult about inheritance? commit patricide, get rewarded... inheritance
<Spooner> Tarential : Unless you aren't in the will.
SegFaultAX|work has quit [Ping timeout: 240 seconds]
<Tarential> you've been talking to my father, haven't you?
swarley has joined #ruby
<Spooner> He said the cat deserved they money more than you. I couldn't argue with him.
<Spooner> *the money
<harushimo> hehe
kiyoura has joined #ruby
<harushimo> i'll be honest with you people. I'm not a computer science
<harushimo> I'm econ guy who turned IT
<harushimo> just let you know
<Tarential> ok, I'll fess up... I'm not a science either
<Spooner> IT isn't science.
<Tarential> IT is the application of technology derived from science
<harushimo> oh
<harushimo> okay
<harushimo> i'm sorry. i didn't mean cause a debate
<harushimo> hehe
pmros has joined #ruby
dpk has quit [Quit: Asleep at the keyboard.]
<pmros> hi!