apeiros changed the topic of #ruby-lang to: Ruby 1.9.3-p374: http://ruby-lang.org (ruby-2.0.0-rc1) || Paste >3 lines of text on http://gist.github.com
cyri_ has joined #ruby-lang
brianpWins has quit [Quit: brianpWins]
drbrain has quit [Remote host closed the connection]
drbrain has joined #ruby-lang
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
krohrbaugh has joined #ruby-lang
KA_ has quit [Quit: KA_]
krohrbaugh has quit [Client Quit]
soypirate has quit [Quit: Leaving]
KA_ has joined #ruby-lang
mrsolo has quit [Quit: Leaving]
lsegal has joined #ruby-lang
krohrbaugh has joined #ruby-lang
KA_ has quit [Client Quit]
Spillrag has joined #ruby-lang
ruurd has quit [Quit: Leaving...]
madhadron has joined #ruby-lang
<madhadron> What's the easiest way to insert some text at the beginning and the end of an IO in Ruby?
kogent has joined #ruby-lang
kogent has quit [Remote host closed the connection]
kogent has joined #ruby-lang
tenderlo_ has joined #ruby-lang
tenderlove has quit [Ping timeout: 255 seconds]
sandbags has quit [Remote host closed the connection]
sush24 has joined #ruby-lang
unlikely_monkey has joined #ruby-lang
<andrewvos> shsjshshdjjsjsh
<CoverSlide> what's an IO and where can I get one?
<madhadron> CoverSlide: A File object, a StringIO...
<madhadron> A iostream, really
<madhadron> Or alternately, how to make Nokogiri handle multiple XML roots in a stream sensibly
<andrewvos> CoverSlide: i got some bro
postmodern has joined #ruby-lang
cyri_ has quit [Quit: cyri_]
Bosox20051 has joined #ruby-lang
havenn has quit [Remote host closed the connection]
krohrbaugh has quit [Quit: Leaving.]
xalei has joined #ruby-lang
marr has quit [Ping timeout: 276 seconds]
wmoxam_ has joined #ruby-lang
<andrewvos> nokogirlllll
madhadron has left #ruby-lang [#ruby-lang]
benanne has quit [Quit: kbai]
mistym has quit [Remote host closed the connection]
megha has quit [Ping timeout: 248 seconds]
havenn has joined #ruby-lang
<zenspider> argh. maglev parser is in gemstone :/
<zenspider> I think...
Kuifje has quit [Ping timeout: 256 seconds]
__butch__ has quit [Quit: Leaving.]
robotmay has quit [Remote host closed the connection]
gregmore_ has quit []
gregmore_ has joined #ruby-lang
gregmore_ has quit [Remote host closed the connection]
mercwithamouth has joined #ruby-lang
unlikely_monkey has quit [Remote host closed the connection]
megha has joined #ruby-lang
Spillrag has quit [Ping timeout: 252 seconds]
bluepojo1 has joined #ruby-lang
KA_ has joined #ruby-lang
bluepojo has quit [Ping timeout: 245 seconds]
tenderlo_ has quit [Remote host closed the connection]
bluepojo1 has quit [Ping timeout: 244 seconds]
nXqd has quit [Ping timeout: 255 seconds]
sush24_ has joined #ruby-lang
glebm has quit [Quit: Computer has gone to sleep.]
sush24 has quit [Ping timeout: 255 seconds]
KA_ has quit [Quit: KA_]
toretore has quit [Quit: Leaving]
drbrain has quit [Ping timeout: 256 seconds]
kentos has quit [Ping timeout: 246 seconds]
krohrbaugh has joined #ruby-lang
kentos has joined #ruby-lang
KA_ has joined #ruby-lang
charliesome has joined #ruby-lang
jtoy has quit [Quit: jtoy]
jtoy has joined #ruby-lang
kogent has quit [Remote host closed the connection]
kogent has joined #ruby-lang
sush24_ has quit [Quit: This computer has gone to sleep]
kiwnix has joined #ruby-lang
tsou has quit [Read error: No route to host]
kogent has quit [Ping timeout: 256 seconds]
Rakko has joined #ruby-lang
kiwnix has quit [Client Quit]
brianpWins has joined #ruby-lang
kiwnix has joined #ruby-lang
srbaker has joined #ruby-lang
gregmore_ has joined #ruby-lang
imajes has quit [Excess Flood]
sush24 has joined #ruby-lang
sush24 has quit [Remote host closed the connection]
sush24 has joined #ruby-lang
imajes has joined #ruby-lang
stardiviner has joined #ruby-lang
gregmore_ has quit [Ping timeout: 252 seconds]
tylersmith has quit [Quit: tylersmith]
srbaker has quit [Quit: Computer has gone to sleep.]
dwu has joined #ruby-lang
lcdhoffman has joined #ruby-lang
<havenn> Seems odd that if you change the capitalization of a gem name when you require it, MRI will actually reload the gem instead of returning false: require 'csv'; require 'CSV'; require 'cSv'
<havenn> JRuby's require seems to be case-insensitive.
drbrain has joined #ruby-lang
wallerdev has joined #ruby-lang
srbaker has joined #ruby-lang
sn0wb1rd has quit [Quit: sn0wb1rd]
<havenn> RBX's require is different than Ruby or JRuby's, returning true to varied caps. Seems to me that JRuby's behavior would be preferred?
madish has quit [Quit: ChatZilla 0.9.89 [Firefox 16.0.1/20121026125834]]
gregmore_ has joined #ruby-lang
retro|cz has joined #ruby-lang
gregmore_ has quit [Remote host closed the connection]
sush24 has quit [Quit: This computer has gone to sleep]
arooni-mobile has joined #ruby-lang
jtoy has quit [Quit: jtoy]
alvaro_o has quit [Quit: Ex-Chat]
<Rakko> havenn: are you talking about just the situation of running various Rubys on case-insensitive file systems? Or is that true on Unix too?
srbaker has quit [Quit: Computer has gone to sleep.]
spuk has quit [Ping timeout: 276 seconds]
mpan has quit [Ping timeout: 248 seconds]
brianpWins has quit [Quit: brianpWins]
sush24 has joined #ruby-lang
dzhulk has quit [Quit: Leaving.]
<havenn> Rakko: Good point. LoadError on Ubuntu but behavior above on OS X.
spuk has joined #ruby-lang
KA_ has quit [Quit: KA_]
KA_ has joined #ruby-lang
drbrain has quit [Remote host closed the connection]
drbrain has joined #ruby-lang
RubyGuy has joined #ruby-lang
emocakes has quit [Quit: emocakes]
jtoy has joined #ruby-lang
jtoy has quit [Client Quit]
sn0wb1rd has joined #ruby-lang
KA_ has quit [Quit: KA_]
wmoxam_ has quit [Ping timeout: 252 seconds]
<RubyGuy> test
RubyGuy has left #ruby-lang ["Leaving"]
RubyGuy has joined #ruby-lang
<RubyGuy> Can Someone answer this question - I want the script to continue on even when a error pops up http://pastebin.com/sZFqR2eH
<drbrain> RubyGuy: you want to rescue Resolv::ResolvError in the loop and continue
mercwithamouth has quit [Ping timeout: 252 seconds]
kurko_ has quit [Quit: Computer has gone to sleep.]
<RubyGuy> can you give me an example
<drbrain> RubyGuy: also, you don't need to redefine rand, use rand(1..255)
<drbrain> begin; Resolv.new.getname "…"; rescue Resolv::ResolvError => e; puts e.message; end
<RubyGuy> as in a,b,c,d = rand(1..255) ?
Nisstyre-laptop has joined #ruby-lang
mpan has joined #ruby-lang
mercwithamouth has joined #ruby-lang
<drbrain> you'll need to assign each one in turn, but you don't need the alias old_rand rand; def rand(min, max) … end
stonerfish has joined #ruby-lang
xalei has quit [Remote host closed the connection]
xalei has joined #ruby-lang
stonerfish has quit [Client Quit]
RWN has quit [Ping timeout: 240 seconds]
ckipel has joined #ruby-lang
jnoon has quit []
earthquake has quit [Ping timeout: 248 seconds]
ckipel is now known as earthquake
earthquake has quit [Client Quit]
xalei has quit [Remote host closed the connection]
dzhulk has joined #ruby-lang
Nisstyre-laptop has quit [Read error: Connection reset by peer]
kiwnix has quit [Remote host closed the connection]
brianpWins has joined #ruby-lang
andrewhl has joined #ruby-lang
gregmore_ has joined #ruby-lang
Nisstyre-laptop has joined #ruby-lang
RubyGuy has left #ruby-lang ["Leaving"]
mercwithamouth has quit [Ping timeout: 255 seconds]
GitNick has quit [Ping timeout: 248 seconds]
GitNick has joined #ruby-lang
havenn has quit [Remote host closed the connection]
ryanf has quit [Ping timeout: 245 seconds]
spuk has quit [Ping timeout: 246 seconds]
sush24 has quit [Quit: This computer has gone to sleep]
brew_ninja has joined #ruby-lang
flori has quit [Read error: Operation timed out]
ivanoats has joined #ruby-lang
flori has joined #ruby-lang
sush24 has joined #ruby-lang
Rakko has quit [Ping timeout: 256 seconds]
Asher has quit [Read error: No route to host]
Asher1 has joined #ruby-lang
Asher1 has quit [Client Quit]
Asher has joined #ruby-lang
brew_ninja has quit [Quit: Leaving]
Nisstyre_ has joined #ruby-lang
Nisstyre has quit [Ping timeout: 256 seconds]
ivanoats has quit [Remote host closed the connection]
ivanoats has joined #ruby-lang
havenn has joined #ruby-lang
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
ryanf has joined #ruby-lang
bzb has joined #ruby-lang
Asher has quit [Quit: Leaving.]
<bzb> learning class continuation...need some insight please...details @ http://pastebin.com/JFdYv60m
Asher has joined #ruby-lang
asaaki has quit [Ping timeout: 264 seconds]
mpan has quit [Ping timeout: 246 seconds]
earthquake has joined #ruby-lang
kentos has quit [Quit: Leaving]
dwu has quit [Disconnected by services]
dwu1 has joined #ruby-lang
asaaki has joined #ruby-lang
stardiviner has quit [Read error: Connection reset by peer]
stardiviner has joined #ruby-lang
gregmore_ has quit [Remote host closed the connection]
ryanf has quit [Ping timeout: 255 seconds]
KA_ has joined #ruby-lang
evanx has joined #ruby-lang
megha has quit [Quit: WeeChat 0.3.9.2]
mercwithamouth has joined #ruby-lang
workmad3 has joined #ruby-lang
<postmodern> how can you test whether a Net::SMTP instance has been closed?
<postmodern> ah wait, it appears do_quit sets @started to false
mytrile has joined #ruby-lang
sepp2k has quit [Remote host closed the connection]
workmad3 has quit [Ping timeout: 256 seconds]
ryanf has joined #ruby-lang
gregmore_ has joined #ruby-lang
evanx has quit [Ping timeout: 246 seconds]
earthquake has quit [Quit: earthquake]
evanx has joined #ruby-lang
stonerfish has joined #ruby-lang
gregmore_ has quit [Remote host closed the connection]
OneWhoFrogs has joined #ruby-lang
mistym has quit [Remote host closed the connection]
ryanf has quit [Ping timeout: 245 seconds]
<OneWhoFrogs> Could someone look over this DSL for me? I'd like to know what I can improve before I start implementing it. https://gist.github.com/4640483
gjaldon has joined #ruby-lang
guns has joined #ruby-lang
ryanf has joined #ruby-lang
stonerfish has quit [Quit: Leaving.]
mytrile_ has joined #ruby-lang
mytrile has quit [Read error: Connection reset by peer]
unlikely_monkey has joined #ruby-lang
unlikely_monkey has quit [Remote host closed the connection]
dhruvasagar has quit [Ping timeout: 246 seconds]
brianpWins has quit [Quit: brianpWins]
unlikely_monkey has joined #ruby-lang
sush24 has quit [Quit: This computer has gone to sleep]
<freedrull> new das screencast is pretty gnarly
OneWhoFrogs has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
unlikely_monkey has quit [Remote host closed the connection]
bzb has quit [Quit: Leaving]
ivanoats has quit [Remote host closed the connection]
arooni-mobile has quit [Ping timeout: 256 seconds]
earthquake has joined #ruby-lang
dwu1 has quit [Quit: Leaving.]
dcwu has joined #ruby-lang
arooni-mobile has joined #ruby-lang
megha has joined #ruby-lang
sush24 has joined #ruby-lang
arooni-mobile has quit [Max SendQ exceeded]
arooni-mobile has joined #ruby-lang
gregmore_ has joined #ruby-lang
brianpWins has joined #ruby-lang
brianpWins has quit [Client Quit]
gregmore_ has quit [Remote host closed the connection]
glebm has joined #ruby-lang
jbsan has joined #ruby-lang
methods has joined #ruby-lang
nirix has quit [Quit: ZNC - http://znc.in]
<charliesome> hah, TIL encodings are stored as an ivar on an object
nirix has joined #ruby-lang
nirix has quit [Client Quit]
nirix has joined #ruby-lang
neocoin has quit [Remote host closed the connection]
neocoin has joined #ruby-lang
KA_ has quit [Quit: KA_]
KA_ has joined #ruby-lang
sush24 has quit [Quit: This computer has gone to sleep]
glebm has quit [Ping timeout: 252 seconds]
arooni-mobile has quit [Ping timeout: 245 seconds]
srinivas has joined #ruby-lang
kgrz has joined #ruby-lang
srinivas has left #ruby-lang [#ruby-lang]
glebm has joined #ruby-lang
solars has joined #ruby-lang
ruurd has joined #ruby-lang
heftig has quit [Ping timeout: 245 seconds]
arooni-mobile has joined #ruby-lang
kgrz has quit [Ping timeout: 252 seconds]
arooni-mobile has quit [Ping timeout: 246 seconds]
andrewhl has quit [Remote host closed the connection]
heftig has joined #ruby-lang
nXqd has joined #ruby-lang
rue has quit [Remote host closed the connection]
rue has joined #ruby-lang
facest has joined #ruby-lang
faces has quit [Ping timeout: 255 seconds]
thufir_ has joined #ruby-lang
arooni-mobile has joined #ruby-lang
ruurd has quit [Quit: Leaving...]
zmack has joined #ruby-lang
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
krz has joined #ruby-lang
KA_ has quit [Quit: KA_]
stardivi` has joined #ruby-lang
Bosox20051 has quit [Remote host closed the connection]
stardivi` has quit [Client Quit]
sush24 has joined #ruby-lang
thufir_ has quit [Remote host closed the connection]
wallerdev has quit [Quit: wallerdev]
sush24 has quit [Quit: This computer has gone to sleep]
nXqd has quit [Ping timeout: 255 seconds]
guns has quit [Quit: guns]
mercwithamouth has quit [Ping timeout: 256 seconds]
earthquake has quit [Quit: earthquake]
__BigO__ has joined #ruby-lang
arooni-mobile has quit [Ping timeout: 256 seconds]
vlad_starkov has joined #ruby-lang
arooni-mobile has joined #ruby-lang
sush24 has joined #ruby-lang
marr has joined #ruby-lang
blahwoop has quit []
tbuehlmann has joined #ruby-lang
vlad_starkov has quit [Read error: Connection reset by peer]
vlad_starkov has joined #ruby-lang
zmack has quit [Read error: Connection reset by peer]
emocakes has joined #ruby-lang
zmack has joined #ruby-lang
arooni-mobile has quit [Ping timeout: 256 seconds]
JohnBat26 has joined #ruby-lang
__BigO__ has quit [Remote host closed the connection]
mossplix has joined #ruby-lang
zmack has quit [Remote host closed the connection]
arooni-mobile has joined #ruby-lang
benanne has joined #ruby-lang
Nisstyre-laptop has quit [Ping timeout: 252 seconds]
vlad_sta_ has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 245 seconds]
emocakes has quit [Quit: emocakes]
<whitequark> how do I specify make pattern like %.o: %.c in Rake?
gjaldon has quit [Remote host closed the connection]
<whitequark> rule '.o' => '.c'.
Skitsu`work has quit [Ping timeout: 240 seconds]
techlife has quit [Ping timeout: 276 seconds]
Skitsu`work has joined #ruby-lang
arooni-mobile has quit [Ping timeout: 256 seconds]
gjaldon has joined #ruby-lang
techlife has joined #ruby-lang
techlife has quit [Max SendQ exceeded]
JohnBat26 has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
techlife has joined #ruby-lang
neocoin has quit [Remote host closed the connection]
arooni-mobile has joined #ruby-lang
emocakes has joined #ruby-lang
Skitsu`work has quit [Ping timeout: 264 seconds]
gjaldon_ has joined #ruby-lang
gjaldon has quit [Ping timeout: 276 seconds]
Skitsu`work has joined #ruby-lang
toretore has joined #ruby-lang
Kuifje has joined #ruby-lang
Kuifje has quit [Changing host]
Kuifje has joined #ruby-lang
blacktulip has joined #ruby-lang
<postmodern> whitequark, i also want to know this
<Mon_Ouie> You did see he found the answer himself?
<whitequark> postmodern: well, I've posted the answer, no?
<postmodern> whitequark, oh oops, nie
<postmodern> it's late :)
asio has joined #ruby-lang
madish has joined #ruby-lang
mossplix has quit [Quit: mossplix]
arooni-mobile has quit [Ping timeout: 256 seconds]
robotmay has joined #ruby-lang
arooni-mobile has joined #ruby-lang
dcwu has quit [Quit: Leaving.]
<khaase> drbrain: you around?
<khaase> anyone experience with client side http?
<khaase> first request with net-http-persistent is horribly slow
<khaase> I think it might be the SSL handshake
<khaase> but curl for instance is way faster
<khaase> we're speaking 5 sec vs 0.1 sec
<khaase> also, subsequent requests with persistent connection are fast (0.15 sec)
<khaase> but I mostly just do one request
<khaase> anyone experience with alternative http libraries
<khaase> have to work on all rubies and on windows, though
<khaase> all rubies as in 1.8.7, 1.9.2, 1.9.3, 2.0, jruby and rubinius
sandbags has joined #ruby-lang
sandbags has quit [Changing host]
sandbags has joined #ruby-lang
Banistergalaxy has joined #ruby-lang
ruurd has joined #ruby-lang
robotmay has quit [Ping timeout: 255 seconds]
dzhulk has quit [Quit: Leaving.]
ruurd has quit [Quit: Leaving...]
arooni-mobile has quit [Ping timeout: 256 seconds]
robotmay has joined #ruby-lang
gjaldon_ has quit [Remote host closed the connection]
jxie has quit [Quit: leaving]
guns has joined #ruby-lang
RWN has joined #ruby-lang
<andrewvos> khaase: HTTParty is quite nice, but it is an abstraction.
<khaase> yeah, they haven't shipped a faraday release with support for it yet
<khaase> though it's in master
<khaase> also, this is not about api, this is about the first request sometimes taking up to 6 seconds
<khaase> which kinda sucks
<khaase> excon isn't any faster
<khaase> typhon doesn't like custom ssl certs
<khaase> patron errors on some timeout
<khaase> net-http is as slow as excon
<khaase> net-http-persistent is really fast, but only for subsequent requests, first one is as slow as net-http
<whitequark> khaase: something with dns?
<khaase> whitequark: dunno, if I just use curl it's wonderfully fast
<whitequark> strace it and check where it spends all that time
<whitequark> or tcpdump is also your friend
megha has quit [Quit: WeeChat 0.4.0]
<whitequark> or wireshark
<whitequark> not every problem in this world can be solved with more ruby code...
<khaase> tcpdump and wireshark will only show the encrypted stream, no?
<whitequark> khaase: correct, but if it retransmits something or waits for SYN|ACK that'll show you the problem
<whitequark> or if it's a DNS problem
<khaase> I imagine that curl would have these issues, too, no?
<khaase> trying rbtrace
<whitequark> you never know it for sure
<whitequark> erm no, strace
<khaase> rbtrace is a wrapper around strace
<khaase> no?
<khaase> ok, if you say I should try strace...
<whitequark> from the readme it seems that it traces ruby functions
<whitequark> and strace traces syscalls
<khaase> ah, so, if I use em-synchrony first call is fast
<whitequark> rbtrace might be useful too, but in different ways
<whitequark> this is interesting. what else do you have loaded?
<khaase> or well, dtruss
<whitequark> well that's os x and I have no idea about os x.
stardiviner has quit [Quit: my website: http://stardiviner.dyndns-blog.com/]
<khaase> whitequark: faraday, faraday_middleware, highline
robotmay has quit [Read error: No route to host]
robotmay has joined #ruby-lang
<whitequark> khaase: it doesn't seem that anything of that would hijack I/O
<whitequark> like synchrony does
sush24 has quit [Ping timeout: 246 seconds]
<khaase> I don't think em-synchrony is an option
<khaase> as event machine is not know to work well on windows
<khaase> or jruby
<whitequark> the fact that it begins to work with EM just means that a complicated bug is hidden somewhere
<whitequark> EM by itself shouldn't impose that effect
sush24 has joined #ruby-lang
gja has joined #ruby-lang
gja has quit [Changing host]
gja has joined #ruby-lang
<khaase> whitequark: yes
<khaase> whitequark: but it must be a bug replicated in excon
<khaase> whitequark: it's also annoying that typhon and patron just error on this, otherwise I wouldn't mind just switching
<khaase> but a 6 second rtt is kinda annoying for a CLI that just does that single request and presents the result
sush24 has quit [Ping timeout: 252 seconds]
<khaase> it also means it's unlikely to be a bug in faraday
<khaase> it's not related to the fiber hacks synchrony does, just using em-http performs well, too
sush24 has joined #ruby-lang
robotmay has quit [Remote host closed the connection]
sush24_ has joined #ruby-lang
sush24 has quit [Ping timeout: 252 seconds]
kennyvb has quit [Ping timeout: 252 seconds]
x0F has quit [Disconnected by services]
x0F_ has joined #ruby-lang
x0F_ is now known as x0F
kennyvb has joined #ruby-lang
retro|cz has quit [Ping timeout: 256 seconds]
robotmay has joined #ruby-lang
vlad_sta_ has quit [Remote host closed the connection]
lcdhoffman has quit [Quit: lcdhoffman]
publicvoid has joined #ruby-lang
lcdhoffman has joined #ruby-lang
lcdhoffman has quit [Client Quit]
lcdhoffman has joined #ruby-lang
sush24_ has quit [Quit: This computer has gone to sleep]
lcdhoffman has quit [Client Quit]
lcdhoffman has joined #ruby-lang
lcdhoffman has quit [Client Quit]
lcdhoffman has joined #ruby-lang
gjaldon has joined #ruby-lang
lcdhoffman has quit [Quit: lcdhoffman]
kurko_ has joined #ruby-lang
gja has quit [Quit: This computer has gone to sleep]
mantono has quit [Remote host closed the connection]
gjaldon has quit [Ping timeout: 245 seconds]
gjaldon has joined #ruby-lang
stardiviner has joined #ruby-lang
gja has joined #ruby-lang
gja has quit [Changing host]
gja has joined #ruby-lang
jtoy has joined #ruby-lang
megha has joined #ruby-lang
sailias has joined #ruby-lang
lcdhoffman has joined #ruby-lang
RWN has quit [Ping timeout: 245 seconds]
glebm has quit [Quit: Textual IRC Client: www.textualapp.com]
RWN has joined #ruby-lang
ruurd has joined #ruby-lang
sush24 has joined #ruby-lang
jxie has joined #ruby-lang
tejas has joined #ruby-lang
tejas has quit [Changing host]
tejas has joined #ruby-lang
<sandbags> anyone have any idea why a random Ruby string might end up with spaces encoded as xC2A0 rather than x20 ?
kurko_ has quit [Ping timeout: 252 seconds]
<sandbags> this is in the context of a Rails application although the puzzling data is in a MySQL row so i've no idea really whether Rails was involved
<sandbags> other rows before and after the offending row seem normal
gja has quit [Ping timeout: 276 seconds]
stardiviner has quit [Quit: my website: http://stardiviner.dyndns-blog.com/]
vlad_starkov has joined #ruby-lang
tejas has quit [Quit: This computer has gone to sleep]
<sandbags> i can handle this via the, rather ugly, s = s.gsub( "\u00A0", " " )
lcdhoffman has quit [Quit: lcdhoffman]
banisterfiend has joined #ruby-lang
sailias has quit [Quit: Leaving.]
asaaki has quit [Remote host closed the connection]
havenn has quit [Remote host closed the connection]
vlad_starkov has quit [Ping timeout: 276 seconds]
postmodern has quit [Quit: Leaving]
<megha> how can i remove disk authorization which i require to mount the device each time after reboot !
<megha> can i do something using polkit ?
dfyuij has joined #ruby-lang
<megha> sorry wrong post
imperator2 is now known as imperator
gja has joined #ruby-lang
gja has joined #ruby-lang
gja has quit [Changing host]
postmodern has joined #ruby-lang
ruskie has quit [Ping timeout: 245 seconds]
neocoin has joined #ruby-lang
KINGSABRI has joined #ruby-lang
<KINGSABRI> hello everybody
swav has joined #ruby-lang
<KINGSABRI> I want to generate long unique string then specify character position , something like pattern_create and pattern_offset in metasploit
<KINGSABRI> and still I did not understand the way to create that
gja has quit [Quit: Leaving]
<postmodern> KINGSABRI, checkout the chars library, https://github.com/postmodern/chars#examples
KA_ has joined #ruby-lang
dzhulk has joined #ruby-lang
<KINGSABRI> postmodern, It generates random chars , I thinks pattern_create is fixed sequanced chars to allow pattern_offsec determine the length , correct me
<postmodern> KINGSABRI, look at the documentation of Chars::CharSet, it allows control the length
<postmodern> KINGSABRI, if you need something more targeted, use String#generate, http://ronin-ruby.github.com/docs/ronin-support/String.html#generate-class_method
sepp2k has joined #ruby-lang
swav has quit [Ping timeout: 245 seconds]
charliesome has quit [Quit: Textual IRC Client: www.textualapp.com]
KA_ has quit [Quit: KA_]
swav has joined #ruby-lang
jxie has quit [Quit: leaving]
methods has left #ruby-lang [#ruby-lang]
gregf has joined #ruby-lang
ruurd has quit [Quit: Leaving...]
RWN has quit [Ping timeout: 255 seconds]
emocakes has quit [Quit: emocakes]
RWN has joined #ruby-lang
enebo has joined #ruby-lang
ruurd has joined #ruby-lang
andrewhl has joined #ruby-lang
mistym has joined #ruby-lang
emocakes has joined #ruby-lang
megha has quit [Quit: WeeChat 0.4.0]
<KINGSABRI> postmodern, it's going good in generating ,, now the another hand ,, get offset
apeiros_ has joined #ruby-lang
enebo has quit [Read error: Connection reset by peer]
enebo has joined #ruby-lang
<yorickpeterse> whitequark: problem: storing AST nodes as Hash keys will result in me not being able to perform a lookup if I have a node with the same structure but with a different object ID. Is there a way to work around this?
<yorickpeterse> e.g. `hash = {}; hash[s(:string, 'example')] = 10; hash[s(:string, 'example')] # => nil`
<yorickpeterse> Ideally I'd compare nodes based on the type, children and meta data but I'm not sure if Hash#key? and Hash#[] and the likes would work with that
banisterfiend has quit [Remote host closed the connection]
<yorickpeterse> Hm, I suppose I could subclass Hash and modify the behaviour of Hash#[]
<yorickpeterse> (of that subclass)
<whitequark> yorickpeterse: hmm
<whitequark> I guess I could precompute hashes before freezing
<yorickpeterse> the easy but non scalable way: extract keys, use #select in combination with #==
<whitequark> yorickpeterse: metadata won't go in hash, it is a design choice
<yorickpeterse> that's fine for me
<whitequark> ok. then I'll do the stuff with #hash
<yorickpeterse> In fact, if it were I'd never get two nodes to equal each other
<yorickpeterse> due to line numbers being stored they'd always be different
ruurd has quit [Quit: Leaving...]
<KINGSABRI> postmodern, I can get it by index s.index(/A2A3A/)
<KINGSABRI> => 4
<whitequark> yorickpeterse: but it will still require one deep comparison on each #== and lookup
<yorickpeterse> hmm
ruurd has joined #ruby-lang
<yorickpeterse> As long as it doesn't get balls slow I'm fine with it, I don't expect an insane amount of lookups anyway
banisterfiend has joined #ruby-lang
<whitequark> well, now it requires one deep comparison per #==
<whitequark> but even if the nodes are actually non-equal
<yorickpeterse> if there was something like #object_id but it not being unique (e.g. `foo'.some_id == 'foo'.some_id # => true`) that would make this so much easier
<whitequark> yorickpeterse: it's called #hash
<whitequark> but it could be same for different nodes, because you have an unbounded amount of nodes but your hash space is obviously bounded
<yorickpeterse> Interesting, it seems Hash#[] doesn't even use #==
<whitequark> yes, it uses #eql?
* whitequark sighs
<whitequark> let me explain this yet again
<yorickpeterse> oh? The C code doesn't seem to show that
<whitequark> ruby has three comparison operators, #== (equality), #eql? (equivalence) and #equal? (identity)
mossplix has joined #ruby-lang
<whitequark> they're mainly important due to the way the numeric tower works
<whitequark> first, 1 == 1, 1.eql? 1, 1.equal? 1
<whitequark> second, 1 == 1.0, !1.eql? 1.0, !1.equal? 1.0
<whitequark> third, 1e30 == 1e30, 1e30.eql? 1e30, !1e30.equal? 1e30
<whitequark> == is what you use, .eql? is what Hash uses, .equal? isn't used by Ruby itself, it's only for your convenience when debugging
<whitequark> and various weird tricks.
<yorickpeterse> if Hash#[] were to use eql? I'd expect to be able to override that method to patch it up (on my AST nodes). This doesn't seem to be the case though
<whitequark> Hash works like this: first it effectively compares elements by their #hash, then, after it found two elements with the same #hash, it compares them with #eql?
<whitequark> "effectively" both as in "in essence" and "fast"
<yorickpeterse> Hm, that would explain: #hash returns different output
<yorickpeterse> so it already bails out there
<whitequark> #hash value should have a nice random distribution in order for the hash table to work efficiently
<whitequark> i.e. have O(1) lookup
<whitequark> #eql? is required because #hash values aren't unique
<whitequark> and in fact #hash return value _must_ be a Fixnum
<Mon_Ouie> Does it error if you return a bignum?
<yorickpeterse> Hm, I think I have an idea
<whitequark> Mon_Ouie: yeah
<yorickpeterse> one that would not require to mess with eql, ==, etc
enebo has quit [Ping timeout: 256 seconds]
<whitequark> try it yourself
<whitequark> Mon_Ouie: hm, it doesn't, strange
megha has joined #ruby-lang
<whitequark> well, it does truncate it internally anyway
<whitequark> yorickpeterse: which idea?
<yorickpeterse> gimme a sec, first need to see if it actually works
enebo has joined #ruby-lang
<yorickpeterse> ha ha!
<yorickpeterse> it works
__BigO__ has joined #ruby-lang
<yorickpeterse> ruby-lint specific though
masa9173 has joined #ruby-lang
<whitequark> yorickpeterse: don't get it
<yorickpeterse> basically I'm just storing the definitions for each new scope. This way I can just say `current_scope.has_definition?(:local_variable, 'foo')` and I'm done
<yorickpeterse> I needed this anyway so it's another win
<whitequark> hm ok
<yorickpeterse> hmmmm, maybe that I means I can even ditch the whole lookup table with AST nodes as the keys
<whitequark> perfect
<yorickpeterse> yes! haha
* yorickpeterse makes a fist
megha has quit [Quit: WeeChat 0.4.0]
<yorickpeterse> Hm, I need to write some tests for this in combination with constant paths though. But first, groceries!
megha has joined #ruby-lang
<KINGSABRI> postmodern, PM, please?
mytrile_ has quit [Ping timeout: 256 seconds]
<postmodern> KINGSABRI, not sure what your trying to do?
pnr has joined #ruby-lang
<KINGSABRI> postmodern, I need to build same "String.generate" but simple one an I can control exact length
<postmodern> KINGSABRI, Array.new(length) { random_char }.join
<KINGSABRI> ronin doing great but I need to build mine to understand how thing going with simple way >> I'm not a prof :$
masa9173 has quit [Quit: Nettalk6 - www.ntalk.de]
<postmodern> KINGSABRI, also String.generate allows you to specify length, check the examples
sandbags has quit [Remote host closed the connection]
sandbags has joined #ruby-lang
sandbags has quit [Changing host]
sandbags has joined #ruby-lang
<postmodern> KINGSABRI, String.generate([:alpha, 3..7])
sandbags1138 has joined #ruby-lang
sandbags has quit [Read error: Connection reset by peer]
<KINGSABRI> postmodern, String.generate([:alpha, 1], :numeric) do |password|; print password; end
<KINGSABRI> this one give me 1040 characters length
wallerdev has joined #ruby-lang
<KINGSABRI> postmodern, assume I need length = 500 exactly
<postmodern> KINGSABRI, uh, that only prints strings of 2 characters?
<postmodern> KINGSABRI, do you mean that you only need 500 elements from that list?
<postmodern> KINGSABRI, String.generate(...).take(500).each
<KINGSABRI> postmodern, yes
<postmodern> KINGSABRI, Enumerable is very handy, http://rubydoc.info/stdlib/core/Enumerable
<KINGSABRI> postmodern, my issue is not the syntax it's the core algorithm to generate this pattern :(
__BigO__ has quit [Remote host closed the connection]
gregmore_ has joined #ruby-lang
<postmodern> KINGSABRI, which is?
_________ has joined #ruby-lang
<KINGSABRI> postmodern, generating fixed permutation of punch of chr+num like (A0A1A2A3A4A5A...etc)
<andrewvos> This should be easy?
<postmodern> KINGSABRI, you can do that with String.generate
<andrewvos> Oh, permutation.
<andrewvos> Oh wait, not that looks simple.
<andrewvos> no*
<KINGSABRI> postmodern, you're doing security framework and you know pattern_create of course
<KINGSABRI> the goal is independent pattern_create - not related to any framework
<postmodern> KINGSABRI, you can use enumerators within String.generate([enum_for(:some_function), 2..10])
<postmodern> KINGSABRI, you can easily recreate this using Enumerable/Enumerator
<KINGSABRI> postmodern, thanks
mytrile has joined #ruby-lang
tdy_ has joined #ruby-lang
tdy has quit [Ping timeout: 246 seconds]
tdy_ has quit [Client Quit]
robotmay has quit [Remote host closed the connection]
lcdhoffman has joined #ruby-lang
_________ has quit [Quit: Textual IRC Client: www.textualapp.com]
tdy has joined #ruby-lang
gustavnils has joined #ruby-lang
gregmore_ has quit [Remote host closed the connection]
Kuifje has quit [Read error: Connection reset by peer]
postmodern has quit [Quit: Leaving]
Kuifje has joined #ruby-lang
gustavnils has quit [Client Quit]
gustavnils has joined #ruby-lang
mytrile has quit [Remote host closed the connection]
tdy has quit [Ping timeout: 252 seconds]
sush24_ has joined #ruby-lang
guns has quit [Ping timeout: 255 seconds]
tdy has joined #ruby-lang
sush24 has quit [Ping timeout: 240 seconds]
KA__ has joined #ruby-lang
mercwithamouth has joined #ruby-lang
masa1973 has joined #ruby-lang
<manveru> String.generate, what gem is that?
KINGSABRI has left #ruby-lang ["Leaving"]
gjaldon has quit [Remote host closed the connection]
sush24_ has quit [Quit: This computer has gone to sleep]
Skitsu`work has quit [Ping timeout: 248 seconds]
Skitsu`work has joined #ruby-lang
guns has joined #ruby-lang
Skitsu`work has quit [Read error: Operation timed out]
ruurd has quit [Quit: Leaving...]
lcdhoffman has quit [Quit: lcdhoffman]
gustavnils has quit [Quit: Textual IRC Client: www.textualapp.com]
<manveru> [3] pry(main)> got = {alpha: [*"a".."z",*"A".."Z"], num: [*0..9]}; Array.new(11){ [got[:alpha].sample, got[:num].sample] }.join
<manveru> => "O9R1O8a9S6d1Y6l7p1G6n0"
<manveru> well, not that hard :)
gustavnils has joined #ruby-lang
<banisterfiend> manveru: btw, u can go: gist -i 3 instead
mytrile has joined #ruby-lang
<lianj> ?
<manveru> i paste everything < 4 lines in irc
<lianj> yea, ruby and oneliner are made for irc
<banisterfiend> manveru: clipit -i 3 (to put the code in clipboard then :D)
<manveru> which clipboard?
<banisterfiend> manveru: it just uses things like pbcopy etc
<banisterfiend> not sure exactly, it's provided by the jist gem
<banisterfiend> puts it in the osx clipboard on osx
<manveru> The command 'clipit' is unavailable because it requires the following gems to be installed: jist
<banisterfiend> install-command gist
<manveru> dunno, i just select to copy and middle-click to paste
<banisterfiend> yeah np
<manveru> no need to break that workflow just for pry
<banisterfiend> yeah, you dont hae to use it, just letting you know
<banisterfiend> sry
<manveru> though it might be handy if i only have tty, but the i have no X clipboards either :P
<banisterfiend> manveru: cool thing about it (imo) is it also works on classes/methods etc: clipit MyClass#my_method
Skitsu`work has joined #ruby-lang
ruurd has joined #ruby-lang
<manveru> :)
<manveru> well, it seems to work, but i'll probably forget about it
mytrile has quit [Ping timeout: 256 seconds]
enebo has quit [Quit: enebo]
jtoy has quit [Quit: jtoy]
mercwithamouth has quit [Ping timeout: 252 seconds]
jtoy has joined #ruby-lang
mossplix has quit [Ping timeout: 256 seconds]
nyuszika7h has quit [Ping timeout: 256 seconds]
nyuszika7h has joined #ruby-lang
sandbags1138 has quit [Remote host closed the connection]
ruurd has quit [Quit: Leaving...]
ruurd has joined #ruby-lang
havenn has joined #ruby-lang
KA__ has quit [Quit: KA__]
tbuehlmann has quit [Remote host closed the connection]
masa1973 has quit [Ping timeout: 246 seconds]
KA__ has joined #ruby-lang
tbuehlmann has joined #ruby-lang
spuk has joined #ruby-lang
dcwu has joined #ruby-lang
ruurd has quit [Quit: Leaving...]
ruurd has joined #ruby-lang
sepp2k1 has joined #ruby-lang
sepp2k has quit [Ping timeout: 252 seconds]
ivanoats has joined #ruby-lang
ivanoats has quit [Changing host]
ivanoats has joined #ruby-lang
earthquake has joined #ruby-lang
thufir_ has joined #ruby-lang
tdy has quit [Ping timeout: 276 seconds]
mytrile has joined #ruby-lang
methods has joined #ruby-lang
apeiros_ has quit [Remote host closed the connection]
banisterfiend has quit [Read error: Connection reset by peer]
methods has left #ruby-lang [#ruby-lang]
tdy has joined #ruby-lang
mercwithamouth has joined #ruby-lang
Nisstyre-laptop has joined #ruby-lang
megha has quit [Quit: WeeChat 0.4.0]
imajes has quit [Excess Flood]
imajes has joined #ruby-lang
tylersmith has joined #ruby-lang
guns has quit [Quit: guns]
dankest has joined #ruby-lang
ivanoats has quit [Remote host closed the connection]
swav has quit [Read error: Connection reset by peer]
swav has joined #ruby-lang
retro|cz has joined #ruby-lang
earthquake has quit [Quit: earthquake]
gregf has quit [Quit: WeeChat 0.3.8]
Miraks has joined #ruby-lang
earthquake has joined #ruby-lang
lunarjar has joined #ruby-lang
mistym has quit [Remote host closed the connection]
Banistergalaxy has quit [Ping timeout: 255 seconds]
banisterfiend has joined #ruby-lang
Banistergalaxy has joined #ruby-lang
Miraks has quit []
megha has joined #ruby-lang
publicvoid has quit [Ping timeout: 252 seconds]
megha has quit [Client Quit]
apeiros_ has joined #ruby-lang
neocoin has quit [Remote host closed the connection]
syncdot has joined #ruby-lang
syncdot has quit [Client Quit]
apeiros_ has quit [Ping timeout: 252 seconds]
xcombelle has joined #ruby-lang
publicvoid has joined #ruby-lang
srbaker has joined #ruby-lang
Banistergalaxy has quit [Ping timeout: 240 seconds]
Banistergalaxy has joined #ruby-lang
spuk has quit [Quit: Human beings were created by water to transport it uphill.]
spuk has joined #ruby-lang
xcombelle has quit [Remote host closed the connection]
havenn has quit [Remote host closed the connection]
Rarrikins has joined #ruby-lang
gustavnils has quit [Quit: Textual IRC Client: www.textualapp.com]
gustavnils has joined #ruby-lang
RWN has quit [Ping timeout: 276 seconds]
banisterfiend has quit [Remote host closed the connection]
RWN has joined #ruby-lang
b1rkh0ff has joined #ruby-lang
jammi has left #ruby-lang ["WeeChat 0.3.9.1"]
lsegal has joined #ruby-lang
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
dankest is now known as dankest|away
havenn has joined #ruby-lang
Rarrikins_a has joined #ruby-lang
Rarrikins has quit [Ping timeout: 240 seconds]
srbaker has quit [Quit: Computer has gone to sleep.]
dankest|away is now known as dankest
rhizmoe has quit [Quit: Lost terminal]
enebo has joined #ruby-lang
havenn has quit [Ping timeout: 256 seconds]
Nisstyre-laptop has quit [Read error: Connection reset by peer]
Nisstyre-laptop has joined #ruby-lang
mistym has quit [Remote host closed the connection]
<manveru> das kann alt-* combos nicht :(
<manveru> muss stattdessen esc-* verwenden
havenn has joined #ruby-lang
<whitequark> manveru: what
<whitequark> or should I say "was ist das"?
<jtoy> what does \1 do here? http://rubular.com/r/IVIA6P0HAk
<manveru> sorry, wrong channel
<whitequark> jtoy: backreference
<whitequark> jtoy: it matches whatever the first group has captured
<jtoy> whitequark: ah, I've never used that before
workmad3 has joined #ruby-lang
<whitequark> manveru: hehe. that was pretty much the only german phrase I know
<manveru> whitequark: "ein bier bitte", now you're able to survive :)
<whitequark> manveru: that being said, I like the language. can just sit and listen to a ebook; don't understand a word, but like how it sounds.
<whitequark> hehe
havenn has quit [Remote host closed the connection]
UNIXgod has joined #ruby-lang
<FiXato> ein?
<FiXato> 'bier und würst bitte. SCHNELLER, SCHNELLER!'
<yorickpeterse> manveru: das macht mir spass
<yorickpeterse> jawohl, etc
<yorickpeterse> my German is so rusty
havenn has joined #ruby-lang
workmad3 has quit [Ping timeout: 256 seconds]
banisterfiend has joined #ruby-lang
evanx has quit [Ping timeout: 256 seconds]
evanx_ has joined #ruby-lang
banisterfiend has quit [Read error: Connection reset by peer]
havenn has quit [Remote host closed the connection]
Banistergalaxy has quit [Ping timeout: 245 seconds]
Banistergalaxy has joined #ruby-lang
havenn has joined #ruby-lang
RWN has quit [Remote host closed the connection]
pythonsnake has joined #ruby-lang
pythonsnake has left #ruby-lang [#ruby-lang]
tbuehlmann has quit [Quit: Yaaic - Yet another Android IRC client - http://www.yaaic.org]
voker57 has quit [Read error: Operation timed out]
thone has joined #ruby-lang
thone_ has quit [Read error: Operation timed out]
voker57 has joined #ruby-lang
voker57 has quit [Changing host]
voker57 has joined #ruby-lang
tylersmith has quit [Quit: tylersmith]
enebo has quit [Quit: enebo]
banisterfiend has joined #ruby-lang
workmad3 has joined #ruby-lang
_tockitj has quit [Ping timeout: 252 seconds]
ruurd has quit [Quit: Leaving...]
blacktulip has quit [Remote host closed the connection]
andrewhl has quit [Remote host closed the connection]
andrewhl has joined #ruby-lang
spuk has quit [Quit: Human beings were created by water to transport it uphill.]
imajes has quit [Excess Flood]
imajes has joined #ruby-lang
andrewhl has quit [Ping timeout: 276 seconds]
KA__ has quit [Quit: KA__]
Vektur has joined #ruby-lang
KA_ has joined #ruby-lang
dfyuij has quit [Ping timeout: 252 seconds]
ruurd has joined #ruby-lang
KA_ has quit [Read error: Connection reset by peer]
KA_ has joined #ruby-lang
workmad3 has quit [Ping timeout: 244 seconds]
vlad_starkov has joined #ruby-lang
drbrain has quit [Remote host closed the connection]
rdw200169 has quit [Ping timeout: 240 seconds]
elux has joined #ruby-lang
gix has quit [Ping timeout: 276 seconds]
swav has quit [Ping timeout: 256 seconds]
swav has joined #ruby-lang
rdw200169 has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 252 seconds]
gix has joined #ruby-lang
spuk has joined #ruby-lang
lunarjar has quit [Remote host closed the connection]
mistym has joined #ruby-lang
mistym has joined #ruby-lang
publicvoid has quit [Ping timeout: 252 seconds]
workmad3 has joined #ruby-lang
spuk has quit [Read error: Connection reset by peer]
gregf has joined #ruby-lang
swav_ has joined #ruby-lang
swav has quit [Ping timeout: 276 seconds]
swav has joined #ruby-lang
swav_ has quit [Read error: Connection reset by peer]
spuk has joined #ruby-lang
ruurd has quit [Quit: Leaving...]
Vektur has quit []
spuk has quit [Quit: Human beings were created by water to transport it uphill.]
Vektur has joined #ruby-lang
workmad3 has quit [Ping timeout: 256 seconds]
spuk has joined #ruby-lang
banisterfiend is now known as banister`sleep
spuk has quit [Read error: Connection reset by peer]
methods has joined #ruby-lang
methods has quit [Client Quit]
robbyoconnor has quit [Read error: Connection reset by peer]
methods has joined #ruby-lang
sepp2k1 has quit [Remote host closed the connection]
lcdhoffman has joined #ruby-lang
methods has left #ruby-lang [#ruby-lang]
sepp2k has joined #ruby-lang
Rarrikins has joined #ruby-lang