ChanServ changed the topic of #ruby-lang to: Ruby 1.9.3-p125: http://ruby-lang.org | Paste >3 lines of text on http://pastie.org or use a gist
t has joined #ruby-lang
t is now known as Guest95144
replore_ has joined #ruby-lang
shtirlic_ has joined #ruby-lang
shtirlic has quit [Ping timeout: 260 seconds]
sora_h is now known as s0ra_h
bryancp has joined #ruby-lang
<whitequark> zenspider: http://rxr.whitequark.org/ is done specifically for such cases
replore_ has quit [Remote host closed the connection]
Guest95144 has quit [Remote host closed the connection]
erpuds has quit [Quit: erpuds]
fukushim_ has joined #ruby-lang
Swimming_Bird has quit [Quit: Computer has gone to sleep.]
<zenspider> whitequark: that doesn't help when the code is commented out?
banisterfiend has joined #ruby-lang
<zenspider> I also didn't know what I was looking for
<zenspider> eventually I searched for rb_define across all .c files and then searched for VM across those results and it was easy to spot
fukushima has quit [Ping timeout: 265 seconds]
<whitequark> zenspider: it's #if 0'd, and also full-text search isn't affected. well, nevermind then
jorendorff has left #ruby-lang [#ruby-lang]
tylerruby has joined #ruby-lang
tylerruby has left #ruby-lang [#ruby-lang]
tylerruby has joined #ruby-lang
tylerruby has quit [Client Quit]
banisterfiend has quit [Remote host closed the connection]
tylerruby has joined #ruby-lang
fgomez has quit [Ping timeout: 250 seconds]
tylerruby has quit [Client Quit]
s0ra_h is now known as sora_h
shtirlic_ has quit [Read error: Connection reset by peer]
shtirlic has joined #ruby-lang
bfreeman has quit [Quit: bfreeman]
bryancp has quit [Remote host closed the connection]
gouthamvel has joined #ruby-lang
gouthamvel has left #ruby-lang [#ruby-lang]
kyrylo has quit [Ping timeout: 245 seconds]
kyrylo has joined #ruby-lang
jxie has quit [Ping timeout: 244 seconds]
perryh_away is now known as perryh
mrck has quit [Remote host closed the connection]
mistym has quit [Read error: Connection reset by peer]
qwerxy has quit [Quit: offski]
neoesque has joined #ruby-lang
Clordio has joined #ruby-lang
piglittlepuffpuf has quit [Read error: Connection reset by peer]
Clordio has quit [Client Quit]
<jtoy> how can I tell if a file object is open?
<cirwin> .closed? :)
Z33K|Lux has joined #ruby-lang
Clordio has joined #ruby-lang
sora_h is now known as s0ra_h
Clordio has quit [Client Quit]
taterbas_ has joined #ruby-lang
taterbas_ has left #ruby-lang [#ruby-lang]
dberg_ has quit [Quit: dberg_]
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
Hakon|mbp has quit [Quit: Leaving...]
fgomez has joined #ruby-lang
asahi has left #ruby-lang [#ruby-lang]
s0ra_h is now known as sora_h
savage-_ has quit [Ping timeout: 245 seconds]
whatasunnyday has quit [Quit: Leaving]
WillMarshall has joined #ruby-lang
agile has quit [Ping timeout: 245 seconds]
BigFatFatty has joined #ruby-lang
ryez_off has quit [Quit: Page closed]
qwerxy has joined #ruby-lang
WillMarshall has quit [Quit: Computer has gone to sleep.]
DEac- has quit [Ping timeout: 244 seconds]
shevy has quit [Ping timeout: 244 seconds]
seanstickle has joined #ruby-lang
<jtoy> cirwin: nice
dasibre has joined #ruby-lang
DEac- has joined #ruby-lang
<cirwin> class File; def open?; !closed?; end; end
kevb32 has joined #ruby-lang
sora_h is now known as s0ra_h
tonesfrommars has quit [Quit: KVIrc 4.0.1 Insomnia http://www.kvirc.net/]
nisstyre has quit [Quit: Leaving]
<jtoy> cirwin: i tried open first, btu didn't think of closers
<jtoy> closed
shevy2 has joined #ruby-lang
dtang has joined #ruby-lang
kevb32 has quit [Ping timeout: 256 seconds]
WillMarshall has joined #ruby-lang
flebel has quit [Quit: :)]
mistym has quit [Read error: Connection reset by peer]
WillMarshall has quit [Client Quit]
stardiviner has joined #ruby-lang
gouthamvel has joined #ruby-lang
shtirlic_ has joined #ruby-lang
gouthamvel has left #ruby-lang [#ruby-lang]
andrewhl has joined #ruby-lang
savage- has joined #ruby-lang
slyphon_ has joined #ruby-lang
shtirlic has quit [Ping timeout: 260 seconds]
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
slyphon has quit [Disconnected by services]
slyphon_ is now known as slyphon
M4g1c5t0rM has quit [Remote host closed the connection]
yannis has joined #ruby-lang
meescha has joined #ruby-lang
<meescha> hello
<cirwin> ahoy!
moxiemk1 has joined #ruby-lang
neocoin has joined #ruby-lang
savage- has quit [Remote host closed the connection]
yannis has quit [Quit: Bye!]
ericmuyser has joined #ruby-lang
BigFatFatty has left #ruby-lang [#ruby-lang]
x0F has quit [Disconnected by services]
x0F_ has joined #ruby-lang
zz_wasnotrice is now known as wasnotrice
x0F_ is now known as x0F
mistym has quit [Remote host closed the connection]
felipe__ has quit [Read error: No route to host]
felipe__ has joined #ruby-lang
kevb32_ has joined #ruby-lang
<meescha> hey! sorry
<meescha> going between irc and email
fgomez has quit [Quit: leaving]
jtoy has quit [Quit: jtoy]
s0ra_h is now known as sora_h
ericmuyser has left #ruby-lang [#ruby-lang]
fgomez has joined #ruby-lang
kevb32 has joined #ruby-lang
<meescha> I'm learning ruby and I'm trying to read and write binary data from a socket. Because I'm new, and my currently preferred language is C, I'm having some problems with.
sora_h is now known as s0ra_h
s0ra_h is now known as sora_h
<cirwin> nomnomnomsockets
<meescha> actually i'm starting to hate the language but I don't think that's fair, so I was hoping some one could give me some advice on how to go about this if anyone can.
<cirwin> fwiw, you generally won't need to program with sockets directly in ruby — there are almost always libraries — but if you do, it should just do the right thing
<cirwin> do you have the code you've tried so far?
<meescha> actually my problem isn't with the socket (i don't think) it's with processing the data
<cirwin> ah ok
<cirwin> what's not working?
postmodern has quit [Ping timeout: 256 seconds]
<meescha> I'm not *really* sure
<cirwin> heh
<meescha> I think it's how i have to go about processing the data
<meescha> the end goal is to get it to become an elf binary but I have to "deobfuscate" it from a binary blob.
<cirwin> hmm
<cirwin> theres String.unpack — and you can also use strings as byte-arrays for C-like-ness
piglittlepuffpuf has joined #ruby-lang
<meescha> let me load it into pastie and you can see what I'm talking about, full disclosure: it's a hacker wargame, If you're not comfortable answering questions of the kind, I understand.
<meescha> I just needed some project to motivate me to learn ruby
<cirwin> ever the way :)
<meescha> Thanks, one second.
<meescha> ok, it's here: http://pastie.org/4035386
<meescha> so my logic is: build the socket, read the binary blob into an array, process the array such that every other byte is the ELF binary and write it to a binary file so that it can be pulled to a linux machine and then executed to give me the password to the next level
joast has joined #ruby-lang
<meescha> the blob of data that you initially get is 14kb, but when I'm done with the file it's just 3-4 bytes long which is only like 3 ascii numbers...
ruby-lang864 has quit [Ping timeout: 245 seconds]
<cirwin> so the code you have there isn't writing to the array — I'd probably do "array = s.read.each_byte.to_a" instead of the loop
jbsan_ has joined #ruby-lang
<meescha> I think it writes to the array but I'm not able to figure out why it's not writing properly
<cirwin> nowhere in that paste does it write to the array
jbsan has quit [Read error: Connection reset by peer]
jbsan_ is now known as jbsan
<cirwin> you just write from the socket straight into semtexbin
qwerxy has quit [Quit: offski]
<meescha> oh, yeah, this is a modified file
<lianj> s.read.unpack("C*").each_slice(2).map(&:first).flaten.pack("C*")
<meescha> I did something like:
<lianj> *flatten
<meescha> while line = s.getbyte
<meescha> array.push(line)
<meescha> end
<cirwin> ok
<cirwin> (though line is a byte? confusing!)
<meescha> yeah, sorry about that
<meescha> yeah, that's another thing, I'm not entirely sure about because I'm fairly new to ruby.
<meescha> fairly == really
<meescha> lianj: i have exactly zero clue as to what that line of code does but it's impressive.
Estanislao has joined #ruby-lang
Estanislao has quit [Client Quit]
<meescha> i've used "getbyte" to get the data from the socket, and IO.binwrite to write the data to the file. Is that the correct way to do it?
<lianj> meescha: maybe try % ruby -rsocket -e 'TCPSocket.open("localhost", 4000){|s| File.open("your_bin","wb"){|f| f.print s.read.unpack("C*").each_slice(2).map(&:first).flatten.pack("C*") } }'
<lianj> meescha: its one way
PhilCK has quit [Quit: PhilCK]
EstanislaoStanis has joined #ruby-lang
<cirwin> meescha: using f.write is more stylish
<meescha> would f.write be writing it as an ascii string or in it's raw form?
<cirwin> raw form
<meescha> ok, so it should be ok to use then.
<cirwin> because you have a string full of binary data it will just write the binary data out
<cirwin> yeah
<meescha> ok, I'll switch it to that then because it think it's easier to understand.
<meescha> lianj I'd use that line of code but it would take me several hours to figure out what it means.
<lianj> meescha: a File.open(..){|f| } block also closes the fd for you ;)
kevb32 has quit [Quit: kevb32]
<meescha> no offense, I'm just so new that I think it would be lost on me
kevb32_ has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
<meescha> lianj, you're saying your line of code would close the file descriptor for me, correct?
<lianj> s.read returns a string like "ABABAB", unpack("C*") on that unpacks chars from it [65, 66, 65, 66, 65, 66], each_slice(2) interates over that array taking two elements, map/collect(&:first) method takes the first of that chunk [[1,2], [3,4]].map(&:first) => [[1],[3]], flatten on that flattens the array [1,3], pack("C*") packs it into a string again "\x01\x03"
<lianj> meescha: right
<meescha> ok, just making sure I'm keeping up.
<meescha> ok...
<meescha> i think i see where this is going..
<meescha> I mean, I trust that it's correct, I'm just trying to understand it
<lianj> as in starting to like or hate ruby? :D
<meescha> so gimme a second to understand it
jperry2 has quit [Quit: Leaving.]
somethin1ellow has quit [Quit: Computer has gone to sleep]
dphase- has joined #ruby-lang
meescha_ has joined #ruby-lang
krohrbaugh1 has joined #ruby-lang
seanstickle_ has joined #ruby-lang
<meescha> I've been beating my head against a wall for quite some time with this, I really prefer to stress myself to the point that when I get it I *REALLY* understand it but this must have been just a little beyond me.
meescha has quit [Read error: Connection reset by peer]
dphase has quit [Read error: Connection reset by peer]
krohrbaugh has quit [Read error: Connection reset by peer]
horus_plex has quit [Ping timeout: 260 seconds]
seanstickle has quit [Read error: Connection reset by peer]
steven has quit [Ping timeout: 260 seconds]
musl has quit [Read error: Connection reset by peer]
Mchl has quit [Quit: ZNC - http://znc.sourceforge.net]
wycats has quit [Excess Flood]
seanstickle_ is now known as seanstickle
musl has joined #ruby-lang
<meescha_> wow...
meescha_ is now known as meescha
<meescha> that was really weird...
Mchl has joined #ruby-lang
horus_plex has joined #ruby-lang
<meescha> ok, so get the string, unpack it as binary data, I don't understand the "C*" though
<meescha> C = 8 bit integer
<meescha> what's the * for
<cirwin> lot's of 8 bit integers!
<cirwin> *lots
Facefox has quit [Ping timeout: 250 seconds]
steven has joined #ruby-lang
<lianj> meescha: C is uchar, * is the rest too
<meescha> ok, I see An asterisk (“*”) will use up all remaining elements.
<meescha> there it is.
<lianj> yes, "CC" or "C2" would mean unpack 2 uchars
<lianj> string.unpack("C*") is just another way of what cirwin wrote string.bytes.to_a
<meescha> still looking for each_slice
Facefox has joined #ruby-lang
<meescha> ohhhh!
<cirwin> lianj: shame my way didn't get 20 minutes explaining :(
<lianj> [1,2,3,4].each_slice(2).to_a # => [[1, 2], [3, 4]]
wycats has joined #ruby-lang
<meescha> my problem is that I never know where to look for this stuff
<cirwin> meescha: install pry
<cirwin> and then you can get help inline
<meescha> I can find it with C but I can never find it with ruby
<cirwin> gem install pry
felipe__ has quit [Quit: Leaving]
<cirwin> show-doc [].each_slice
<cirwin> (you might need gem install pry-doc too)
<lianj> cirwin: woa, we're 20 minutes in? gotta sleep
<cirwin> only 10
<cirwin> sorry, I must hvae been *really* bored :p
bfreeman has joined #ruby-lang
diegoviola has quit [Ping timeout: 244 seconds]
<meescha> hehe, sorry, :)
<cirwin> meescha: I was only teasing lianj, he threw you in the deep-end a bit :)
hinbody has joined #ruby-lang
<lianj> indeed, sorry
<meescha> hehe, yeah
gja has joined #ruby-lang
gja has quit [Changing host]
gja has joined #ruby-lang
<meescha> just loaded that line into a file and made some changes and I think it worked...
<cirwin> w00t!
<lianj> did we make the next level? :D
<meescha> hah
<meescha> nah, it segfaulted
<meescha> but it still worked better then mine
<lianj> hm, prolly because read didnt read all of it
<meescha> maybe
<lianj> `file your_bin` recognises it though?
<meescha> I changed it to semtexbin
<meescha> might delete it and rewrite the file
postmodern has joined #ruby-lang
<meescha> hmm... it seg faults.
<cirwin> ruby shouldn't segfault :(
<meescha> it wouldn't return if it hadn't reached the end of the file, right?
<cirwin> that's the theory
<meescha> oh, sorry, the resulting elf executable seg faults.
<cirwin> ah
<meescha> unless...
<cirwin> 32bit, 64bit, et?C
<meescha> it may have never been intended to run
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
<lianj> cirwin: just tested. looks like s.read returns when the socket gets closed, which is what we want
<meescha> hmm, this one should be a 32bit elf executable
hakunin has quit [Remote host closed the connection]
<meescha> I'm still trying to understand how ruby iterates through stuff
mrsolo has quit [Quit: Leaving]
<lianj> objdump -D semtexbin
<meescha> the {|x| .. do stuff} thing gets me
<lianj> aw, nevermind. youre on windows
<meescha> linux vms
<meescha> :)
<meescha> hmm... it doesn't recognize it as a file...
<meescha> that's kind of interesting
benjammin891 has joined #ruby-lang
seanstickle has quit [Quit: Nihil sub sole novum]
<meescha> hmm
EstanislaoStanis has quit []
EstanislaoStanis has joined #ruby-lang
<meescha> alright, guys, thanks for your help. I've got class in the morning, I'm going to hit the sack.
meescha has left #ruby-lang [#ruby-lang]
benjammin891 has quit [Ping timeout: 245 seconds]
igotnolegs has joined #ruby-lang
benjammin891 has joined #ruby-lang
savage- has joined #ruby-lang
EstanislaoStanis has quit []
EstanislaoStanis has joined #ruby-lang
Estanislao has joined #ruby-lang
jlawler has joined #ruby-lang
EstanislaoStanis has quit [Client Quit]
EstanislaoStanis has joined #ruby-lang
Estanislao has quit [Client Quit]
twittard has joined #ruby-lang
<twittard> Wow, things that you forget about and that bite you in the ass: Digest::SHA1.new("Some text") will spit out a SHA1 that has nothing to do with the input string.
EstanislaoStanis has quit [Client Quit]
<twittard> What an idiotic fucking API.
<cirwin> it gives me an error
brushbox1 has joined #ruby-lang
ryanf has joined #ruby-lang
<twittard> you're using 1.9.3?
brushbox has quit [Ping timeout: 240 seconds]
benjammin891 has quit [Ping timeout: 244 seconds]
gouthamvel has joined #ruby-lang
gouthamvel has left #ruby-lang [#ruby-lang]
twittard has quit [Remote host closed the connection]
tomb_ has quit [Quit: Computer has gone to sleep.]
<postmodern> twittard, on 1.8.7 it accepts zero arguments, and quietly discards your string
twittard has joined #ruby-lang
<postmodern> twittard, on 1.8.7 it accepts zero arguments, and quietly discards your string
<postmodern> twittard, so Digest::SHA1.new('foo') == Digest::SHA1.new
benjammin891 has joined #ruby-lang
<postmodern> twittard, consider upgrading to 1.9.3, it will lower your blood pressure
benjammin891 has quit [Client Quit]
<twittard> postmodern: noted. thanks for pointing that out. JRuby's Digest::SHA1 seems to still behave like 1.8.7? I have no idea anymore.
<postmodern> twittard, even with --1.9 ?
<twittard> Yeah. My JRuby is still at 1.6.5, so it might've been fixed.
wasnotrice is now known as zz_wasnotrice
<postmodern> twittard, hmm no, still broken
<postmodern> twittard, that's a bug
<twittard> yep
<postmodern> twittard, i can report it for you, if you want
<twittard> I'll go ahead and file it then
<postmodern> k
<twittard> nah, thanks for verifying / pointing that out. I'll file an issue.
<postmodern> wonder if rubinius also does this
zz_wasnotrice is now known as wasnotrice
<bnagy> jruby seems fixed in 1.7
<bnagy> argumenterror
<twittard> Hum
<bnagy> jruby 1.7.0.preview1 (ruby-1.9.3-p203) (2012-05-24 d745248)
tomb_ has joined #ruby-lang
<bnagy> I didn't even know you could instantiate those classes :/
<twittard> Yeah, I recall headius saying he wasn't going to release any more 1.6 version
<twittard> except in a rare case
<twittard> guess I won't file the bug then
<postmodern> you can even extend Digest::Base to make your own custom digests
<postmodern> did that in digest-crc
<twittard> Yeah, I just forgot that I needed to call hexdigest instead of .new
<bnagy> ohh for block digests
<postmodern> twittard, yeah jruby 1.7 is going through heavy testing because of the new invoke dynamic stuff
tomb_ has quit [Client Quit]
<bnagy> \o/ that commit is for my bug ;)
Gekz has joined #ruby-lang
Gekz has quit [Changing host]
Gekz has joined #ruby-lang
eph3meral has joined #ruby-lang
jfarmer has joined #ruby-lang
bryno has quit [Quit: brb]
rippa has joined #ruby-lang
acyed has quit [Remote host closed the connection]
ryanf_ has joined #ruby-lang
ryanf has quit [Quit: leaving]
ryanf_ is now known as ryanf
cirwin has quit [Ping timeout: 248 seconds]
gsav has quit [Read error: Connection reset by peer]
piglittlepuffpuf has left #ruby-lang [#ruby-lang]
acyed has joined #ruby-lang
bryno has joined #ruby-lang
moxiemk1 has quit [Remote host closed the connection]
jfarmer has quit [Quit: jfarmer]
dankest has quit [Quit: Linkinus - http://linkinus.com]
yannis has joined #ruby-lang
corburn has quit [Quit: Leaving]
gja has quit [Ping timeout: 250 seconds]
wasnotrice is now known as zz_wasnotrice
t has joined #ruby-lang
t is now known as Guest64078
tRAS has joined #ruby-lang
gja has joined #ruby-lang
gja has quit [Changing host]
gja has joined #ruby-lang
TheHunter_1039 has quit [Quit: TheHunter_1039]
A124 has quit [Ping timeout: 252 seconds]
replore_ has joined #ruby-lang
tRAS has quit [Quit: Mother, did it need to be so high?]
geekfactor has quit [Remote host closed the connection]
cirwim has joined #ruby-lang
postmodern has quit [Ping timeout: 245 seconds]
geekfactor has joined #ruby-lang
b1rkh0ff has quit [Ping timeout: 260 seconds]
gsav has joined #ruby-lang
A124 has joined #ruby-lang
tejas has joined #ruby-lang
tejas has quit [Changing host]
tejas has joined #ruby-lang
gja has quit [Ping timeout: 252 seconds]
postmodern has joined #ruby-lang
ryanf_ has joined #ruby-lang
b1rkh0ff has joined #ruby-lang
tRAS has joined #ruby-lang
tRAS has quit [Client Quit]
ryanf has quit [Quit: broken pipes |||]
mytrile has joined #ruby-lang
Guest64078 has quit [Remote host closed the connection]
ryanf_ has left #ruby-lang [#ruby-lang]
ryanf has joined #ruby-lang
qpingu has joined #ruby-lang
yxhuvud has joined #ruby-lang
postmodern has quit [Ping timeout: 244 seconds]
<eph3meral> is there a way to merge an array of hashes in to a single hash? ala translating [my_hash, some_other_hash, yet_another_hash]; into something like my_hash.merge(some_other_hash).merge(yet_another_hash);
<eph3meral> dynamically
eph3meral has left #ruby-lang ["Leaving"]
Fullmoon has quit [Quit: Fullmoon]
ConstantineXVI has quit [Read error: Connection reset by peer]
ConstantineXVI has joined #ruby-lang
tRAS has joined #ruby-lang
twittard_ has joined #ruby-lang
kitallis has joined #ruby-lang
tejas has quit [Quit: Leaving]
wallerdev has quit [Quit: wallerdev]
postmodern has joined #ruby-lang
twittard has quit [Ping timeout: 240 seconds]
twittard_ is now known as twittard
|Vargas| has joined #ruby-lang
gja has joined #ruby-lang
gja has quit [Changing host]
gja has joined #ruby-lang
postmodern has quit [Ping timeout: 240 seconds]
JohnBat26 has joined #ruby-lang
JohnBat26 has quit [Client Quit]
JohnBat26 has joined #ruby-lang
JohnBat26 has quit [Client Quit]
JohnBat26 has joined #ruby-lang
twittard has quit [Remote host closed the connection]
twittard has joined #ruby-lang
twittard has quit [Read error: Connection reset by peer]
perryh has quit [Quit: ZNC - http://znc.in]
qpingu has quit [Read error: Connection reset by peer]
arooni-mobile has quit [Ping timeout: 245 seconds]
mistym has quit [Remote host closed the connection]
mytrile has quit [Remote host closed the connection]
Z33K|Lux has quit []
gsav has quit [Read error: Connection reset by peer]
arooni-mobile has joined #ruby-lang
Asher has quit [Ping timeout: 244 seconds]
ramonmaruko has quit [Quit: Leaving.]
postmodern has joined #ruby-lang
tjadc has quit [Read error: Connection reset by peer]
ramonmaruko has joined #ruby-lang
perryh_ has joined #ruby-lang
Asher has joined #ruby-lang
Asher1 has joined #ruby-lang
Asher has quit [Read error: Operation timed out]
Boohbah has quit [Remote host closed the connection]
dc5ala has joined #ruby-lang
WillMarshall has joined #ruby-lang
Asher1 has quit [Quit: Leaving.]
Asher has joined #ruby-lang
tRAS has quit [Quit: Mother, did it need to be so high?]
toretore has joined #ruby-lang
postmodern has quit [Ping timeout: 245 seconds]
andrewhl has quit [Remote host closed the connection]
arooni-mobile has quit [Ping timeout: 256 seconds]
igotnolegs has quit [Quit: Computer has gone to sleep.]
stardiviner has quit [Quit: my website: http://stardiviner.dyndns-blog.com/]
srbartlett has quit [Remote host closed the connection]
fayimora has joined #ruby-lang
stardiviner has joined #ruby-lang
stardiviner has quit [Client Quit]
tbuehlmann has joined #ruby-lang
replore_ has quit [Remote host closed the connection]
gouthamvel has joined #ruby-lang
Criztian has joined #ruby-lang
qwerxy has joined #ruby-lang
zmack has joined #ruby-lang
jenrzzz has quit [Quit: Timed out]
jenrzzz has joined #ruby-lang
stardiviner has joined #ruby-lang
kitallis has quit [Ping timeout: 244 seconds]
WillMarshall has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
heftig has quit [Quit: leaving]
sora_h is now known as s0ra_h
toretore has quit [Quit: This computer has gone to sleep]
kitallis has joined #ruby-lang
savage- has quit [Remote host closed the connection]
pabloh has joined #ruby-lang
s0ra_h is now known as sora_h
apeiros_ has joined #ruby-lang
savage- has joined #ruby-lang
qwerxy has quit [Quit: offski]
pabloh has quit [Quit: Ex-Chat]
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
sora_h is now known as s0ra_h
s0ra_h is now known as sora_h
ryanf has quit [Quit: leaving]
<rue> By the power of programmiiiiing
fserb has joined #ruby-lang
QaDeS has joined #ruby-lang
gnufied has joined #ruby-lang
gouthamvel has quit [Ping timeout: 260 seconds]
sora_h is now known as s0ra_h
s0ra_h is now known as sora_h
savage- has quit [Remote host closed the connection]
cantonic_ has joined #ruby-lang
cdt has joined #ruby-lang
nevynxxx has joined #ruby-lang
cantonic has quit [Read error: Operation timed out]
cantonic_ is now known as cantonic
tejas has joined #ruby-lang
tejas has quit [Changing host]
tejas has joined #ruby-lang
saLOUt has joined #ruby-lang
gja has quit [Ping timeout: 250 seconds]
postmodern has joined #ruby-lang
seoaqua has joined #ruby-lang
fserb has quit [Quit: ttyl]
cirwim has quit [Quit: sleep….ping!]
kain has joined #ruby-lang
tomb__ has joined #ruby-lang
kalleth has quit [Ping timeout: 252 seconds]
agarie has quit [Quit: A ligeira raposa marrom ataca o cão preguiçoso [www.fullt.net]]
nevynxxx has quit [Quit: leaving]
nevynxxx has joined #ruby-lang
tejas has quit [Ping timeout: 265 seconds]
sora_h is now known as s0ra_h
vmoravec has joined #ruby-lang
judofyr has joined #ruby-lang
Fullmoon has joined #ruby-lang
adgar has quit [Ping timeout: 252 seconds]
s0ra_h is now known as sora_h
adgar has joined #ruby-lang
zz_chrismcg has left #ruby-lang [#ruby-lang]
chrismcg has joined #ruby-lang
qwerxy has joined #ruby-lang
riffraff has joined #ruby-lang
dhruvasagar has joined #ruby-lang
fayimora has quit [Ping timeout: 260 seconds]
lele has quit [Ping timeout: 260 seconds]
gja has joined #ruby-lang
gja has quit [Changing host]
gja has joined #ruby-lang
lele has joined #ruby-lang
charliesome has joined #ruby-lang
tRAS has joined #ruby-lang
fayimora has joined #ruby-lang
kyrylo has quit [Ping timeout: 265 seconds]
sora_h is now known as s0ra_h
heftig has joined #ruby-lang
<manveru> ire
Tick-Tock has quit [Ping timeout: 272 seconds]
robotmay has joined #ruby-lang
jmcphers has quit [Quit: Leaving]
s0ber has quit [Remote host closed the connection]
s0ber has joined #ruby-lang
jmcphers has joined #ruby-lang
Tick-Tock has joined #ruby-lang
rolfb has joined #ruby-lang
tekin has joined #ruby-lang
kyrylo has joined #ruby-lang
hibariya has quit [Quit: No Ping reply in 180 seconds.]
hibariya_ has joined #ruby-lang
seoaqua has quit [Ping timeout: 245 seconds]
<rue> Rage?
<bnagy> Eire?
fgomez has quit [Ping timeout: 256 seconds]
fayimora has quit [Read error: Connection reset by peer]
fayimora has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 252 seconds]
futurechimp has joined #ruby-lang
dhruvasagar has joined #ruby-lang
seoaqua has joined #ruby-lang
LarryLv has joined #ruby-lang
dhruvasagar has quit [Client Quit]
dhruvasagar has joined #ruby-lang
LarryLv has quit [Read error: Connection reset by peer]
LarryLv has joined #ruby-lang
s0ra_h is now known as sora_h
b1rkh0ff has quit [Ping timeout: 260 seconds]
sora_h is now known as s0ra_h
voker57 has joined #ruby-lang
dreieins has joined #ruby-lang
kyrylo has quit [Ping timeout: 240 seconds]
s0ra_h is now known as sora_h
gnufied has quit [Quit: Leaving.]
sora_h is now known as s0ra_h
s0ra_h is now known as sora_h
kyrylo has joined #ruby-lang
kyrylo has quit [Changing host]
kyrylo has joined #ruby-lang
ViperMaul has quit [Ping timeout: 245 seconds]
ViperMaul has joined #ruby-lang
gnufied has joined #ruby-lang
shevy2 is now known as shevy
sora_h is now known as s0ra_h
LarryLv has quit [Remote host closed the connection]
neoesque has quit [Quit: Bye!]
s0ra_h is now known as sora_h
voker57 has quit [Ping timeout: 244 seconds]
kalleth has joined #ruby-lang
fgomez has joined #ruby-lang
solars has joined #ruby-lang
fgomez has quit [Ping timeout: 244 seconds]
cantonic_ has joined #ruby-lang
anathan_ has joined #ruby-lang
cantonic has quit [Ping timeout: 265 seconds]
cantonic_ is now known as cantonic
anathan has quit [Ping timeout: 252 seconds]
anathan_ is now known as anathan
sepp2k has joined #ruby-lang
srbartlett has joined #ruby-lang
flak has joined #ruby-lang
rippa has quit [Read error: Connection reset by peer]
flak is now known as Guest29062
Hakon|mbp has joined #ruby-lang
saLOUt has quit [Quit: Konversation terminated!]
srbartlett has quit [Remote host closed the connection]
kvs_ has quit [Quit: ZNC - http://znc.in]
sandbags has joined #ruby-lang
sandbags has quit [Changing host]
sandbags has joined #ruby-lang
ryez has joined #ruby-lang
Fullmoon has quit [Ping timeout: 240 seconds]
d3vic3 has quit [Ping timeout: 252 seconds]
tRAS has quit [Ping timeout: 256 seconds]
d3vic3 has joined #ruby-lang
Fullmoon has joined #ruby-lang
kvs has joined #ruby-lang
Criztian has quit [Remote host closed the connection]
VGoff is now known as VGoff_afk
<kke> any tips on installing charguess on a 64bit ubuntu?
postmodern has quit [Quit: Leaving]
ruurd has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 252 seconds]
burgestrand has quit [Quit: Leaving.]
tRAS has joined #ruby-lang
gnufied1 has joined #ruby-lang
mark_locklear has joined #ruby-lang
gnufied has quit [Ping timeout: 260 seconds]
riffraff has quit [Ping timeout: 250 seconds]
dasibre has quit [Remote host closed the connection]
ryez has quit [Ping timeout: 245 seconds]
sora_h is now known as s0ra_h
s0ra_h is now known as sora_h
gentz has quit [Remote host closed the connection]
diegoviola has joined #ruby-lang
kyrylo has quit [Ping timeout: 260 seconds]
Guest29062 has quit [Read error: Connection reset by peer]
robotmay_ has joined #ruby-lang
Guest29062 has joined #ruby-lang
burgestrand has joined #ruby-lang
riffraff_ has joined #ruby-lang
Axsuul has quit [Ping timeout: 240 seconds]
robotmay has quit [Ping timeout: 260 seconds]
toretore has joined #ruby-lang
fayimora has quit [Ping timeout: 260 seconds]
ttilley is now known as ttilley_off
ryez has joined #ruby-lang
tekin has quit [Quit: Computer has gone to sleep.]
<rue> kke: No, are you having a problem?
kyrylo has joined #ruby-lang
kyrylo has quit [Changing host]
kyrylo has joined #ruby-lang
ryez has quit [Client Quit]
mark_locklear has quit [Ping timeout: 250 seconds]
brunocoelho has joined #ruby-lang
jperry2 has joined #ruby-lang
chrismcg is now known as zz_chrismcg
brunocoelho has quit [Remote host closed the connection]
Criztian has joined #ruby-lang
fayimora has joined #ruby-lang
hakunin has joined #ruby-lang
fayimora has quit [Ping timeout: 252 seconds]
fayimora has joined #ruby-lang
fayimora has quit [Client Quit]
geekfactor has quit [Remote host closed the connection]
geekfactor has joined #ruby-lang
ttilley_off is now known as ttilley
tommyvyo_ has joined #ruby-lang
gouthamvel has joined #ruby-lang
gix has quit [Ping timeout: 252 seconds]
zz_wasnotrice is now known as wasnotrice
<andrewvos> Hey, I'm doing an interview and as a first step I want to show them a piece of code and say what's ugly about it. Can anyone recommend a piece of code?
<andrewvos> Ruby please
gix has joined #ruby-lang
gouthamvel has left #ruby-lang [#ruby-lang]
<rue> You’re conducting?
<rue> You’d have good pickings from the various gists…
<andrewvos> ...
<andrewvos> Which gists? :)
<oddmunds> andrewvos: what sort of ugly do you want to talk about?
dv310p3r has joined #ruby-lang
<andrewvos> oddmunds: Just badly written code
<andrewvos> Like a begin;rescue;end with lots of code in the begin part.
<oddmunds> you can have my roguelike http://github.com/jraregris/cave-santa
huugsy has joined #ruby-lang
huugsy has quit [Client Quit]
<oddmunds> the svirfneblin.rb class and the map.rb class has lots of code begging for refactorings
andrewhl has joined #ruby-lang
hynkle has joined #ruby-lang
tekin_ has joined #ruby-lang
dalekurt has joined #ruby-lang
<erikh> the binscript is pretty hairy too, IIRC
<andrewvos> erikh: Looking for something abit smaller
<erikh> hrm
<erikh> ok sec
<andrewvos> like 50 lines
<andrewvos> erikh: Maybe some inline sql :)
<erikh> pick one
<shevy> show them any part of bundler
<erikh> haha yes
<andrewvos> shevy: Oooh
<erikh> excellent play shevy
<shevy> nah, it is probably too big
<erikh> bundler is horrid
<shevy> if he just wants ~40/50 lines hmm
<erikh> those binscripts are pretty bad
<andrewvos> Mother of God
<erikh> sorry :(
<erikh> it was from a long time ago
<andrewvos> homer_reversing_into_hedge.gif
<shevy> lol
<shevy> ack
<erikh> f.e.
<erikh> 4 space indent, rescue Exception, use of fu_klass instead of includes, etc
<shevy> oh I know something
<shevy> didn't matz say that he does not like autoload?
<erikh> yes. but then you could cite most of rails
<shevy> lol
<Defusal> andrewvos, how about the method i pasted for someone 2 days ago?
<andrewvos> Defusal: Not that good a memory
<Defusal> it does the job, but its not written for other people, its extremely compact
<Defusal> will find the link now
TheHunter_1039 has joined #ruby-lang
fgomez has joined #ruby-lang
<erikh> jesus
<Defusal> :D
kyrylo has quit [Read error: Connection reset by peer]
<erikh> handing him the job
<andrewvos> Defusal: Uhhh. I want to interview the guy, not *kill* him.
<Defusal> haha
<andrewvos> hah
<Defusal> yeah i thought so
<erikh> anyhow if you want some more examples, ip has some gory bits
<erikh> some necessary and some not
soahccc` is now known as soahccc
<erikh> anyhow HTH
<erikh> time to make the donuts.
<andrewvos> Euphemism?
<erikh> work time
dv310p3r has quit [Ping timeout: 260 seconds]
krohrbaugh1 has quit [Quit: Leaving.]
xanaru has joined #ruby-lang
melter has quit [Read error: Operation timed out]
<oddmunds> Defusal: I think that's a breach of the Pastie.org terms of use.
stardiviner has quit [Quit: my website: http://stardiviner.dyndns-blog.com/]
<andrewvos> oddmunds: Yeah man. There should be a "Report Abuse" button.
<oddmunds> hehe
<erikh> andrewvos: oh, you could pick some code gems out of the right_aws gem
<erikh> lived in that code for a few weeks; it's special.
brushbox1 has quit [Quit: Leaving.]
<judofyr> HTTP is hard
<judofyr> let's go shopping
ttilley is now known as ttilley_off
<andrewvos> judofyr: YES
<oddmunds> yeah
<erikh> judofyr: raw socket communication. nuff said
* judofyr implements a HTTP client
<judofyr> pipelining, streaming, chunking
<erikh> oh, they even rewind sockets in a few spots.
<judofyr> what?
<erikh> yes.
<erikh> what's sad is that the lib works beautifully
<erikh> I mean, I have no desire to use fog (A competing lib)
<erikh> just the code is a complete CF
<darix> judofyr: yet another http client library?
<oddmunds> judofyr:are you going to the ruby thing tonight?
<judofyr> oddmunds: yes
<judofyr> darix: yes; it's going to be integrated with the HTTP server/framework I'm writing
<judofyr> so the request/response object in the framework are the same as those in the client library
dabradley has joined #ruby-lang
kyrylo has joined #ruby-lang
kyrylo has quit [Changing host]
kyrylo has joined #ruby-lang
dphase- has left #ruby-lang [#ruby-lang]
<zzak> judofries hypertext transportation pockets
<zzak> "jump in and go.."
dc5ala has quit [Quit: Ex-Chat]
burgestrand has quit [Quit: Leaving.]
<rue> Gotsta name it Kangaroo
<judofyr> why?
fgomez has quit [Ping timeout: 252 seconds]
<andrewvos> judofyr: Read up
<judofyr> how much up? :P
<andrewvos> <zzak> "jump in and go.."
<judofyr> andrewvos: the stdlib has plenty of … interesting code :)
<andrewvos> :)
brunocoelho has joined #ruby-lang
<oddmunds> "transportation pockets"
<andrewvos> I need like a single a4 page chunk of code. It should have large begin/rescue/ends, inline sql, and some other shit I can't think of now.
charliesome has quit [Ping timeout: 248 seconds]
Marcccccc3K has joined #ruby-lang
<judofyr> andrewvos: this code has no methods and lots of inline File-stuff: https://github.com/judofyr/gemify/blob/master/bin/gemify ?
Guest29062 has quit [Quit: derp herp]
<Marcccccc3K> Hi everyone, could someone tell me why this simple code doesn't work : [1..8].find_all{|item| item % 3 == 0 }.inject(0){|sum,item| sum + item } . It does work if I create an array from 1 to 8, but not with this sequence. Thanks
<andrewvos> judofyr: Interesting
<judofyr> Marcccccc3K: use (1..8) instead
apeiros_ has quit [Remote host closed the connection]
<judofyr> Marcccccc3K: [0..8] is an array of length 1, where the only element is the range (1..8)
<Marcccccc3K> Thanks judofyr :)
slyphon has quit [Ping timeout: 245 seconds]
tRAS has quit [Quit: Mother, did it need to be so high?]
Marcccccc3K has quit [Ping timeout: 245 seconds]
xanaru has quit [Remote host closed the connection]
rolfb has quit [Quit: Linkinus - http://linkinus.com]
solars has quit [Ping timeout: 250 seconds]
gouthamvel has joined #ruby-lang
gouthamvel has left #ruby-lang [#ruby-lang]
dalekurt has quit [Read error: Connection reset by peer]
sonicpond has joined #ruby-lang
dejongge has joined #ruby-lang
<andrewvos> #vagrant is a dead place.
tomb__ has quit [Quit: Computer has gone to sleep.]
slyphon has joined #ruby-lang
bryancp has joined #ruby-lang
<andrewvos> So this is what I've concocted https://gist.github.com/2881988
outoftime has joined #ruby-lang
<andrewvos> Not sure how I can make it worse though
<judofyr> andrewvos: change the "result" with "puts"?
<andrewvos> judofyr: Very good!
dalekurt has joined #ruby-lang
<andrewvos> On CentOS what can I use to create services easily?
<heftig> cp and nano
<heftig> and man
<andrewvos> :9
<andrewvos> :9
solars has joined #ruby-lang
<heftig> er whoops, wrong channel, sorry
<andrewvos> :(
<heftig> andrewvos: services as in things that daemonize?
<heftig> something that listens on a socket?
Guedes_out is now known as Guedes
<erikh> you can install the setsid or ssid tools
<erikh> the latter is from the suckless.org project and probably comes with dwm
<andrewvos> Hmmm
<andrewvos> Thanks
<heftig> er
<heftig> ruby has Process.setsid
apeiros_ has joined #ruby-lang
<erikh> right
<erikh> andrewvos: there's also the classic 'nohup program &'
<andrewvos> erikh: Indeed
<heftig> which doesn't disconnect the TTY, though
<erikh> which isn't really daemonizing but is close enough for horseshoes
zz_chrismcg is now known as chrismcg
<heftig> there is probably a gem that does the classic daemonizing double fork and all
<judofyr> I think it's even called "daemon"
<heftig> see "SysV Daemons", unless you want something that depends on systemd or inetd or whatnot
dv310p3r has joined #ruby-lang
ttilley_off is now known as ttilley
fgomez has joined #ruby-lang
DefV has quit [Read error: Connection reset by peer]
dalekurt has quit [Read error: Connection reset by peer]
<Defusal> andrewvos, are you not using 1.9?
slyphon has quit [Quit: WeeChat 0.3.6]
<erikh> if you want ruby code that does it, I can share some with you
<erikh> but I didn't realize that's what you wanted.
heftig has quit [Quit: leaving]
krohrbaugh has joined #ruby-lang
<andrewvos> Defusal: I don't have access to 1.9 on the machine in question. 1.8.7-p302 :(
<andrewvos> erikh: Who me? Nahh I may just go with the <gem> & approach
<andrewvos> Or even nohup
tRAS has joined #ruby-lang
<Defusal> ah that is unlucky
<darix> runit + having apps run in foreground. gets you autorestart^^
<erikh> oh yeah
<erikh> nice call on runit
<erikh> andrewvos: runit is really worth it, I'd look into that first.
crudson has joined #ruby-lang
scampbell has joined #ruby-lang
mistym has joined #ruby-lang
wasnotrice is now known as zz_wasnotrice
mistym has quit [Changing host]
mistym has joined #ruby-lang
tRAS has quit [Quit: Mother, did it need to be so high?]
fgomez has quit [Quit: Lost terminal]
<andrewvos> erikh: Thanks I'll see if it has an rpm on this box.
Jan_ has joined #ruby-lang
<erikh> probably in epel
<andrewvos> No Matches Found :(
melter has joined #ruby-lang
andrewhl has quit [Remote host closed the connection]
rippa has joined #ruby-lang
akira989_ has joined #ruby-lang
phoenix_g11 has joined #ruby-lang
akira989 has quit [Ping timeout: 252 seconds]
|Vargas| has quit [Quit: ...]
phoenix_g11 has left #ruby-lang [#ruby-lang]
jxie has joined #ruby-lang
deryl has joined #ruby-lang
deryl is now known as Guest83718
Guest83718 has quit [Client Quit]
qwerxy has quit [Quit: offski]
qwerxy has joined #ruby-lang
nevynxxx has quit [Quit: leaving]
deryl has joined #ruby-lang
eschwartz has joined #ruby-lang
slyphon has joined #ruby-lang
Skif has quit [Ping timeout: 240 seconds]
Dakotaz has joined #ruby-lang
qwerxy has quit [Ping timeout: 244 seconds]
kyrylo has quit [Read error: Connection reset by peer]
qwerxy has joined #ruby-lang
solars has quit [Ping timeout: 265 seconds]
bfreeman has quit [Quit: bfreeman]
wallerdev has joined #ruby-lang
rmichael has joined #ruby-lang
jperry2 has quit [Ping timeout: 244 seconds]
M4g1c5t0rM has joined #ruby-lang
gouthamvel has joined #ruby-lang
Dakotaz has left #ruby-lang [#ruby-lang]
gouthamvel has left #ruby-lang [#ruby-lang]
mistym has quit [Remote host closed the connection]
jperry2 has joined #ruby-lang
JohnBat26 has quit [Quit: KVIrc 4.1.3 Equilibrium http://www.kvirc.net/]
kyrylo has joined #ruby-lang
kyrylo has quit [Changing host]
kyrylo has joined #ruby-lang
asahi has joined #ruby-lang
<asahi> i'm wondering how to use a symbol (registered mark in my case) in a regex
yannis has quit [Quit: yannis]
<apeiros_> asahi: you mean you have a string "™" and want to use it in a regex?
andrewhl has joined #ruby-lang
<apeiros_> (or is ® or © registered mark? I think it's ™, but I don't know…)
burgestrand has joined #ruby-lang
<asahi> apeiros_: I actually want to be able to use all three as necessary
Criztian has quit [Remote host closed the connection]
<asahi> but I meant ®
<apeiros_> asahi: /®/ is a valid regex.
dreieins has quit [Ping timeout: 260 seconds]
<apeiros_> do you use ruby 1.8 or 1.9?
<asahi> 1.9
<apeiros_> then just make sure you have your encodings sorted out
<asahi> so when I paste the symbol into pry, it appears as \U+FFC2\U+FFAE
dalekurt has joined #ruby-lang
<apeiros_> that sounds more like a problem with your terminal/shell…
kyrylo has quit [Ping timeout: 260 seconds]
vaelen has joined #ruby-lang
<apeiros_> especially since those two codepoints don't seem to have much to do with the ® sign…
<apeiros_> "®" == "\u00AE"
<apeiros_> but if you've trouble copy & pasting certain unicode characters, you can always use escape sequences. /\u00AE/ =~ "\u00AE" works just as fine.
fgomez has joined #ruby-lang
gmvsea has joined #ruby-lang
<asahi> I see. and does the regex like /®/ have an encoding associated with it?
<Defusal> the file does
imperator has joined #ruby-lang
<apeiros_> asahi: yes, it does
<apeiros_> /®/.encoding
gsav has joined #ruby-lang
<Defusal> ah, i didn't know regex objects do as well
<apeiros_> if it is a literal, then it depends on your `# encoding: …` comment in that source file.
<apeiros_> you can force 3 encodings directly on the literal by using the u/n/j flags
<apeiros_> (unicode, binary, sjis)
<apeiros_> sorry, u/n/s, not u/n/j
<darix> andrewvos: runit is easily built. in worst case start off with my spec file + init script
<apeiros_> however, if you use an encoding that differs from your source-file, then you must use escape sequences for all sequences that aren't valid in the source file's encoding.
<asahi> ah okay. and does /\u00AE/ match "®" regardless of the encoding of "®"?
<andrewvos> darix: Just going to go with nohup. In this situation it's probably the best choice. The process is only used for testing purposes and doesn't hit production.
<darix> k
<andrewvos> darix: Thanks though
M4g1c5t0rM has quit [Ping timeout: 260 seconds]
<apeiros_> asahi: well, since \u escapes are only allowed within unicode regexen…
<apeiros_> and since your regex and your string must have the same encoding in order to match
<apeiros_> it all comes down to you having your encodings sorted out and correctly converting between them.
judofyr has quit [Remote host closed the connection]
<asahi> I see. that makes sense. thanks
judofyr has joined #ruby-lang
judofyr has quit [Ping timeout: 244 seconds]
rushed has joined #ruby-lang
<andrewvos> It seems Zed is doing things again.
<apeiros_> ruby things?
<apeiros_> (because things he's been doing all the time…)
arooni-mobile has joined #ruby-lang
<andrewvos> No, "arguing on the internet" type things.
<apeiros_> that too
<apeiros_> he wrote a couple "learning … the hard way" books (or parts of it)
<andrewvos> Yeah
<andrewvos> Seems he's going to the Riak offices tomorrow because some Riak guy said he was scared to meet him. The fuck is wrong with developers in the states?
thone_ has joined #ruby-lang
<shevy> they are fight happy
<andrewvos> Acting like little fucking children.
<oddmunds> haha
thone has quit [Ping timeout: 252 seconds]
<zzak> zed's a bad example
<shevy> we need a MMA cage where developers duke it out with one another
<oddmunds> RMS vs Torvalds GO!
<dominikh> more like Torvalds vs Tanenbaum
<andrewvos> Richard Stallman would get a bit bitey I imagine.
<andrewvos> Steve Ballmer would just rip people apart.
tomb__ has joined #ruby-lang
robotmay_ has quit [Remote host closed the connection]
<oddmunds> RMS is like Blanka
kitallis has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
jperry2 has quit [Quit: Leaving.]
<andrewvos> diegoviola: AHHHHHHHHHHHHHHHHHH
<diegoviola> lol
<andrewvos> NSFL
lsegal has joined #ruby-lang
retro|cz has quit [Ping timeout: 265 seconds]
<whitequark> imperator: https://gist.github.com/2882962
somethinYellow has joined #ruby-lang
<diegoviola> NSFL indeed
<asahi> how can I make a regex match but not include a literal?
<imperator> whitequark, hm, thought i tried that before, but yep, that works, thanks
somethinYellow has quit [Read error: Operation timed out]
<asahi> for example, if I have the string "xyznomatch" and I want only the "xyz" part
<asahi> or rather, what comes before the "nomatch"
<andrewvos> "xyznomatch".gsub("nomatch")
dejongge has quit [Quit: Leaving.]
<asahi> andrewvos: oh, so I can't do it with a regex?
<dominikh> uh, since he's talking about _matching_ "xyznomatch".match(/^(.+)nomatch$/), [1] will be the stuff before nomatch
arooni-mobile has quit [Read error: Connection reset by peer]
<andrewvos> asahi: You can do ANYTHING with a regex.
<dominikh> andrewvos: false.
somethinYellow has joined #ruby-lang
<dominikh> you cannot parse irregular languages with a regex, for one :P
harryv has joined #ruby-lang
<andrewvos> True. You also can't create a dinosaur.
ddfreyne has quit [Excess Flood]
ddfreyne has joined #ruby-lang
<whitequark> dominikh: false.
<harryv> anybody have a ruby mirror handy?
<harryv> ruby-lang.org is down
<whitequark> harryv: try github
<whitequark> dominikh, andrewvos: you can't parse a context-free grammar with PCREs
<whitequark> but you can with oniguruma
<whitequark> it backtracks, it is INCREDIBLY SLOW, but it works
<asahi> dominikh: thanks but the "nomatch" isn't necessarily at the end of the string. I just want whatever would be in front of "nomatch" regardless of where it is in the string
<andrewvos> whitequark: Was going to look at that but then I saw geocities and bailed.
<dominikh> asahi: then be smart and get rid of the $ marker...
<dominikh> anchor even
<whitequark> andrewvos: nothing wrong with geocities
<whitequark> at least .jp
<whitequark> there are some fine docs there
<andrewvos> The 90s called, they said they don't want their hosting service back because it's shit.
<whitequark> sigh. another fanatic
<erikh> geocities hosted fine
<erikh> it's the pages that were horrible
<whitequark> erikh: andrewvos didn't care enough to actually open the oniguruma docs
<asahi> dominikh: I see. thanks
<andrewvos> If you're not using Heroku, you're doing it wrong and you have a stupid face.
<andrewvos> whitequark: I was just joking really.
<dominikh> people with stupid faces shouldn't be allowed to reproduce
jlawler has quit [Quit: Leaving.]
<whitequark> dominikh: you mean, like Stephen Hawking?
<dominikh> his face is funny, not stupid
<dominikh> huge difference
<whitequark> oh, I see
<rue> Stupid face is a recognized medical condition
<dominikh> I doubt he's going to reproduce though...
<whitequark> dominikh: read wiki, have a surprise
<andrewvos> Stupid Face Syndrome
harryv has left #ruby-lang [#ruby-lang]
<dominikh> whitequark: too long, couldn't find anything with ctrl+f :P
<Mon_Ouie> The *personal* life section on wikipedia pages always sounds ironic to me
<whitequark> ^ that
jtoy has joined #ruby-lang
mistym has joined #ruby-lang
vmoravec has quit [Quit: Leaving]
jtoy has quit [Read error: Connection reset by peer]
savage- has joined #ruby-lang
butchanton has joined #ruby-lang
brianpWins has joined #ruby-lang
<imperator> hm, what could i have done to make it think it was compiling in C90 mode? "warning: ISO C90 forbids mixed declarations and code"
<rue> Ha-ha
Criztian has joined #ruby-lang
<imperator> i do much around with CFLAGS a bit, wonder if that's it
<imperator> s/much/muck
<erikh> -gnu99
riffraff_ has quit [Quit: Leaving]
<imperator> i don't remember ever seeing this before, either
<imperator> this is odd
gmvsea has left #ruby-lang [#ruby-lang]
tekin_ has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
<rue> Can you force it via another CFLAG?
<imperator> what would it be?
<imperator> btw, the only CFLAG I'm adding (on OSX at least) is -D_POSIX_PTHREAD_SEMANTICS
<imperator> i know i've run these tests before without seeing that warning, so i don't know wtf i did to my environment
<dominikh> there's -std to set the standard. there's also -ansi, which is equivalent to -std=c90 for C code and c++98 for c++ code
mrsolo has joined #ruby-lang
gja has quit [Quit: This computer has gone to sleep]
<erikh> herp
<erikh> yes, you're correct: -std=gnu99
jinnko has joined #ruby-lang
cdt has quit [Quit: Ex-Chat]
<imperator> nope, still does it
<imperator> too weird
<imperator> bah, no time for this now, another day
carloslopes has joined #ruby-lang
<jinnko> hey folks. any news on when ruby-lang.org will be back?
bfreeman has joined #ruby-lang
hynkle has quit [Quit: hynkle]
hynkle has joined #ruby-lang
cirwin has joined #ruby-lang
chrismcg is now known as zz_chrismcg
rmichael has left #ruby-lang [#ruby-lang]
flak has joined #ruby-lang
flak is now known as Guest3082
<jds> Heya
gouthamvel has joined #ruby-lang
<jds> Any state-machine gem recommendations? https://github.com/pluginaweek/state_machine seems to be the standard choice, but it seems _way_ more complex than my simple needs
<jds> (it's for an ActiveRecord model, if that makes any difference)
rippa has quit [Ping timeout: 244 seconds]
Guest3082 has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
rippa has joined #ruby-lang
futurechimp has quit [Quit: Leaving]
gja has joined #ruby-lang
gouthamvel has left #ruby-lang [#ruby-lang]
stepnem has quit [Ping timeout: 250 seconds]
gnufied1 has quit [Quit: Leaving.]
enebo has joined #ruby-lang
<krohrbaugh> jds: I've always used state_machine myself.
slyphon is now known as slyphon_away
anathan has quit [Read error: Connection reset by peer]
anathan has joined #ruby-lang
japaniel has joined #ruby-lang
jperry2 has joined #ruby-lang
flebel has joined #ruby-lang
stepnem has joined #ruby-lang
gnufied has joined #ruby-lang
eschwartz has quit [Remote host closed the connection]
Skif has joined #ruby-lang
seoaqua has quit [Quit: Leaving]
tRAS has joined #ruby-lang
<asahi> anyone know how to find an anchor tag with particular text in it with nokogiri?
sush24 has joined #ruby-lang
qwerxy has quit [Ping timeout: 240 seconds]
<sush24> Very much a noob here, trying to work out modules. http://pastebin.com/5hZc7dWi
cirwin has left #ruby-lang [#ruby-lang]
stepnem has quit [Ping timeout: 260 seconds]
Carnage\ has joined #ruby-lang
<asahi> sush24: could be because you didn't require 'sequel' in your other file. seeing the actual output would be helpful
<asahi> and some real code you're using
gregf has quit [Quit: WeeChat 0.3.8]
zz_wasnotrice is now known as wasnotrice
stepnem has joined #ruby-lang
mistym has quit [Remote host closed the connection]
<sush24> asahi, I think it's something to do with the tree requirements.. brb in a few minutes..
havenn has joined #ruby-lang
fserb has joined #ruby-lang
<anildigital_work> Anybody know what is the ratio of base64 data and regular data?
<whitequark> anildigital_work: base64'd data is 1/3 bigger
<anildigital_work> whitequark: hmm.. so 3 times bigger right?
<whitequark> no
<whitequark> let me show
hahuang65 has joined #ruby-lang
<whitequark> so it's 1.(3) times bigger than original data
<imperator> "checking whether the C compiler works... no" - holy fucking shit
<imperator> c compile is all fucked up
<imperator> god i fucking hate osx sometimes - how the fucking fuck does this shit happen?
null- has joined #ruby-lang
<whitequark> imperator: http://www.xkcd.com/371/
<whitequark> alt-text.
<whitequark> "checking whether the C compiler works... no, it's on a strike"
<whitequark> "checking whether the C compiler works... no, it's occupying a public place"
<whitequark> "checking whether the C compiler works... no, it is high on drugs"
<imperator> i can compile little c programs fine
<imperator> but the configure script for ruby borks
<whitequark> imperator: pastebin config.log for me
<anildigital_work> whitequark: will it be always 1.375?
<anildigital_work> or will it varry?
<erikh> imperator: do you have a gcc-4.2?
<whitequark> anildigital_work: it's more like 1.3333...
<erikh> in /usr/bin
<whitequark> anildigital_work: the result is different in this case because of 1) embedded \n's, and 2) small sample size
<whitequark> try "a" * 80000
<whitequark> also note that base64 has padding in some cases, which can make the result 2 bytes bigger than expected
<whitequark> but not more than 2
<imperator> whitequark, https://gist.github.com/2883721
<imperator> erikh, 4.2.1
VGoff_afk is now known as VGoff
slyphon_away is now known as slyphon
<imperator> maybe all those "shutdown -r now" weren't such a good idea
<whitequark> presumably, apple hates gnu
<asahi> does someone know what this means? "[text()*='some text']"
<apeiros_> asahi: you *could* give a little context. it looks like an xpath or css selector.
crudson has left #ruby-lang [#ruby-lang]
<asahi> sorry. Nokogiri's search method uses it
<asahi> ex: doc.search "[text()*='Name:']"
tonesfrommars has joined #ruby-lang
<apeiros_> xpath select then.
<cout> any news on why ruby-lang.org is down?
<zzak> cout: someone in #mendicant having the same problem
<apeiros_> *selector
<asahi> okay, thanks
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
<imperator> oh, there we go
<imperator> apparently i had a bad CC option i was screwing around with
<imperator> i blame erikh
<whitequark> imperator: oh, I should have been more clear
<whitequark> the "apple hates gnu" meant "your gcc didn't recognize -gnu99 flag".
<whitequark> I, er, was distracted a bit
<imperator> "Father's Day deals for the man who felt you kick inside him for nine months" - from Groupon
<imperator> oh, god, i need to laugh - that helped
<whitequark> apeiros_: btw, are you an op for this channel or something like that?
<imperator> whitequark, np
DWoodiwiss has joined #ruby-lang
<imperator> yes, something like that :)
<cout> zzak: thanks
<whitequark> well, irclog.whitequark.org logs this channel for more than 6 months now, and it's stable and IMO pretty usable
<whitequark> even was linked to in an article in Ruby Weekly
<whitequark> so maybe it'd be a good idea to put the url in the topic, in case someone needs it
retro|cz has joined #ruby-lang
<apeiros_> whitequark: something like that
Hakon|mbp has quit [Quit: Leaving...]
Michagogo has joined #ruby-lang
Michagogo has left #ruby-lang [#ruby-lang]
neocoin has quit [Remote host closed the connection]
neocoin has joined #ruby-lang
DWoodiwiss has quit [Quit: dwoodiwiss]
dwoodiwiss_ has joined #ruby-lang
null- has left #ruby-lang [#ruby-lang]
neocoin has quit [Ping timeout: 245 seconds]
<imperator> dang, recompiling ruby didn't get rid of that c90 warning
dwoodiwiss_ has left #ruby-lang [#ruby-lang]
neocoin has joined #ruby-lang
tRAS has quit [Quit: Mother, did it need to be so high?]
DWoodiwiss has joined #ruby-lang
hynkle has quit [Ping timeout: 244 seconds]
<rue> What is it that’s giving you the warning, an extension?
<imperator> any extension actually
<imperator> maybe i haven't actually tried building one before on my snow leopard box
<imperator> i was using 1.8.7 until recently
<imperator> rebuilding it now with -std=c99, let's see what happens
Hakon|mbp has joined #ruby-lang
<whitequark> imperator: what does the warning say?
rushed has quit [Quit: rushed]
<DWoodiwiss> Hi all, anyone able to take a quick look at this for a ruby newbie? (http://pastie.org/private/eraug7h8jfvonj53y2jtw)
<imperator> whitequark, ISO C90 forbids mixed declarations and code
<whitequark> uh.
eschwartz has joined #ruby-lang
<whitequark> dwoodiwiss: static_price * (1.00 - 0.10)
<whitequark> or static_price * 0.90
<whitequark> also you don't need "then", it's not VisualBasic
<apeiros_> prices & floats = fail
<whitequark> ^ he says wise things
<whitequark> take a look at gem "money"
<canton7> "your total is: 18.999999999995"
<whitequark> canton7: "your total is: 18.99999"[truncated by the edge of paper]
<whitequark> bonus points for breaking the head of thermal printer :D
hynkle has joined #ruby-lang
<canton7> haha!
<DWoodiwiss> Cheers for the help, shall take a look at the money gem now. LOL
* imperator scrapes some penny shavings off
<whitequark> imperator: shavings?
<shevy> he shaves with a penny
<whitequark> what is this i dont even
<whitequark> shevings!
<imperator> to get to the .999999999995
<shevy> lol
workmad3 has joined #ruby-lang
<imperator> i would melt it down and give him part of results, but that's illegal :)
Skif has quit [Ping timeout: 240 seconds]
<whitequark> ~ How To Get Your ¢0.0000001, a Step-By-Step Guide ~
<whitequark> Step One: Register your own Bank;
<whitequark> Step Two: Deposit ¢1 on your Account in your Bank;
<whitequark> Step Three: Transfer ¢0.0000001 to a your second Account in your Bank;
<whitequark> Step Four: There is no Step Four!
benanne has joined #ruby-lang
<whitequark> imperator: actually, I just realized
<imperator> oh ffs, even though i compiled with -std=c99, it still gives me that warning
<whitequark> how all other people compile ruby on os x?
<whitequark> or, iow: what are you trying to do?
<imperator> whitequark, i get that warning for even a simple test extension
<whitequark> imperator: yeah, I understand
<whitequark> but people used osx for ruby development for years, no?
<whitequark> with ruby-build and rvm and so on
<whitequark> so, what are you trying to do so that a) you cannot use standard tools b) it fails for you?
<whitequark> just trying to understand your problem
wasnotrice is now known as zz_wasnotrice
anathan has quit [Quit: anathan]
<Mon_Ouie> "foo" is a const char *, not a char*
<Mon_Ouie> If you try bar[2] = 'z', behavior is undefined
<Mon_Ouie> (or whatever is the exact term)
* imperator accidentally stabs Mon_Ouie in the face
hahuang65 has quit [Quit: Computer has gone to sleep.]
<imperator> IGNORE THAT WARNING IT DOESN'T MATTER
anathan has joined #ruby-lang
<whitequark> rofl
<whitequark> imperator: try --std=c99
<imperator> there, i updated the gist
<whitequark> erm, actually, wait a sec
<rue> What is it that dumps the defs, -dM?
<Mon_Ouie> The other one just means, that you should first declare all your variables and then do the rest
<imperator> whitequark, oh, duh, that worked
<whitequark> imperator: hehe
<imperator> foiled by a single dash!
<imperator> cripes
<whitequark> another victory of my telepathic abilites over the cruel gcc
<imperator> Mon_Ouie, yes, i know
<imperator> but that's a c90 standard, not c99
<shevy> hasn't clang/llvm killed gcc already...
<whitequark> shevy: gcc is already dead, clang just raped the body
<whitequark> ... several times
<shevy> lol
<whitequark> right into the optimizer
<imperator> oh, am i supposed to be using clang now? i can't keep up
<whitequark> imperator: clang driver is expected to be mostly gcc-compatible
<whitequark> (at the word "mostly" your eyes should turn red, and you'll go into a violent rage)
ruurd has quit [Quit: Linkinus - http://linkinus.com]
<imperator> "make -j4" - faster, dammit, faster!
<apeiros_> random question - is it possible in 1.9 C API to create a ruby string from a C string without copying the data? i.e., by just giving a proper pointer and length? (the string can/should be frozen)
<whitequark> apeiros_: just ALLOC(RString)
<whitequark> or how is it done properly, let me check
<imperator> one of the innumerable rb_str_xxx functions doesn't do this?
<whitequark> well, I'm looking at them right now.
<Mon_Ouie> All of those that I know either copy until the first null byte or the first n bytes
<asahi> what's the best way to remove escaped characters (i.e. \n or \t or \r) from a string?
<apeiros_> asahi: String#delete
<asahi> thanks
<apeiros_> or do you mean actual n/t/r's with a preceding backslash?
<apeiros_> ie., '\n' (== "\\n")
<whitequark> imperator: probably no
<whitequark> all functions I see use str_new
<asahi> apeiros_: like if I have "\n\t\rsometext", I want to get rid of anything like \n or \t or \r
arooni-mobile has joined #ruby-lang
<apeiros_> ok, so remove newlines, tabs and carriage returns. String#delete then indeed.
<Mon_Ouie> "anything like" is vague
<imperator> fuck, now i have that stupid cflags mod to all my extconf.rb files for 1.9
<apeiros_> e.g. str.delete("\r\n\t")
ruurd has joined #ruby-lang
<imperator> good thing i mostly use ffi these days
<whitequark> imperator: try env vars
<Mon_Ouie> That doesn't help if you're going to distribute your code to other people
<asahi> apeiros_: cool. thanks
<whitequark> Mon_Ouie: problem is on his side
<Mon_Ouie> Since their compilers will probably default to C90/C89
<whitequark> what
<whitequark> only osx compiler is stupid enough
codesturgeon has joined #ruby-lang
codesturgeon has quit [Remote host closed the connection]
<Mon_Ouie> So we need to make other compilers more stupid?
<imperator> i'm going to see prometheus on friday, and that will make everything better
<imperator> whitequark, ok, set CFLAGS in my .bash_profile, that did it...finally
<rue> You know what’s weird?
<imperator> platypi?
<rue> Both “Avengers” and “Prometheus” premiered a week before the US here
<rue> But those too
<imperator> probably an obama conspiracy of some sort
<imperator> or perhaps it's an austerity measure
Y_Ichiro has joined #ruby-lang
Y_Ichiro has joined #ruby-lang
Y_Ichiro has quit [Changing host]
workmad3 has quit [Ping timeout: 248 seconds]
retro|cz has quit [Ping timeout: 265 seconds]
fserb has quit [Quit: ttyl]
relix has quit [Remote host closed the connection]
denysonique has quit [Remote host closed the connection]
abuiles has quit [Read error: Connection reset by peer]
cldwalker has quit [Read error: Connection reset by peer]
mrb_bk has quit [Remote host closed the connection]
cesario has quit [Read error: Connection reset by peer]
akahn has quit [Remote host closed the connection]
mccraig has quit [Remote host closed the connection]
pkondzior has quit [Remote host closed the connection]
agib has quit [Remote host closed the connection]
anildigital_work has quit [Remote host closed the connection]
wycats has quit [Read error: Connection reset by peer]
beawesomeinstead has quit [Remote host closed the connection]
L0rdShrek has quit [Remote host closed the connection]
brownies has quit [Remote host closed the connection]
akamike has quit [Remote host closed the connection]
relix has joined #ruby-lang
dkannan has quit [Remote host closed the connection]
brownies has joined #ruby-lang
L0rdShrek has joined #ruby-lang
Skif has joined #ruby-lang
eschwartz has quit [Read error: Connection reset by peer]
Dreamer3 has joined #ruby-lang
mrb_bk has joined #ruby-lang
mistym has quit [Ping timeout: 260 seconds]
brownies- has joined #ruby-lang
x0F has quit [Disconnected by services]
x0F_ has joined #ruby-lang
x0F_ is now known as x0F
brownies has quit [Disconnected by services]
hahuang65 has joined #ruby-lang
benwoody_ has joined #ruby-lang
solars has joined #ruby-lang
beawesomeinstead has joined #ruby-lang
fserb has joined #ruby-lang
akahn has joined #ruby-lang
brownies- has quit [Ping timeout: 246 seconds]
rmascarenhas has joined #ruby-lang
ando has quit [Read error: Connection reset by peer]
ando has joined #ruby-lang
<shevy> the biggest conspiracy is the rubyOS
<lianj> close ahead of shevy-lang
<shevy> nah
<shevy> shevy-lang was duschendestroyer's thing
<shevy> I think he created an empty scaffold on github for this
ViperSBT has joined #ruby-lang
pkondzior has joined #ruby-lang
cesario has joined #ruby-lang
<lianj> there are private branches
<cout> I don't believe in conspiracy theories.
brownies has joined #ruby-lang
brownies has joined #ruby-lang
brownies has quit [Changing host]
brownies has quit [Changing host]
brownies has joined #ruby-lang
<cout> I KNOW conspiracies are true.
wycats has joined #ruby-lang
<shevy> cout yeah
Axsuul has joined #ruby-lang
bglusman has quit [Remote host closed the connection]
agib has joined #ruby-lang
bglusman has joined #ruby-lang
stderr_ has left #ruby-lang [#ruby-lang]
Criztian has quit [Read error: Operation timed out]
zz_wasnotrice is now known as wasnotrice
wasnotrice is now known as zz_wasnotrice
Carnage\ has quit []
Criztian has joined #ruby-lang
sepp2k has quit [Ping timeout: 252 seconds]
havenn has quit [Remote host closed the connection]
bglusman has quit [Ping timeout: 246 seconds]
sepp2k has joined #ruby-lang
brunocoelho has quit [Remote host closed the connection]
<Dreamer3> how can i check to see if a class name i have in a variable is defined?
nisstyre has joined #ruby-lang
rippa has quit [Ping timeout: 244 seconds]
<apeiros_> Dreamer3: const_defined? on the containing namespace.
<Dreamer3> yep, that's what i was looking for :)
<Dreamer3> thanks
slyphon has quit [Quit: WeeChat 0.3.6]
anildigital_work has joined #ruby-lang
slyphon has joined #ruby-lang
nofxx has joined #ruby-lang
banister_ has joined #ruby-lang
rmascarenhas has quit [Quit: leaving]
tbuehlmann has quit []
benanne has quit [Ping timeout: 252 seconds]
slyphon has quit [Quit: WeeChat 0.3.6]
japaniel has quit [Quit: japaniel]
slyphon has joined #ruby-lang
Bwild has quit [Quit: leaving]
carloslopes has quit [Quit: Leaving]
robbyoconnor has joined #ruby-lang
tommyvyo_ is now known as tommyvyo
gsav has quit [Read error: Connection reset by peer]
Bwild has joined #ruby-lang
jperry2 has quit [Ping timeout: 260 seconds]
sepp2k has quit [Remote host closed the connection]
fserb has quit [Quit: ttyl]
Carnage\ has joined #ruby-lang
benanne has joined #ruby-lang
toretore has quit [Quit: This computer has gone to sleep]
yxhuvud has quit [Ping timeout: 248 seconds]
singpolyma has quit [Read error: Connection reset by peer]
tommyvyo has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
hahuang65 has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
cldwalker has joined #ruby-lang
singpolyma has joined #ruby-lang
zmack has quit [Remote host closed the connection]
bglusman has joined #ruby-lang
tjadc has joined #ruby-lang
hynkle has quit [Quit: hynkle]
tonesfrommars has quit [Quit: KVIrc 4.0.1 Insomnia http://www.kvirc.net/]
gregf has joined #ruby-lang
scampbell has quit [Quit: Ex-Chat]
fserb has joined #ruby-lang
akamike has joined #ruby-lang
stamina has quit [Quit: Lost terminal]
fserb has quit [Client Quit]
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
owen1 has joined #ruby-lang
dkannan has joined #ruby-lang
owen1 has left #ruby-lang [#ruby-lang]
abuiles has joined #ruby-lang
mccraig has joined #ruby-lang
ViperSBT has quit [Read error: Connection reset by peer]
gja has quit [Quit: This computer has gone to sleep]
fserb has joined #ruby-lang
hakunin has quit [Remote host closed the connection]
hakunin has joined #ruby-lang
gnufied has quit [Quit: Leaving.]
fserb has quit [Quit: ttyl]
deryl has quit [Quit: Time To Go, So Sad!]
krohrbaugh has quit [Ping timeout: 240 seconds]
imperator has quit [Quit: Leaving]
deryl has joined #ruby-lang
banister_ has quit [Read error: Connection reset by peer]
workmad3 has joined #ruby-lang
neocoin has quit [Remote host closed the connection]
neocoin has joined #ruby-lang
chimkan_ has joined #ruby-lang
neocoin has quit [Ping timeout: 246 seconds]
chimkan___ has joined #ruby-lang
nazty has quit [Ping timeout: 245 seconds]
Carnage\ has quit [Ping timeout: 252 seconds]
chimkan_ has quit [Ping timeout: 260 seconds]
chimkan___ has quit [Client Quit]
bryancp has quit [Remote host closed the connection]
enebo has quit [Quit: enebo]
slyphon has quit [Quit: WeeChat 0.3.6]
fserb has joined #ruby-lang
Boohbah has joined #ruby-lang
sora_h is now known as s0ra_h
gsav has joined #ruby-lang
brushbox has joined #ruby-lang
Boohbah_ has joined #ruby-lang
Boohbah_ has quit [Remote host closed the connection]
dv310p3r has quit [Ping timeout: 244 seconds]
brushbox has quit [Client Quit]
fayimora has joined #ruby-lang
M4g1c5t0rM has joined #ruby-lang
benanne has quit [Quit: kbai]
Guedes has quit [Disconnected by services]
ttilley is now known as ttilley_off
bryancp has joined #ruby-lang
mrsolo has quit [Quit: This computer has gone to sleep]
srbartlett has joined #ruby-lang
stamina has joined #ruby-lang
mrsolo has joined #ruby-lang
<musl> What'd be the best way to implement or delegate the method methods() for a subclass of BasicObject, assuming I don't want to include Kernel?
tommyblue has quit [Ping timeout: 250 seconds]
<erikh> Forwardable probably
<erikh> (in stdlib)
<manveru> you can call methods only on Object instances
mistym has quit [Read error: Connection reset by peer]
<manveru> so you probably gonna have to implement it yourself
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
* musl reads about Forwardable
heftig has joined #ruby-lang
<erikh> manveru is probably right
<erikh> he usually doesn't say anything if he isn't. :P
<musl> hehe
tommyblue has joined #ruby-lang
<manveru> heh
dax has left #ruby-lang [#ruby-lang]
<manveru> well, unless you're on rbx, then there may be other ways
<musl> Naw, 1.9.3.
krohrbaugh has joined #ruby-lang
srbartlett has quit [Remote host closed the connection]
solars has quit [Ping timeout: 245 seconds]
tommyblue has quit [Ping timeout: 260 seconds]
Defusal_ has joined #ruby-lang
Defusal_ has joined #ruby-lang
postmodern has joined #ruby-lang
<drbrain> this is some pretty amazing code: http://paste.segment7.net/xk.html
<drbrain> (it also crashes ruby)
Defusal has quit [Ping timeout: 252 seconds]
<drbrain> in the original code, crash_in_infinite_loop was method_missing
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
DWoodiwiss has quit [Quit: dwoodiwiss]
<drbrain> apparently it was a work in progress, but I'm not sure what the next step would be
<zzak> good evening!
<shevy> magic!
bglusman has quit [Remote host closed the connection]
<shevy> the next step is pure magic
bglusman has joined #ruby-lang
<drbrain> I think the author wanted to implement method_missing do some hand-wavy magic then use super
llakey has quit [Quit: leaving]
llakey has joined #ruby-lang
bglusman has quit [Ping timeout: 245 seconds]
tommyblue has joined #ruby-lang
tommyblue has quit [Quit: Coyote finally caught me]
<erikh> wow, that's marvelous
<erikh> I think methlab does equally stupid things
<drbrain> right now it's just a SystemStackError factory
msaffitz_ has joined #ruby-lang
<shevy> you guys seem to have some kind of morbid fascination for code like that
<shevy> you scare me :\
<erikh> methlab has some nice features, that are unfortunately very slow
<drbrain> shevy: I'm curious about where it was going
<erikh> it handles method prototypes, multimethods, attr prototypes
<whitequark> ... methlab?
<whitequark> like mathlab, but for another kind of substances?..
<musl> manveru: Ahh, methods is implemented by class.c, and added to Object in object.c. Thanks for the pointer. :)
<erikh> drbrain: really not trying to pester you on this, but is there any other action on that rdoc superclass stuff?
<erikh> also I want to talk to you about refactoring RDoc::Stats, mainly to add formatters, but I think that's a longer conversation and I'm leaving soon.
felipe__ has joined #ruby-lang
<zzak> im hacking on stats atm too
<drbrain> erikh: sorry, I have been busy in HTTP land ☹
<erikh> it's ok
<drbrain> erikh: I will do my best to give it a look
<drbrain> … this week
<erikh> ok -- no rush, just wanted to get an idea.
<erikh> zzak: what are you doing with stats?
<drbrain> NARUSE is teaching me many things about net/http I did not know it could do
<erikh> awesome
<drbrain> … through my naive attempts at patching
<erikh> heh
<erikh> that's how I got familiar with rubygems!
* erikh runs
<drbrain> me: this adds feature A! NARUSE: you can't do it that way due to X! me: But Y! NARUSE: But Z! me: oh…
<zzak> erikh: any pointers?
<drbrain> so… I'm glad I'm not net/http maintainer
Skif has quit [Remote host closed the connection]
llakey has quit [Quit: leaving]
Skif has joined #ruby-lang
<shevy> hehe
<zzak> think i've got a test for it https://gist.github.com/2885375
postmodern has quit [Ping timeout: 246 seconds]
<zzak> its just not a very good test, and it only verifies that Object is indeed undocumented
postmodern has joined #ruby-lang
fserb has quit [Quit: ttyl]
llakey has joined #ruby-lang
<drbrain> zzak: that's a good-enough test
<drbrain> I would use refute_match %r%^class Object$%, report
dalekurt has quit [Quit: Zzz...]
<zzak> then i was thinking: RDoc::TopLevel.unique_classes.reject! { |cm| cm.full_name == 'Object' }
<drbrain> I think reject instead of reject!
<drbrain> in case unique_classes every becomes cached
srbartlett has joined #ruby-lang
msaffitz_ has quit [Quit: Computer has gone to sleep.]
anathan has quit [Quit: anathan]
s0ra_h is now known as sora_h
vaelen has quit [Remote host closed the connection]
bryancp_ has joined #ruby-lang
<zzak> drbrain: do you want a patch or PR?
<drbrain> PR, please
anathan has joined #ruby-lang
outoftime has quit [Quit: Leaving]
bryancp has quit [Ping timeout: 260 seconds]
<drbrain> seems fine
<zzak> thank you!
brianpWins has quit [Quit: brianpWins]
<drbrain> Travis will check it too
<zzak> those other test failures were cleared up on rdoc trunk
<zzak> the nonexistant ones
* drbrain nods
<andrewvos> Holy fuck just seen how many passwords I lost to linkedin.
<andrewvos> FFS
<andrewvos> Just spent the last 20 minutes fucking about with awkward guis.
NuclearLucifer has joined #ruby-lang
<andrewvos> By the way the search functionality in 1password is useful.
sush24 has quit [Quit: This computer has gone to sleep]
rmascarenhas has joined #ruby-lang
butchanton has quit [Remote host closed the connection]
butchanton has joined #ruby-lang
zerokarmaleft has quit [Ping timeout: 245 seconds]
zerokarmaleft has joined #ruby-lang
<zzak> drbrain: close #127 then?
arooni-mobile has quit [Read error: Connection reset by peer]
<drbrain> I'll do it
<drbrain> that other failure is order-dependent ☹
mistym has quit [Remote host closed the connection]
<drbrain> … and I'm not sure how ☹
<drbrain> oh, classes is not ordered
msaffitz has joined #ruby-lang
geekfactor has quit [Remote host closed the connection]
fayimora has quit [Read error: Connection reset by peer]
fayimora has joined #ruby-lang
<zzak> whoops
brushbox has joined #ruby-lang
ryanf has joined #ruby-lang
<zzak> i couldnt reproduce it with ree-1.8.7-2012.02
jbsan has quit [Quit: jbsan]
<zzak> maybe i should get ruby-1.8.7-p358
<drbrain> you have to run it a couple times
<drbrain> I fixed it now
<zzak> ree 2012.02 is p358 anyways
<zzak> it shouldnt matter
jbsan has joined #ruby-lang
butchanton has quit [Quit: Leaving.]