havenwood changed the topic of #ruby to: Rules & more: http://ruby-community.com || Ruby 2.3.0; 2.2.4; 2.1.8; 2.0.0-p648: https://ruby-lang.org || Paste >3 lines of text on https://gist.github.com || log @ http://irclog.whitequark.org/ruby/
lkba_ has joined #ruby
sdwrage_ has quit [Quit: This computer has gone to sleep]
sdwrage_ has joined #ruby
XnbqNT9SrauX has joined #ruby
xxneolithicxx has quit [Quit: Leaving.]
<jackcom> if i excute gruff file, then i make png file instead of excuting app. how can i do?
ivanskie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
pawnbox has joined #ruby
scottschecter has joined #ruby
gruz0 has quit [Quit: This computer has gone to sleep]
Snowy has joined #ruby
TDJACR has joined #ruby
northfurr has joined #ruby
scottschecter has quit [Client Quit]
<havenwood> jackcom: huh?
<jackcom> how?
lkba has quit [Ping timeout: 246 seconds]
<jackcom> i want excute app instead of png
mondok has quit [Ping timeout: 240 seconds]
XnbqNT9SrauX_ has joined #ruby
<havenwood> jackcom: what app?
sepp2k has quit [Read error: Connection reset by peer]
XnbqNT9SrauX_ has quit [Read error: Connection reset by peer]
<jackcom> program
<jackcom> instead of png
<havenwood> You want to "execute app" with a library that creates pngs? What does that mean?
<Ox0dea> Unreal.
tubuliferous_ has joined #ruby
<Ox0dea> havenwood: He doesn't deserve your time.
Snowy has quit [Ping timeout: 240 seconds]
emilford has quit [Ping timeout: 246 seconds]
<jackcom> i want see chart in the framework instead of png havenwood
dpg_ has joined #ruby
pawnbox has quit [Ping timeout: 256 seconds]
jgt1 has joined #ruby
govg has quit [Ping timeout: 272 seconds]
emilford has joined #ruby
ivanskie has joined #ruby
B1n4r10 has joined #ruby
tubuliferous_ has quit [Ping timeout: 260 seconds]
<jackcom> png don’t move
<jackcom> :(
dn5 has joined #ruby
felixdd has joined #ruby
pawnbox has joined #ruby
choke has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
babblebre has quit [Quit: Connection closed for inactivity]
Klumben has joined #ruby
carella has quit [Remote host closed the connection]
jgt2 has joined #ruby
jgt2 has quit [Client Quit]
mondok has joined #ruby
jgt1 has quit [Ping timeout: 255 seconds]
B1n4r10 has quit [Ping timeout: 246 seconds]
Guest27 has quit [Quit: Textual IRC Client: www.textualapp.com]
govg has joined #ruby
pawnbox has quit [Ping timeout: 255 seconds]
yfeldblum has quit [Remote host closed the connection]
baweaver has quit [Remote host closed the connection]
northfurr has quit [Quit: northfurr]
yfeldblum has joined #ruby
psyq has quit [Quit: Conversation terminated]
mozzarella has quit [Ping timeout: 265 seconds]
gbgdev has quit [Remote host closed the connection]
Melpaws has quit [Quit: Leaving.]
pawnbox has joined #ruby
GGMethos has quit [Ping timeout: 240 seconds]
hannelita has joined #ruby
asccigcc has quit [Quit: asccigcc]
hanneli has joined #ruby
baweaver has joined #ruby
Melpaws has joined #ruby
<dn5> Is there a way to force a particular responses content-type over Net::HTTP::Get
blur3d has quit [Quit: blur3d]
<Ox0dea> dn5: Your only recourse there is to send an Accept header with the request.
<Ox0dea> The rest is up to the server.
baweaver has quit [Remote host closed the connection]
hannelita has quit [Ping timeout: 255 seconds]
jayne_ is now known as jayne
<dn5> hi Ox0dea.. yes I know that it's up to the server on what should it return as a response, yet I'm interested is it possible to override it
<dn5> some firefox plugins enable that
baweaver has joined #ruby
northfurr has joined #ruby
vandemar has quit [Ping timeout: 245 seconds]
pawnbox has quit [Ping timeout: 276 seconds]
<Ox0dea> dn5: Er, are you trying to modify the Content-Type to pass it along to something else, or...?
vandemar has joined #ruby
vandemar has quit [Changing host]
vandemar has joined #ruby
<dn5> Ox0dea, yes. If for e.g. the server returns binary/octet-stream, I want to force it to html/text
DarkElement has joined #ruby
emilford has quit [Ping timeout: 276 seconds]
TomPeed has joined #ruby
Melpaws has quit [Quit: Leaving.]
<Ox0dea> dn5: Yep, an `Accept: text/plain` header is your best bet.
ss_much has joined #ruby
underplank has joined #ruby
emilford has joined #ruby
<DarkElement> I want to either 1. Remove a substring and everything to the right of it from a string(I am already doing this while ignoring case, but need everything to the right as well), or 2. split on aforementioned substring without caring about case. What is the best way to go about doing this?
<dn5> Ox0dea, so: Net::HTTP::Get.new(uri.request_uri, {'Accept' => 'text/plain'}) if I'm correct
spider-mario has quit [Remote host closed the connection]
Martiini has quit [Ping timeout: 265 seconds]
<Ox0dea> dn5: That might do it, yep. The server is under no obligation to pay any attention, of course.
<dn5> Roger, thanks
<Ox0dea> Happy to help.
<lucasb> DarkElement: maybe str.sub(/substring.*/i, '') ?
<DarkElement> lucasb, ahhh the * makes all the difference
<DarkElement> Gotta love regex
<Ox0dea> >> "foo\nuh-oh".sub /foo.*/, '' # lucasb
<ruby[bot]> Ox0dea: # => "\nuh-oh" (https://eval.in/502873)
butthurt has joined #ruby
<lucasb> the 'm' option fixes it? /re/im
butthurt has quit [Client Quit]
fourq|away has left #ruby ["twip"]
<Ox0dea> That it does.
ivanskie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Snowy has joined #ruby
<lucasb> maybe a better option is to use str.index(/sep/) to get an index of where the substring starts, and then truncate the original string up to there
freerobby has joined #ruby
Snowy has quit [Client Quit]
jam_ has joined #ruby
<DarkElement> * should work fine
Xeago has quit [Remote host closed the connection]
houhoulis has joined #ruby
<DarkElement> in fact, it did work fine
dlitvak has joined #ruby
XnbqNT9SrauX has quit [Quit: goodbye]
<voidDotClass> If you have a variable of type 'Foo', can you get 'foo' from it somehow?
<voidDotClass> e.g foo = Foo.new, puts foo.class.downcase ?
DLSteve has joined #ruby
<Ox0dea> >> 'foo'.class.to_s.downcase # voidDotClass
<ruby[bot]> Ox0dea: # => "string" (https://eval.in/502877)
<voidDotClass> ty
<Ox0dea> Sure thing.
klaas has joined #ruby
jam_ has quit [Ping timeout: 240 seconds]
Azure has quit [Ping timeout: 240 seconds]
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
gbgdev has joined #ruby
kith has quit [Quit: kith]
dlitvak has quit [Ping timeout: 264 seconds]
Azure has joined #ruby
huQeQwdpu47q has joined #ruby
TomPeed has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
lucasb has quit [Quit: leaving]
GGMethos has joined #ruby
sftrabbit has quit [Quit: sftrabbit]
rakm has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
B1n4r10 has joined #ruby
baweaver has quit [Remote host closed the connection]
dorei has quit []
Rickmasta has joined #ruby
nfk|laptop has quit [Ping timeout: 240 seconds]
|ifei5good has joined #ruby
marr has quit [Ping timeout: 260 seconds]
nfk has joined #ruby
|ifei5g00d has quit [Ping timeout: 260 seconds]
rrichardsr3 has joined #ruby
rrichardsr3 has quit [Max SendQ exceeded]
rrichardsr3 has joined #ruby
rrichardsr3 has quit [Client Quit]
pawnbox has joined #ruby
fl has quit [Ping timeout: 260 seconds]
vikas027 has joined #ruby
Jonah11_ has joined #ruby
pawnbox has quit [Ping timeout: 240 seconds]
Prominent has quit [Quit: Leaving]
northfurr has quit [Quit: northfurr]
houhoulis has quit [Remote host closed the connection]
choke has joined #ruby
huQeQwdpu47q is now known as huQeQwdpu47q_
vikas027 has quit [Ping timeout: 245 seconds]
huQeQwdpu47q_ is now known as huQeQwdpu47q
pawnbox has joined #ruby
scottschecter has joined #ruby
karapetyan has quit [Remote host closed the connection]
rodolfowtf has joined #ruby
mfb2 has quit [Remote host closed the connection]
scottschecter is now known as scottschecter_
TomPeed has joined #ruby
gregf has quit [Quit: WeeChat 1.3]
CloCkWeRX has joined #ruby
fourq|away has joined #ruby
scottschecter_ is now known as scottschecter
TomPeed is now known as justbleed
fl has joined #ruby
RobertBirnie has quit [Ping timeout: 250 seconds]
hanneli has quit [Remote host closed the connection]
scottschecter has quit [Client Quit]
bkxd has joined #ruby
Azure has quit [Ping timeout: 265 seconds]
chipotle has joined #ruby
pawnbox has quit [Ping timeout: 255 seconds]
gregf has joined #ruby
Azure has joined #ruby
arescorpio has joined #ruby
vikas027 has joined #ruby
<vikas027> Hello All, I have a small code https://dpaste.de/Ep65 which works fine, but I want to redirect some output to null. Forgive my ignorance, I am not very well versed with ruby.
casadei has joined #ruby
<Cohedrin> you want to do what
fl has quit [Remote host closed the connection]
<Cohedrin> I dont understand what "redirect output to null" means
atomical has quit [Ping timeout: 272 seconds]
pawnbox has joined #ruby
dlitvak has joined #ruby
<Ox0dea> vikas027: There are several ways to go about this.
<Ox0dea> You don't want to capture the output, right? You want to completely ignore it?
<vikas027> Ox0dea: yes, please point me to an easier one :)
dlitvak has quit [Remote host closed the connection]
kalopsian has quit [Ping timeout: 246 seconds]
lkba has joined #ruby
lkba_ has quit [Read error: Connection reset by peer]
<Ox0dea> vikas027: `$stdout.reopen(IO::NULL)`, then do the noisy things, then `$stdout = STDOUT`.
rkoller has quit [Quit: Textual IRC Client: www.textualapp.com]
casadei has quit [Ping timeout: 276 seconds]
Jardayn has quit [Quit: Leaving]
Jardayn has joined #ruby
misguided923 has joined #ruby
gregf has quit [Quit: WeeChat 1.3]
DarkElement has quit [Quit: Leaving]
emilford has quit [Ping timeout: 240 seconds]
Jardayn has quit [Client Quit]
pawnbox has quit [Ping timeout: 240 seconds]
peterhu_ is now known as peterhu
<vikas027> Ox0dea: I have done this https://dpaste.de/bb6M, but it nulls out whole method
<misguided923> Hi, does anybody know what is the Net::SSH equivalent of command-line "ssh -R $port:$host:$hostport $user@$host"
<vikas027> Ox0dea: I guess, I have to close the $stdout stream as well before printing out. Right ?
<Ox0dea> vikas027: Ah, no, I forgot. Calling #reopen on $stdout modifies it in-place, which affects the STDOUT constant.
<havenwood> >> $stdout = StringIO.new; puts 'stuff'; $stdout = STDOUT
matugm has joined #ruby
matugm has joined #ruby
<ruby[bot]> havenwood: # => #<IO:<STDOUT>> (https://eval.in/502898)
<havenwood> My first impulse was to cheat ^.
<misguided923> I've tried Net::SSH::Gateway.new(remote, user).open(host, hostport, port), to no avail
<Ox0dea> vikas027: You could either re-assign $stdout to File.new(IO::NULL), or just #dup the original and restore it after.
Limix has quit [Quit: Limix]
choke has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Ox0dea> vikas027: https://eval.in/502899
bronson has joined #ruby
bb010g has quit [Quit: Connection closed for inactivity]
<vikas027> Ox0dea, havenwood: Thank you, let me try these.
CloCkWeRX has quit [Ping timeout: 246 seconds]
<misguided923> I've also tried Net::SSH.start(*options){|ssh| ssh.remote_to(port,host,hostport); ssh.loop { true } }
<misguided923> but that didn't work either
yqt has quit [Ping timeout: 246 seconds]
<Ox0dea> The StringIO approach is certainly cleaner, but a little wasteful since it'll capture the output instead of just not printing it.
pawnbox has joined #ruby
underplank has quit [Ping timeout: 264 seconds]
<vikas027> https://eval.in/502899 works great. Thanks a lot guys.
ico has quit [Remote host closed the connection]
Yzguy has quit [Quit: Zzz...]
bronson has quit [Ping timeout: 265 seconds]
fl has joined #ruby
chipotle_ has joined #ruby
chipotle has quit [Ping timeout: 264 seconds]
graffix222 has quit [Ping timeout: 260 seconds]
krz has joined #ruby
gruz0 has joined #ruby
rkazak has joined #ruby
pawnbox has quit [Ping timeout: 250 seconds]
underplank has joined #ruby
B1n4r10 has quit [Ping timeout: 272 seconds]
<misguided923> nobody knows or should i repeat?
B1n4r10 has joined #ruby
howdoi has quit [Quit: Connection closed for inactivity]
krz has quit [Ping timeout: 264 seconds]
kalopsian has joined #ruby
graffix222 has joined #ruby
UtkarshRay has joined #ruby
pawnbox has joined #ruby
emilford has joined #ruby
felixdd has quit [Ping timeout: 240 seconds]
jackjackdripper has quit [Quit: Leaving.]
chipotle_ has quit [Quit: cheerio]
houhoulis has joined #ruby
graffix222 has quit [Ping timeout: 260 seconds]
<havenwood> misguided923: Just times out?
mondok has quit [Quit: Leaving]
<misguided923> It gets as far as the password prompt, but the tunnel doesn't stay open
freerobby has quit [Quit: Leaving.]
CloCkWeRX has joined #ruby
<misguided923> i hadn't thought yet to actually check the connection logs, i was just trying to use the tunnel
<misguided923> i'll do that now
graffix222 has joined #ruby
baweaver has joined #ruby
|ifei5good has quit [Read error: Connection reset by peer]
<misguided923> ok so the connection is established and stays up
|ifei5g00d has joined #ruby
DLSteve has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
pawnbox has quit [Ping timeout: 265 seconds]
SCHAAP137 has quit [Remote host closed the connection]
KensoDev has quit [Remote host closed the connection]
<misguided923> Ok, so I found the problem
baweaver has quit [Ping timeout: 240 seconds]
<misguided923> I was trying to forward from port 8081 which was closed
underplank has quit [Quit: underplank]
<misguided923> changing it to a nonrestricted port number made it work
felixdd has joined #ruby
atomical has joined #ruby
|ifei5good has joined #ruby
Xiti has quit [Read error: Connection reset by peer]
terminalrecluse has quit [Read error: Connection reset by peer]
nickjj_ has joined #ruby
amclain_ has joined #ruby
Xiti has joined #ruby
terminalrecluse has joined #ruby
tuelz has quit [Read error: Connection reset by peer]
amclain has quit [Read error: Connection reset by peer]
ryotarai has quit [Ping timeout: 250 seconds]
tuelz1 has joined #ruby
csaunders has quit [Ping timeout: 250 seconds]
sindork has quit [Ping timeout: 250 seconds]
|ifei5g00d has quit [Ping timeout: 276 seconds]
sindork has joined #ruby
LiquidInsect has quit [Ping timeout: 250 seconds]
nickjj has quit [Ping timeout: 250 seconds]
jordanm has quit [Read error: Connection reset by peer]
baweaver has joined #ruby
jordanm has joined #ruby
LiquidInsect has joined #ruby
ryotarai has joined #ruby
csaunders has joined #ruby
jgpawletko has joined #ruby
Shidash has joined #ruby
<misguided923> ok nevermind
<misguided923> i'm dumb haha
<misguided923> i had an existing reverse tunnel open
<misguided923> the code still doesn't work
baweaver has quit [Ping timeout: 240 seconds]
dfinninger has joined #ruby
zambini has quit [Quit: Leaving.]
Jonah11_ has quit [Remote host closed the connection]
hannelita has joined #ruby
<jackcom> YXnZCG3QeUiCo5ZHQuzwFw%3D%3D <— i can decrypt it?
unreal_ has joined #ruby
Jonah11_ has joined #ruby
tomdp has quit [Quit: ZNC - http://znc.in]
hannelita has quit [Ping timeout: 264 seconds]
unreal has quit [Ping timeout: 265 seconds]
Coldblackice has quit [Read error: Connection reset by peer]
<havenwood> jackcom: Unknown hash.
|ifei5g00d has joined #ruby
pawnbox has joined #ruby
<jbrhbr1> my beautiful mind is currently seeing patterns pop out of that hash on my monitor
<jackcom> YXnZCG3QeUiCo5ZHQuzwFw%3D%3D —> roma…….. : you can do it? havenwood
Pupeno has quit [Quit: Leaving...]
<jbrhbr1> is this a challenge or a question of possibility?
<jackcom> question
<havenwood> jackcom: wat
<jackcom> i can’t do it
<jackcom> so i need help
mfb2 has joined #ruby
<Ebok> What are you trying to do with it?
<jbrhbr1> it could decrypt into another hash. or the number 3. or anything. not sufficient information to answer your question
|ifei5good has quit [Ping timeout: 260 seconds]
C0deMaver1ck has quit [Ping timeout: 256 seconds]
<havenwood> jackcom: What is that you've pasted? If this is just some random blob and that's all you have to say about it it's not related to Ruby.
yfeldblum has quit [Remote host closed the connection]
<jackcom> i will back, mother call me
<jackcom> :(
<havenwood> !kick jackcom Ruby only
jackcom was kicked from #ruby by ruboto [Ruby only]
misguided923 has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
blur3d has joined #ruby
C0deMaver1ck has joined #ruby
C0deMaver1ck is now known as Guest68186
pawnbox has quit [Ping timeout: 255 seconds]
mfb2 has quit [Ping timeout: 255 seconds]
loatbac has joined #ruby
loatbac has quit [Client Quit]
dn5 has quit [Quit: Leaving]
mfb2 has joined #ruby
|ifei5g00d has quit [Ping timeout: 276 seconds]
|ifei5g00d has joined #ruby
pawnbox has joined #ruby
Yzguy has joined #ruby
jam_ has joined #ruby
Coldblackice has joined #ruby
pawnbox has quit [Ping timeout: 246 seconds]
Yzguy has quit [Quit: Zzz...]
Yzguy has joined #ruby
jam_ has quit [Ping timeout: 256 seconds]
jbrhbr1 has quit [Quit: Leaving.]
jackcom has joined #ruby
<jackcom> .
smactive has joined #ruby
janebootydoe has joined #ruby
<havenwood> jackcom: hi
<havenwood> jackcom: What was that hash? Is it a hash? Where'd it come from?
rkazak has quit [Quit: Sleep.....ing....]
<jackcom> havenwood: yeah friend give me it to solve
pawnbox has joined #ruby
<jackcom> so i must solve it
<havenwood> jackcom: So it was created by someone as a personal cryptography challenge?
solocshaw has quit [Ping timeout: 240 seconds]
<jackcom> i don’t know. but i want use ruby for solving it
<jackcom> ruby module
<havenwood> jackcom: It doesn't appear to be a standard hashing function, so I think it's a mystery for you to solve.
<jackcom> impossible?
<havenwood> doubtful
<havenwood> Unless it's gibberish. Then yes, impossible.
<jackcom> jY4P%2B2fKUxdAdD%2BEMj0Lyg%3D%3D ——> 12er???????
<havenwood> jackcom: What?
<jackcom> if you decrypt ‘jY4P%2B2fKUxdAdD%2BEMj0Lyg%3D%3D’, then result start with ‘12er’
<jackcom> 12er?????
<havenwood> jackcom: Sounds like you have some hints for your challenge. Good luck!!
<jackcom> :(
freerobby has joined #ruby
<havenwood> jackcom: If you make some progress and have Ruby questions, ask here!
<jackcom> there is no ruby module?
underplank has joined #ruby
<havenwood> jackcom: For what?
<jackcom> to decrypt password
<soahccc> jackcom: there is no such thing as "Magic.dowhatineed". there are modules for things but you don't know what "thing" is
<jackcom> yeah
BTRE has quit [Quit: Leaving]
gruz0 has quit [Quit: Leaving]
<havenwood> jackcom: You should solve it yourself or ask for something more accessible I think.
pawnbox has quit [Ping timeout: 245 seconds]
B1n4r10 has quit [Ping timeout: 276 seconds]
<jackcom> for solving that password algorism, iq must be over 180
MrSamuel has joined #ruby
<jackcom> but my iq is 159 only
guacamol_ has quit [Quit: My face has gone to sleep. ZZZzzz…]
<havenwood> !ban jackcom !T 1w trolling
jackcom was banned on #ruby by ChanServ [jackcom!*@*]
jackcom was kicked from #ruby by ChanServ [Banned: trolling]
dlitvak has joined #ruby
hahuang65 has quit [Ping timeout: 255 seconds]
B1n4r10 has joined #ruby
matp_ is now known as matp
pawnbox has joined #ruby
dlitvak_ has joined #ruby
dlitvak has quit [Ping timeout: 245 seconds]
rkazak has joined #ruby
yfeldblum has joined #ruby
atomical has quit [Ping timeout: 260 seconds]
MrSamuel has quit [Quit: Leaving]
sdwrage_ has quit [Quit: This computer has gone to sleep]
dlitvak_ has quit [Remote host closed the connection]
pawnbox has quit [Ping timeout: 265 seconds]
Yzguy has quit [Quit: Zzz...]
hahuang61 has joined #ruby
howdoi has joined #ruby
mfb2 has quit [Remote host closed the connection]
bkxd has quit [Ping timeout: 246 seconds]
pawnbox has joined #ruby
bkxd has joined #ruby
Tempesta has quit [Quit: See ya!]
underplank has quit [Quit: underplank]
hannelita has joined #ruby
underplank has joined #ruby
blur3d has quit [Quit: blur3d]
underplank has quit [Client Quit]
pawnbox has quit [Ping timeout: 272 seconds]
hannelita has quit [Ping timeout: 255 seconds]
casadei has joined #ruby
minimalism has joined #ruby
rodolfowtf has quit [Remote host closed the connection]
pawnbox has joined #ruby
spacemud has quit [Quit: ZNC - http://znc.in]
akem has joined #ruby
sdwrage_ has joined #ruby
casadei has quit [Ping timeout: 276 seconds]
atomical has joined #ruby
pawnbox has quit [Ping timeout: 245 seconds]
usershell has joined #ruby
mostlybadfly has quit [Quit: Connection closed for inactivity]
chipotle has joined #ruby
UtkarshRay has quit [Quit: Leaving]
guacamole has joined #ruby
frem has quit [Quit: Connection closed for inactivity]
guacamole has quit [Client Quit]
pawnbox has joined #ruby
baweaver has joined #ruby
usershell has quit [Remote host closed the connection]
lacuna has joined #ruby
lacuna has joined #ruby
_Tariq has joined #ruby
lacuna has quit [Client Quit]
UtkarshRay has joined #ruby
<_Tariq> Hello, I want to define an instnace method that only works on that one specific instance of a class
<_Tariq> It does not "carry over" to other instances
lockdown has joined #ruby
<Ox0dea> _Tariq: Define it on the instance's singleton class.
<Ox0dea> There are several ways to do so.
<_Tariq> Thanks, I'll look it up then
<Ox0dea> >> a = []; def a.foo; 42; end; [a.foo, ([].foo rescue $!)] # _Tariq
baweaver has quit [Ping timeout: 240 seconds]
<ruby[bot]> Ox0dea: # => [42, #<NoMethodError: undefined method `foo' for []:Array>] (https://eval.in/502920)
<Ox0dea> That'll suffice if you've already got a reference to the instance in question.
<Ox0dea> You'll have to get a little fancier if it's dynamic.
<_Tariq> Yeah, and I'm doing dynamic stuff
dopie has quit [Quit: Lost terminal]
dopie has joined #ruby
gbgdev has quit [Remote host closed the connection]
pawnbox has quit [Ping timeout: 255 seconds]
<Ox0dea> Yay!
<_Tariq> self.instance_eval { def foo; 42; end }
<_Tariq> might work?
<Ox0dea> Er... that'll depend on the value of `self`, but it's an option, sure.
<_Tariq> >> class foo; def initialize(number); self.instance_eval { def bar; number; end }; end; end
<Ox0dea> You're not registered.
<_Tariq> Ah
lockdown has left #ruby [#ruby]
fourq|away is now known as fourq
fourq is now known as fourq|away
fourq|away is now known as fourq
fourq is now known as fourq|away
smactive has quit [Remote host closed the connection]
<_Tariq> doing it in irb seems to imply it might work
radgeRayden_ has joined #ruby
<_Tariq> but I have to do some fixing
tuelz1 has quit [Ping timeout: 250 seconds]
Jonah11_ has quit []
cholq has joined #ruby
bronson has joined #ruby
diegoviola has quit [Quit: WeeChat 1.3]
pawnbox has joined #ruby
radgeRayden has quit [Ping timeout: 276 seconds]
usershell has joined #ruby
blur3d has joined #ruby
rkazak has quit [Quit: Sleep.....ing....]
speakingcode has quit [Ping timeout: 240 seconds]
toretore has quit [Quit: Leaving]
bronson has quit [Remote host closed the connection]
wolffles has joined #ruby
<wolffles> heeyyyy
casadei has joined #ruby
<shevy> hey waffles
<shevy> still writing ruby code?
pawnbox has quit [Ping timeout: 240 seconds]
<shevy> ruby[bot] is so snobbish :(
<wolffles> yeah
<wolffles> so this text says that BasicObject is a blank empty class
<wolffles> but BasicObject == nil is false ?
sankaber has joined #ruby
rkazak has joined #ruby
casadei has quit [Ping timeout: 276 seconds]
zast has joined #ruby
braincrash has quit [Quit: bye bye]
imperator has joined #ruby
pawnbox has joined #ruby
cholq has quit [Remote host closed the connection]
pdoherty has quit [Read error: Connection reset by peer]
hahuang65 has joined #ruby
hahuang61 has quit [Ping timeout: 250 seconds]
dfinninger has quit [Remote host closed the connection]
B1n4r10 has quit [Ping timeout: 260 seconds]
<Coraline> wolffles: this is a blank empty class: class Foo; end
pawnbox has quit [Ping timeout: 250 seconds]
<Coraline> That's not nil
krz has joined #ruby
karapetyan has joined #ruby
rodolfowtf has joined #ruby
usershell has quit [Remote host closed the connection]
ivanskie has joined #ruby
usershell has joined #ruby
al2o3-cr has quit [Read error: Connection reset by peer]
braincrash has joined #ruby
al2o3-cr has joined #ruby
pawnbox has joined #ruby
underplank has joined #ruby
voidDotClass has quit [Ping timeout: 240 seconds]
<Ox0dea> That's not a blank empty class at all.
krz has quit [Quit: WeeChat 1.2]
<_Tariq> Instance_eval isn't really working for me, Ox0dea
A124 has quit [Ping timeout: 240 seconds]
karapetyan has quit [Ping timeout: 265 seconds]
<Ox0dea> _Tariq: How about #define_singleton_method, then?
<_Tariq> Let me try that out
fsapo has joined #ruby
hannelita has joined #ruby
<_Tariq> Oh my god its syntax is so much cleaner than instance_eval
Guest91150 has joined #ruby
davedev24 has quit [Remote host closed the connection]
<_Tariq> And it works too, Ox0dea!
<Ox0dea> Hurrah!
dlitvak has joined #ruby
hannelita has quit [Ping timeout: 240 seconds]
pawnbox has quit [Ping timeout: 276 seconds]
dlitvak has quit [Remote host closed the connection]
atomical has quit [Ping timeout: 245 seconds]
Guest91150 has quit [Ping timeout: 256 seconds]
chipotle has quit [Read error: Connection reset by peer]
chipotle_ has joined #ruby
tubuliferous_ has joined #ruby
dlitvak has joined #ruby
Bloomer has joined #ruby
<wolffles> Ox0dea: whats not a blank empty class?
rkazak has quit [Quit: Sleep.....ing....]
c355e3b has quit [Quit: Connection closed for inactivity]
bvbrandon has joined #ruby
<bvbrandon> bv12K#$L5
<bvbrandon> hello all
<Ox0dea> bvbrandon: Sick password, bruv.
yfeldblum has quit [Remote host closed the connection]
<Ox0dea> wolffles: class Foo; end
<wolffles> ahh
tubuliferous_ has quit [Ping timeout: 276 seconds]
cholq has joined #ruby
<bvbrandon> I have a ruby issue that’s killing me!
arescorpio has quit [Quit: Leaving.]
<Ox0dea> Somebody get this man a medic!
_Tariq has quit [Remote host closed the connection]
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
cholq has quit [Remote host closed the connection]
<bvbrandon> I have this koan which requires me to pass a test using this instance method @person.hand.create
<bvbrandon> but I can’t figure out how to define create in the controller
<Ox0dea> That looks odd.
<bvbrandon> I’ve defined hand, I was reading up on how to chain methods but that seems to require args are being passed
<Ox0dea> Why does @person.hand already exist if it hasn't been created?
<bvbrandon> wait, maybe that;s what I’m doing wrong
<bvbrandon> is there a native c reate method in ruby and it’s just being called on @person.hand?
<cscheib> one of the original koans from rubykoans.com?
<Ox0dea> `create` seems like the kind of method that ought to go on the Hand class itself, if you have such a one.
<cscheib> or elsewhere
<Ox0dea> bvbrandon: No, that'd be #initialize, but it's always been called that.
<bvbrandon> ahh, so this would be creating a hand object belonging to this person instance?
<bvbrandon> @cscheib no it isn't
nfk has quit [Quit: Try memory.free_dirty_pages=true in about:config]
<Ox0dea> bvbrandon: Right, you'd have a Person instance and a Hand instance, and a has-one relationship between them.
atomical has joined #ruby
<Ox0dea> Well, s/instance/class/, but the instances are what're interacting in `@person.hand`.
<cscheib> bvbrandon: if you don't mind my asking, where'd you get it from? I'm always looking for more exercises
<Ox0dea> cscheib: Have you written a poker hand evaluator yet, then?
<cscheib> negative
<bvbrandon> it’s an internal excercise for a company cscheib, the Sr’s built it
<wolffles> likewise cscheib
<cscheib> bvbrandon: gotcha
<Ox0dea> I solved that one in C on paper...
<cscheib> Ox0dea: it's probably over my head currently, but I'll certainly give it a try, thanks
<bvbrandon> man that makes so much sense Ox0dea
<Ox0dea> cscheib: You can totally do it.
<Ox0dea> bvbrandon: Object-orientation is one honking great idea! Let's do more of that. :)
<bvbrandon> yea, that’s my weakness…
<wolffles> that looks fun :D
jam_ has joined #ruby
<shevy> OOP is simple. object: beer, object: pizza ... it can't get no simpler than that
pawnbox has joined #ruby
<wolffles> you down for OPP?
underplank has quit [Quit: underplank]
tuelz1 has joined #ruby
<shevy> I am down for waffles too!
usershell has quit [Remote host closed the connection]
<wolffles> !walffles
jam_ has quit [Ping timeout: 255 seconds]
pawnbox has quit [Ping timeout: 240 seconds]
sneakerhax has joined #ruby
dlitvak has quit [Ping timeout: 276 seconds]
blackgoat has quit [Quit: WeeChat 1.3]
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tuelz1 has quit [Ping timeout: 256 seconds]
<wolffles> walffles = nil; !walffles == true
<wolffles> but
<wolffles> walffles = 1; !walffles == true
<wolffles> is false?
underplank has joined #ruby
<wolffles> ! makes variable equal to nil?
<Ox0dea> wolffles: !x == false for *everything* except `false` and `nil`, for which it's `true`.
<wolffles> ahhh
gix has quit [Ping timeout: 240 seconds]
<Ox0dea> >> [0, '', [], {}, 1, false, nil].map(&:!)
<ruby[bot]> Ox0dea: # => [false, false, false, false, false, true, true] (https://eval.in/502924)
<Ox0dea> Everything except `false` and `nil` are considered "truthy", and ! inverts the "truthiness" of the receiver.
arthurix_ has joined #ruby
pawnbox has joined #ruby
<wolffles> hmm
bronson has joined #ruby
krz has joined #ruby
arthurix has quit [Ping timeout: 240 seconds]
gix has joined #ruby
dlitvak has joined #ruby
underplank has quit [Quit: underplank]
underplank has joined #ruby
justbleed has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
bronson has quit [Ping timeout: 265 seconds]
pawnbox has quit [Ping timeout: 272 seconds]
underplank has quit [Quit: underplank]
Limix has joined #ruby
colegatron has quit [Ping timeout: 245 seconds]
chipotle_ has quit [Quit: cheerio]
pawnbox has joined #ruby
underplank has joined #ruby
<wolffles> how would you read (&:!). & is a way to pass blocks yeah? so is :! a comparison or a symbol?
sdwrage_ has quit [Quit: This computer has gone to sleep]
fsapo has quit [Ping timeout: 246 seconds]
<Ox0dea> It's a Symbol representing the ! method.
<Ox0dea> & converts its argument to a Proc by invoking #to_proc on it, and then passes that along as a block.
pawnbox has quit [Ping timeout: 240 seconds]
baweaver has joined #ruby
davedev24 has joined #ruby
dlitvak has quit [Remote host closed the connection]
<wolffles> [0, '', [], {}, 1, false, nil].map(&:!) == [0, '', [], {}, 1, false, nil].map{|x| !x }
<wolffles> :D did i do good!?!?!?
<Ebok> Thats what &:! does
<Ebok> yup
usershell has joined #ruby
<wolffles> woot i get a cookie
griffindy has joined #ruby
griffindy has quit [Client Quit]
pawnbox has joined #ruby
darkf has joined #ruby
bkxd has quit [Ping timeout: 256 seconds]
davedev24 has quit [Remote host closed the connection]
hannelita has joined #ruby
colegatron has joined #ruby
mary5030 has joined #ruby
<bvbrandon> handy tip for passing tests, make sure your method just returns true at the end
<bvbrandon> make sit so much easaier
akem has quit [Remote host closed the connection]
sdwrage_ has joined #ruby
bkxd has joined #ruby
<Ox0dea> ?cookie wolffles
<ruby[bot]> wolffles: here's your cookie:
janebootydoe has quit [Ping timeout: 246 seconds]
hannelita has quit [Ping timeout: 264 seconds]
fsapo has joined #ruby
pawnbox has quit [Ping timeout: 272 seconds]
spacesuit has joined #ruby
<pontiki> COOKIES!!!!
Fridtjof_ has quit [Ping timeout: 240 seconds]
<pontiki> bvbrandon: tat
<pontiki> grr
<bvbrandon> lol what?
<imperator> handy tip for passing tests: comment out the failing tests
<pontiki> bvbrandon: that's going to make my work life *so* much easier!
<imperator> voila! tests pass
<bvbrandon> yeeeees
<Ebok> ?cookie Ox0dea
<ruby[bot]> Ox0dea: here's your cookie:
<pontiki> sorry, bvbrandon, twas a misplaced typing hand
<Ebok> Yay
<Ebok> xD
<Ox0dea> Ebok: Danke! <3
<Ox0dea> ?cake Ebok
<ruby[bot]> Ebok: here's your cake:
<Ebok> Yay
mfb2 has joined #ruby
<Ox0dea> I suspect the bot is hungry after handing out all these treats.
<Ox0dea> ?botsnack
<ruby[bot]> nomnomnomnom
spacesuit has quit [Client Quit]
bkxd has quit [Ping timeout: 255 seconds]
kalopsian has quit [Ping timeout: 245 seconds]
djbkd has quit [Remote host closed the connection]
Spacesuit_ has joined #ruby
kalopsian has joined #ruby
djbkd has joined #ruby
pawnbox has joined #ruby
mary5030 has quit [Ping timeout: 260 seconds]
djbkd has quit [Remote host closed the connection]
imperator has quit [Quit: Leaving]
djbkd has joined #ruby
Xiti has quit [Quit: Xiti]
djbkd has quit [Client Quit]
mfb2 has quit [Ping timeout: 255 seconds]
Spacesuit_ has quit [Remote host closed the connection]
jnj has joined #ruby
cholq has joined #ruby
Xiti has joined #ruby
<jnj> I'm trying to create a ruby script that'll list all the bash aliases that I have. What's a good regex for matching all sentences with alias in them? I have /^.*alias.*$/ but it only takes one line instead of all of them
zast has quit [Remote host closed the connection]
pawnbox has quit [Ping timeout: 260 seconds]
fsapo has quit [Remote host closed the connection]
cholq has quit [Ping timeout: 272 seconds]
BTRE has joined #ruby
<shevy> .scan() probably
<shevy> however had, if you read from a file, you could also use File.readlines and then just work on the array directly
tjohnson has quit [Quit: Connection closed for inactivity]
<shevy> I have my bash aliases in yaml files
mikecmpbll has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
yfeldblum has joined #ruby
pawnbox has joined #ruby
Lewix has quit [Ping timeout: 240 seconds]
rodolfowtf has quit [Read error: Connection reset by peer]
tuelz1 has joined #ruby
preyalone has joined #ruby
pawnbox has quit [Ping timeout: 260 seconds]
spacesuit has joined #ruby
griffindy has joined #ruby
yfeldblum has quit [Ping timeout: 276 seconds]
tuelz1 has quit [Ping timeout: 264 seconds]
mary5030 has joined #ruby
arup_r has joined #ruby
pawnbox has joined #ruby
ponga has joined #ruby
spacesuit has quit [Ping timeout: 256 seconds]
cornerma1 has joined #ruby
Lewix has joined #ruby
<pontiki> why, shevy?
griffindy has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Fridtjof has joined #ruby
emilford has quit [Ping timeout: 260 seconds]
<shevy> I can autogenerate them from there
<pontiki> jnj, bash scripts are inherently line-oriented, so why not just gather them up a line at a time?
<pontiki> is it just because you can, shevy? i'm trying to figure out why you'd bother
<jnj> pontiki: So, when Ruby finds matches, will it return a collection of all the matches?
underplank has quit [Quit: underplank]
<jnj> Then, I could just iterate through all the matches?
mary5030 has quit [Ping timeout: 260 seconds]
pawnbox has quit [Ping timeout: 245 seconds]
TheAnachron has joined #ruby
<pontiki> pretty much, jnj
cornerman has quit [Ping timeout: 264 seconds]
cornerma1 is now known as cornerman
<shevy> pontiki lots of advantages; another one is https://rubygems.org/gems/expand_cd_aliases, I can very easily use all of my aliases in any ruby project that way; I could store in shell script but then I'd have to manually parse, whereas in a yaml file, I get that for free
<shevy> pontiki dunno how many aliases you have, I am well over 30.000 so far :)
<jnj> shevy: yeah I have a ton. I have a bunch of fun ones that aren't useful at all, like running the matrix thing haha
<shevy> jnj yeah same here. some aliases I use a lot though, for quick navigation on the filesystem
<shevy> lately I added dancing ascii to my aliases
<shevy> so ascii_fireworks.rb can be invoked via "fireworks" for awesome ascii fireworks!
<shevy> It's one of my more useless projects that makes me surprisingly happy
amclain_ has quit [Quit: Leaving]
pawnbox has joined #ruby
<baweaver> that may be useful
freerobby has quit [Quit: Leaving.]
<shevy> whoa... what is that image?
<pontiki> shevy: having made things that make you surprisingly happy is quite important
<shevy> pontiki but dancing ascii is so utterly useless! :D
<pontiki> shevy: indeed!! but it's happy-making!!
pawnbox has quit [Ping timeout: 250 seconds]
tubuliferous_ has joined #ruby
sneakerhax has quit [Quit: Leaving]
usershell has quit [Remote host closed the connection]
blackgoat has joined #ruby
tubuliferous_ has quit [Ping timeout: 260 seconds]
pawnbox has joined #ruby
hannelita has joined #ruby
sneakerhax has joined #ruby
dopie has quit [Quit: Lost terminal]
dopie has joined #ruby
bkxd has joined #ruby
hannelita has quit [Ping timeout: 240 seconds]
pawnbox has quit [Ping timeout: 260 seconds]
harai has joined #ruby
haraigoshi has quit [Ping timeout: 265 seconds]
bkxd has quit [Ping timeout: 245 seconds]
pawnbox has joined #ruby
vdamewood has joined #ruby
speakingcode has joined #ruby
tubuliferous_ has joined #ruby
wolffles has quit [Quit: wolffles]
pawnbox has quit [Ping timeout: 265 seconds]
krz has quit [Read error: Connection reset by peer]
lxsameer has joined #ruby
mistermocha has joined #ruby
kalopsian has quit [Ping timeout: 264 seconds]
jam_ has joined #ruby
jnj has quit [Ping timeout: 240 seconds]
pawnbox has joined #ruby
sdwrage_ has quit [Quit: This computer has gone to sleep]
tuelz1 has joined #ruby
tmtwd has joined #ruby
jam_ has quit [Ping timeout: 250 seconds]
speaking2ode has joined #ruby
Limix has quit [Quit: Limix]
speaking3ode has joined #ruby
yfeldblum has joined #ruby
krz has joined #ruby
speaking2ode has quit [Client Quit]
speaking3ode has quit [Client Quit]
pawnbox has quit [Ping timeout: 246 seconds]
tuelz1 has quit [Ping timeout: 240 seconds]
hahuang65 has quit [Ping timeout: 250 seconds]
mostlybadfly has joined #ruby
bronson has joined #ruby
sdwrage_ has joined #ruby
pawnbox has joined #ruby
sdwrage_ has quit [Remote host closed the connection]
lkba has quit [Ping timeout: 245 seconds]
CloCkWeRX has quit [Ping timeout: 265 seconds]
<fl> ruby -v
DmitryBochkarev has joined #ruby
DmitryBochkarev has quit [Remote host closed the connection]
DmitryBochkarev has joined #ruby
bronson has quit [Ping timeout: 265 seconds]
DmitryBochkarev has quit [Remote host closed the connection]
pawnbox has quit [Ping timeout: 240 seconds]
chipotle has joined #ruby
fl has quit [Quit: Leaving]
pawnbox has joined #ruby
<Ox0dea> ruby 2.4.0dev (2016-01-16 trunk 53552) [x86_64-linux]
ivanskie has quit [Quit: Textual IRC Client: www.textualapp.com]
sdwrage_ has joined #ruby
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
harai54 has joined #ruby
harai has quit [Ping timeout: 240 seconds]
usershell has joined #ruby
CloCkWeRX has joined #ruby
carraroj has joined #ruby
AlphaAtom has joined #ruby
usershell has quit [Ping timeout: 265 seconds]
hannelita has joined #ruby
vikas027 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
lipoqil has quit [Quit: Connection closed for inactivity]
sdwrage_ has quit [Quit: This computer has gone to sleep]
smactive has joined #ruby
hannelita has quit [Ping timeout: 264 seconds]
agentmeerkat has joined #ruby
chipotle has quit [Quit: cheerio]
smactive has quit [Ping timeout: 276 seconds]
Macaveli has joined #ruby
mistermocha has quit [Remote host closed the connection]
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
junglebunnys has joined #ruby
dpg_ has quit [Ping timeout: 245 seconds]
Macaveli has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
JohnT has joined #ruby
mistermocha has joined #ruby
kerunaru has joined #ruby
pawnbox has quit [Remote host closed the connection]
Mon_Ouie has quit [Ping timeout: 245 seconds]
pawnbox has joined #ruby
arup_r has quit [Remote host closed the connection]
karapetyan has joined #ruby
arup_r has joined #ruby
tuelz1 has joined #ruby
usershell has joined #ruby
tmtwd has quit [Ping timeout: 256 seconds]
jgt has joined #ruby
karapetyan has quit [Ping timeout: 255 seconds]
tuelz1 has quit [Ping timeout: 250 seconds]
dionysus69 has joined #ruby
mistermocha has quit [Remote host closed the connection]
preyalone has quit [Quit: Connection closed for inactivity]
Anderson69s has joined #ruby
agentmeerkat has quit [Ping timeout: 272 seconds]
twistedpixels has quit [Quit: ZNC - http://znc.in]
felixdd has quit [Quit: Verlassend]
bubbys has quit [Ping timeout: 276 seconds]
sdwrage_ has joined #ruby
kt2 has joined #ruby
leksster has joined #ruby
baweaver has quit [Remote host closed the connection]
Ox0dea has quit [Quit: WeeChat 1.4-rc1]
sdwrage_ has quit [Client Quit]
puria has quit [Ping timeout: 260 seconds]
radgeRayden_ has quit [Ping timeout: 250 seconds]
blackgoat has quit [Quit: WeeChat 1.3]
CloCkWeRX has quit [Ping timeout: 260 seconds]
dmolina has joined #ruby
Dicki has joined #ruby
<Dicki> Herro
<Dicki> I know what is wrong with youtube
<Dicki> It is screwing me in da butt butt
<Dicki> Anyways
<Dicki> Can you fix this code for me?
<Dicki> Go test it out and you will see what is wrong with it
d0nn1e has quit [Ping timeout: 276 seconds]
bhalash has joined #ruby
d0nn1e has joined #ruby
cornerman has quit [Read error: Connection reset by peer]
Sirithcam has joined #ruby
hannelita has joined #ruby
cornerman has joined #ruby
bkxd has joined #ruby
puria has joined #ruby
dionysus69 has quit [Remote host closed the connection]
hannelita has quit [Ping timeout: 240 seconds]
CloCkWeRX has joined #ruby
bkxd has quit [Ping timeout: 265 seconds]
pabs has quit [Ping timeout: 240 seconds]
dionysus69 has joined #ruby
usershell has quit [Remote host closed the connection]
Macaveli has joined #ruby
Macaveli has quit [Client Quit]
krz has quit [Read error: Connection reset by peer]
pabs has joined #ruby
Macaveli has joined #ruby
dmolina has quit [Quit: Leaving.]
codecop has joined #ruby
dzejrou has joined #ruby
arob has joined #ruby
dn` has quit [Quit: dn`]
jam_ has joined #ruby
krz has joined #ruby
firstdayonthejob has joined #ruby
bhalash has quit [Ping timeout: 255 seconds]
Meow-J has joined #ruby
sandstrom has joined #ruby
Dimik has quit [Ping timeout: 264 seconds]
jam_ has quit [Ping timeout: 260 seconds]
tuelz1 has joined #ruby
Sirithcam has quit [Ping timeout: 246 seconds]
tuelz1 has quit [Ping timeout: 255 seconds]
arup_r has quit []
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
dionysus69 has quit [Quit: dionysus69]
sdwrage_ has joined #ruby
sdwrage_ has quit [Client Quit]
marr has joined #ruby
davedev24 has joined #ruby
Sirithcam has joined #ruby
karapetyan has joined #ruby
bronson has joined #ruby
dasher00 has joined #ruby
kerunaru has joined #ruby
baweaver has joined #ruby
ledestin has joined #ruby
bronson has quit [Ping timeout: 265 seconds]
junglebunnys has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
dmolina has joined #ruby
mostlybadfly has quit [Quit: Connection closed for inactivity]
JohnT has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
baweaver has quit [Ping timeout: 240 seconds]
sftrabbit has joined #ruby
B5X has joined #ruby
zotherstupidguy has quit [Ping timeout: 264 seconds]
houhoulis has quit [Remote host closed the connection]
bhalash has joined #ruby
B5X has quit [Client Quit]
sandstrom has quit [Quit: My computer has gone to sleep.]
colegatron has quit [Ping timeout: 265 seconds]
hannelita has joined #ruby
Jackneill has joined #ruby
ss_much has quit [Quit: Connection closed for inactivity]
bkxd has joined #ruby
B5X has joined #ruby
B5X has quit [Client Quit]
Anderson69s has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
hannelita has quit [Ping timeout: 255 seconds]
waka has quit [Quit: Leaving]
rkazak has joined #ruby
bkxd has quit [Ping timeout: 246 seconds]
antgel has quit [Remote host closed the connection]
waka has joined #ruby
dmolina has quit [Quit: Leaving.]
tubuliferous_ has quit [Ping timeout: 264 seconds]
aspiers has quit [Ping timeout: 255 seconds]
jbrhbr has joined #ruby
junglebunnys has joined #ruby
antgel has joined #ruby
SCHAAP137 has joined #ruby
Anderson69s has joined #ruby
Anderson69s has quit [Remote host closed the connection]
Mon_Ouie has joined #ruby
<jhass> .troll junglebunnys
junglebunnys was kicked from #ruby by ruby[bot] [trolling is a bannable offense, see http://ruby-community.com/pages/user_rules]
arup_r has joined #ruby
dzejrou has quit [Quit: Leaving]
<arup_r> lol
<jhass> Dicki: sorry for the troll. Could you please properly indent your code and describe what you think is wrong with it, where it's showing behavior you want differently?
tuelz1 has joined #ruby
pabs has quit [Ping timeout: 240 seconds]
pabs has joined #ruby
Sirithcam has quit [Ping timeout: 272 seconds]
firstdayonthejob has quit [Ping timeout: 245 seconds]
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tuelz1 has quit [Ping timeout: 240 seconds]
gruz0 has joined #ruby
dwfait has joined #ruby
sftrabbit has quit [Quit: sftrabbit]
FernandoBasso has joined #ruby
DoubleMalt has joined #ruby
bluOxigen has quit [Ping timeout: 255 seconds]
marr has quit []
marr has joined #ruby
tubuliferous_ has joined #ruby
Sirithcam has joined #ruby
junglebunnys has joined #ruby
<junglebunnys> jhass: why are you a piece of shit?
<jhass> same reason you are, bye
<jhass> .troll junglebunnys
junglebunnys was kicked from #ruby by ruby[bot] [trolling is a bannable offense, see http://ruby-community.com/pages/user_rules]
carraroj has quit [Ping timeout: 260 seconds]
<dwfait> >> Float::NAN == Float::NAN
<ruby[bot]> dwfait: # => false (https://eval.in/502979)
<dwfait> >> [Float::NAN] == [Float::NAN]
<jhass> yes, isn't that even documented?
<ruby[bot]> dwfait: # => true (https://eval.in/502980)
<dwfait> It seems there's an optimisation in Array#== that sees them as equal. Would that be considered a bug or intended behaviour?
<jhass> mh, good question, gotta leave that to others
<jhass> >> Float::NAN.equal? Float::NAN
<ruby[bot]> jhass: # => true (https://eval.in/502991)
<jhass> I guess Array#== checks that first since cheaper
<dwfait> It doesn't - it does a raw pointer comparison on the VALUE
<dwfait> (for some context)
<jhass> well, amounts to the same for the majority of cases though
<apeiros> mhm, a bug due to optimization
norc has joined #ruby
<apeiros> pointer comparison on VALUE is #equal? (unless somebody rewrites #equal?, which shouldn't be done ever)
<apeiros> and in general, the optimization makes sense, since #equal? implies ==. but NaN is quite the exception there :-/
<dwfait> Sorry, yes - #equal? should always be pointer comparison, but it is possible to over ride. The method doesn't call the method however, it just 'does' the comparison
<apeiros> it is possible. but when people speak of it it's clearly not meant to be an overridden, wrongly behaving variant ;-)
Cohedrin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<apeiros> IMO report it. I wonder whether they'll change the behavior.
<dwfait> So what are your thoughts? should the PR be considered again or should a bug be raised against Array#== ?
<dwfait> Ok, thanks for your thoughts
<apeiros> I currently wonder whether I would change it.
<apeiros> or maybe check first whether others already reported it
<apeiros> dwfait: ^
<norc> apeiros: Have you read about my suggestion yesterday evening?
<apeiros> norc: sorry no.
<apeiros> was afk almost whole friday
<norc> apeiros: I would like some kind of shortcut for ruby[bot] to produce VM disassembled bytecode.
sandstrom has joined #ruby
<norc> Because typing >> RubyVM::InstructionSequence.compile("some_code").disasm every time is rather annoying. :-)
<norc> Oh, even missed a puts there.
<dwfait> apeiros: thanks - after reading that it appears Matz has said that the handling of the system of NAN may be 'undefined' (if my interpretation of google translate is correct), and this could be considered correct behaviour
<norc> And perhaps even a wrapper for Ripper.sexp too, giving us tools to quickly demonstrate how Ruby parses and compiles a given snippet.
Dicki has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
<norc> so that perhaps we could do: sexp>> puts "foo"
<norc> or disasm>> puts "bar"
astrofog has joined #ruby
harai54 has quit [Ping timeout: 264 seconds]
tubuliferous_ has quit [Ping timeout: 256 seconds]
<apeiros> norc: ok. I can add code and/or I can ask charliesom (never sure about how his nick is spelt) to add something I can require.
PERSIAN has joined #ruby
A124 has joined #ruby
<apeiros> norc: `asm>> foo` and `asm20>> foo`?
<norc> apeiros: yeah that would work
hannelita has joined #ruby
TheAnachron has left #ruby [#ruby]
astrofog has quit [Quit: Quite]
astrofog has joined #ruby
hanmac1 has joined #ruby
hannelita has quit [Ping timeout: 264 seconds]
leksster has quit [Remote host closed the connection]
rkazak has quit [Quit: Sleep.....ing....]
hanmac has quit [Ping timeout: 240 seconds]
jbrhbr has quit [Quit: Leaving.]
agit0 has joined #ruby
tvw has joined #ruby
ziyadb has quit [Quit: Connection closed for inactivity]
marr has quit [Ping timeout: 276 seconds]
cpup has quit [Ping timeout: 240 seconds]
cpup has joined #ruby
bkxd has joined #ruby
<apeiros> norc: in-query triggering of ruby[bot] is currently not allowed. sorry :)
<norc> Heh. :-)
<apeiros> it'll change with the next release. I simply forgot to add an `in_query: true` in the permission settings of some plugins.
<norc> I remember there was some documentation about him somewhere, just cannot find it.
tvw has quit [Ping timeout: 255 seconds]
<apeiros> ruby-community.com
<apeiros> .help
<ruby[bot]> apeiros: You can find a list of my commands on http://ruby-community.com/ruboto/commands and my factoids on http://ruby-community.com/ruboto/facts
<norc> Ah thank you. :)
<jhass> except that's all out of date by now
<apeiros> though, ruby[bot] uses . instead of ! to avoid conflicts with ruboto.
<apeiros> not all. only some of the commands.
jam_ has joined #ruby
<apeiros> the factoids are even live
<norc> What is the deal with ruby[bot] anyway?
<apeiros> it's the new implementation of ruboto
tvw has joined #ruby
<apeiros> cinch had issues with getting the account of all registered users, which is a requirement for some of the things I want to do.
<apeiros> s/had/has/
bkxd has quit [Ping timeout: 240 seconds]
<norc> Is the implementation that bot made available on some git repo?
<apeiros> f.ex. a couple of commands are now no longer available to people who aren't registered
<norc> Was ruboto abused?
<apeiros> sadly not yet, no. I took some shortcuts when reviving butler. but I'll make the framework available again.
<apeiros> yes
mikecmpbll has joined #ruby
mkosaki_ has quit [Quit: Leaving...]
jam_ has quit [Ping timeout: 250 seconds]
tuelz1 has joined #ruby
pandaant has joined #ruby
aspiers has joined #ruby
tuelz1 has quit [Ping timeout: 255 seconds]
spacemud has joined #ruby
dlitvak has joined #ruby
sftrabbit has joined #ruby
kerunaru has joined #ruby
dlitvak has quit [Ping timeout: 276 seconds]
dwfait has quit [Remote host closed the connection]
oo7cat has joined #ruby
bkxd has joined #ruby
jgt has quit [Ping timeout: 240 seconds]
dwfait has joined #ruby
agit0 has quit [Quit: zzzZZZ….]
spider-mario has joined #ruby
baweaver has joined #ruby
sftrabbit has quit [Quit: sftrabbit]
karapetyan has quit [Remote host closed the connection]
iskander has joined #ruby
m8 has joined #ruby
baweaver has quit [Ping timeout: 250 seconds]
ljames has quit []
Xeago has joined #ruby
cholq has joined #ruby
craysiii has quit [Quit: Leaving.]
Biohazard has quit [Quit: WE ARE IN THE BEEEAAAAMMMM]
Fridtjof has quit [Quit: ZNC - http://znc.in]
kt2 has quit [Quit: ...]
cholq has quit [Ping timeout: 260 seconds]
zenlot has quit [Quit: WeeChat 1.1.1]
hannelita has joined #ruby
Sirithcam has quit [Ping timeout: 240 seconds]
zenlot has joined #ruby
Biohazard has joined #ruby
edwinvdgraaf has joined #ruby
hannelita has quit [Ping timeout: 264 seconds]
Biohazard has quit [Client Quit]
Biohazard has joined #ruby
aspiers has quit [Ping timeout: 264 seconds]
Biohazard has quit [Read error: Connection reset by peer]
AlphaAtom has quit [Quit: Textual IRC Client: www.textualapp.com]
edwinvdgraaf has quit [Read error: Connection reset by peer]
usershell has joined #ruby
edwinvdgraaf has joined #ruby
edwinvdgraaf has quit [Read error: Connection reset by peer]
psy has joined #ruby
usershell has quit [Remote host closed the connection]
aspiers has joined #ruby
edwinvdgraaf has joined #ruby
usershell has joined #ruby
c355e3b has joined #ruby
edwinvdg_ has joined #ruby
edwinvdgraaf has quit [Read error: Connection reset by peer]
usershell has quit [Ping timeout: 246 seconds]
Sirithcam has joined #ruby
zotherstupidguy has joined #ruby
karapetyan has joined #ruby
krz has quit [Quit: WeeChat 1.2]
dwfait has quit [Remote host closed the connection]
ht__ has joined #ruby
Xeago has quit [Remote host closed the connection]
karapetyan has quit [Remote host closed the connection]
aspiers has quit [Ping timeout: 240 seconds]
ledestin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tuelz1 has joined #ruby
bhalash has quit [Ping timeout: 255 seconds]
Xeago has joined #ruby
tuelz1 has quit [Ping timeout: 245 seconds]
usershell has joined #ruby
aspiers has joined #ruby
jxs_ has quit [Remote host closed the connection]
sftrabbit has joined #ruby
jxs_ has joined #ruby
Biohazard has joined #ruby
Fridtjof_ has joined #ruby
Fridtjof_ has quit [Client Quit]
Biohazard has quit [Client Quit]
ht__ has quit [Quit: Konversation terminated!]
Biohazard has joined #ruby
ht__ has joined #ruby
Biohazard has quit [Client Quit]
<norc> apeiros: I think it makes sense to include lex/sexp too.
Biohazard has joined #ruby
<norc> Not sure if that is pushing it though.
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
Fridtjof_ has joined #ruby
<apeiros> norc: can you make the required amendments? https://gist.github.com/apeiros/8faff2aded4e9fa1d4d0
jgt has joined #ruby
<apeiros> I can add them to the testbot and you can test immediately in #ruboto_test
<apeiros> I think you'd have to add another :format: entry in the .yaml
<apeiros> and add the code there
<norc> Let me take a look.
ht__ has quit [Client Quit]
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tk__ has joined #ruby
ht__ has joined #ruby
edwinvdg_ has quit [Read error: Connection reset by peer]
sftrabbit has quit [Quit: sftrabbit]
edwinvdgraaf has joined #ruby
BaroMeter has joined #ruby
FooMunki has joined #ruby
edwinvdgraaf has quit [Read error: Connection reset by peer]
edwinvdg_ has joined #ruby
TomPeed has joined #ruby
edwinvdgraaf has joined #ruby
edwinvdg_ has quit [Read error: Connection reset by peer]
dbugger has joined #ruby
<dbugger> Hello everyone
firstdayonthejob has joined #ruby
<norc> Hello dbugger
ht__ has quit [Quit: Konversation terminated!]
<apeiros> d, the bugger?
ta has quit [Remote host closed the connection]
hannelita has joined #ruby
ta has joined #ruby
TomPeed has quit [Ping timeout: 240 seconds]
mondok has joined #ruby
hannelita has quit [Ping timeout: 255 seconds]
ht__ has joined #ruby
ziyadb has joined #ruby
theRealAlexz has quit [Ping timeout: 276 seconds]
theRealAlexz has joined #ruby
spooq has joined #ruby
sdothum has joined #ruby
rkoller has joined #ruby
<dbugger> I was wondering if someone could give me a hand. I was following this dead easy tutorial (http://guides.rubygems.org/make-your-own-gem/#introduction) to make my own gem, but when I do "gem push ..." I get this error: "ERROR: While executing gem ... (Psych::SyntaxError) (<unknown>): mapping values are not allowed in this context at line 9 column 26"
blur3d has quit [Quit: blur3d]
<dbugger> Can someone tell me what Im doing wrong?
<shevy> dbugger sounds like an error in some yaml file
shibly has joined #ruby
shibly has left #ruby [#ruby]
<dbugger> The only YML file I have is the gemspec. This is it: http://laravel.io/bin/RExke
<shevy> that is ruby code
jgt has quit [Read error: Connection reset by peer]
<dbugger> mmm, true
<dbugger> I have no YML file
<shevy> but something invokes psych
karapetyan has joined #ruby
firstdayonthejob has quit [Ping timeout: 272 seconds]
<dbugger> The code is that one on the page...
<dbugger> there is a simple "puts"
jottr has joined #ruby
<shevy> no I do not believe you
tuelz1 has joined #ruby
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
kalopsian has joined #ruby
DoubleMalt has quit [Remote host closed the connection]
sdothum has joined #ruby
Xeago has quit [Remote host closed the connection]
tuelz1 has quit [Ping timeout: 240 seconds]
gregf has joined #ruby
karapetyan has quit [Ping timeout: 276 seconds]
<norc> dbugger: Take your actual code and the full stacktrace from the error message, and paste it to gisthub please.
dlitvak has joined #ruby
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
<dbugger> norc, That is the only output I got. how do I get a full stacktrace?
<norc> dbugger: Oh wait a second.
<dbugger> That, and the actual code (http://laravel.io/bin/Yyx2V) is the only code I got
<norc> dbugger: My first instinct is that the https://rubygems.org/api/v1/api_key.yaml that you tried to get is somehow borked.
Xeago has joined #ruby
<norc> So look at your credentials file
dlitvak has quit [Remote host closed the connection]
<dbugger> you mean that yaml file?
<norc> Yes.
Xeago has quit [Remote host closed the connection]
<dbugger> Oh!
<dbugger> Its a "not found" page o.O
<norc> :-)
<dbugger> So "https://rubygems.org/api/v1/api_key.yml" is not the right URL? It is the one in that tutorial...
<norc> I cannot help you any further, perhaps someone else here knows more. :)
<dbugger> aha!
<dbugger> silly error. probably a typewriting error in the article
emilford has joined #ruby
<norc> Glad you figured it out. :)
gruz0 has quit [Quit: This computer has gone to sleep]
<dbugger> It was pure luck :)
<norc> dbugger: The tutorial states https://rubygems.org/api/v1/api_key.yaml though..
<dbugger> In that case it was ME who made the error :)
<norc> dbugger: Im willing to bet that there are RSpec tests verifying that the code snippets work even.
<norc> (The ones on the page)
<dbugger> Really? Wow that is something else :)
<dbugger> I have seen so many more .yml files, than .yaml files, that I get confused with them often
<norc> I would certainly try spec such things on a large popular website
<norc> To ensure my users don't get non-functional snippets.
<dbugger> I didnt even though such thing existed. i thought it was plain text inside a <code> and that what it :)
<norc> dbugger: Read carefully, this is just an assumption.
<norc> But it is certainly possible to do it.
<norc> dbugger: If you dont know about automated tests, it probably would be a good idea to look into them.
<norc> Especially when you start writing gems.
allcentury has joined #ruby
bronson has joined #ruby
<norc> Minitest / RSpec (whichever you use) improve code reliability and usually even speed up development.
skade has joined #ruby
firstdayonthejob has joined #ruby
baweaver has joined #ruby
<dbugger> norc, I know about them, but I didnt thought about doing them on "posted content" on the website. Just on the website itself :)
bronson has quit [Ping timeout: 265 seconds]
<norc> dbugger: Most websites are not static, they are usually built on MVC stacks (such as Ruby on Rails). So content like snippets can easily be wrapped and tested.
dlitvak has joined #ruby
yfeldblum has quit [Ping timeout: 246 seconds]
baweaver has quit [Ping timeout: 240 seconds]
Pupeno has joined #ruby
vdamewood has quit [Quit: Life beckons.]
mondok has quit [Read error: Connection reset by peer]
Pupeno has quit [Client Quit]
rkoller has quit [Quit: Textual IRC Client: www.textualapp.com]
ht__ has quit [Quit: Konversation terminated!]
<norc> dbugger: But sure, even on "posted" content on a running website this could be doable.
ht__ has joined #ruby
<norc> (I was thinking rather along the way of such guides being hard wired into the code)
norc_ has joined #ruby
norc has quit [Quit: Page closed]
norc_ is now known as norc
<dbugger> Of course, everything is doable :)
agit0 has joined #ruby
<dbugger> I just never thought anyone out there was doing it :)
dlitvak has quit [Ping timeout: 246 seconds]
Helheim has quit [Quit: Bah, stupid error messages.]
pawnbox has quit [Remote host closed the connection]
gruz0 has joined #ruby
agit0 has quit [Client Quit]
<norc> dbugger, when I go around to discover new libraries, I will not use them if even the basic install instructions contain errors.
Helheim has joined #ruby
psyq has joined #ruby
<norc> But that is just me,
TomyLobo has joined #ruby
hannelita has joined #ruby
usershel_ has joined #ruby
JohnT has joined #ruby
usershell has quit [Ping timeout: 265 seconds]
<shevy> norc sounds reasonable
lucasb has joined #ruby
dtordable has left #ruby [#ruby]
<lucasb> irclog.whitequark.org is down?
<apeiros> seems like
ht__ has quit [Quit: Konversation terminated!]
bMalum has joined #ruby
<apeiros> more reason to get up to speed with ruby-community.com/irc/log
hannelita has quit [Ping timeout: 240 seconds]
gruz0 has quit [Quit: Leaving]
<dbugger> What is that?
<apeiros> ruby-community.com is this channel's official companion website.
ht__ has joined #ruby
<apeiros> development of it is public and coordinated in #ruby-community
pawnbox has joined #ruby
arup_r has quit [Remote host closed the connection]
skade has quit [Read error: Connection reset by peer]
SCHAAP137 has quit [Ping timeout: 250 seconds]
skade has joined #ruby
aspiers has quit [Ping timeout: 240 seconds]
Melpaws has joined #ruby
Apocalypse has quit [Quit: Input/Output Error]
Apocalypse has joined #ruby
lxsameer has quit [Quit: Leaving]
SCHAAP137 has joined #ruby
DoubleMalt has joined #ruby
pawnbox has quit [Ping timeout: 260 seconds]
carraroj has joined #ruby
carraroj has quit [Changing host]
carraroj has joined #ruby
SaturnMir has joined #ruby
pawnbox has joined #ruby
jottr has quit [Quit: WeeChat 1.4]
rkoller has joined #ruby
kalopsian has quit [Ping timeout: 256 seconds]
astrofog has quit [Quit: Quite]
pawnbox has quit [Ping timeout: 260 seconds]
tuelz1 has joined #ruby
pawnbox has joined #ruby
kobain has joined #ruby
bMalum has quit [Ping timeout: 260 seconds]
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
taq has joined #ruby
tuelz1 has quit [Ping timeout: 264 seconds]
FooMunki has quit [Quit: FooMunki]
FooMunki has joined #ruby
mostlybadfly has joined #ruby
<bvbrandon> how does one replace text in backets with a valie?
usershel_ has quit [Remote host closed the connection]
<Papierkorb> bvbrandon: What do you mean?
dlitvak has joined #ruby
JohnT has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
karapetyan has joined #ruby
<bvbrandon> lol sorry for the typos. I have this string. “I {want to} go to the park” and I have a hash with a value key “want to” => “never did” and I am trying to replace the want to in the string, with the never did from the hash
dlitvak has quit [Remote host closed the connection]
<lucasb> str.gsub(/{(.*)}/, a_hash)
<lucasb> maybe. I didn't test.
skade has quit [Ping timeout: 246 seconds]
northfurr has joined #ruby
<lucasb> use a non-greedy quantifier: /{(.+?)}/
edwinvdgraaf has quit [Read error: Connection reset by peer]
<Papierkorb> >> the_hash = { 'foo' => 'bar' }; "This {foo} works".gsub(/\{(.*)\}/){ the_hash[$1] }
<ruby[bot]> Papierkorb: # => "This bar works" (https://eval.in/503034)
<Papierkorb> bvbrandon: ^
<Papierkorb> lucasb: {} in regex have special meaning, you need to escape them
edwinvdgraaf has joined #ruby
<Papierkorb> >> "This {foo} is much better".gsub(/\{(.*)\}/, { '{foo}' => 'bar' })
<ruby[bot]> Papierkorb: # => "This bar is much better" (https://eval.in/503035)
<Papierkorb> bvbrandon:
<bvbrandon> thank you!
<nickjj_> bvbrandon, it's worth mentioning that if you plan to do this a lot it might be worth looking into a templating language
<Papierkorb> Oh, sorry, now you'd have to add the {} to the hash ..
skade has joined #ruby
<norc> bvbrandon, ruby comes with erb out of the box in case you are interested in nickjj_'s suggestion.
<lucasb> Papierkorb: no need to escape {} if they are not in a quantifier position
nickjj_ is now known as nickjj
iateadonut has joined #ruby
<lucasb> >> 'a{ }b'.sub(/{.*}/, 'x')
<norc> bvbrandon, In all likelihood it will solve your problem more easily.
<ruby[bot]> lucasb: # => "axb" (https://eval.in/503036)
<jhass> or if there's influence on the source format, String#%/Kernel#sprintf can do it too
sankaber has joined #ruby
psyq has quit [Quit: Conversation terminated]
edwinvdgraaf has quit [Read error: Connection reset by peer]
jgpawletko has quit [Quit: jgpawletko]
edwinvdgraaf has joined #ruby
cornerman has quit [Ping timeout: 276 seconds]
cornerman has joined #ruby
<lucasb> >> 'My lucky number is %d.' % (40..45).to_a.sample
<ruby[bot]> lucasb: # => "My lucky number is 42." (https://eval.in/503037)
psyq_ is now known as psyq
skade has quit [Quit: Computer has gone to sleep.]
psyq has quit [Changing host]
psyq has joined #ruby
freerobby has joined #ruby
jottr has joined #ruby
cornerman has quit [Client Quit]
ympeg has joined #ruby
cornerman has joined #ruby
<apeiros> lucasb: is there any position besides "right at the start of the regexp" where {} isn't in quantifier position?
arup_r has joined #ruby
<lucasb> apeiros, Papierkorb: yes you are right, {} is special and I should always escape it to avoid problems.
<apeiros> hm?
<apeiros> that was a genuine question
<lucasb> apeiros: but did you saw my eval? it was 'a{ }b' and it didn't matter
<apeiros> yes, I've seen it
<apeiros> ah, I mean any position in the regex, not the string
<apeiros> that it doesn't matter in the string is obvious :)
<lucasb> ah, sorry, my misundertand. let me test something then :)
<bvbrandon> papierkorb: that didn’t solve all of my test cases :/
<bvbrandon> it’s very close!
<apeiros> I just can't come up with any other situation than at the start of a regex where {} wouldn't be treated as a quantifier. iirc even after a quantifier it's one. i.e. iirc (expr){a,b}{c,d} is treated as ((expr){a,b}){c,d}
<apeiros> well, (?:) instead of ()
<apeiros> maybe I'm wrong. I didn't try :D
<apeiros> yepp, works that way
<apeiros> >> ["aaaaaaaaaa"[/a{1,2}{2,4}/], "aaa"[/a{1,2}{2,4}/]]
<ruby[bot]> apeiros: # => ["aaaaaaaa", "aaa"] (https://eval.in/503042)
<norc> apeiros, okay just started this. What is your preferred method of escaping the input string? Im thinking of simply using %%q`%s` in the format string, since Im not sure whether there is a trivial way to properly escape any input string.
<ponga> every website has to turn into "black background, white font"
hannelita has joined #ruby
Limix has joined #ruby
<apeiros> ?ot ponga
<ruby[bot]> ponga: this seems to be off-topic. Please move your discussion to #ruby-offtopic, to keep this channel free for Ruby related topics. Thanks!
<jhass> apeiros: inside a character class?
<ponga> oh sorry this irccloud thing
ht__ has quit [Quit: Konversation terminated!]
<apeiros> jhass: ah, didn't consider that since you don't have to escape anything there
<apeiros> well, except ]
dlitvak has joined #ruby
<apeiros> and potentially :
<apeiros> or wait, no, posix use [[?
<apeiros> so except [ and ] then :)
<apeiros> norc: purely stylistic wise?
dlitvak_ has joined #ruby
ht__ has joined #ruby
<apeiros> I do strings in this order: "" > %{} > %q{} > <<-HERE
<apeiros> btw. norc - join #ruboto_test? better to talk there :)
PedramT has joined #ruby
<lucasb> apeiros: regexs are tricky, I should study them more. I didn't know {1,2} could nest like that. thanks for the example :)
usershell has joined #ruby
<apeiros> lucasb: I only know because of IRC either :D
hannelita has quit [Ping timeout: 264 seconds]
allcentury has quit [Ping timeout: 276 seconds]
PedramT has quit [Read error: Connection reset by peer]
dlitvak has quit [Ping timeout: 260 seconds]
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
Ishido has joined #ruby
PedramT has joined #ruby
PedramT has quit [Remote host closed the connection]
dfinninger has joined #ruby
agit0 has joined #ruby
PedramT has joined #ruby
BSaboia has joined #ruby
BaroMeter has quit [Remote host closed the connection]
houhoulis has joined #ruby
<pontiki> is %{} equivalent to %q or %Q ?
<pontiki> %Q
<norc> pontiki, %{} is the general form, and the Q modified is applied by default.
<norc> *modifier
<al2o3-cr> one allows interpolation
<pontiki> would there be a situation where the non-interpolating for would be applied instead?
<pontiki> form*
<norc> pontiki, it is the same as '' vs ""
<norc> pontiki, use "" when you intend for interpolation and '' if you do not.
<pontiki> no, it's not, norc
<al2o3-cr> same with %w %W
<pontiki> i *know* how to interpolate
usershell has quit [Remote host closed the connection]
<norc> pontiki, you misunderstood
<pontiki> i'm asking, because you said "default", if %{} can become %q instead of %Q
<norc> pontiki, yes, by using %q{}
<pontiki> then it's not %{}
<norc> pontiki, %{} is just short for %Q{}
<pontiki> see, that's what i was originally asking. then you said "by default"
Melpaws1 has joined #ruby
<pontiki> which implies %{} can assume a different form
<norc> pontiki, ah. Okay that was badly phrased then sorry.
Melpaws has quit [Ping timeout: 240 seconds]
<oo7cat> i want learn ruby but i don’t know ruby?
<norc> .guides
<norc> .books
<norc> ?books
<ruby[bot]> You can find a list of recommended books at http://ruby-community.com/pages/links
<norc> oo7cat, ^-
<oo7cat> heh norc thanks
<SaturnMir> 007cat it is simple to learn (I started a week ago). I just generally google things and look at examples on github :D if you are interested, I have a little cheatsheet I wrote here; https://github.com/SpriteMidr/Experiments/blob/master/Ruby%2C%20Rails/rubyCheatSheet.md :P
kalopsian has joined #ruby
<apeiros> hm, never seen .rbw as a ruby extension
ta0 has joined #ruby
<apeiros> and I think you want "#!/usr/bin/ruby" as shebang, not "#!\usr\bin\ruby -w"
<norc> apeiros, I think its a windows related thing.
<shevy> for windows system, I believe the w is for windows, in that one can probably avoid a command prompted window appearing
jottr has quit [Quit: WeeChat 1.4]
ponga has quit []
<norc> But then again, considering what a major PITA it is - who does Ruby development on windows anyway. :-)
ponga has joined #ruby
ht__ has quit [Quit: Konversation terminated!]
<pontiki> beginners
ht__ has joined #ruby
<shevy> I used to test my ruby scripts on windows! but that was many years ago by now...
cholq has joined #ruby
<norc> apeiros, oh I can only imagine the run trying to get ruby-oci8 running on Windows. :-))
<norc> the fun I mean.
<ta0> so after I run 'gem rdoc --all' where can I find the html documentation for the gems I've installed?
<ta0> there's no .rdoc in my home directory or anything so where else should I look?
kalopsian has quit [Read error: Connection reset by peer]
allcentury has joined #ruby
kalopsian has joined #ruby
phoo1234567 has joined #ruby
tuelz1 has joined #ruby
<pontiki> ta0: the command for reading ruby documentation is `ri`
<ta0> so there's no way to browse the html output with my browser?
ht__ has quit [Client Quit]
<pontiki> sure. you run `gem serve` i think
dlitvak_ has quit [Ping timeout: 256 seconds]
<ta0> !! just what I needed, that's perfect
<ta0> thanks mate
<pontiki> no worries, love
cholq has quit [Ping timeout: 240 seconds]
emilford has quit [Ping timeout: 240 seconds]
casadei has joined #ruby
<ta0> it even shows all the different gems on the homepage, insane
<oo7cat> perl vs ruby, which is good for learning easily?
<apeiros> norc: on windows you don't have \usr, no? I mean all paths start with either \\ or \<drive letter>?
<ta0> oo7cat: ruby is more natural
<shevy> oo7cat both languages require quite a lot of effort
dfinninger has quit [Remote host closed the connection]
<pontiki> oo7cat: it sort of depends on where you're coming from, and what you want to do with it
<taq> apeiros, can you insert my free Ruby ebook on the Ruby books listing? it is free and kind of popular on Brazil: https://leanpub.com/conhecendo-ruby
<shevy> oo7cat I'd still love to have a lean, mean mini-ruby with lots of stuff removed :)
<apeiros> taq: make PR ;-)
<taq> apeiros, just saw the community link over there :-)
tuelz1 has quit [Ping timeout: 240 seconds]
<pontiki> shevy: i thought that *was* perl
<pontiki> or is that the wrong set of stuff removed? :D
<norc> apeiros, you would still only use /
tmtwd has joined #ruby
PedramT has quit [Ping timeout: 245 seconds]
dlitvak has joined #ruby
<shevy> pontiki well perl has that weird perl syntax
casadei has quit [Ping timeout: 276 seconds]
<shevy> things like oh my $god and strangeness
<norc> apeiros, might not be well known but Windows has been accepting / as a path separator for a heck of a long time
<shevy> and $_ $% $)()=&()§=&(&/§=/()"§"!°°°"!"
<pontiki> meh, those are just different sygils
<apeiros> norc: I actually do know
<apeiros> norc: in programming it depends on the API you use, though
<apeiros> afaik windows actually translates the /, and not all of the API does
<norc> apeiros, indeed, Win32 API supports it throughout tho afaik
<apeiros> but I'm not a windows programmer, so take it with a bit of salt :)
awad has joined #ruby
<shevy> nobody would admit to this anyway!
<norc> apeiros, on all my Windows projects we used Qt anyway, which allowed us to not worry about such things.
emilford has joined #ruby
<apeiros> shevy: some admit it, some even proudly so
<norc> I find the Win32 API to be extremely enjoyable to work with honestly.
<apeiros> sadly our new CIO is a microsoft fan :(
<apeiros> but OT…
<shevy> hehe
<norc> And Visual Studio is by far the most powerful IDE for C/C++ development without any real competition honestly.
<norc> Or C#
dfinninger has joined #ruby
<Papierkorb> Tried VS in Uni with C#. Was not impressed.
<norc> apeiros, funny thing though - we made sure our applications were completely wine portable, and the reason is we used valgrind for memory debugging - since it is unmatched in that area.
PedramT has joined #ruby
<shevy> this is cool because both norc and Papierkorb are qt users
<Papierkorb> QtCreator ftw
<norc> Papierkorb, meh, IntelliSence is just priceless. :P
<norc> *Intellisense
<Papierkorb> norc: it didn't work at all really for my stuff. It was barely helpful, nothing more than a list displayed as overlay. Nothing 'clever' about it. Adding imports was way too much of a hassle too
dlitvak has quit [Remote host closed the connection]
<Papierkorb> Either it's really that bad, or the out of the box settings are awful. Or both.
<norc> Papierkorb, the thing that annoyed me most was that MSVC really abided by the C++ standard and not enforced a bit of ABI stability between any version.
<norc> For c++
<oo7cat> i made this code before 2 years ago. but i can’t remember how i made it. http://ideone.com/DklSaM
<norc> So for larger projects you ended up writing C wrappers to be able to work with the modules by other groups.
<oo7cat> so i want to learn new language like ruby.
<Papierkorb> norc: I never had to deal with that idiosyncrasy, GCC for everything, and the windows port seemed to work with MinGW :)
northfurr has quit [Quit: northfurr]
<norc> Papierkorb, well I suppose it was just political problems. One dept. working with VS2003 at the time, another with VS2008, etc.
sepp2k has joined #ruby
<norc> And GCC has the same ABI instability. It is just more likely to expect everybody to use the same version.
Yzguy has joined #ruby
<Papierkorb> norc: Yeah, though it is a mess. People mistake this as issue of C++, where their unstable runtime environment is at fault. And it makes it nigh impossible to "just use some library" from the internet too.
dfinninger has quit [Remote host closed the connection]
allcentury has quit [Quit: WeeChat 1.2]
<Papierkorb> norc: Mh? GCC is pretty stable, they just changed it after the last change (Which was with .. 4.2?) in 5.0 iirc. Isn't there even a switch to tell it to use the old bindings?
<norc> Papierkorb, you misunderstand "ABI instability" for unstable.
arthurix_ has quit [Read error: Connection reset by peer]
<oo7cat> can i come here tomorrow?
<norc> oo7cat, sure thing. :)
Melpaws has joined #ruby
arthurix has joined #ruby
<pontiki> you have to pay a new entrance fee, and there's a $5 cover for the band
<oo7cat> thanks norc
emilford_ has joined #ruby
Melpaws1 has quit [Ping timeout: 245 seconds]
dlitvak has joined #ruby
<norc> Papierkorb, ohh - I think my information has been greatly outdated... I take it back.
dorei has joined #ruby
<norc> You are right. GCC has been trying to adhere to an ABI standard.
mfb2 has joined #ruby
<oo7cat> bye :)
<Papierkorb> norc: I also haven't done any C++ in a year now, things could've changed. Things have been hectic since C++11 :)
emilford has quit [Ping timeout: 260 seconds]
oo7cat has left #ruby [#ruby]
<norc> Papierkorb, Im really sad I had to quit my job right when C++11 came out since it brought some pretty exciting features (not concepts though, was really sad)
ta0 has quit [Remote host closed the connection]
duckson has left #ruby ["Textual IRC Client: www.textualapp.com"]
dasher00 has quit [Quit: Leaving]
kalopsian has quit [Ping timeout: 246 seconds]
kalopsian has joined #ruby
karapetyan has quit [Remote host closed the connection]
emilford_ has quit [Read error: Connection reset by peer]
DarthGandalf has quit [Quit: Bye]
mfb2 has quit [Ping timeout: 260 seconds]
bottiger has joined #ruby
ht__ has joined #ruby
tk__ has quit [Quit: ばいばい]
karapetyan has joined #ruby
<Papierkorb> norc: Ton of things came with it. The most important feature for me were variadic templates, as I did use Qt stuff for everything I could, so I didn't really use the stdlib at all. I know what the std::*_ptr classes do, but besides other beginner stuff, not a whole lot more in that regard. (Also plucking #ruby-offtopic)
<bottiger> Can I have a UTF-32 string in Ruby? like a = "æ" but where "æ" is encoded in UTF-32 and not UTF-8 ? I'm not looking for something like a = "\xf3"
DarthGandalf has joined #ruby
emilford has joined #ruby
<bottiger> the thing is, I want a compact method to store 32 bits in a variable
<bottiger> and if UTF-32 is not possible, then maybe UTF-16
<norc> bottiger, sure. Ruby allows for a wide variety of encodings, including UTF-32
<norc> &ri Encoding
<norc> >> "æ".encode "utf-32"
<ruby[bot]> norc: # => "\uFEFF\u00E6" (https://eval.in/503045)
ht__ has quit [Quit: Konversation terminated!]
taq has quit [Quit: "Lunch time"]
nerium has joined #ruby
CloCkWeRX has quit [Quit: Leaving.]
PedramT has quit [Remote host closed the connection]
Bloomer has quit [Remote host closed the connection]
emilford has quit [Ping timeout: 264 seconds]
hannelita has joined #ruby
<bottiger> norc, I see
<bottiger> norc, Thanks
mfb2 has joined #ruby
<bottiger> I honestly a bit unsure what my problem was
emilford has joined #ruby
dlitvak has quit [Remote host closed the connection]
futilegames has joined #ruby
<lucasb> in addition, you can also put a magic comment at the beginning of your file: # encoding: utf-32
<al2o3-cr> >> Encoding.name_list
<ruby[bot]> al2o3-cr: # => ["ASCII-8BIT", "UTF-8", "US-ASCII", "UTF-16BE", "UTF-16LE", "UTF-32BE", "UTF-32LE", "UTF-16", "UTF-3 ...check link for more (https://eval.in/503046)
TheHodge has joined #ruby
<bottiger> lucasb: can I? then I get an argumentError that UTF-32 is not ascii compatible (which is correct) when I run the script
hannelita has quit [Ping timeout: 264 seconds]
emilford_ has joined #ruby
futilegames has quit [Ping timeout: 260 seconds]
emilford has quit [Ping timeout: 260 seconds]
Bloomer has joined #ruby
nerium has quit [Quit: nerium]
<norc> bottiger, the magic comment is not for transcoding, but telling the interpreter which encoding to assume.
<lucasb> bottiger: I was expecting that to work, but apparently I'm mistaken
futilegames has joined #ruby
<norc> bottiger, so it is the equivalent of String#force_encoding
agit0 has quit [Quit: zzzZZZ….]
<norc> bottiger, so the question is, which encoding does your text editor use? If it is set to UTF-8 you should not specify a different encoding in a magic comment.
northfurr has joined #ruby
<bottiger> norc: I think it's UTF-8, but I'm working over SSH on a windows machine. So I guess I 1000 things can go wrong in the process
futilegames has quit [Client Quit]
<norc> bottiger, by default Ruby assumes script files to be UTF-8 since 2.0
<norc> (Before that it was US-ASCII)
<bottiger> I remember that from a long time ago
bhalash has joined #ruby
radgeRayden_ has joined #ruby
PedramT has joined #ruby
northfurr has quit [Quit: northfurr]
usershell has joined #ruby
karapetyan has quit [Remote host closed the connection]
psyq has quit [Quit: Conversation terminated]
al2o3-cr has quit [Quit: WeeChat 1.3]
psyq has joined #ruby
Melpaws has quit [Quit: Leaving.]
karapetyan has joined #ruby
PedramT has quit [Ping timeout: 256 seconds]
Bloomer has quit [Remote host closed the connection]
al2o3-cr has joined #ruby
nanoz has joined #ruby
<lucasb> strange, if put the comment "encoding: utf-16" or utf-32 and save the file with the right encoding, it silences the error 'UTF-16 is not ASCII compatible (ArgumentError)', but then it doesn't run or output anything
<lucasb> *if I put...
arup_r has quit []
northfurr has joined #ruby
usershell has quit [Ping timeout: 255 seconds]
emilford_ has quit [Ping timeout: 260 seconds]
Bloomer has joined #ruby
tuelz1 has joined #ruby
agit0 has joined #ruby
emilford has joined #ruby
JohnT has joined #ruby
newbie22 has joined #ruby
<jhass> maybe your terminal fails to render UTF-16?
<newbie22> *:hello,,, is anyone there ???
<jhass> wouldn't surprise me that much
<jhass> newbie22: you are for starters
tubuliferous_ has joined #ruby
<lucasb> jhass: yes, probably. My terminal is not configured
<jhass> lucasb: try piping the output to hexdump
ht__ has joined #ruby
tuelz1 has quit [Ping timeout: 245 seconds]
<lucasb> still nothing. tried outputing to a file too, nothing.
<jhass> but then the output encoding should remain UTF-8 and Ruby should convert, hmm
emilford has quit [Ping timeout: 256 seconds]
<jhass> can you upload your testfile somewhere that preserves the bytes?
ht__ has quit [Client Quit]
<lucasb> I just wrote "# encoding: utf-16\nputs 'hi'"
<lucasb> and made sure to save with the right encoding with vim
<lucasb> I may have done something wrong
bluOxigen has joined #ruby
bkxd has quit [Ping timeout: 250 seconds]
govg has quit [Quit: leaving]
<jhass> I don't remember, does utf-16 default to LE or BE?
awad has quit [Ping timeout: 246 seconds]
govg has joined #ruby
Guest68186 is now known as C0deMaver1ck
bluOxigen_ has joined #ruby
<lucasb> I have no idea :)
ht__ has joined #ruby
awad has joined #ruby
tubuliferous_ has quit [Ping timeout: 272 seconds]
<jhass> I can actually reproduce, interesting
kuon has joined #ruby
<lucasb> but I see ruby has this internal/external encoding. I should probably try to understand that before saying anything
tubuliferous_ has joined #ruby
<kuon> Hi. Is there a way to map values in a hash? {foo: 'bar'}.map_values_something{|v| v.upcase} -> {foo: 'BAR'}
<kuon> I mean a built in function, I can implement something myself.
<kuon> Something I might have missed.
iateadonut has quit [Quit: Leaving.]
<jhass> newbie22: do you have a question?
chipotle has joined #ruby
<lucasb> kuon: {a: 'foo'}.each_value {|v| v.upcase! }
fsapo has joined #ruby
<jhass> kuon: .each_value.map
bluOxigen has quit [Ping timeout: 260 seconds]
SaturnMir has quit [Remote host closed the connection]
psyq has left #ruby [#ruby]
<jhass> oh, misunderstood, ^
karapety_ has joined #ruby
<kuon> lucasb: ho yeah, mutating the string is a nice idea.
<jhass> or .map {|k, v| [k, v.upcase] }.to_h for the non-destructive version
<newbie22> jhass: I do not have a question.
chipotle has quit [Max SendQ exceeded]
<kuon> jhass: ok, but I can mutate the string in this case.
<kuon> thanks:)
northfurr has quit [Quit: northfurr]
<newbie22> Jhass: I am tinking of leaning ruby
<jhass> that's great
<jhass> your first programming language?
chipotle has joined #ruby
<newbie22> jhass: well yes, I have done some basic unix scripting, some perl, and a small bit of python
karapetyan has quit [Ping timeout: 256 seconds]
mfb2 has quit [Remote host closed the connection]
<newbie22> Jhass: but I have never really mastered a lanquage
chipotle has quit [Max SendQ exceeded]
<jhass> Chris Pine's Learn to program is a generally recommended resource in that case if you want to give it a shot
<newbie22> jhass: I am starting with book. "Learning Ruby the Hard Way"
<jhass> and then Ruby under a Microscope if you want to dive deep I guess
chipotle has joined #ruby
<jhass> mh, I dislike Shaw's Ruby style personally, make sure to read a styleguide afterwards
dlitvak has joined #ruby
jam_ has joined #ruby
aryaching has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
<jhass> anyway, if you got any question in the process just ask it, no need to wait for activity or something
<jhass> ;)
<newbie22> jhass: thanks..
karapety_ has quit [Remote host closed the connection]
sandstrom has joined #ruby
karapetyan has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
emilford has joined #ruby
jam_ has quit [Ping timeout: 260 seconds]
sepp2k has quit [Read error: Connection reset by peer]
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
mfb2 has joined #ruby
chipotle has quit [Read error: Connection reset by peer]
emilford has quit [Ping timeout: 240 seconds]
chipotle has joined #ruby
bollullera has joined #ruby
emilford has joined #ruby
mfb2 has quit [Ping timeout: 260 seconds]
arup_r has joined #ruby
bollullera has left #ruby [#ruby]
mostlybadfly has quit [Quit: Connection closed for inactivity]
yardenbar has quit [Ping timeout: 264 seconds]
chipotle has quit [Read error: Connection reset by peer]
r00k has joined #ruby
r00k has left #ruby [#ruby]
chipotle has joined #ruby
Macaveli has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
emilford has quit [Ping timeout: 260 seconds]
hannelita has joined #ruby
myntcake has joined #ruby
chipotle has quit [Read error: Connection reset by peer]
chipotle has joined #ruby
unreal_ is now known as unreal
newbie22 has quit [Quit: Leaving]
myntcake_ has joined #ruby
emilford has joined #ruby
JohnT has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
rkazak has joined #ruby
<myntcake_> myntcake: ?
myntcake_ has quit [Client Quit]
rodolfowtf has joined #ruby
myntcake_ has joined #ruby
hannelita has quit [Ping timeout: 255 seconds]
<arup_r> wut ? :p
Limix has quit [Quit: Limix]
myntcake is now known as Guest58365
emilford has quit [Ping timeout: 272 seconds]
yardenbar has joined #ruby
carraroj has quit [Ping timeout: 260 seconds]
myntcake_ has quit [Quit: Leaving]
karapetyan has quit [Remote host closed the connection]
myntcake_ has joined #ruby
<myntcake_> myntcake_: ?
emilford has joined #ruby
<myntcake_> check
chipotle has quit [Read error: Connection reset by peer]
<jhass> sup?
chipotle has joined #ruby
<myntcake_> jhass: this is really weird haha
houhoulis has quit [Remote host closed the connection]
<jhass> what?
<myntcake_> i messed with my hexchat, and can't seem to get my nick back
<apeiros> myntcake_: /ghost
<jhass> registered with nickserv?
<apeiros> or /ns ghost
psyq has joined #ruby
<myntcake_> jhass: yes
<myntcake_> i nickserv released it and now when i try to change my name i get : myntcake :Nick/channel is temporarily unavailable
<jhass> then what apeiros said, /msg NickServ ghost myntcake
<myntcake_> but i get myntcake is not onliine if i ghost XD this is really messing with me hahah
<jhass> myntcake_: try regain
<myntcake_> i used to be able to /server irc.freenode.net and now it won't even let me do that, i have to /server chat.freenode.net for me to get in
<jhass> /msg nickserv regain myntcake
myntcake_ is now known as myntcake
<myntcake> woah!!!
<myntcake> dude u're awesome
<myntcake> hahaha
<jhass> you're welcome girl
emilford_ has joined #ruby
emilford has quit [Ping timeout: 260 seconds]
<myntcake> jhass: *boy
<myntcake> haha, anyways that wasn't the reason that i came here
<myntcake> i just started running an aws ec2 machine and installed ruby on rails. my question is, do i need apache installed too?
<myntcake> i can't seem to see the rails page on ip_address:3000
Guest58365 has quit [Quit: Page closed]
sftrabbit has joined #ruby
<jhass> you want a reverse proxy if you want to use port 80, yes. Apache and Nginx are common choices
<myntcake> jhass: so i still need to install apache even if i have rails server, right?
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
<jhass> that's what I said
<jhass> you don't need apache in particular
C0deMaver1ck has quit [Ping timeout: 276 seconds]
tubuliferous_ has quit [Ping timeout: 264 seconds]
yardenbar has quit [Ping timeout: 240 seconds]
<myntcake> so even if i want to connect to port 3000 only, i would still need it, right?
ledestin has joined #ruby
northfurr has joined #ruby
emilford_ has quit [Ping timeout: 250 seconds]
ht__ has quit [Client Quit]
<jhass> no
dlitvak has quit [Ping timeout: 255 seconds]
tuelz1 has joined #ruby
tvw has quit []
emilford has joined #ruby
tuelz1 has quit [Ping timeout: 240 seconds]
DarthGandalf has quit [Remote host closed the connection]
C0deMaver1ck has joined #ruby
C0deMaver1ck is now known as Guest25647
<dbugger> Hey guys. I was looking at this code (http://pastie.org/10692021), and wandering... where is :test defined?
DarthGandalf has joined #ruby
<apeiros> dbugger: Rake::TestTask.new defines the :test task
northfurr has quit [Quit: northfurr]
chipotle has quit [Read error: Connection reset by peer]
chipotle_ has joined #ruby
Limix has joined #ruby
dpg_ has joined #ruby
tmtwd has quit [Ping timeout: 240 seconds]
<dbugger> apeiros, implicitely?
northfurr has joined #ruby
<apeiros> not sure how you define something implicitly
emilford has quit [Ping timeout: 272 seconds]
m8 has quit [Quit: Sto andando via]
emilford has joined #ruby
<dbugger> apeiros, I mean, I see nowhere being ":test" written... << "test" is the name of a folder, not the symbol. So does TestTask build always a task called :test? or does it build always a task with the same symbol as the folder name?
<jhass> let's ask the docs!
<jhass> &ri Rake::TestTask
<`derpy> No results
<jhass> aw
<havenwood> To the docmobile!
<lucasb> def initialize(name=:test)
<lucasb> ^^ from Rake::TestTask
DoubleMalt has quit [Read error: Connection reset by peer]
<jhass> yeah, that's what I was getting at ;)
<apeiros> dbugger: take a look at the code havenwood linked you to
<shevy> havenwood lol docmobile ... never read that word before
<apeiros> dbugger: line 81, 82 and 100 are the relevant lines.
norc_ has joined #ruby
norc_ has left #ruby [#ruby]
<apeiros> shevy: you never did? to the logmobile then!
bronson has joined #ruby
<shevy> lol
<dbugger> I see
<dbugger> thanks guys
<apeiros> ?guys dbugger
Azure has quit [Ping timeout: 264 seconds]
<ruby[bot]> dbugger: Though inclusion was probably intended, not everyone relates to being "one of the guys". Maybe consider using "folks", "all", "y'all", or "everyone" instead?
<dbugger> Thank you everyone
<apeiros> 3
<apeiros> whoops
<apeiros> <3
<dbugger> In my country, guys is just an over term for people of all genders
<dbugger> That is why the term
<dbugger> sorry, if someone felt excluded
<arup_r> +1
<apeiros> sure. no explanation needed.
<dbugger> Well, if someone felt excluded, the explanation is DO needed :)
jbrhbr has joined #ruby
jbrhbr has quit [Client Quit]
<apeiros> many feel that way, hence the wording tries to non-accusatory
<arup_r> that command is unnecessary ...
<apeiros> +be
ponga has quit [Quit: Connection closed for inactivity]
<apeiros> arup_r: no, it isn't. and that's the end of this discussion.
northfurr has quit [Quit: northfurr]
<phreakocious> people love getting told how to talk, I hear...
rodolfowtf has quit [Ping timeout: 260 seconds]
baweaver has joined #ruby
<apeiros> !kick phreakocious I said this was the end of the discussion
phreakocious was kicked from #ruby by ruboto [I said this was the end of the discussion]
phreakocious has joined #ruby
Azure has joined #ruby
<phreakocious> cute
bronson has quit [Ping timeout: 265 seconds]
Melpaws has joined #ruby
<arup_r> phreakocious: i hear you.. how day ? :)
<phreakocious> good.. full of looking for ways to be a victimn :)
mfb2 has joined #ruby
<jhass> arup_r: don't feed
<jhass> .kick phreakocious come back when you have a ruby question
phreakocious was kicked from #ruby by ruby[bot] [come back when you have a ruby question]
baweaver has quit [Ping timeout: 240 seconds]
<shevy> dual bot power
<apeiros> shevy: last day, though
jbrhbr has joined #ruby
mfb2 has quit [Ping timeout: 246 seconds]
bhalash has quit [Ping timeout: 240 seconds]
pawnbox has quit [Remote host closed the connection]
FooMunki has quit [Quit: FooMunki]
pawnbox has joined #ruby
fnux has quit [Ping timeout: 255 seconds]
rodolfowtf has joined #ruby
symm- has quit [Ping timeout: 246 seconds]
guacamole has joined #ruby
symm- has joined #ruby
hannelita has joined #ruby
volty has joined #ruby
vikaton has joined #ruby
jbrhbr has quit [Quit: Leaving.]
einarj has joined #ruby
hannelita has quit [Ping timeout: 240 seconds]
pskosinski is now known as DrNetMed
DrNetMed is now known as pskosinski
pawnbox has quit [Remote host closed the connection]
<apeiros> (bot should have done that, but seems that's one of the remaining bugs)
jgt has joined #ruby
pawnbox has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
pandaant has quit [Remote host closed the connection]
ziyadb has quit [Quit: Connection closed for inactivity]
radgeRayden_ has quit [Read error: Connection reset by peer]
Channel6 has joined #ruby
sandstrom has joined #ruby
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
JohnT has joined #ruby
diegoviola has joined #ruby
kalopsian has quit [Ping timeout: 260 seconds]
finisherr has joined #ruby
jackjackdripper has joined #ruby
einarj has quit [Remote host closed the connection]
Yzguy has quit [Quit: Zzz...]
<arup_r> In my page I have a file field. now, people can upload CSV there, then I will work on it. Now, people are putting some invaid data file also.. which causes "ArgumentError: invalid byte sequence in UTF-8" .. I am thinking instead of fixing the byte issue, I will rescue the exception, and then I will show them in page some reason. What exception class should I rescue for this kind of issues.
PedramT has joined #ruby
<arup_r> rescuing ArgumentError will not be best thing..
FernandoBasso has quit [Quit: Leaving]
<apeiros> don't use rescue for flow control
<apeiros> string.valid_encoding?
<volty> chain them, from the more specific to the less ones
freerobby has quit [Quit: Leaving.]
bhalash has joined #ruby
freerobby has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
<arup_r> apeiros: That error comes from this `CSV.read(@filepath, { :col_sep => "\t" })`.. during the read it is coming.
<arup_r> so that trick will not work
<apeiros> uh, yeah, ok…
karapetyan has joined #ruby
<arup_r> CSV throws it while parsing..
<apeiros> mhm
<apeiros> and that's your code or 3rd party?
tuelz1 has joined #ruby
<arup_r> my own.. should I gist ?
emilford has quit [Ping timeout: 260 seconds]
<arup_r> not a big class.. may be 50 lines
<arup_r> nah, 62 :) lines
<volty> enough to not fill here > 50 lines about it :)
sandstrom has joined #ruby
<arup_r> hehe I know.. I am old :(
<apeiros> arup_r: no. the point is if it's your code the trick absolutely works. it just means you have to adapt it.
<apeiros> wouldn't call it a trick either.
PedramT has quit [Ping timeout: 250 seconds]
emilford has joined #ruby
karapetyan has quit [Ping timeout: 255 seconds]
mostlybadfly has joined #ruby
tuelz1 has quit [Ping timeout: 255 seconds]
kobain has quit [Ping timeout: 240 seconds]
<volty> something that cannot be read cannot be read, so as I said, chain around that CSV.read a few rescues - from that specific one, to a very generic one, and others maybe (grep for raise within csv source)
bhalash has quit [Quit: leaving]
<volty> i need to rpc with a dataset (sequel) as an argument, drb can deal with it? or there's something newer & better ?
amclain has joined #ruby
<arup_r> volty: CSV lib, not doing it. CSV internally using Ruby, from that part it comes.. https://github.com/JEG2/faster_csv/search?utf8=%E2%9C%93&q=raise I didn't see any so as per use should I chain like
<arup_r> rescue CSV::MalformedCSVError, RuntimeError, StandardError
bluOxigen_ has quit []
Xeago has joined #ruby
bluOxigen has joined #ruby
rkazak has quit [Quit: Sleep.....ing....]
camillo has joined #ruby
kalopsian has joined #ruby
jam_ has joined #ruby
<volty> have no any further idea. just a hint : could be grepping c source files you can find invalid byte seq....
Tarellel has joined #ruby
TheHodge has quit [Quit: Connection closed for inactivity]
sandstrom has quit [Quit: My computer has gone to sleep.]
<apeiros> or just read the exception backlog…
sol_ has quit [Ping timeout: 240 seconds]
camillo is now known as sol_
<apeiros> *backtrace
<volty> I would just rescue and log whatever comes.
<volty> (and what to present to the user is another choice ...)
<volty> backtrace's nice idea
rkazak has joined #ruby
sandstrom has joined #ruby
ziyadb has joined #ruby
tubuliferous_ has joined #ruby
dionysus69 has joined #ruby
radgeRayden has joined #ruby
jam_ has quit [Ping timeout: 250 seconds]
m1dnight_ has quit [Ping timeout: 250 seconds]
myntcake has quit [Ping timeout: 245 seconds]
diegoviola has quit [Quit: WeeChat 1.3]
underplank has joined #ruby
bruce__lee has joined #ruby
kerunaru has joined #ruby
awad has quit [Ping timeout: 246 seconds]
northfurr has joined #ruby
Dimik has joined #ruby
tjohnson has joined #ruby
Xeago has quit [Remote host closed the connection]
bruce_lee has quit [Ping timeout: 264 seconds]
sgambino has joined #ruby
dfinninger has joined #ruby
chipotle_ has quit [Read error: Connection reset by peer]
emilford has quit [Ping timeout: 260 seconds]
chipotle has joined #ruby
einarj has joined #ruby
Xeago has joined #ruby
emilford has joined #ruby
PedramT has joined #ruby
Tarellel has quit [Quit: Tarellel]
czsr has joined #ruby
dfinning_ has joined #ruby
einarj has quit [Remote host closed the connection]
zast has joined #ruby
dfinninger has quit [Read error: Connection reset by peer]
Xeago has quit [Remote host closed the connection]
graffix222 has quit [Ping timeout: 260 seconds]
PedramT_ has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
speakingcode has quit [Ping timeout: 276 seconds]
PedramT has quit [Ping timeout: 260 seconds]
dfinninger has joined #ruby
emilford has quit [Ping timeout: 250 seconds]
houhoulis has joined #ruby
hannelita has joined #ruby
<arup_r> :)
speakingcode has joined #ruby
sandstrom has joined #ruby
emilford has joined #ruby
kalopsian has quit [Ping timeout: 240 seconds]
Phage has quit [Quit: I suddenly got busy, who'd have guessed that?]
underplank has quit [Quit: underplank]
graffix222 has joined #ruby
<volty> arup_r: nice done, and nice to know about, thx :)
<arup_r> volty: yes, found in CSV doc, I can add my own.. so I didn't miss the chance to add my own
<arup_r> hehe
kalopsian has joined #ruby
dfinning_ has quit [Ping timeout: 240 seconds]
chipotle has quit [Read error: Connection reset by peer]
blackmesa has joined #ruby
fsapo has quit [Remote host closed the connection]
hannelita has quit [Ping timeout: 240 seconds]
chipotle has joined #ruby
fourq|away is now known as fourq
<arup_r> now I need some bad data.. to test if that works.. or not :) where i can get them..
<arup_r> any idea
<volty> fill yourself, write an InvalidUtf8Generator class
<volty> :)
rkazak has quit [Quit: Sleep.....ing....]
<arup_r> you are very smart.. :) I like you
rkazak has joined #ruby
<arup_r> any way, I am going to edit my csv add some junk data which that thoughtbot blog has.. and I will see if it works or not..
<arup_r> I am lazy! :(
<arup_r> I wrote too much code all day.. so.. now planning to sleep asap
<volty> me too, and fuzzy often
ympeg_ has joined #ruby
ohaibbq has joined #ruby
nanoz has quit [Read error: Connection reset by peer]
emilford has quit [Ping timeout: 265 seconds]
phoo1234567 has quit [Quit: Leaving]
futilegames has joined #ruby
ympeg has quit [Ping timeout: 264 seconds]
kalopsian has quit [Ping timeout: 255 seconds]
guacamole has quit [Quit: My face has gone to sleep. ZZZzzz…]
lucasb has quit [Ping timeout: 260 seconds]
dfinning_ has joined #ruby
kalopsian has joined #ruby
dfinninger has quit [Read error: Connection reset by peer]
sandstrom has quit [Quit: My computer has gone to sleep.]
krobzaur has joined #ruby
kith has joined #ruby
PedramT has joined #ruby
craysiii has joined #ruby
sandstrom has joined #ruby
dfinninger has joined #ruby
spooq|2 has joined #ruby
dfinninger has quit [Read error: Connection reset by peer]
dfinnin__ has joined #ruby
asmodlol has quit [Ping timeout: 265 seconds]
emilford has joined #ruby
spooq|2 has quit [Max SendQ exceeded]
PedramT_ has quit [Ping timeout: 260 seconds]
spooq|2 has joined #ruby
dfinning_ has quit [Ping timeout: 265 seconds]
arup_r has quit [Remote host closed the connection]
bluOxigen has quit [Ping timeout: 250 seconds]
spooq has quit [Ping timeout: 255 seconds]
dfinnin__ has quit [Remote host closed the connection]
PedramT has quit [Remote host closed the connection]
PedramT has joined #ruby
tuelz1 has joined #ruby
PedramT has quit [Remote host closed the connection]
nerium has joined #ruby
yardenbar has joined #ruby
ericfreese has joined #ruby
stevednd has quit [Ping timeout: 255 seconds]
einarj has joined #ruby
stevednd has joined #ruby
ericfreese has quit [Client Quit]
tuelz1 has quit [Ping timeout: 276 seconds]
griffindy has joined #ruby
ericfreese has joined #ruby
arup_r has joined #ruby
ericfreese has quit [Client Quit]
pyphile has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
nerium has quit [Ping timeout: 260 seconds]
nerium has joined #ruby
sdwrage_ has joined #ruby
Jardayn has joined #ruby
inukshuk_ has joined #ruby
ericfreese has joined #ruby
yardenbar has quit [Ping timeout: 255 seconds]
asmodlol has joined #ruby
sandstrom has joined #ruby
pyphile has left #ruby ["Leaving"]
PedramT has joined #ruby
inukshuk_ has quit [Client Quit]
kalopsian has quit [Ping timeout: 240 seconds]
kuon has quit [Ping timeout: 260 seconds]
<ericfreese> Hey ruby, I'm writing a gem that will have several bins that will interact, but only one bin needs to be on the user's path. Is there a best practice place to put the supporting bin scripts? or should they all just go in my_gem/bin
kalopsian has joined #ruby
lucasb has joined #ruby
futilegames has quit [Quit: futilegames]
<havenwood> ericfreese: If only one needs to be in PATH how are the others bins at all? Do put your executable in bin/ and add it to the executables list in the gemspec. Put supporting files in lib/ and require them from your executable.
emilford has quit [Ping timeout: 260 seconds]
northfurr has quit [Quit: northfurr]
nerium has quit [Read error: Connection reset by peer]
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
krobzaur has quit [Ping timeout: 260 seconds]
<ericfreese> havenwood: ok I think that makes sense thanks
sdwrage_ has quit [Quit: This computer has gone to sleep]
emilford has joined #ruby
kadoppe has quit [Ping timeout: 265 seconds]
blackmesa has quit [Ping timeout: 272 seconds]
Xeago has joined #ruby
kerunaru has quit [Quit: Textual IRC Client: www.textualapp.com]
nfk has joined #ruby
kadoppe has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
jackjackdripper has quit [Quit: Leaving.]
Xeago has quit [Remote host closed the connection]
sandstrom has joined #ruby
Xeago has joined #ruby
kalopsian has quit [Read error: Connection reset by peer]
futilegames has joined #ruby
kalopsian has joined #ruby
rkazak has quit [Quit: Sleep.....ing....]
dionysus69 has quit [Remote host closed the connection]
JohnT has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
dionysus69 has joined #ruby
dlitvak has joined #ruby
krobzaur has joined #ruby
chipotle has quit [Read error: Connection reset by peer]
Trieste has quit [Ping timeout: 264 seconds]
dlitvak has quit [Remote host closed the connection]
chipotle has joined #ruby
hannelita has joined #ruby
Trieste has joined #ruby
harai54 has joined #ruby
usershell has joined #ruby
haraigo has joined #ruby
chipotle has quit [Read error: Connection reset by peer]
emilford has quit [Ping timeout: 245 seconds]
emilford has joined #ruby
fedexo has joined #ruby
hannelita has quit [Ping timeout: 240 seconds]
chipotle has joined #ruby
harai54 has quit [Ping timeout: 260 seconds]
sandstrom has quit [Quit: My computer has gone to sleep.]
<apeiros> module Foo; using SomeRefinement; Bar = Struct.new(:a, :b) do self.wontwork; …; end; end; Foo::Bar.wontwork # -> raises a NoMethodError for wontwork
<apeiros> bug or not? IMO it's a bug
Jet4Fire has joined #ruby
<apeiros> same without `using SomeRefinement` works.
sandstrom has joined #ruby
<apeiros> I have to test though whether it only happens with a refinement targeting Struct (my case refines the Struct class among others)
JohnT has joined #ruby
yokel has quit [Ping timeout: 245 seconds]
chipotle has quit [Read error: Connection reset by peer]
chipotle has joined #ruby
yokel has joined #ruby
rkazak has joined #ruby
Channel6 has quit [Quit: Leaving]
m1dnight_ has joined #ruby
sdwrage_ has joined #ruby
kuon has joined #ruby
einarj has quit [Remote host closed the connection]
sftrabbit has quit [Quit: sftrabbit]
chipotle has quit [Read error: Connection reset by peer]
sdwrage_ has quit [Client Quit]
chipotle has joined #ruby
agentmeerkat has joined #ruby
<norc> apeiros, did you mean "def self.wontwork" ?
<apeiros> yes. it's a class method.
<apeiros> but same problem with instance methods.
<norc> Just asking because in your snippet you just called a method inside the block.
<apeiros> ah, I forgot the `def` in the example, yeah
<apeiros> module Foo; using SomeRefinement; Bar = Struct.new(:a, :b) do def self.wontwork; …; end; end; Foo::Bar.wontwork # -> raises a NoMethodError for wontwork
<apeiros> module Foo; using SomeRefinement; Bar = Struct.new(:a, :b) do def neitherdoesthis; …; end; end; Foo::Bar.new.neitherdoesthis # -> raises a NoMethodError for neitherdoesthis
<apeiros> corrected examples :)
Jet4Fire has quit []
marcdel has joined #ruby
usershell has quit [Remote host closed the connection]
marcdel has quit [Max SendQ exceeded]
casadei has joined #ruby
marcdel has joined #ruby
howdoi has quit [Quit: Connection closed for inactivity]
<norc> apeiros, works for me
<norc> which ruby version, and what is your refinement doing?
<lucasb> so, inside your module SomeRefinement, there's a 'refine Struct do ... end'?
sandstrom has quit [Quit: My computer has gone to sleep.]
yardenbar has joined #ruby
<apeiros> norc: 2.3, the refinement does a lot
<lucasb> apeiros: but it refines Struct too, right?
<apeiros> let me check, I'll try to create a reproduceable example
<apeiros> reproducible
sandstrom has joined #ruby
<apeiros> ah, speciality - I refine Struct.singleton_class
tuelz1 has joined #ruby
krobzaur has quit [Ping timeout: 255 seconds]
czsr has quit [Remote host closed the connection]
chipotle has quit [Read error: Connection reset by peer]
ohaibbq has quit [Remote host closed the connection]
<norc> apeiros, Struct is a rather special class to fiddle with though. :)
JohnT has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
chipotle has joined #ruby
Mackerel has joined #ruby
<apeiros> shouldn't matter for me as a user
<apeiros> as long as I don't fiddle in C :)
* norc has experience with that
usershell has joined #ruby
<norc> Last month I have segfaulted Ruby so many times... :)
<Mackerel> Hello
<norc> Hello Mackerel
<Mackerel> I want it on the record I know nothing of coding and starting off with Ruby.
<Mackerel> Thank you for having me.
<norc> It has been duely noted.
emilford_ has joined #ruby
<Mackerel> norc: Can I ask if you know what Cinchhrb is
govg has quit [Ping timeout: 264 seconds]
<norc> A what?
emilford has quit [Ping timeout: 245 seconds]
yardenbar has quit [Ping timeout: 260 seconds]
tuelz1 has quit [Ping timeout: 240 seconds]
<jhass> Mackerel: a Ruby framework (library) for writing IRC bots
kalopsian has quit [Ping timeout: 265 seconds]
Dicki has joined #ruby
kalopsian has joined #ruby
<Mackerel> jhass: Yes, I am making an IRC bot because I was told by someone this would make it easier for me.
ashemark has joined #ruby
<ashemark> Hi!
<norc> Hi ashemark.
<Mackerel> Hello.
sftrabbit has joined #ruby
<ashemark> what editor/ide do you use for ruby/sinatra/rails development?
<apeiros> hm, refining struct is not sufficient…
<Mackerel> Anyways I should continue with basic learning.
<apeiros> what on earth… but it fails when I use my other refinement…
<norc> ashemark, that is probably one of the worst topics to bring up in these IRC developer channels... :)
<ashemark> norc: that's probably one of the worse topics to be in a ruby developer's life... no editor/ide matches ruby's awesomeness...
<norc> You will have your vim people like me, others advertise emacs, then you have some TextMate or Sublime users, others use RubyMine
Dimik has quit [Ping timeout: 264 seconds]
Rinalds has joined #ruby
<shevy> vimsters!
<ashemark> ok..
<norc> ashemark, no, it is just that nothing good can come that question. :)
tubuliferous_ has quit [Ping timeout: 255 seconds]
<norc> Try out editors and pick one you like.
<shevy> ashemark you need a good brain, then the editor shall not matter
<jhass> ashemark: developer environments are like religions, try out a few, stay with what you like and don't talk about it :P
<norc> ^--
<shevy> ashemark jhass is using sublime!!!
<ashemark> ok
freerobby has quit [Quit: Leaving.]
<norc> ashemark, and if you want a real religion war going on, ask about "vi" or "emacs" - that is better than your worst religion discussion.
<apeiros> haha, ok, got the minimal case. it happens when you refine new
<apeiros> line 29 & 30 will fail
<apeiros> norc: ^
chipotle has quit [Read error: Connection reset by peer]
ferr has joined #ruby
tomeara has joined #ruby
<lucasb> apeiros: does it change the outcome if you put an argument list of (*members, &block) in both new methods?
chipotle has joined #ruby
<apeiros> lucasb: oh dear
<apeiros> lucasb: 100 internet points for you. that was the reason. silly me forgot to pass on the block.
agentmeerkat has quit [Ping timeout: 264 seconds]
<lucasb> apeiros: <3
<apeiros> thank you :D
jabreity__ has quit [Changing host]
jabreity__ has joined #ruby
jabreity__ has joined #ruby
jam_ has joined #ruby
Mackerel has quit [Quit: Page closed]
ashemark has left #ruby ["WeeChat 1.3"]
sandstrom has quit [Quit: My computer has gone to sleep.]
jabreity__ is now known as jabreity
sandstrom has joined #ruby
chipotle has quit [Read error: Connection reset by peer]
jam_ has quit [Ping timeout: 260 seconds]
marcdel has quit [Quit: Textual IRC Client: www.textualapp.com]
chipotle has joined #ruby
casadei has quit [Remote host closed the connection]
iamvery has quit [Ping timeout: 240 seconds]
PedramT has quit []
dlitvak has joined #ruby
marcdel has joined #ruby
lele has quit [Ping timeout: 240 seconds]
Dicki has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
usershell has quit [Remote host closed the connection]
Melpaws has quit [Ping timeout: 260 seconds]
Melpaws has joined #ruby
iamvery has joined #ruby
sftrabbit has quit [Quit: sftrabbit]
lele has joined #ruby
freerobby has joined #ruby
tmtwd has joined #ruby
dlitvak has quit [Ping timeout: 250 seconds]
futilegames has quit [Quit: futilegames]
bronson has joined #ruby
Xeago has quit [Remote host closed the connection]
czsr has joined #ruby
usershell has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
kuon has quit [Ping timeout: 240 seconds]
Dicki has joined #ruby
chipotle_ has joined #ruby
chipotle has quit [Read error: Connection reset by peer]
sandstrom has joined #ruby
hannelita has joined #ruby
marcdel has quit [Ping timeout: 276 seconds]
bronson has quit [Ping timeout: 265 seconds]
zeroDivisible has quit [Quit: WeeChat 1.3]
Dicki has quit [Client Quit]
marcdel has joined #ruby
Dicki has joined #ruby
hannelita has quit [Ping timeout: 240 seconds]
darkf has quit [Quit: Leaving]
Dicki has quit [Client Quit]
chipotle_ has quit [Read error: Connection reset by peer]
chipotle has joined #ruby
who42 has joined #ruby
ferr has quit [Quit: WeeChat 1.3]
Dicki has joined #ruby
ferr has joined #ruby
svkurowski has quit [Remote host closed the connection]
svkurowski has joined #ruby
Dicki has quit [Client Quit]
underplank has joined #ruby
|ifei5g00d has quit [Read error: Connection reset by peer]
Mon_Ouie has quit [Ping timeout: 265 seconds]
Dicki has joined #ruby
Dicki has quit [Client Quit]
sandstrom has quit [Quit: My computer has gone to sleep.]
jxs_ has quit [Ping timeout: 250 seconds]
sandstrom has joined #ruby
carraroj has joined #ruby
aryaching has quit [Read error: No route to host]
Xeago has joined #ruby
atomical has quit [Quit: Textual IRC Client: www.textualapp.com]
Dicki has joined #ruby
fedexo has quit [Remote host closed the connection]
tubuliferous_ has joined #ruby
spooq|2 has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
aryaching has joined #ruby
spooq|2 has joined #ruby
carraroj has quit [Client Quit]
<norc> apeiros, proving my point from yesterday exactly!
<norc> This magical block passing is just nonsense.
underplank has quit [Quit: underplank]
freerobby has quit [Quit: Leaving.]
carraroj has joined #ruby
<shevy> ruby is magic
chipotle has quit [Read error: Connection reset by peer]
ManUtd27 has joined #ruby
ericfreese has quit [Ping timeout: 256 seconds]
chipotle has joined #ruby
ManUtd27 has quit [Client Quit]
<apeiros> norc: huh? there was nothing magical there?
underplank has joined #ruby
tuelz1 has joined #ruby
Dicki has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
<norc> apeiros, oh you were not there right. My usual rant about blocks in Ruby.
tmtwd has quit [Ping timeout: 272 seconds]
<apeiros> I assume your rant was about super vs super() vs super(&nil)?
<norc> That rant was last month.
Meow-J has quit [Quit: Connection closed for inactivity]
<norc> Imo blocks should not be used outside stdlib and high performance cases.
djbkd has joined #ruby
* apeiros blinks
<apeiros> come again?
<norc> Heh :D
Dicki has joined #ruby
<norc> procs/lambda are much cleaner since they are obvious from the methods perspective that receives them
<apeiros> o0
<apeiros> you're referring to the distinction between Proc and block?
<norc> >> def foo; yield; end; foo { puts "foo" }
<ruby[bot]> norc: # => foo ...check link for more (https://eval.in/503155)
<norc> >> def foo(arg); arg.call; end; foo proc{ puts "foo }
<ruby[bot]> norc: # => /tmp/execpad-b6e6371ab501/source-b6e6371ab501:7: syntax error, unexpected keyword_end, expecting '}' ...check link for more (https://eval.in/503156)
<norc> >> def foo(arg); arg.call; end; foo proc{ puts "foo" }
<ruby[bot]> norc: # => foo ...check link for more (https://eval.in/503157)
tuelz1 has quit [Ping timeout: 260 seconds]
<norc> Try explaining the first one to newcomers and why it works.
<apeiros> dunno, I found that quite intuitive actually
Dicki has quit [Client Quit]
<apeiros> I mean, apart from having to learn the keywords yield & block_given?
sandstrom has quit [Quit: My computer has gone to sleep.]
<norc> These two are the same really, and the only advantage of using a block is that it is much faster in the creation
<apeiros> but yeah, I solved the issue differently in my language
tmtwd has joined #ruby
<apeiros> trying to remember the current state of block-arguments, but it looks about like this: .foo(arg: { code! }, arg2: { yay, more code! })
underplank has quit [Quit: underplank]
yfeldblum has joined #ruby
sandstrom has joined #ruby
<apeiros> it has an alternative syntax where you use indentation instead of {} :)
baweaver has joined #ruby
blackmesa has joined #ruby
Dicki has joined #ruby
BSaboia has quit [Read error: Connection reset by peer]
arup_r has quit []
Xeago has quit [Remote host closed the connection]
BSaboia has joined #ruby
rkazak has quit [Quit: Sleep.....ing....]
ericfreese has joined #ruby
cpup has quit [Ping timeout: 245 seconds]
_Tariq has joined #ruby
<_Tariq> How do you check if an instance variable is defined in a class?
<_Tariq> And the instance variable being queried is dynamic?
<adaedra> instance_variable_get
<_Tariq> Well, yes, but if it doesn't exist
<_Tariq> We get nil
<_Tariq> right?
twistedpixels has joined #ruby
<adaedra> yes
twistedpixels has quit [Changing host]
twistedpixels has joined #ruby
cpup has joined #ruby
<_Tariq> Hm.
<Radar> ?xy _Tariq
<ruby[bot]> _Tariq: it seems like you are asking for a specific solution to a problem, instead of asking about your problem. This often leads to bad solutions and increases frustration for you and those trying to help you. More: http://meta.stackexchange.com/a/66378
<adaedra> There's instance_variable_defined?, too.
<_Tariq> ruby[bot], that's because the actual problem itself is that I'm doing things the hard way
<Radar> _Tariq: ruby[bot] is a bot.
<Radar> _Tariq: It does not care.
<_Tariq> I know.
<Radar> _Tariq: And if you're not willing to explain the actual problem to us mere mortals then we're way less likely to help yoiu.
<Radar> _Tariq: And if it keeps up, then you'll find it a real struggle to get help in here.
<_Tariq> Right.
chipotle has quit [Read error: Connection reset by peer]
<_Tariq> But I got the answer to that problem per se.
<_Tariq> I am trying to build a FixedArray class, without using arrays
<_Tariq> So I'm using instance variables as indexes
<adaedra> o_O
chipotle has joined #ruby
<Radar> _Tariq: Show us what code you have so far? We can probably help then.
<_Tariq> Sure, give me a sec
<lucasb> what you mean? if the FixedArray has 5 elements, it will have 5 instance variables?
<apeiros> that… sounds wrong.
<apeiros> sooo sooo wrong
dlitvak has joined #ruby
<_Tariq> lucasb: Yes.
<_Tariq> Here we go.
<apeiros> _Tariq: I'm sorry, but that's probably one of the worst possible approaches to the problem
<_Tariq> Oh. Hm.
<_Tariq> Got it
<_Tariq> What would be a better approach?
<apeiros> wrap an array.
<_Tariq> ...that would defeat the purpose right?
<_Tariq> I'm trying to make an Array, so why would I create a new array?
<apeiros> the purpose is nonsensical.
<apeiros> that is, if the purpose is indeed "build it without using Array"
<_Tariq> Well, that is how I interpret the purpose.
<apeiros> is this a school assignment?
tuelz1 has joined #ruby
<_Tariq> Yeah.
<_Tariq> To help me learn algorithms.
* apeiros sobs
<apeiros> is that school teaching ruby or proglangs in general?
<_Tariq> It is teaching data structures and computer science basics.
<shevy> haha
Xeago has joined #ruby
<_Tariq> Anyway, this code does work.
<_Tariq> so thank you adaedra
<apeiros> _Tariq: ok, this exercise is badly suited for ruby
<apeiros> it makes sense in a language like C. but not in ruby.
<_Tariq> Yeah, I suspect that.
kobain has joined #ruby
<adaedra> _Tariq: pleasure to bring more evil in this sad world. /s
iskander has quit [Quit: Textual IRC Client: www.textualapp.com]
dlitvak has quit [Ping timeout: 256 seconds]
sandstrom has quit [Quit: My computer has gone to sleep.]
<apeiros> or rather: it probably only makes sense in languages with direct access to memory (or a simulation thereof)
JohnT has joined #ruby
chipotle has quit [Read error: Connection reset by peer]
chipotle has joined #ruby
tuelz1 has quit [Ping timeout: 250 seconds]
sandstrom has joined #ruby
Xeago has quit [Remote host closed the connection]
bithon has quit [Ping timeout: 246 seconds]
bottiger has quit [Quit: Page closed]
PaulCapestany has quit [Quit: .]
PaulCapestany has joined #ruby
emilford_ has quit [Ping timeout: 265 seconds]
agit0 has quit [Quit: zzzZZZ….]
tmtwd has quit [Ping timeout: 256 seconds]
gbgdev has joined #ruby
czsr has quit [Remote host closed the connection]
Nikola_ has joined #ruby
emilford has joined #ruby
dravine has quit [Quit: dravine]
carraroj has quit [Quit: Konversation terminated!]
Xeago has joined #ruby
jbrhbr has joined #ruby
underplank has joined #ruby
underplank has quit [Client Quit]
hannelita has joined #ruby
Nikola_ has quit [Ping timeout: 252 seconds]
Dicki has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
Xeago has quit [Remote host closed the connection]
Cohedrin has joined #ruby
Xeago has joined #ruby
emilford has quit [Ping timeout: 260 seconds]
Dicki has joined #ruby
sdwrage_ has joined #ruby
<norc> apeiros, honestly with lambda syntax its pretty elegant already in Ruby
<apeiros> ugly compared to block syntax :D
hannelita has quit [Ping timeout: 264 seconds]
sandstrom has quit [Quit: My computer has gone to sleep.]
usershell has quit [Remote host closed the connection]
emilford has joined #ruby
underplank has joined #ruby
<al2o3-cr> >> require 'fiddle'; include Fiddle; p = proc {}; p_id = p.__id__<<1; p_ptr = Pointer.new p_id; k_cls = [Kernel.__id__<<1].pack('q'); p_ptr[8,8] = k_cls; p.class
<ruby[bot]> al2o3-cr: # => Proc (https://eval.in/503172)
crdpink2 has joined #ruby
<al2o3-cr> How's this work
sandstrom has joined #ruby
kent\n has quit [Quit: have to turn off irc box for 1-3 weeks, bbs]
crdpink has quit [Ping timeout: 260 seconds]
sdwrage_ has quit [Quit: This computer has gone to sleep]
emilford has quit [Ping timeout: 240 seconds]
odulzaides_ has joined #ruby
codecop has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
aryaching has quit [Ping timeout: 260 seconds]
<odulzaides_> grep >
emilford has joined #ruby
Xeago has joined #ruby
underplank has quit [Quit: underplank]
_Tariq has quit [Remote host closed the connection]
<jhass> bash: syntax error near unexpected token `newline'
antgel has quit [Ping timeout: 265 seconds]
agit0 has joined #ruby
Xeago has quit [Ping timeout: 250 seconds]
guacamole has joined #ruby
chipotle has quit [Quit: cheerio]
Jackneill has quit [Ping timeout: 272 seconds]
FernandoBasso has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
<apeiros> al2o3-cr: duct-tape, pixie dust and some holy water
<al2o3-cr> :D
<apeiros> alternatively by accessing a specific memory region
<al2o3-cr> So VALUE is uint64_t?
<apeiros> it's a pointer
<apeiros> and in most rubies that'll be 64bit wide
sp4rrow has joined #ruby
sandstrom has joined #ruby
<al2o3-cr> I see
<al2o3-cr> So p_ptr[8,8] starts from 8 bytes along and grabs another 8 bytes?
Channel6 has joined #ruby
DavidJones has joined #ruby
<apeiros> I'd assume so
howdoicomputer has joined #ruby
puria has quit [Read error: Connection reset by peer]
colegatron has joined #ruby
Dicki has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
<al2o3-cr> ok, thanks
Matthew_ has joined #ruby
DavidJones has quit []
Matthew_ has left #ruby [#ruby]
casadei has joined #ruby
Xeago has joined #ruby
Dicki has joined #ruby
centrx has joined #ruby
spstarr has left #ruby ["Leaving"]
<al2o3-cr> frosties are greaaAATTT... i mean fiddle
bruce__lee has quit [Remote host closed the connection]
underplank has joined #ruby
kalopsian has quit [Ping timeout: 255 seconds]
solars has joined #ruby
<shevy> lol
Dicki has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
Dicki has joined #ruby
tubuliferous_ has quit [Ping timeout: 260 seconds]
wolffles has joined #ruby
gbgdev has quit [Remote host closed the connection]
sandstrom has quit [Quit: My computer has gone to sleep.]
colegatron has quit [Ping timeout: 260 seconds]
sandstrom has joined #ruby
<wolffles> would anyone like rate my code and give me some pointers on style or tricks? https://eval.in/503179
janebootydoe has joined #ruby
janebootydoe has quit [Max SendQ exceeded]
janebootydoe has joined #ruby
DLSteve has joined #ruby
guacamole has quit [Quit: My face has gone to sleep. ZZZzzz…]
<shevy> needs more waffles
<wolffles> more of what?
<shevy> your indent seems weird
<al2o3-cr> wolffles: fibanacci(0) return 2
Channel6 has quit [Quit: Leaving]
<wolffles> its cuz i tweaked it so much @shevy
bkxd has joined #ruby
<wolffles> took me a while to even get the proper solution
tuelz1 has joined #ruby
Yzguy has joined #ruby
<wolffles> al2o3-cr: i didnt know how to start the sequence off
<wolffles> so i di fib = [1,2] but should i just have a conditional if n = 0 ?
Dicki has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
<al2o3-cr> wolffles: just add `return n if [0,1].include? n`
<al2o3-cr> or something like this
RaceCondition has left #ruby ["Textual IRC Client: www.textualapp.com"]
robbyoconnor has quit [Ping timeout: 276 seconds]
Dicki has joined #ruby
<al2o3-cr> should look at the code closely first :/
<al2o3-cr> wolffles: what you doing a code quiz or something?
newbie22 has joined #ruby
<wolffles> is that a rookie mistake? in the professional world would that cause major problems?
tuelz1 has quit [Ping timeout: 264 seconds]
bkxd has quit [Ping timeout: 272 seconds]
<newbie22> *: what is the difference between ruby and ruby on rails
<wolffles> im doing practice problems projecteuler.net
<newbie22> *:??
bkxd has joined #ruby
solars has quit [Ping timeout: 240 seconds]
<al2o3-cr> wolffles: oh, nice :)
<al2o3-cr> newbie22: rails is a framework written in ruby
<wolffles> specifically for web applications right?
marcdel has quit [Ping timeout: 246 seconds]
Xiti has quit [Quit: Xiti]
<al2o3-cr> wolffles: yep
colegatron has joined #ruby
kuon has joined #ruby
guacamole has joined #ruby
newbie22 has quit [Quit: Leaving]
marcdel has joined #ruby
<awox> is anyone aware of any libraries that involve building a nested query structure in xml?
sandstrom has quit [Quit: My computer has gone to sleep.]
sp4rrow has quit [Quit: Textual IRC Client: www.textualapp.com]
underplank has quit [Quit: underplank]
sandstrom has joined #ruby
kuon has quit [Ping timeout: 272 seconds]
Xeago has quit [Remote host closed the connection]
underplank has joined #ruby
Xiti has joined #ruby
sdwrage_ has joined #ruby
n00bdev has joined #ruby
hannelita has joined #ruby
<apeiros> awox: is "nested query structure in xml" verbose for "xml"?
sdwrage_ has quit [Client Quit]
BrunoSaboia has joined #ruby
blur3d has joined #ruby
<lucasb> maybe he meant xpath
hannelita has quit [Ping timeout: 240 seconds]
Yzguy has quit [Quit: Zzz...]
BSaboia has quit [Ping timeout: 276 seconds]
<apeiros> possible. I shall wait for their reply.
zenlot1 has joined #ruby
<lucasb> I shall do the same
<apeiros> though, the 10min threshold will soon have passed
zenlot has quit [Ping timeout: 256 seconds]
janebootydoe has quit [Quit: Leaving]
underplank has quit [Quit: underplank]
<awox> Sorry for the late response.
al2o3-cr has quit [Ping timeout: 260 seconds]
yqt has joined #ruby
centrx has quit [Remote host closed the connection]
<awox> I am working with an API that takes something like <queryxml><condition><field ../></condition></queryxml>
<awox> except the condition/field portions can be nested to group conditions or do ORs
ympeg_ has quit [Ping timeout: 246 seconds]
Dicki has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
zacts has quit [Quit: leaving]
Yzguy has joined #ruby
Xeago has joined #ruby
tubuliferous_ has joined #ruby
Xeago has quit [Remote host closed the connection]
sandstrom has quit [Quit: My computer has gone to sleep.]
sandstrom has joined #ruby
duoi has quit [Remote host closed the connection]
tubuliferous_ has quit [Ping timeout: 246 seconds]
zacts has joined #ruby
mistermocha has joined #ruby
vikas027 has joined #ruby
marr has joined #ruby
marcdel has quit [Ping timeout: 245 seconds]
bkxd has quit [Ping timeout: 260 seconds]
karapetyan has joined #ruby
Azure has quit [Ping timeout: 260 seconds]
ericfreese has quit [Ping timeout: 246 seconds]
BrunoSaboia has quit [Quit: Leaving]
bkxd has joined #ruby
Azure has joined #ruby
griffindy has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
who42 has quit [Ping timeout: 245 seconds]
mistermocha has quit [Remote host closed the connection]
sandstrom has quit [Quit: My computer has gone to sleep.]
guacamole has quit [Quit: My face has gone to sleep. ZZZzzz…]
Darmani has joined #ruby
sandstrom has joined #ruby
chipotle has joined #ruby
<apeiros> huh? didn't recently a uniq_by method get added to ruby?
<apeiros> ah, uniq takes a block now.
symm- has quit [Read error: Connection reset by peer]
symm- has joined #ruby
underplank has joined #ruby
Cyrus has joined #ruby
chipotle_ has joined #ruby
odulzaides_ has quit [Quit: ChatZilla 0.9.92 [Firefox 42.0/20151029151421]]
chipotle has quit [Read error: Connection reset by peer]
<Radar> awox: look at Nokogiri. It has a good builder for that.
Dimik has joined #ruby
<awox> Radar, I did, but I couldn't really wrap my head around working with the objects
<awox> I'm finding much better examples for Lib::XML and using XML::Node
sftrabbit has joined #ruby
corecode has joined #ruby
<corecode> hi
tubuliferous_ has joined #ruby
<corecode> oh, the channel name changed?
jbrhbr has quit [Quit: Leaving.]
tuelz1 has joined #ruby
<adaedra> You're looking for #ruby-lang?
<adaedra> It merged with #ruby months ago
<corecode> nice
<corecode> what's the suggested way to get a fresh variable in a loop? i have something of the sort ... while some_cond; obj << queue; set_callback{ obj.foo }; end
jam_ has joined #ruby
<corecode> but obj in the callback refers to the last value of obj the loop
sandstrom has quit [Quit: My computer has gone to sleep.]
ghox has joined #ruby
<volty> and you need the previous one ?
northfurr has joined #ruby
<volty> ops, distract
sandstrom has joined #ruby
djbkd has quit [Remote host closed the connection]
<corecode> well, the value as it was when i call set_callback
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
tuelz1 has quit [Ping timeout: 260 seconds]
<volty> sorry, I can't get it
haraigo has quit [Ping timeout: 240 seconds]
jam_ has quit [Ping timeout: 240 seconds]
jbrhbr has joined #ruby
haraigo has joined #ruby
emilford has quit [Ping timeout: 260 seconds]
northfurr has quit [Client Quit]
djbkd has joined #ruby
ferr has quit [Ping timeout: 246 seconds]
underplank has quit [Quit: underplank]
haraigoshi has joined #ruby
<corecode> volty: http://ideone.com/jJw1Sw
ixti has joined #ruby
haraigo has quit [Ping timeout: 264 seconds]
Yzguy has quit [Ping timeout: 276 seconds]
<lucasb> maybe you could try: cb << lambda { inval.shift }
<lucasb> but that doesn't fix your original problem
<corecode> no.
<corecode> this just illustrates the problem
hannelita has joined #ruby
<corecode> i need to create a new scope
<adaedra> don't mutate obj, create a new one
<apeiros> cb << ->(inner) { lambda { inner } }.call(val)
<apeiros> adaedra: problem is their closure over val
<corecode> yea, ugly :/
<apeiros> all callbacks will point to the last iteration's val's object
blackmesa has quit [Ping timeout: 264 seconds]
<adaedra> yeah, should not happen if they use obj = something instead of #<< ?
<corecode> so only a lambda gives me a new scope?
<apeiros> corecode: the other option is a method for those two lines in the loop
<apeiros> add_cb(cbs, inval.shift) -> def add_cb(cbs, val); lambda { val }; end
<apeiros> forgot the `cbs <<`
hannelita has quit [Ping timeout: 255 seconds]
<lucasb> 1.times do |;val| val = ... end
kuon has joined #ruby
<adaedra> wouldn't `obj.clone.tap { |o| set_callback { o.foo } }` do what you want?
<awox> .::
<awox> ?::
al2o3-cr has joined #ruby
<awox> can someone tell me why modules use :: instead of .?
arob has quit [Ping timeout: 246 seconds]
diegoviola has joined #ruby
<adaedra> :: is used for constant resolution, . for method resolution, usually
<apeiros> adaedra: that usually belongs to :: ;-)
<adaedra> ?
<awox> hm, okay
<apeiros> :: is usually used for constant resolution
sankaber has joined #ruby
<apeiros> can be used for method invocation too. but really, don't do that.
<apeiros> . otoh can't be used for constant resolution.
Danishman has quit [Quit: KVIrc 4.9.1 Aria http://www.kvirc.net/]
rkazak has joined #ruby
robbyoconnor has joined #ruby
DLSteve has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
bkxd_ has joined #ruby
<awox> so, say I import a module, and it has like 'QueryXML.if_' as a method, can I import that module's items to the current scope?
<awox> i.e. from queryxml import *?
<apeiros> awox: the terminology 'import' is not used in ruby
<apeiros> you require/load files
<apeiros> you include/extend/prepend modules
<awox> sorry, say I require that module :P
<lucasb> modules can have module methods and instance methods
<apeiros> you can't require a module ;-)
<awox> okay, say I have required a file that happens to have a module in it
blackmesa has joined #ruby
<adaedra> I think they want to import module methods into global scope
dionysus69 has quit [Ping timeout: 260 seconds]
<awox> can I create a short-hand to the module's methods?
<apeiros> awox: anyway - say you required a file which contains a module - you can use include to have its methods in the toplevel scope f.ex.
tubuliferous_ has quit [Ping timeout: 260 seconds]
tenderlove has quit [Quit: Leaving...]
<apeiros> >> include Math; sin(PI)
<ruby[bot]> apeiros: # => 1.2246063538223773e-16 (https://eval.in/503192)
northfurr has joined #ruby
<apeiros> important: Math.sin() is not the same method as the one called via `include Math; sin()`
<apeiros> Math uses module_function to have both, Math#sin and Math::sin
casadei has quit [Remote host closed the connection]
bkxd has quit [Ping timeout: 246 seconds]
<apeiros> a pattern which you should use too if the method makes no use of self (i.e. is a pseudo-function)
northfurr has quit [Client Quit]
<lucasb> but if the module used 'def self.foo', does foo gets included in my scope too?
<lucasb> (ok, I can try myself :)
<apeiros> no
<lucasb> apeiros: ok, thanks
<apeiros> include/extend/append only deal with instance methods and constants
northfurr has joined #ruby
dlitvak has joined #ruby
<awox> woo. my first crappy ruby module. :O
karapetyan has quit [Remote host closed the connection]
krobzaur has joined #ruby
karapetyan has joined #ruby
<apeiros> s/append/prepend/
<apeiros> almost did that mistake on the first time I said it too… weird.
dlitvak has quit [Remote host closed the connection]
northfurr has quit [Client Quit]
northfurr has joined #ruby
solocshaw has joined #ruby
<lucasb> just going back to that closure problem. I think I settled on wrapping everything in '1.times do ... end' as the best option. do you agree?