bzalasky has quit [Remote host closed the connection]
CoverSlide has joined #ruby-lang
kgrz has quit [Quit: Computer has gone to sleep.]
sush24 has quit [Quit: This computer has gone to sleep]
rwk1 has quit [Read error: Connection timed out]
rwk1 has joined #ruby-lang
maxmanders has joined #ruby-lang
maxmande_ has joined #ruby-lang
ruby-lang783 has joined #ruby-lang
maxmanders has quit [Ping timeout: 264 seconds]
adambeynon has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
ruby-lang783 has quit [Ping timeout: 245 seconds]
io_syl has quit [Quit: Computer has gone to sleep.]
kgrz has joined #ruby-lang
reactormonk has quit [Ping timeout: 272 seconds]
idkazuma has joined #ruby-lang
runeb has joined #ruby-lang
glebm has quit [Ping timeout: 264 seconds]
glebm has joined #ruby-lang
mixandgo has joined #ruby-lang
swav has quit [Remote host closed the connection]
reactormonk has joined #ruby-lang
<yorickpeterse>
morning
<yorickpeterse>
zenspider: because one can also define return values and in the future possibly other bits of information. I also fail to see how tossing it all into arguments would be any better
glebm has quit [Ping timeout: 246 seconds]
GarethAdams has joined #ruby-lang
idkazuma has quit [Remote host closed the connection]
mixandgo has quit [Ping timeout: 245 seconds]
runeb has quit [Remote host closed the connection]
jasiek has quit [Ping timeout: 256 seconds]
rolfb has joined #ruby-lang
apeiros_ has joined #ruby-lang
burgestrand has joined #ruby-lang
burgestrand has quit [Client Quit]
burgestrand has joined #ruby-lang
mixandgo has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 256 seconds]
glebm has joined #ruby-lang
dhruvasagar has joined #ruby-lang
runeb has joined #ruby-lang
jgoss has quit [Remote host closed the connection]
<yorickpeterse>
wooo, rbx patch got merged
skade has joined #ruby-lang
swav has joined #ruby-lang
xxaM has quit [Quit: ZzZz]
swav_ has joined #ruby-lang
swav has quit [Ping timeout: 248 seconds]
ryez has quit [Ping timeout: 245 seconds]
chendo_ has joined #ruby-lang
Domon has quit [Remote host closed the connection]
rwk1 has quit [Remote host closed the connection]
Domon has joined #ruby-lang
dhruvasagar has quit [Read error: Connection reset by peer]
mineiro has quit [Remote host closed the connection]
Mon_Ouie has joined #ruby-lang
swav_ has quit [Ping timeout: 252 seconds]
swav has joined #ruby-lang
tonni_ has joined #ruby-lang
tonni has quit [Read error: Connection reset by peer]
sepp2k has joined #ruby-lang
rwk1 has joined #ruby-lang
Domon has quit [Remote host closed the connection]
Gruu_ has joined #ruby-lang
woollyams has joined #ruby-lang
<andrewvos>
Why are gem installs from rubygems.org so slow?
<andrewvos>
I mean, right now.
Domon has joined #ruby-lang
<andrewvos>
Not in general.
rwk1 has quit [Remote host closed the connection]
woollyams has quit [Ping timeout: 240 seconds]
voker57 has joined #ruby-lang
voker57 has quit [Changing host]
voker57 has joined #ruby-lang
woollyams has joined #ruby-lang
<kith>
can we have .lrstrip please? :)
<GarethAdams>
kith: what would that do?
<kith>
.lstrip.rstrip
<GarethAdams>
what's wrong with .strip ?
<kith>
damn
<kith>
overlooked it in the docs
Bwild has quit [Ping timeout: 240 seconds]
francisfish has quit [Read error: Connection timed out]
Domon has quit [Remote host closed the connection]
francisfish has joined #ruby-lang
chendo_ has quit [Quit: Computer has gone to sleep.]
<apeiros_>
lawl
<andrewvos>
haha
shirokuro11 has joined #ruby-lang
maxmande_ has quit [Ping timeout: 245 seconds]
maxmande_ has joined #ruby-lang
chendo_ has joined #ruby-lang
Gruu_ has quit [Quit: Gruu_]
ruby-lang592 has joined #ruby-lang
ruby-lang592 has quit [Client Quit]
rwk1 has joined #ruby-lang
soknee has joined #ruby-lang
voker57 has quit [Read error: Connection reset by peer]
voker57 has joined #ruby-lang
saLOUt has joined #ruby-lang
thone has joined #ruby-lang
rwk1 has quit [Ping timeout: 240 seconds]
vlad_starkov has joined #ruby-lang
wmoxam has joined #ruby-lang
thone_ has quit [Ping timeout: 240 seconds]
rwk1 has joined #ruby-lang
woollyams has quit [Quit: Computer has gone to sleep.]
baba has joined #ruby-lang
fire has quit [Ping timeout: 245 seconds]
ritek has joined #ruby-lang
refd has joined #ruby-lang
refd has quit [Max SendQ exceeded]
dustint has joined #ruby-lang
jtperreault has quit [Quit: WeeChat 0.3.7]
<injekt>
:D
mineiro has joined #ruby-lang
jtperreault has joined #ruby-lang
<tbuehlmann>
hehe
jxpx777 has quit [Quit: Leaving...]
tonni_ has quit [Read error: Connection reset by peer]
tonni has joined #ruby-lang
ykk has joined #ruby-lang
vlad_sta_ has joined #ruby-lang
vlad_st__ has joined #ruby-lang
vlad_st__ has quit [Read error: Connection reset by peer]
vlad_starkov has quit [Ping timeout: 246 seconds]
<cored>
morning
<cored>
apeiros_: tried a lot of different regex's could not find any
<bougyman>
cored: what's your input string, and what is your expected result?
<bougyman>
i never did figure that out yesterday before I had to get on a plane
vlad_sta_ has quit [Ping timeout: 252 seconds]
vlad_starkov has joined #ruby-lang
maxmande_ has quit [Quit: Computer has gone to sleep.]
vlad_starkov has quit [Read error: Connection reset by peer]
srbaker has joined #ruby-lang
ykk has quit [Remote host closed the connection]
vlad_starkov has joined #ruby-lang
maxmanders has joined #ruby-lang
carloslopes has joined #ruby-lang
saLOUt has quit [Quit: Konversation terminated!]
<cored>
bougyman: wait
<cored>
["Love [i][s] good", "Chocolate [i][s] sweet", "Snow [i][s] cold", "Good [i][s] not evil", "[I] love dog[s]"]
<cored>
that's the output
<cored>
["Love is good", "Chocolate is sweet", "Snow is cold", "Good is not evil", "I love dogs"]
<cored>
that's the input and I'm sending "is" to match it out
sush24 has joined #ruby-lang
<cored>
so as you can see if I match "is" together in any part of the string and mark it "that's the sustitution" but not only S and not only I as you can see in Snow is cold
<cored>
yes, I was trying to learn about strings and regex and decided to implement some sort of fuzzy search
<cored>
but it's seems that problem can't be solve with regex and gsub because of the match part
<manveru>
well, you can match /i.*s/i
<GarethAdams>
cored: when you say "I pass 'is'" is this a method that you're passing a two-character start/end string to?
<cored>
if I match the entire thing the replacement will also change 'S' alone and 'I' alone, I want to match I if the next character is an 'S' even when there are characters in between
<cored>
GarethAdams: yeap
<cored>
manveru: in my method I will have to do something like pattern.spli(//).join(".*")
<cored>
and use that as the pattern
<manveru>
yeah
<cored>
manveru: but that also doesn't work because of the same effect as before
<cored>
it will match 'S' alone without an 'I' in front
runeb has quit [Read error: Connection reset by peer]
<manveru>
[27] pry(main)> r = Regexp.escape('is'); a.map{|s| s.gsub(/(.*)(i)(.*)(s)(.*)/i){|s| p $~.captures.each_with_index.map{|c,i| i % 2 == 0 ? c : "[#{c}]" }.join}}
<manveru>
there you go
<manveru>
no need for the p, but anyway
<cored>
let me try to understand that
kgrz has quit [Ping timeout: 264 seconds]
<manveru>
now just join with '(.*)' and prefix/suffix with '(.*)'
<manveru>
i.even? works too
emmdeeess has quit [Ping timeout: 276 seconds]
<cored>
code for transforming the "(.*)#{pattern, pattern.split(//).each { |w| w.gsub(//, "(#{w})" }.join(".*")(.*)"
tonni_ has joined #ruby-lang
<cored>
manveru: remember I have to transform the pattern first
tonni has quit [Read error: Connection reset by peer]
spuk_ has quit [Quit: Human beings were created by water to transport it uphill.]
face has quit [Ping timeout: 240 seconds]
io_syl has joined #ruby-lang
tonni_ has quit [Read error: Connection reset by peer]
quazimodo is now known as fire_butt
tonni has joined #ruby-lang
voker57 has quit [Remote host closed the connection]
runeb has quit [Remote host closed the connection]
runeb has joined #ruby-lang
pygmael has quit [Quit: pygmael]
<injekt>
knu: awesome job!
dr_bob has quit [Quit: Leaving.]
maxmanders has quit [Quit: Computer has gone to sleep.]
soypirate has joined #ruby-lang
carloslopes has joined #ruby-lang
dr_bob has joined #ruby-lang
gregmoreno has joined #ruby-lang
carloslopes has quit [Ping timeout: 240 seconds]
amerine has joined #ruby-lang
dr_bob has quit [Read error: Connection reset by peer]
burgestrand has quit [Quit: Leaving.]
jonahR has joined #ruby-lang
<rking>
What's the state of the art of Ruby code coverage tools?
<andrewvos>
rking: Test Driven Development
<rking>
We're about to dive into this mondo idea at work; basically integrating code coverage into other tools, like having vim show the # of times a line is run, plus having git auto-stage whenever there's a passing test and also the new diff is covered.
nXqd has quit [Ping timeout: 240 seconds]
<andrewvos>
Wow
<andrewvos>
Sounds cool
<rking>
andrewvos: Right, but that's only great when you're greenfielding. With legacy code you have to get dirtier.
flujan has joined #ruby-lang
<andrewvos>
True :(
<injekt>
durdy
<flujan>
hello guys. I need to write a TCP Socket server that receive a connection on port 27000, send data to the connection, wait for a answer, send more data, read result and close connection. Do you recommend a gem or I must create it in plain ruby?
gnufied has quit [Quit: Leaving.]
<injekt>
it's pretty easy to write something like that without the requirement of an external library
carloslopes has joined #ruby-lang
Gaelan has joined #ruby-lang
stardiviner has joined #ruby-lang
gnufied has joined #ruby-lang
sepp2k has quit [Ping timeout: 240 seconds]
<rking>
andrewvos: We're already auto-staging on green bars. It's freaking correct.
benlovell has quit [Quit: Computer has gone to sleep.]
<rking>
97/100 times it's exactly what we've wanted (staging is nice, because you can roll back to the staged version if the next refactoring doesn't go well, or you can commit it if you decide to do a new refactoring that would lead to a glommed-together commit)
Gaelan has quit [Read error: Connection reset by peer]
maxmanders has joined #ruby-lang
<rking>
It's just a nicety we're seeking to also require that that staged content have coverage.
nXqd has joined #ruby-lang
Uranio has joined #ruby-lang
Nisstyre-laptop has quit [Ping timeout: 272 seconds]
threeday1onk has left #ruby-lang [#ruby-lang]
threedaymonk has joined #ruby-lang
<andrewvos>
flujan: Use eventmachine or something that uses eventmachine
<andrewvos>
rking: That's cool
maxmanders has quit [Client Quit]
<rking>
Mark Bates's cover_me looks promising (basically, it says "RCov was cool but this works for 1.9")
<rking>
I'm not sure if there's another coverage gem that does other things in addition to working on >1.8, but that's a good start. =)
maxmanders has joined #ruby-lang
brianpWins has joined #ruby-lang
sepp2k has joined #ruby-lang
jxpx777 has quit [Quit: Leaving...]
jonahR has quit [Quit: jonahR]
srbaker has quit [Quit: Computer has gone to sleep.]
spuk has joined #ruby-lang
srbaker has joined #ruby-lang
bluepojo has quit [Remote host closed the connection]
stef_204 has quit [Quit: quitting]
bluepojo has joined #ruby-lang
<flujan>
andrewvos: Yeap, I am trying to use event machine but AFAIK event machine receive_data, I send_data when the client sends more data EM calls receive_data again
nXqd_ has joined #ruby-lang
nXqd has quit [Ping timeout: 246 seconds]
dr_bob has joined #ruby-lang
vlad_starkov has quit [Remote host closed the connection]
solars has quit [Ping timeout: 264 seconds]
Mon_Ouie has joined #ruby-lang
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby-lang
ruby-lang882 has joined #ruby-lang
spuk has quit [Quit: Human beings were created by water to transport it uphill.]
bawigga has joined #ruby-lang
wmoxam has quit [Ping timeout: 252 seconds]
MaddinXx has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 256 seconds]
alec_eiffel has joined #ruby-lang
tylersmith has joined #ruby-lang
jonahR has joined #ruby-lang
stef_204 has joined #ruby-lang
maxmanders has quit [Quit: Computer has gone to sleep.]
maxmanders has joined #ruby-lang
wmoxam has joined #ruby-lang
ruby-lang882 has quit [Ping timeout: 245 seconds]
XxBlakeFailxX has quit [Ping timeout: 245 seconds]
<fragmachine>
yorickpeterse, like stack pointers...
<fragmachine>
are we in C?
<whitequark>
fragmachine: yes because we don't have stack pointers in ruby</sarcasm>
r0bby_ has joined #ruby-lang
<fragmachine>
I'm a novice, I never see them
ykk_ has joined #ruby-lang
chrismar035_ has joined #ruby-lang
<whitequark>
meh, I was just referring to the fact that as long as your code executes on something relatively modern (1970+), you have a stack pointer, and use it, whether you want it or not.
chrismar035 has quit [Ping timeout: 246 seconds]
chrismar035_ is now known as chrismar035
davidbalbert is now known as davidbalber|away
<fragmachine>
ok fun quiz: a stack pointer follows function calls?
ykk has quit [Ping timeout: 246 seconds]
r0bby has quit [Ping timeout: 246 seconds]
dustint has quit [Ping timeout: 246 seconds]
outoftime has quit [Ping timeout: 246 seconds]
<fragmachine>
ok wrong forum
kurko_ has joined #ruby-lang
kurko_ has quit [Max SendQ exceeded]
mineiro has quit [Read error: Connection reset by peer]
mineiro has joined #ruby-lang
kurko_ has joined #ruby-lang
kurko_ has quit [Max SendQ exceeded]
mistym_ has quit [Remote host closed the connection]
kurko_ has joined #ruby-lang
kurko_ has quit [Max SendQ exceeded]
<yorickpeterse>
fragmachine: No, it was a lame reference to "Dropping the bass"
outoftime has joined #ruby-lang
kurko_ has joined #ruby-lang
<fragmachine>
Oh man, I didn't get that reference
mmaatthhe has joined #ruby-lang
ruby-lang452 has quit [Ping timeout: 245 seconds]
gregmoreno has quit [Read error: Connection reset by peer]
techlife has quit [Ping timeout: 245 seconds]
gregmore_ has joined #ruby-lang
gregmore_ has quit [Remote host closed the connection]
gregmoreno has joined #ruby-lang
megha has joined #ruby-lang
techlife has joined #ruby-lang
techlife has quit [Max SendQ exceeded]
baba has quit [Ping timeout: 272 seconds]
techlife has joined #ruby-lang
techlife has quit [Max SendQ exceeded]
Nisstyre-laptop has joined #ruby-lang
techlife has joined #ruby-lang
techlife has quit [Max SendQ exceeded]
JohnBat26 has joined #ruby-lang
techlife has joined #ruby-lang
techlife has quit [Max SendQ exceeded]
kgrz has quit [Quit: Computer has gone to sleep.]
techlife has joined #ruby-lang
techlife has quit [Max SendQ exceeded]
dustint has joined #ruby-lang
techlife has joined #ruby-lang
techlife has quit [Max SendQ exceeded]
techlife has joined #ruby-lang
techlife has quit [Max SendQ exceeded]
techlife has joined #ruby-lang
techlife has quit [Max SendQ exceeded]
techlife has joined #ruby-lang
retro|cz has quit [Ping timeout: 252 seconds]
dhruvasagar has quit [Ping timeout: 240 seconds]
<cored>
hello
<cored>
I'm trying to create a generic output for a hash using printf
<fragmachine>
you don't need printf
<cored>
I did something like str_output = Array.new(hash.values.size) { "%s" }
<cored>
and then printf(str_output, hash.values.join(",")
<cored>
but it's always saying that there are few arguments
<fragmachine>
what do you want to print?
<cored>
each value of the hash
<fragmachine>
There are man ways to do this, but you can do hash.each {|key, value| puts value}
<cored>
ok
<cored>
I think I found the problm
<cored>
I'm only passing an argument as the error message says
<cored>
and it's expecting 5
<fragmachine>
post your code at pastie or something
<fragmachine>
It's hard to tell what's wrong without the code...
kurko_ has quit [Quit: Computer has gone to sleep.]
<cored>
the code is just that two lines
<cored>
the one above
dc5ala has quit [Quit: Ex-Chat]
<cored>
puts hash.values.join(", ")
<cored>
that solve the issue
<fragmachine>
yea you don't need printf in ruby much
<fragmachine>
you're thinking in C
alessio_rocco has quit [Remote host closed the connection]
davidbalber|away is now known as davidbalbert
crudson has quit [Ping timeout: 240 seconds]
banaan has joined #ruby-lang
mineiro has quit [Remote host closed the connection]
apeiros_ has quit [Remote host closed the connection]
soknee has quit [Quit: Leaving.]
pygmael has joined #ruby-lang
rwk1 has joined #ruby-lang
alessio_rocco has quit [Remote host closed the connection]
mistym has quit [Remote host closed the connection]
glebm has quit [Ping timeout: 246 seconds]
rwk1 has quit [Ping timeout: 252 seconds]
maerch has quit [Ping timeout: 246 seconds]
idkazuma has quit [Remote host closed the connection]
glebm has joined #ruby-lang
chrismar035 has quit [Quit: chrismar035]
mixandgo has quit [Quit: mixandgo]
bluepojo has joined #ruby-lang
soknee has joined #ruby-lang
ruby-lang513 has quit [Ping timeout: 245 seconds]
<zenspider>
RAWR. just added subset detection to flay
maxmanders has quit [Ping timeout: 258 seconds]
<zenspider>
ok... this is awesome... but SLOW
<zenspider>
damn... I must be doing something wrong... this is too slow
Nuru has joined #ruby-lang
tonni_ has joined #ruby-lang
<injekt>
write it in node
<zenspider>
no need. flay is multi language
<injekt>
via plugins?
maerch has joined #ruby-lang
tonni has quit [Ping timeout: 256 seconds]
<injekt>
man .txt readmes in rdoc format are so hard to read on github
<injekt>
and by on github i mean in general
<zenspider>
yeah. already has erb, shipping with it. I've done haml and c as well
<injekt>
neat
<zenspider>
I thought I did JS at one point too, using rkelly or something
<zenspider>
if you can't read plain text, maybe you shouldn't be a developer
<injekt>
that's an unfortunately library name
<zenspider>
rkelly? not as bad as half of tenderlove's other projects
<injekt>
hey man you have rdoc formatting inside a .txt file, you cant talk
<injekt>
hah true
<zenspider>
johnson
<zenspider>
I don't bitch about the formatting, do I? because I can read text
mjio has joined #ruby-lang
<zenspider>
that's like, 2/3rds of my job... reading text
<injekt>
I can read text, I didn't say I couldn't read it, did i?
<injekt>
unless I missed typing that
<zenspider>
"so hard"
soknee has quit [Quit: Leaving.]
<injekt>
hard
<injekt>
not can't
<injekt>
;)
<injekt>
because with proper formatting, it's much nicer and easier to read
<injekt>
you disagree?
<zenspider>
I don't really give a shit. reading unformatted rdoc or markdown works just fine
<zenspider>
better even, since I then have superior text tools than my stupid web browser provides
<injekt>
alright, just thought I'd point it out as someone trying to learn more about flay
<zenspider>
I try to avoid style over substance arguments... since that is all you're really arguing... but this one gets on my nerves.
<injekt>
I'm not arguing, your readme looks like shit but it doesn't have to. Yes that is style over substance, I'm not saying you've done a bad job so you don't need to get so defensive, if you don't 'give a shit' then that's fine, I just wanted to point it out, forgive me for that
<zenspider>
holy crap... the code is slow because the code is slow.... I don't think there is anything I can do about this complexity
soknee has joined #ruby-lang
maerch has quit [Ping timeout: 272 seconds]
agarie_ has quit [Remote host closed the connection]
soknee has quit [Client Quit]
<zenspider>
ugh... a module with 51 methods (or... things) in it is just eating up cpu.
<injekt>
drbrain: I updated that mech issue, I think maybe something can be done inside net-http-persistent though
<injekt>
drbrain: I'll let you decide, I'm more than happy to do it in mech, though