apeiros changed the topic of #ruby to: Ruby 2.1.0; 2.0.0-p353; 1.9.3-p484: http://ruby-lang.org || Paste >3 lines of text on http://gist.github.com || this channel is logged at http://irclog.whitequark.org, other public logging is prohibited
<razrunelord> apeiros: good catch
<razrunelord> apeiros: need a guard clause for that
<apeiros> and you'll get each pair twice, once as [a,b] and once as [b,a]
<nhmood> Is there anyway to do an augmented assignment of a ternary operator?
<nhmood> i.e. my_var = myvar ? true : false
<apeiros> nhmood: hm? that should work fine, why?
msmith has quit [Remote host closed the connection]
alexherbo2 has quit [Quit: WeeChat 0.4.3-dev]
danshultz has quit [Ping timeout: 265 seconds]
<nhmood> apeiros: I know it works fine, I'm just wondering if there is a more concise syntax for it
<nhmood> apeiros: that is always how i've done it but I'm wondering if there is some ruby magic lol
<apeiros> btw. razrunelord: getting the pairs twice might provide a way to improve performance
jonr22 has joined #ruby
stephenmac7 has joined #ruby
Sawbones has joined #ruby
slowcon has quit [Ping timeout: 265 seconds]
<stephenmac7> What is the difference between class AlreadyDefinedClass
<stephenmac7> And class << AlreadyDefinedClass
<razrunelord> apeiros: Do you think sorting the array would be useful?
<razrunelord> apeiros: before iterating, that is
<apeiros> razrunelord: sorting is O(nlogn)
aspires has joined #ruby
tyl has quit [Ping timeout: 252 seconds]
randomnick_ has quit [Quit: Leaving]
yasushi has joined #ruby
<apeiros> stephenmac7: `class << obj` opens the singleton class of obj
<apeiros> which is where methods immediately callable on obj reside.
dubsteph has quit [Ping timeout: 245 seconds]
<apeiros> most common of them: class methods.
RoryHughes has quit []
<itadder> hi
<itadder> what is inst_section[:cello] #=> "String" this bit of code doing in my hash
<stephenmac7> apeiros: So, it allows you to change the object directly, rather than the class?
<itadder> it is to output what value this key has
ndrei has joined #ruby
<apeiros> stephenmac7: depends on the implementation. and/or how you view it.
<stephenmac7> CRuby
<itadder> ruby
Sawbones has quit [Ping timeout: 265 seconds]
sethen has joined #ruby
<apeiros> not sure how it's implemented there. I think it's separate from the object.
burgess has quit [Quit: ^zzz]
<apeiros> but well, given that obj is not the same as obj.singleton_class, I'd say no
<stephenmac7> Well, it might help if I know what a singleton class is
axl_ has joined #ruby
<apeiros> stephenmac7: as I said, a special class where methods directly callable on the object reside.
danshultz has joined #ruby
<apeiros> and those methods belong only to that single object
mojjojo has quit [Quit: mojjojo]
<apeiros> >> x = "hi"; def x.foo; "foo"; end; x.foo
<eval-in> apeiros => "foo" (https://eval.in/102541)
<apeiros> >> x = "hi"; def x.foo; "foo"; end; "some other string".foo
<eval-in> apeiros => undefined method `foo' for "some other string":String (NoMethodError) ... (https://eval.in/102542)
freezey has quit [Ping timeout: 260 seconds]
<apeiros> `def x.foo…end` is a short form for `class << x; def foo…end; end`
yasushi has quit [Ping timeout: 260 seconds]
Zunonia has joined #ruby
<apeiros> if you've seen class methods being defined as `def self.foo…end`, that's exactly that.
jzig has joined #ruby
<stephenmac7> So, it's like every method is defined in when using Lua
<stephenmac7> function MyTable:somemethod()...end
<itadder> how come when I the code thru IRB it shows me output but when I turn via ruby symbolsprog1.rb I don't get the output
<stephenmac7> Rather than putting somemethod directly in the class definition
<stephenmac7> Correct, apeiros?
ephemerian has quit [Read error: Connection reset by peer]
<itadder> same thing happens when I do command b
<itadder> in sublimetext
<apeiros> stephenmac7: I don't know lua
<stephenmac7> apeiros: So, basically it allows you to add another method (or edit an existing method) of an existing class
RoryHughes has joined #ruby
<apeiros> stephenmac7: that's true for all classes. no, the center point is that it allows you to add methods to a single object.
danshultz has quit [Remote host closed the connection]
<stephenmac7> Okay
<apeiros> instead of to all instances of a class.
<stephenmac7> Okay, got it.
petey_ has quit [Remote host closed the connection]
danshultz has joined #ruby
Hiall has joined #ruby
pwh has quit []
petey has joined #ruby
mojjojo has joined #ruby
zz_jrhorn424 is now known as jrhorn424
LiohAu has quit [Ping timeout: 245 seconds]
mocfive has quit [Remote host closed the connection]
LexicalScope has quit [Ping timeout: 260 seconds]
mocfive has joined #ruby
jobewan has quit [Quit: Leaving]
srji_ has joined #ruby
cmoylan has quit [Ping timeout: 260 seconds]
jzig has quit [Ping timeout: 260 seconds]
kristiandelay has joined #ruby
elaptics is now known as elaptics`away
meatherly has joined #ruby
danshultz has quit [Ping timeout: 260 seconds]
petey has quit [Ping timeout: 264 seconds]
predator217 has joined #ruby
srji has quit [Ping timeout: 252 seconds]
vlad_starkov has quit [Ping timeout: 260 seconds]
mocfive has quit [Ping timeout: 265 seconds]
danshultz has joined #ruby
mocfive has joined #ruby
confounds has joined #ruby
kristiandelay has quit [Ping timeout: 252 seconds]
<itadder> netsplit
meatherly has quit [Ping timeout: 260 seconds]
predator117 has quit [Ping timeout: 272 seconds]
Hobogrammer_ has joined #ruby
mushky has quit [Quit: mushky]
carif has quit [Quit: Ex-Chat]
ktosiek has quit [Ping timeout: 252 seconds]
angusiguess has joined #ruby
thesheff17 has joined #ruby
xcv has joined #ruby
hamakn has quit [Remote host closed the connection]
blackmesa has quit [Quit: WeeChat 0.4.2]
Hobogrammer has quit [Ping timeout: 245 seconds]
jonah_k has quit [Remote host closed the connection]
angusiguess has quit [Ping timeout: 245 seconds]
arianit has quit [Quit: Leaving]
jonah_k has joined #ruby
Aryasam has quit [Quit: Bye]
Aryasam has joined #ruby
zz_karupanerura is now known as karupanerura
aspires has quit []
korzybski has joined #ruby
rootshift_ has joined #ruby
<korzybski> hi all
rootshift_ is now known as rootshift
firefly20131 has joined #ruby
RoryHughes has quit []
jbueza has quit [Quit: Textual IRC Client: www.textualapp.com]
postmodern has joined #ruby
slowcon has joined #ruby
pel_daniel has left #ruby [#ruby]
wallerdev has quit [Quit: wallerdev]
firefly2013 has quit [Ping timeout: 272 seconds]
fgo has joined #ruby
venkat_ has quit [Remote host closed the connection]
sukima has joined #ruby
<lagweezle> itadder: Do you actually have any 'puts' or other output calls in whatever symbolsprog1.rb is?
venkat_ has joined #ruby
<itadder> lagweezle: nope
slowcon has quit [Client Quit]
<itadder> wow I just wrote my frist hash table
<sukima> How do you run a command (foreman start) and NOT have it terminate when the parent recieves a SIGINT?
zastern has quit [Quit: WeeChat 0.4.2]
<itadder> https://gist.github.com/anonymous/0d23ef1362104e854aad <-- This is symbolsprog1.rb
<lagweezle> itadder: If you are executing code w/o a puts or other output to screen type call, you won't see any output.
<lagweezle> Ah.
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Hanmac has joined #ruby
firefly2013 has joined #ruby
<itadder> https://gist.github.com/anonymous/385a07a31a78a55f96e6 now this is my first hash table <---
<itadder> lagweezle: ahh
<itadder> so why does irb excute it
sski has joined #ruby
<itadder> is irb just going step by step
<lagweezle> "Wille Nelson is both Country and Rock Music" <-- that is the only thing you should see output normally.
<sukima> exec("foreman start > log 2>&1") if fork == nil will kill the process if the user presses CTRL-C I don't want that.
charliesome has joined #ruby
<lagweezle> irb is indeed giving you the result of everything that is run.
firefly20131 has quit [Ping timeout: 248 seconds]
<itadder> ahh that is different then just ruby somecode.rb
<lagweezle> very
<itadder> ahh wow I just understand simple hash table
<lagweezle> woot :)
<itadder> and wrote my first program Holly cow
<itadder> simple
Hanmac1 has quit [Ping timeout: 245 seconds]
<itadder> why does sublime text auto completes some code but not all
gnephiak has joined #ruby
<itadder> not code by things I am typing
<lagweezle> It auto-compeltes things it has seen in your code.
meatherly has joined #ruby
<itadder> for example #{inst_genere[:Outlaw].capitalize}
slowcon has joined #ruby
<itadder> it won't autocomplete .capitalize
kennym_ has quit [Remote host closed the connection]
cgcardona_ has joined #ruby
<itadder> not becuase I am lazy but becuase I suck at spelling
lmickh has quit [Remote host closed the connection]
<itadder> because HEHEH
venkat_ has quit [Ping timeout: 260 seconds]
<lagweezle> hehe
<itadder> oh I see if it seen capitlize before it will start using it
<lagweezle> Generally, yeah, that seems to be how it works.
<itadder> but that part of the ruby lang, becuase it does other things like {} or []
sski has quit [Client Quit]
jonr22 has quit [Remote host closed the connection]
<lagweezle> Yeah. It has a few things already in it's brain. I definitely don't understand the full rules.
<itadder> so it not like a IDE that will tell me what choses I have. I know with Powershell ISE which I used in the past, that I have been able to use that
sski has joined #ruby
sdwrage has quit [Quit: This computer has gone to sleep]
<itadder> lagweezle: Ahh thanks lagweezle your the best :)
<itadder> let me keep going
jonr22 has joined #ruby
<itadder> 10 more minutes and then I am done for today, I have to drive back home and work tomorrow.
angusiguess has joined #ruby
<itadder> I think TOmorrow for the first time in a long time I will go to GYM first then Work
PistDov has joined #ruby
PistDov has left #ruby [#ruby]
<itadder> Oh and I found under my bed my fitbit flex this device rules....
<itadder> so lagweezle doing some examples and then making my own code from them is great way to learn right
meatherly has quit [Ping timeout: 265 seconds]
Columcille has quit [Quit: leaving]
jonr22 has quit [Read error: Operation timed out]
Kricir has joined #ruby
kennym has joined #ruby
kennym has joined #ruby
kennym has quit [Changing host]
speakingcode has joined #ruby
Sawbones has joined #ruby
shawnjgoff has quit [Ping timeout: 252 seconds]
jpinnix_ has quit [Ping timeout: 245 seconds]
meinside has quit [Ping timeout: 245 seconds]
Guest85414______ has quit [Ping timeout: 245 seconds]
tyl has joined #ruby
mikecmpbll has quit [Quit: i've nodded off.]
Wolland has joined #ruby
pedda has quit [Quit: Textual IRC Client: www.textualapp.com]
jpinnix_ has joined #ruby
Kricir has quit [Ping timeout: 252 seconds]
meinside has joined #ruby
xcv has quit [Remote host closed the connection]
Guest85414______ has joined #ruby
mojjojo has quit [Quit: mojjojo]
raphaelivan1 has quit [Read error: No route to host]
tylersmith has quit [Remote host closed the connection]
pwh has joined #ruby
Sc0rp10n has quit [Quit: Leaving]
Sawbones has quit [Ping timeout: 260 seconds]
surtin has joined #ruby
tkuchiki has joined #ruby
surtin has quit [Client Quit]
Wolland has quit [Ping timeout: 264 seconds]
mikepack has joined #ruby
freezey has joined #ruby
robustus has quit [Ping timeout: 245 seconds]
freezey has quit [Read error: Connection reset by peer]
shadoi has quit [Quit: Leaving.]
freezey has joined #ruby
shadoi has joined #ruby
lukec has quit [Quit: lukec]
robustus has joined #ruby
korzybski has quit [Quit: korzybski]
<lagweezle> A pretty good way, yeah. With programming, doing seems to be required, ultimately, to /actually/ understand any of it.
Sawbones has joined #ruby
<lagweezle> The whole process will never end, but doing will get you there faster.
<lagweezle> That only kind of makes sense the way I wrote it. .. :/
RoxasShadowRS has quit [Quit: Leaving]
Sawbones has quit [Remote host closed the connection]
venkat_ has joined #ruby
ndrei has quit [Ping timeout: 265 seconds]
mushky has joined #ruby
sdwrage has joined #ruby
Sawbones has joined #ruby
vlad_starkov has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
sukima has left #ruby [#ruby]
knigitz has joined #ruby
confounds has quit [Ping timeout: 265 seconds]
mocfive has quit [Remote host closed the connection]
lyanchih has joined #ruby
Shidash has quit [Ping timeout: 252 seconds]
mocfive has joined #ruby
necrotic_ has joined #ruby
necrotic_ has quit [Remote host closed the connection]
iliketur_ has quit [Quit: zzzzz…..]
gwz has joined #ruby
<gwz> hey is it possible to get indexes of all max values in array
nfk has quit [Quit: yawn]
telling has quit [Ping timeout: 272 seconds]
Lewix has joined #ruby
mocfive has quit [Ping timeout: 245 seconds]
venkat_ has quit [Remote host closed the connection]
venkat_ has joined #ruby
burlyscudd has quit [Quit: Leaving.]
rootshift has quit [Quit: My MacBook has decided to go to sleep. Zzzz..]
Sawbones has quit [Remote host closed the connection]
marr has quit [Ping timeout: 265 seconds]
Sawbones has joined #ruby
<centrx> gwz, It is possible, but there is probably a better way to do what you are doing overall
jcs222 has joined #ruby
recurrence has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
venkat_ has quit [Ping timeout: 245 seconds]
shadoi has quit [Quit: Leaving.]
Wolland has joined #ruby
mocfive has joined #ruby
* centrx has noticed that Ruby 2.1 seems to be about 25% faster than Ruby 2.0
btanaka has joined #ruby
telling has joined #ruby
<RubyPanther> gwz: what does that even mean?
jcs222 has quit [Quit: Page closed]
Wolland has quit [Read error: Connection reset by peer]
Wolland_ has joined #ruby
Sawbones has quit [Ping timeout: 240 seconds]
cmoylan has joined #ruby
Zunonia has quit [Ping timeout: 260 seconds]
SilentHobo has joined #ruby
slowcon has quit [Quit: slowcon]
jonah_k has quit [Remote host closed the connection]
snath has quit [Ping timeout: 245 seconds]
Zunonia has joined #ruby
Hobogrammer_ has quit [Ping timeout: 248 seconds]
itadder has quit [Remote host closed the connection]
hamakn has joined #ruby
dubsteph has joined #ruby
itadder has joined #ruby
trhodes_ has joined #ruby
[krisbulman] is now known as krisbulman
senayar has quit []
trhodes has quit [Ping timeout: 245 seconds]
tyl has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
andy has joined #ruby
wallerdev has joined #ruby
slowcon has joined #ruby
dkamioka has quit [Remote host closed the connection]
<gwz> is there a reason why a ruby script wont work on linux but works fine on windows
<gwz> i ahve added the /usr/bin/env ruby
dubsteph has quit [Ping timeout: 240 seconds]
itadder has quit [Ping timeout: 252 seconds]
<centrx> Works for me
kenndel_ has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
kenndel_ has joined #ruby
jonr22 has joined #ruby
sparrovv has quit [Remote host closed the connection]
koell has quit [Read error: Connection reset by peer]
danshultz has quit [Remote host closed the connection]
<pipework> gwz: Why wouldn't it be possible?
meatherly has joined #ruby
<gwz> well I have a progrma which worked fine on windows but when I took it to linux, its complaining about `block in <main>': undefined method `[]=' for nil:NilClass (NoMethodError) but when I give it the same input on windows, it works
btanaka has quit [Quit: Leaving]
<RubyPanther> Throw a rubber chicken at your Saint Ignucius idol and try again
Kricir has joined #ruby
meatherly has quit [Read error: Connection reset by peer]
<RubyPanther> If that fails, ponder: was your input really nil on windoze?
diegoviola has joined #ruby
meatherly has joined #ruby
<RubyPanther> and were you really calling #[]= on it?
<gwz> actually, I see that i have ; in arguments which makes it end prematurly on linux
vlad_starkov has quit [Ping timeout: 260 seconds]
<pipework> gwz: So you're doing something wrong probably.
<gwz> so argv[0] ends at the first ; instead of reading the whole string
monkegjinni has quit [Ping timeout: 265 seconds]
<pipework> I can't really tell without code.
iliketurtles has joined #ruby
<RubyPanther> You're generally expected to quote data arguments, only use bareword arguments where they are --options-that-follow="normal rules"
<gwz> ahhh there we go
<gwz> it was just the quotes
<gwz> thanks
snath has joined #ruby
meatherly has quit [Ping timeout: 245 seconds]
chrisseaton has joined #ruby
tungd has joined #ruby
m00nlight has joined #ruby
LexicalScope has joined #ruby
geggam has joined #ruby
Mongey has joined #ruby
bklane has quit [Remote host closed the connection]
mikepack has quit [Remote host closed the connection]
bklane has joined #ruby
razrunelord has quit []
andy has quit [Remote host closed the connection]
shawnjgoff has joined #ruby
Mongey has quit [Quit: Mongey]
abra has quit [Quit: Textual IRC Client: www.textualapp.com]
freezey has quit [Remote host closed the connection]
abra has joined #ruby
eka has quit [Quit: My computer has gone to sleep. ZZZzzz…]
bklane has quit [Ping timeout: 265 seconds]
slowcon has quit [Quit: slowcon]
Wolland_ has quit [Ping timeout: 240 seconds]
venkat_ has joined #ruby
confounds has joined #ruby
axl_ has quit [Quit: axl_]
<mostlybadfly> HI all. could someone help explain this ? http://pastebin.com/DSj0HbzG
<mostlybadfly> specifically the line words.each { |word| frequencies[word] += 1 }
<centrx> It is source code in the Ruby programming language
<chrisseaton> mostlybadfly: for each word in the array of words, increment the frequency (number of occurencies seen) of that word
speakingcode has quit [Ping timeout: 260 seconds]
<mostlybadfly> I know what it does but I'm curious as to how it is actually assigning a value to the key in the hash
<mostlybadfly> hmmm
<chrisseaton> mostlybadfly: it's syntactic sugar for frequencies[word] = frequencies[word] + 1
<chrisseaton> mostlybadfly: and you set a default value when you instantiate the hash, so all words are found in the hash
msmith has joined #ruby
tylersmith has joined #ruby
krisbulman is now known as [krisbulman]
troyready has quit [Ping timeout: 248 seconds]
Hanmac1 has joined #ruby
<mostlybadfly> thanks chrisseaton
abra has quit [Quit: Textual IRC Client: www.textualapp.com]
freezey has joined #ruby
Hanmac has quit [Ping timeout: 264 seconds]
freezey has quit [Read error: Connection reset by peer]
Hanmac has joined #ruby
freezey has joined #ruby
vlad_starkov has joined #ruby
tylersmith has quit [Ping timeout: 245 seconds]
petey has joined #ruby
Hanmac1 has quit [Ping timeout: 240 seconds]
eka has joined #ruby
kristiandelay has joined #ruby
jrhorn424 is now known as zz_jrhorn424
amclain has joined #ruby
kevinykchan has quit [Read error: Connection reset by peer]
rafaelmagu has quit [Quit: Textual IRC Client: www.textualapp.com]
kevinykchan has joined #ruby
petey has quit [Ping timeout: 260 seconds]
eka has quit [Ping timeout: 256 seconds]
havenwood has quit [Remote host closed the connection]
kristiandelay has quit [Ping timeout: 260 seconds]
funburn has joined #ruby
snuffeluffegus has joined #ruby
P1RATEZ has joined #ruby
snuffeluffegus has quit [Client Quit]
havenwood has joined #ruby
meatherly has joined #ruby
apeiros has quit [Remote host closed the connection]
sepp2k has quit [Read error: Connection reset by peer]
apeiros has joined #ruby
<benzrf> whoa
<centrx> whoa
Wolland has joined #ruby
sailias has quit [Quit: Leaving.]
<benzrf> sup
fijimunkii has quit [Ping timeout: 260 seconds]
<centrx> I am going to show pipework why I won all those awards and certificates
<pipework> centrx: You mix up channels a lot.
OrangejuiceJames has joined #ruby
<centrx> It's one big happy channel!
Wolland has quit [Read error: Connection reset by peer]
<pipework> k
SilentHobo is now known as Hobogrammer
chrisseaton has quit []
Wolland has joined #ruby
m104 has joined #ruby
subbyyy has joined #ruby
mikepack has joined #ruby
[gmi] has quit [Read error: Connection reset by peer]
sensen has joined #ruby
bklane has joined #ruby
maroloccio has quit [Quit: WeeChat 0.4.2]
lyanchih has quit [Quit: lyanchih]
mikepack has quit [Remote host closed the connection]
thomasxie has joined #ruby
Kricir has quit [Remote host closed the connection]
fgo has quit [Remote host closed the connection]
Sawbones has joined #ruby
lyanchih_ has joined #ruby
vlad_starkov has quit [Ping timeout: 240 seconds]
Erenzie has quit [Quit: Time for a true display of fail!]
reset has quit [Ping timeout: 260 seconds]
sdwrage has quit [Quit: This computer has gone to sleep]
sdwrage has joined #ruby
cgcardona_ has quit [Quit: cgcardona_]
marcdel has joined #ruby
Lewix has quit [Remote host closed the connection]
FScottFitzgerald has joined #ruby
Sawbones has quit [Remote host closed the connection]
Sthebig has quit [Remote host closed the connection]
Sawbones has joined #ruby
firewater has joined #ruby
Erenzie has joined #ruby
Sthebig has joined #ruby
jonr22 has quit [Remote host closed the connection]
bkparso has joined #ruby
FScottFitzgerald has quit [Client Quit]
marcdel has quit [Read error: Operation timed out]
marcdel has joined #ruby
kevinykchan has quit [Read error: Connection reset by peer]
Hobogrammer has quit [Read error: Operation timed out]
kevinykchan has joined #ruby
danshultz has joined #ruby
bklane has quit [Quit: Leaving...]
Sawbones has quit [Ping timeout: 240 seconds]
P1RATEZ has quit []
mehlah has quit [Quit: Leaving...]
Sawbones has joined #ruby
Zunonia has quit [Quit: Computer has gone to sleep.]
<firewater> why would I be getting an "unexpected '}' , expecting tASSOC"? All I'm doing is taking an input in a method, puting it in {} and setting that equal to the existing blank hash.
danshultz has quit [Ping timeout: 252 seconds]
<firewater> AKA, hash= {input}
<firewater> Why would I get that error?
<centrx> Post real code
<firewater> k, second.
<firewater> Ignore the test at the bottom.
<firewater> Basically, it gives me an error.
TheMoonMaster has quit [Excess Flood]
telling has quit [Ping timeout: 248 seconds]
<firewater> Any ideas centrx ?
m00nlight has quit [Quit: Konversation terminated!]
duffyt has joined #ruby
<RubyPanther> wtf is privatpastie that sounds like a pr0n site
<firewater> Its just a site I use to paste code so I can just delete it.
<firewater> Easy temprorary site to use.
jrunning__ has quit [Ping timeout: 264 seconds]
gozali has joined #ruby
<bnagy> hash declarations need two values, that's why it wants an association token
<RubyPanther> easy for you, new and strange and dangerous to me. I recommend gist or pastie.org
<centrx> input_hash is already a hash...
<bnagy> k => v or symkey: v
jrunning__ has joined #ruby
hamakn has quit [Remote host closed the connection]
<lpvn> firewater, everytime you get an unexpected something you have a syntactic mistake
andy has joined #ruby
confounds has quit [Quit: Textual IRC Client: www.textualapp.com]
<firewater> k, but when I just take the braces away, then it says it doesn't work.
<firewater> I will try again, and tell you the error I get with that.
m00nlight has joined #ruby
<bnagy> fuzz coding
<bnagy> make random syntax changes until it runs
telling has joined #ruby
<firewater> Ok, actually it seems to work.
<firewater> Nevermind.
<firewater> I'm doing those rspec puzzles.
subbyyy has quit [Ping timeout: 272 seconds]
fijimunkii has joined #ruby
<firewater> So, its just something I am doing to learn. By making them pass.
Sawbones has quit [Remote host closed the connection]
<centrx> If you don't know what is going on, you're not learning anything
<firewater> I do know what is going on somewhat. But, no I'm not going to know everything 100%.
Sawbones has joined #ruby
<firewater> If I could go back to school to do CS, I would.
<firewater> I can't, so I am doing this outside work.
vlad_starkov has joined #ruby
<bnagy> CS is not really about learning to program, at least not in an ideal world
<lpvn> firewater, what's your job?
msmith has quit [Remote host closed the connection]
<bnagy> it's about learning to think
<firewater> I'm in finance right now.
andy has quit [Ping timeout: 240 seconds]
<firewater> bnagy: I understand, one can make a lot of arguements about what CS is, but you do learn programming too in it.
burlyscudd has joined #ruby
msmith has joined #ruby
dkamioka has joined #ruby
<bnagy> arguably
<bnagy> mostly you get CS programming beaten out of you fairly swiftly
<bnagy> but the thinking remains :P
subbyyy has joined #ruby
venkat_ has quit [Read error: Connection reset by peer]
Drogean2 has joined #ruby
mwillhite has joined #ruby
Drogean2 has left #ruby ["Leaving"]
Sawbones has quit [Ping timeout: 272 seconds]
venkat_ has joined #ruby
<mwillhite> hey there - I'm working on a CLI app and I'd like to do something more than just puts to the screen…I'd like information that updates in place
__greg has joined #ruby
TheMoonMaster has joined #ruby
<mwillhite> any pointers?
<benzrf> sounds like you want curses!
dkamioka has quit [Remote host closed the connection]
<benzrf> or something of that ilk
<bnagy> except curses is vile
dkamioka has joined #ruby
<bnagy> sadly, termbox is very bare bones, so it's tons of work to do anything nontrivial
jonno11 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dkamioka has quit [Remote host closed the connection]
<havenwood> mwillhite: for super simple stuff you can use `"\r"` to backspace: 'OMGWTFBBQ'.chars { |char| print char; sleep 0.5; print ?\r }
<firewater> Anyhow, going to head off now. Thanks for the help everyone.
<bnagy> mwillhite: there are a ton of libs for "in between" apps, where you don't have to own the whole terminal
<mwillhite> thanks havenwood thats a start
<mwillhite> an example bnagy ?
<bnagy> whose names I always forget :/ highline?
<mwillhite> ah yeah…I was going to start with commander
<havenwood> bnagy: ya
<bnagy> if you google around you'll find several. Having a kind of REPL is a good option for a lot of stuff
<mwillhite> which now brings highline it it looks like
sambao21 has joined #ruby
<mwillhite> I just haven't found clear information on how to maintain one screen, I'm looking at building a simple dashboard
<bnagy> honestly, I would rather write a full GUI app than use curses
<benzrf> firewater: oh hey totally missed you
<bnagy> but if you just want to blat stuff, then I have had good experiences with termbox
gtech_ has left #ruby [#ruby]
<firewater> benzrf: Its ok, heading off anyhow.
<bnagy> it's things like drop down menus and whatever that are a PITA to add to that, simple dividing up screen and refreshing is easy
Mousse_ has quit [Quit: Computer has gone to sleep.]
rismoney has quit [Ping timeout: 246 seconds]
<benzrf> blat?
<bnagy> send, push, output
<mwillhite> this is just a peronal project that I don't intend to share…I'm sick of writing web UIs so I thought I'd go the console route :)
sambao21 has quit [Ping timeout: 272 seconds]
Mongey has joined #ruby
tylersmith has joined #ruby
Zunonia has joined #ruby
<stephenmac7> So, I just read Why's Poignant Guide
<stephenmac7> ...and hated it
<benzrf> D:
<benzrf> noo
<stephenmac7> Is there a good, fast way to... recover... from the incoherence in that book?
<mwillhite> stephenmac7 you should definitely download the album then
sailias has joined #ruby
rismoney has joined #ruby
<stephenmac7> mwillhite: ?
<benzrf> stephenmac7: you clearly just don't like things that are good
<benzrf> it's not incoherence, it is PLEASANT MADNESSS
<benzrf> gosh!!
Sawbones has joined #ruby
<stephenmac7> I tried to like it... I really did
<benzrf> [but seriously that's fine, its def a matter of taste]
freezey has quit [Remote host closed the connection]
<benzrf> [im just needling you]
Zunonia has quit [Ping timeout: 264 seconds]
<stephenmac7> The problem is, I'm just more accustomed to books like LYAH (Learn you a Haskell), PIL (Programming in Lua), and K&R
aspires has joined #ruby
<stephenmac7> Anyway, the question was, is there a terse overview of ruby without the fluff that was in wGtR so I can go over what I missed?
sailias has quit [Client Quit]
<stephenmac7> (Which was almost everything)
<stephenmac7> mwillhite: I already saw that
<stephenmac7> Can't take it
<mwillhite> haha
<bnagy> people speak well of the pickaxe ( programming ruby )
<bnagy> personally I have zero time for programming books
<benzrf> stephenmac7: what languages do you already kno?
<benzrf> *know
<bnagy> have you run across the ruby quickref?
<bnagy> that's reasonably awesome if you code other langs
<stephenmac7> benzrf: A few... Haskell, Python, Lua, C, Javascript, Java, C++, LiveScript
<benzrf> you've done LiveScript?
<benzrf> :D
<benzrf> o/
<stephenmac7> Yes, noticed some similarities to ruby
<benzrf> i have met but few who have encountered it
dseitz has joined #ruby
<stephenmac7> benzrf: It seems like a mix between Haskell and Ruby
toasty has joined #ruby
sailias has joined #ruby
<benzrf> yep!
radic_ has quit [Ping timeout: 252 seconds]
<benzrf> unfortunately it still transpiles to js
<benzrf> so it smells of it regardless
<benzrf> ;-;
<stephenmac7> Anyway, bnagy, you suggest http://www.zenspider.com/Languages/Ruby/QuickRef.html ?
firewater has quit [Quit: Page closed]
<benzrf> stephenmac7: ruby is not so hard
<benzrf> stephenmac7: if you already know all of those languages, ruby has relatively few new ideas
<benzrf> you just need to mix them appropriately in ur brain
<stephenmac7> It has weird things though...
<benzrf> likemike_: ?
<stephenmac7> Like mutable strings
<benzrf> *like
<benzrf> that's what symbols are for
<stephenmac7> Oh, and not being able to pass around functions
<benzrf> well you can pass blocks
<stephenmac7> Even though it's a high-level language
<benzrf> but yea, first-class functions are sadly lacking
<benzrf> :(
<benzrf> to be precise, it has plenty of function/method objects
<benzrf> but foo.bar is calling syntax, not lookup syntax
<stephenmac7> Supposedly everything's an object (according to the guide), but functions are not :P
<benzrf> well, no
<benzrf> every _value_ is an object
<stephenmac7> Bleh
<benzrf> method aren't values
<benzrf> if you do like:
<centrx> You can pass around methods
<benzrf> foo.method(:bar)
radic has joined #ruby
<benzrf> you get an object representing that bar method on foo
<benzrf> but
<benzrf> foo.bar is a call
<benzrf> period
<benzrf> this comes from smalltalk
monkegjinni has joined #ruby
<benzrf> where 'foo bar' is like ruby's foo.bar
<stephenmac7> ?
<benzrf> ruby's object system is basically smalltalk's
<stephenmac7> I've never used smalltalk
<benzrf> ok
<benzrf> it's p simple
<benzrf> 1. from the outside, all you can do to an object is send it messages (call methods)
<benzrf> 2. from the inside, you can set any var you like ,scoped to the object
<benzrf> so it's like a java object from the outside, but a JS one from the inside
<benzrf> ish
<stephenmac7> I see.
<bnagy> that's just syntax, you can (effectively) use methods as first class variables, it's just not idiomatic
<stephenmac7> So, what's with the symbols with method names?
<benzrf> symbols are just symbols
petey has joined #ruby
<bnagy> the rest is just whining by people who don't like the syntax
<benzrf> bnagy: i respectfully disagree o;
<benzrf> but w/e
<benzrf> stephenmac7: do you grok symbols
<stephenmac7> It's some type of "light-weight string"
<benzrf> not really
<benzrf> basically, the idea is
<benzrf> there are 2 main uses for strings
<bnagy> benzrf: what can you not _do_ with a Method object?
<benzrf> bnagy: shh im lecturing
<benzrf> stephenmac7: you might use them to store text, where you care about the content
<benzrf> OR
<bnagy> ignoring the fact that you can't just use blah.meth to get one
* stephenmac7 wonders why benzrf and bnagy's names are so similar
<benzrf> you might use them as identifiers, where you care about equality
<benzrf> stephenmac7: have you used flask?
<stephenmac7> benzrf: No, I'm a Pyramid person :P
meatherly has quit [Remote host closed the connection]
<benzrf> w/e
<benzrf> i'm going to assume it does something like flask where you specify the http method of a route with a string
<benzrf> ?
<stephenmac7> Yes
<benzrf> ok
<benzrf> in that case
meatherly has joined #ruby
<benzrf> you don't care about the textual content of the string 'POST'
<benzrf> you just care that it is equal to every other string 'POST'
<stephenmac7> Right, just what it means
<benzrf> exactly
<stephenmac7> So, we use :post
<stephenmac7> or :POST
<stephenmac7> No
<benzrf> in ruby, you use symbols for identity
vlad_starkov has quit [Ping timeout: 265 seconds]
<stephenmac7> Not the second
<stephenmac7> Just :post
<benzrf> mhm
<benzrf> and strings for text
Liothen has quit [Quit: System of a down……]
monkegjinni has quit [Ping timeout: 260 seconds]
jonah_k has joined #ruby
<stephenmac7> So, why do we use them for function names
<stephenmac7> When passing them as arguments
<benzrf> because they are the standard value used for identifiers
<benzrf> there's nothing magic about them that makes them used as method names
<stephenmac7> So how does that can run method work?
angusiguess has quit [Ping timeout: 252 seconds]
<stephenmac7> What was it...
<benzrf> you mean respond_to?
Liothen has joined #ruby
<benzrf> foo.respond_to? :bar
<stephenmac7> Yeah, that
<benzrf> that's like python's has_attr
<benzrf> or something?
<benzrf> does python have that idr
<bnagy> >> "foo".respond_to? 'bytes'
<eval-in> bnagy => true (https://eval.in/102551)
<stephenmac7> Is it just some fancy implementation built-in that somehow knows what function you're talking about
<benzrf> well
<benzrf> in python you can do
<benzrf> getattr(foo, "__str__")
<benzrf> in ruby you can do
<bnagy> it's just convention to use symbols there
<benzrf> foo.respond_to? :to_s
<benzrf> same diff
<benzrf> well not really
<benzrf> the former is more like
<benzrf> foo.method :to_s
<stephenmac7> But how is respond_to implemented?
<benzrf> in C
<stephenmac7> :/
<benzrf> how is __getattr__ implemented in python?
<benzrf> how is type.__call__ implemented in python?
burlyscudd has quit [Quit: Leaving.]
<stephenmac7> You've got a point there
<benzrf> =]
<benzrf> everything in a new language seems unpleasantly magic
<benzrf> you get used to it, trust me
<stephenmac7> But in python, I can pass functions
b00stfr3ak has joined #ruby
<benzrf> in python, functions and vars share a namespace because functions are normal values
meatherly has quit [Ping timeout: 240 seconds]
<benzrf> in ruby, there are no functions, only methods
<stephenmac7> So, how would I do something like
<benzrf> when i say foo() that is just calling self.foo
<stephenmac7> (in pseudocode)
<stephenmac7> function apply(f, v) f(v) end
<benzrf> def apply(f, v)
<benzrf> f.call v
<benzrf> end
<benzrf> proc objects implement #call
sambao21 has joined #ruby
<stephenmac7> I see.
<benzrf> as should all other well-behaved function-like objects
<benzrf> there's also .() which is just sugar for .call
<benzrf> i.e.
<benzrf> some_proc.(1, 2, 3)
<benzrf> =>
<benzrf> some_proc.call(1, 2, 3)
<stephenmac7> And proc means....
<benzrf> i don't use it myself
slowcon has joined #ruby
<benzrf> a proc is a kind of value that blocks get converted into
<benzrf> if I do this:
<RubyPanther> that's not sugar that is saccharine :P
<benzrf> [1, 2, 3].map {|n| n + 1}
<benzrf> the map method may receive the block as a Proc object
<benzrf> or it can use yield
venkat_ has quit [Remote host closed the connection]
<stephenmac7> It's the &block thing
<benzrf> right
<benzrf> you know how you can use * or ** in python to specify a special arg?
mehlah has joined #ruby
<stephenmac7> Yes
kennym has quit [Remote host closed the connection]
<benzrf> that receives vars differently
<benzrf> in ruby, there's *
<benzrf> ther's also &
<benzrf> an &argument will have the block passed dropped into it as a Proc
<benzrf> or nil if no block was given
venkat_ has joined #ruby
<benzrf> symmetrically you can pass procs with & in a call
rhys has quit [Ping timeout: 265 seconds]
<benzrf> just like * pushes lists into args
<benzrf> so
<benzrf> >> p = proc {|n| n + 1}; p.call 3
<eval-in> benzrf => 4 (https://eval.in/102552)
<benzrf> >> p = proc {|n| n + 1}; [1, 2, 3].map(&p)
<eval-in> benzrf => [2, 3, 4] (https://eval.in/102553)
<stephenmac7> I just looked at QuickRef...
<benzrf> if the thing you pass with & is not already a proc, it gets #to_proc called on it, which lets you do interesting things
<stephenmac7> and I feel extremely stupid for having wasted my time on the guide
<benzrf> D:
<benzrf> stephenmac7: do you follow &arg and &call
<stephenmac7> Yes, I do
<benzrf> ok
<stephenmac7> Thanks
<benzrf> now, Symbol#to_proc is cool
fgo has joined #ruby
<benzrf> >> c = :to_s.to_proc; c.call 3
<eval-in> benzrf => "3" (https://eval.in/102554)
Es0teric has quit [Ping timeout: 264 seconds]
<benzrf> any_symbol.to_proc will give you a proc that calls the method named that on the arg
<benzrf> i.e. :to_s.to_proc creates a proc that calls to_s
<benzrf> on its argument
<benzrf> if you try to pass something that's not a proc with &
sambao21 has quit [Ping timeout: 272 seconds]
<stephenmac7> Ah.
<RubyPanther> the Guide is a journey through space, time, and Ruby. It is not a reference tome.
<benzrf> it gets to_proc called on it
<stephenmac7> Shiny :D
<benzrf> so you can do this:
<benzrf> >> [1, 2, 3].map &:to_s
<eval-in> benzrf => ["1", "2", "3"] (https://eval.in/102555)
<benzrf> very common idiom
<benzrf> =D
<stephenmac7> Now that's what I wanted
<stephenmac7> Almost first class functions... but not quite
<RubyPanther> it is also from an ancient time before Symbol#to_proc
<stephenmac7> Just like Haskell almost has state, but not quite
<benzrf> yas
<benzrf> check this out too
Es0teric has joined #ruby
<benzrf> >> class String; def to_proc; proc {|the_arg| eval self}; end; end; "the_arg + 1".to_proc.call(3)
<eval-in> benzrf => 4 (https://eval.in/102556)
<benzrf> ^makes sense right?
venkat_ has quit [Ping timeout: 272 seconds]
<stephenmac7> Yes
<benzrf> >> class String; def to_proc; proc {|the_arg| eval self}; end; end; [1, 2, 3].map(&"the_arg * 3")
<benzrf> ^terrible idea, never do it
Vivekananda has quit [Read error: Connection reset by peer]
<benzrf> also why so laggy eval-in
<stephenmac7> benzrf: Sad thing is, I still don't see what's so special about ruby :(
<centrx> Probably anti-spam
<stephenmac7> Which is probably why I'm not remembering half of it
fgo has quit [Ping timeout: 260 seconds]
<stephenmac7> I have to learn it for my job
fedexo has joined #ruby
sailias has quit [Quit: Leaving.]
Mongey has quit [Quit: Mongey]
<stephenmac7> benzrf: Anything specific I could do to get more "into it"?
<benzrf> stephenmac7: idk, write some o:
<benzrf> ruby is not super special
<benzrf> it is just a nice language
<benzrf> i enjoy it because it feels more convenient than python, while retaining most of the parts of python i like
<benzrf> although not all of them :\
<centrx> It is the cleanest language around
<benzrf> it's a bit messy
<benzrf> centrx: it sure as hell isn't >:(
<benzrf> look at require
<benzrf> you can't call that clean
fijimunkii has quit [Read error: Connection reset by peer]
<centrx> require 'file'
<centrx> How is that not clean
<benzrf> it literally executes the file in the same namespace as you
<benzrf> that's HORRIBLE practice
<centrx> Why?
<benzrf> python, now that's a language that does imports righ
<benzrf> t
<benzrf> centrx: namespace pollution for one!
braincrash has quit [Quit: bye bye]
<benzrf> for another, it makes it harder to see where somethign came from
<stephenmac7> Lua does the same thing
<centrx> but you specified to require it
<benzrf> and it allows absurd levels of spooky action at a distance
<stephenmac7> It's even called require in Lua also
<benzrf> require 'foo'; require 'bar'
sdwrage has quit [Quit: This computer has gone to sleep]
<benzrf> you now have no idea how much of foo bar has messed with
<benzrf> perhaps not on purpose!
freezey has joined #ruby
<benzrf> stephenmac7: i like ruby because
axsuul has joined #ruby
<benzrf> 1. it has very nice OO
axsuul has quit [Excess Flood]
<benzrf> it doesnt stand out at first glance, but having used it, it just feels NICER than python
<benzrf> 2. it has pervasive lambda-taking functions, like map
<benzrf> which i kept really feeling the lack of in python
<benzrf> 3. it has lisp-style everything-is-an-expr and automatic returning
<benzrf> which imo creates cleaner code
<stephenmac7> I did like that
<benzrf> 4. it just feels nice, most things i want to do feel more natural and easier in ruby than in python
sdwrage has joined #ruby
<benzrf> once i acclimated
krz has joined #ruby
<benzrf> for one thing, it isn't of two minds about its OOPness
freezey has quit [Read error: Connection reset by peer]
freezey_ has joined #ruby
<benzrf> in python there's len(this) and str(that), but then everything else is a method and it's weird
braincrash has joined #ruby
<RubyPanther> require isn't support to be "clean"
<RubyPanther> Ruby isn't supposed to be "clean"
<benzrf> oh yeah also one major benefit of pervasive lambdas is that almost all iteration is internal
<benzrf> which is p neat
<stephenmac7> benzrf: That's true. It's hard to remember whether it's this.lenth or len(this) or something like that
<benzrf> the thing is that everything is tradeoffs
Vivekananda has joined #ruby
<stephenmac7> Okay, thanks.
<benzrf> ruby fully embraces the idea that a function should be a method on the thing it primarily operates on
<benzrf> which is cool!
<stephenmac7> I'll read the quickref, take a quick look at metaprogramming, and see how I like it
<benzrf> but otoh it causes major namespace pollution
<benzrf> OK
<centrx> Which is never an actual problem
<benzrf> true
<benzrf> it just feels a bit icky
<benzrf> ~_~
<stephenmac7> What, exactly, does metaprogramming do, btw?
freezey_ has quit [Read error: Connection reset by peer]
freezey has joined #ruby
<RubyPanther> Programs your programming, of course
<bnagy> makes people write terrible code, mostly
<benzrf> metaprogramming is neat yo
<stephenmac7> bnagy: Isn't that always nice?
<RubyPanther> same as meta- in meta-physics
<benzrf> ruby is good for dsls
<stephenmac7> I get what metaprogramming itself is.
<benzrf> 11:01 < ScootaLewis> it's 4AM and my dad's at mcdonalds
<benzrf> oops
Zunonia has joined #ruby
RyanD has quit [Read error: Connection reset by peer]
<benzrf> wrong channel
fijimunkii has joined #ruby
<stephenmac7> But not what it does, exactly
<benzrf> stephenmac7: in ruby it mostly lets you dynamically do almost anything you can do at code-writing time
thesheff17 has quit [Ping timeout: 260 seconds]
<benzrf> i.e. create methods, define classes, etc
<bnagy> how can you get what it is but not what it does? :/
<benzrf> bnagy: how about macros?
papito_ has quit [Remote host closed the connection]
bahar has joined #ruby
<stephenmac7> bnagy: Meaning, the idea, but not how it's useful
<benzrf> stephenmac7: at any level you're going to run into patterns and repetition
<bnagy> I mean the term is stupid, admittedly
mehlah has quit [Quit: Leaving...]
<benzrf> at each level, you should be able to step up a level to generalize those patterns
<RubyPanther> Like meta-physics, it is more often harmful than useful, and can be lived without entirely ;)
<centrx> benzrf, The Python way is actually more of a hack because Python lacks modules
<stephenmac7> I know it can write methods for you, but if you're writing a method to write a method, won't you just be writing the method with a wrapper method around it?
<benzrf> stephenmac7: in manual processing, stepping up a level is writing programs
<benzrf> stephenmac7: nope!
JBreit has quit [Read error: Connection reset by peer]
lyanchih_ has quit [Quit: lyanchih_]
thomasxie has quit [Read error: Connection reset by peer]
<bnagy> stephenmac7: you'll know it when you see it :P
<RubyPanther> Meta-programming is useful especially in prototyping, for example prototyping a bugfix from a REPL
<benzrf> stephenmac7: because then the name of the method can be determined at runtime, and you can declare it on onther things
thomasxie has joined #ruby
<bnagy> at some point runtime code generation is suddenly a good idea
<benzrf> stephenmac7: one popular and terrible example:
<RubyPanther> or for example, with duck-typing you might want to mixin additional behaviors at a later time
<bnagy> for a very small class of problems
<benzrf> stephenmac7: you can write a framework that looks at a database, examines what columns it has, and creates a class with method names corresponding to the columns
<stephenmac7> So, it's basically Haskell Generics?
<benzrf> stephenmac7: then the user's code can directly address columns by name as methods, even though your code doesn't know them at write-time
<benzrf> not really no
<benzrf> haskell generics fix a problem that can be fixed with metaprogramming in ruby i guess?
stonevil has joined #ruby
<benzrf> stephenmac7: when you see a pattern in your work that you do manually, you generalize it with programming
joelroa has quit [Ping timeout: 245 seconds]
<stephenmac7> benzrf: I see, but can't you just use index?
<benzrf> stephenmac7: when you see a pattern in your programming, you generalize it with metaprogramming
freezey has quit [Ping timeout: 260 seconds]
<benzrf> stephenmac7: well, you could!
<stephenmac7> myreturnedobj['somecolumn']
<benzrf> symbols in ruby probs
<stephenmac7> myreturnedobj[:somecolumn]
<benzrf> stephenmac7: but do you want to keep writing [:]
<benzrf> ;p
<stephenmac7> :P
<stephenmac7> That's not a good reason...
<benzrf> but yeah that's probably a better solution
<benzrf> i was just giving an example!
<RubyPanther> When you're stuck in Dwemthy's Array, and you're just a rabbit... meta-programming is the only way you're ever going to slay that dragon and escape.
<stephenmac7> RubyPanther: I see you didn't see my rant about the guide
<RubyPanther> lol
<stephenmac7> By the time I got to that section, my brain was toasted
vlad_starkov has joined #ruby
<stephenmac7> Anyway, thanks. I have to go.
bahar has quit [Changing host]
bahar has joined #ruby
<benzrf> alright, gl with ruby o:
<stephenmac7> I'll come back with the results of my search for meaning ruby
<RubyPanther> if you're not jumping up and down squealing like a little child at how awesome the Guide is by page 3, you should put it down and find a technical manual. ;)
<stephenmac7> *in ruby
Steve445 has joined #ruby
<centrx> Learn better by programming something
<stephenmac7> RubyPanther: Why didn't anyone tell me this earlier?
<stephenmac7> centrx: No, I like those terse, technical manuals
<RubyPanther> stephenmac7: They assumed the cartoon foxes were a give-away
<bnagy> stephenmac7: bindata is a good use of metaprogramming
<bnagy> and DSLs
RyanV has joined #ruby
<RubyPanther> Canonical is things like Enumerable
<stephenmac7> RubyPanther: Yeah, I only realized I hated it in the middle
<stephenmac7> Then I said, "I've already wasted so much time!"
<bahar> hey guys anyone here have experience with parsing cURL commands and turning them into, say, a typhoeus command? i've been trying to do that, but it doesn't seem to be working, i must be missing something
<stephenmac7> Must finish it
JBreit has joined #ruby
<stephenmac7> What's with all these five-letter b---- names?
slowcon has quit [Quit: slowcon]
<stephenmac7> benzrf, bnagy, and bahar
<RubyPanther> we metaprogram because we don't have static interfaces, we just have interfaces-by-convention, so it is normal to add behaviors at a late enough time that it becomes "meta-programming." But most of the good uses are things you would just do at compile time in static languages, not any of the nonsense.
<bahar> ah, it's our names :)
<stephenmac7> RubyPanther: I see.
<stephenmac7> So, it's what ruby uses to make up for what it doesn't have
<benzrf> my name is literally Ben Z. R.F. irl
<benzrf> most original name
<RubyPanther> yeah, it saves us a lot of boilerplate, and lets us relax in the REPL
kevinykchan has quit [Ping timeout: 260 seconds]
kristiandelay has joined #ruby
<centrx> Don't listen to RubyPanther. He is insane.
<RyanV> hey, looking for a one liner that will will convert a url, that may or may not include a scheme, and spit out a uri with scheme included ('www.foo.com => ''http://www.foo.com'). maybe URI has something?
mehlah has joined #ruby
Hobogrammer has joined #ruby
<benzrf> stephenmac7: ignore RubyPanther
<benzrf> always
<RubyPanther> I may be insane, but I'm also right twice a day.
<benzrf> stephenmac7: RubyPanther literally things that fp is awful
<benzrf> *thinks
<stephenmac7> benzrf: Who could think FP is awful?
<RubyPanther> I think what I actually said was something like, functional programming is not actually harmful, it just tastes awful.
<benzrf> RubyPanther.
cmoylan has quit [Ping timeout: 245 seconds]
<benzrf> stephenmac7: he also believes that your sql database should have no significant internal constraints and that all metadata should be handled by your program, btw also you should always use an ORM!!
<benzrf> ^insanity
<stephenmac7> RubyPanther: FP feels clean
<stephenmac7> Honestly, I don't like ORMs
<RubyPanther> Nothing is cleaner than a nice polished set of parens
<stephenmac7> *SQL
<centrx> bahar, You are parsing it command-line options from a different program?
slowcon has joined #ruby
gwz has quit [Quit: Page closed]
<bahar> centrx: from an example i found online
<benzrf> stephenmac7: it has ubiquitous lambdas
<RubyPanther> I use emacs, so even I can suffer a small amount of FP, especially if it is hidden from view
<benzrf> :I
<bahar> i think where i'm going wrong lies here in this part of the body (at least i think it's the body): \"1\":\
<RubyPanther> Ruby is not functional, but it permits a functional style
zastern has joined #ruby
<stephenmac7> Ruby is about as functional as Java
m104 has quit [Quit: bye]
<RubyPanther> You will not be executed for dressing funny in Ruby. That is obvious from the ruby slippers, though.
<stephenmac7> benzrf: By the way, how does wikipedia claim that ruby is functional?
nanoyak has joined #ruby
Steve445 has quit [Quit: Steve445]
stonevil has quit [Quit: Computer has gone to sleep.]
msmith has quit [Remote host closed the connection]
kristiandelay has quit [Read error: Operation timed out]
<benzrf> that's more functional than python anyway
w1zeman1p has joined #ruby
<centrx> Does Java have blocks?
<benzrf> heck no
<bnagy> RyanV: if it doesn't have a scheme it doesn't have one
<stephenmac7> benzrf: Python has lambdas, partial application, and first-class functions
<centrx> Ruby seems much more functional than Java
<stephenmac7> centrx: That was a slight exaggeration
maroloccio has joined #ruby
drPoggs has quit [Ping timeout: 252 seconds]
<bnagy> RyanV: you can do sc = parsed_uri.scheme || 'http' or something
<benzrf> stephenmac7: yes, but they aren't idiomatic or commonplace
drPoggs has joined #ruby
<benzrf> stephenmac7: the extent of fcf usage in python is pretty much just for callbacks
<stephenmac7> Decorators are also a functional feature
<RubyPanther> The lengths I've gone to to avoid fp: writing Perl to do the fp for me! https://gist.github.com/rubypanther/56688a2a70a882bafd16
petey has quit [Remote host closed the connection]
fijimunkii has quit [Read error: Connection reset by peer]
<stephenmac7> Anyway, I really, really have to go
yasushi has joined #ruby
<RyanV> best i have atm is: URI(url).scheme ? url : "http://#{url}"
<stephenmac7> Thank you all!
<stephenmac7> Especially Ben
<RyanV> those were supposed to be curly brackets
<benzrf> ;)
<bnagy> RyanV: you can set u.scheme ||= 'http' as well
<RyanV> thats assuming that url is a URI object already
<RyanV> its a string
<bnagy> well that sounds like an insoluble problem, I can't see any possible way to overcome it
Ivo has joined #ruby
<Ivo> does `cmd` just run cmd as a shell command?
<centrx> Yes, it is in Kernel
<RubyPanther> Ivo: mostly
slowcon has quit [Quit: slowcon]
<benzrf> Ivo: to be precise it calls `
<benzrf> with "cmd" as an argument
<benzrf> Kernel.` does what you think though
<RubyPanther> RyanV: I would parse it with URI.parse first, and then do like bnagy suggested
<RubyPanther> for some values of "just"
<benzrf> >> Kernel.` "ls"
<eval-in> benzrf => (https://eval.in/102557)
fijimunkii has joined #ruby
dkamioka has joined #ruby
sdwrage has quit [Quit: This computer has gone to sleep]
funburn has quit [Read error: Connection reset by peer]
<RyanV> i must be missing something because u = URI('www.google.com'); u.scheme = 'http'; u.to_s == 'http:www.google.com'
<RubyPanther> >> :botsnack && :nomnomnom
<eval-in> RubyPanther => :nomnomnom (https://eval.in/102559)
<RyanV> it doesnt add the forward slashes between scheme and host
<Ivo> benzrf: in particular, I'm wondering if there's any gotchas to running the code snippet on every script call (to help out windows), in https://github.com/jekyll/jekyll/issues/1835#issuecomment-35348213
funburn has joined #ruby
<RyanV> bnagy heres a shorter version but again, run into the concat problem: URI(url).tap {|u| u.scheme ||= 'http'}.to_s
dkamioka has quit [Ping timeout: 245 seconds]
<benzrf> RyanV: uris dont naturally have //
<RyanV> so thats valid?
<benzrf> that's a pecularity of most web-based ones
<benzrf> look at the about url scheme
<benzrf> it has no //
<benzrf> *uri
Vivekananda has quit [Remote host closed the connection]
fijimunkii has quit [Ping timeout: 265 seconds]
mwillhite has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<RyanV> typing it in that way works in the browser too
<benzrf> how odd
fijimunkii has joined #ruby
dubsteph has joined #ruby
Lewix has joined #ruby
joelroa has joined #ruby
maroloccio has quit [Quit: WeeChat 0.4.2]
Lewix has quit [Remote host closed the connection]
<RubyPanther> >> require 'uri' ; u = URI(''); u.hostname = 'www.google.com' ; u.scheme = 'http' ; u.to_s
<benzrf> ...huh
<RubyPanther> >> require 'uri' ; u = URI(''); u.hostname = 'www.google.com' ; u.scheme = 'http' ; u.relative?
<eval-in> RubyPanther => false (https://eval.in/102561)
Vivekananda has joined #ruby
Lewix has joined #ruby
<RubyPanther> >> u = URI.parse('www.google.com'); u.relative?
<eval-in> RubyPanther => uninitialized constant URI (NameError) ... (https://eval.in/102562)
<RubyPanther> so if you parse the hostname as the url, it thinks that is a relative url, and then you add the scheme and it just is a little confused, but blindly trusts you
<RubyPanther> >>require 'uri'; u = URI.parse('www.google.com'); u.relative?
<eval-in> RubyPanther => true (https://eval.in/102563)
brjannc has quit [Read error: Operation timed out]
fijimunkii has quit [Read error: Connection reset by peer]
toddabrahm has quit [Read error: Operation timed out]
micah` has quit [Read error: Operation timed out]
Rickmast- has quit [Read error: Operation timed out]
Gate has quit [Read error: Operation timed out]
adeponte has quit [Read error: Operation timed out]
dubsteph has quit [Ping timeout: 264 seconds]
adeponte has joined #ruby
vlad_starkov has quit [Ping timeout: 265 seconds]
micah` has joined #ruby
mocfive has quit [Remote host closed the connection]
Gate has joined #ruby
mocfive has joined #ruby
iliketurtles has quit [Quit: zzzzz…..]
hamakn has joined #ruby
joelroa has quit [Ping timeout: 245 seconds]
tcopp has quit [Ping timeout: 252 seconds]
Sawbones has quit [Remote host closed the connection]
twiceaday has quit [Ping timeout: 264 seconds]
brjannc has joined #ruby
twiceaday has joined #ruby
Rickmasta has joined #ruby
Sawbones has joined #ruby
stonevil has joined #ruby
<AlexRussia> someone know, what is regexp in sql?(sqlite)
armyriad has joined #ruby
RyanV has quit [Ping timeout: 265 seconds]
mocfive has quit [Ping timeout: 248 seconds]
iliketurtles has joined #ruby
toddabrahm has joined #ruby
sdwrage has joined #ruby
Sawbones_ has joined #ruby
venkat_ has joined #ruby
toasty has quit [Remote host closed the connection]
Sawbones has quit [Read error: Connection reset by peer]
RyanV has joined #ruby
jobewan has joined #ruby
<centrx> AlexRussia, What is it?
aspires has quit []
<AlexRussia> centrx: seen 'like and glob opersators' https://www.sqlite.org/lang_expr.html
burlyscudd has joined #ruby
<centrx> Search for REGEXP in that page
burlyscudd has quit [Client Quit]
<centrx> Apparently SQLite does not have Regex
<AlexRussia> centrx: hm
wallerdev has quit [Quit: wallerdev]
<AlexRussia> centrx: k, i try some way
sensen has quit [Ping timeout: 260 seconds]
speakingcode has joined #ruby
Hobogrammer has quit [Read error: Connection reset by peer]
Hobogrammer has joined #ruby
Jakee` has quit [Ping timeout: 252 seconds]
sailias has joined #ruby
ext0 has quit [Remote host closed the connection]
speakingcode has quit [Ping timeout: 260 seconds]
recurrence has joined #ruby
stonevil has quit [Ping timeout: 240 seconds]
rndstr has quit [Ping timeout: 252 seconds]
stkowski has quit [Quit: stkowski]
lyanchih_ has joined #ruby
makara has joined #ruby
tcopp has joined #ruby
RyanV has quit [Quit: Lingo - http://www.lingoirc.com]
jobewan has quit [Remote host closed the connection]
Jakee`_ has joined #ruby
mloveless has joined #ruby
17SAAGOOT has joined #ruby
Jakee`_ is now known as Jakee`
tcopp has quit [Ping timeout: 240 seconds]
freezey has joined #ruby
Jakee` has quit [Changing host]
Jakee` has joined #ruby
rndstr has joined #ruby
rndstr has quit [Changing host]
rndstr has joined #ruby
jeregrine has quit [Ping timeout: 252 seconds]
freezey has quit [Ping timeout: 245 seconds]
JasmeetQA has joined #ruby
sensen has joined #ruby
jeregrine has joined #ruby
mikepack has joined #ruby
vlad_starkov has joined #ruby
SirCmpwn is now known as SirCmpwn_
yasushi has quit [Remote host closed the connection]
burlyscudd has joined #ruby
Sawbones_ has quit [Remote host closed the connection]
SirCmpwn_ is now known as SirCmpwn
Sawbones has joined #ruby
IceDragon has quit [Ping timeout: 252 seconds]
mweshi has joined #ruby
17SAAGOOT is now known as speakingcode
Aquilo has left #ruby [#ruby]
<AlexRussia> centrx: you dont know, how to limit values, returned sqlite?
burlyscudd has quit [Client Quit]
iliketur_ has joined #ruby
<AlexRussia> centrx: for example, i have get not > 5 elements, how to do?
<centrx> add "LIMIT 5" to the end of your query
<AlexRussia> centrx: Thanks
Sawbones has quit [Ping timeout: 265 seconds]
noop has joined #ruby
sailias has quit [Read error: Operation timed out]
<AlexRussia> centrx: hm, a possible select like 5< x <15 values?
<AlexRussia> centrx: range values
<centrx> LIMIT 10 OFFSET 5
pskosinski has joined #ruby
iliketurtles has quit [Ping timeout: 260 seconds]
<AlexRussia> centrx: offset is where starter count limit?
<AlexRussia> start*
<centrx> yes
<AlexRussia> centrx: your help great for me ;)
Synthead has joined #ruby
duffyt has left #ruby [#ruby]
stonevil has joined #ruby
bobdobbs has joined #ruby
sensen_ has joined #ruby
JohnBat26 has joined #ruby
sensen has quit [Ping timeout: 252 seconds]
SirCmpwn is now known as SirAway
<RubyPanther> it says it has REGEXP but not regexp()
<AlexRussia> RubyPanther: ?
Tobarja has quit [Ping timeout: 272 seconds]
Guest81327 has joined #ruby
<RubyPanther> 'The REGEXP operator is a special syntax for the regexp() user function. No regexp() user function is defined by default and so use of the REGEXP operator will normally result in an error message. If an application-defined SQL function named "regexp" is added at run-time, then the "X REGEXP Y" operator will be implemented as a call to "regexp(Y,X)".'
<RubyPanther> it has the operator but not the function
<Guest81327> is it possible to run website with ruby inplace of php-WAMP?
<centrx> Yes
mocfive has joined #ruby
<AlexRussia> hm
Tobarja has joined #ruby
dik_dak has quit [Quit: Leaving]
<RubyPanther> Guest81327: the sky is no limit, Ruby can possibly go to the stars
<RubyPanther> Guest81327: consider this fine example: http://mislav.uniqpath.com/poignant-guide/book/expansion-pak-1.html
<Guest81327> RubyPanther: i guess there may be some limits
stonevil has quit [Ping timeout: 272 seconds]
<RubyPanther> Yeah, like multiple inheritance. But that is awful anyways, and not needed.
<centrx> Mixins are like multiple inheritance
<centrx> A better implementation of multiple inheritance
<RubyPanther> For some values of "like," sure!
mikepack has quit [Remote host closed the connection]
<Guest81327> is it possible to run/import ruby code containing modules(like nokogiri) in the online/webbased browser environment at free?
Es0teric has quit [Quit: Nigga, im OUTIE 5000]
<Guest81327> which woudl be those sites?
root_empire has joined #ruby
tgkokk has joined #ruby
w1zeman1p has quit [Remote host closed the connection]
gtech_ has joined #ruby
Shidash has joined #ruby
phansch has joined #ruby
<gtech_> I'm using the au3 gem in windows and when I try WIN32OLE.new "AutoItX3.Control" it tells me it fails to create the object "WIN32OLERuntimeError" any ideas?
<centrx> Win32 OLE Runtime Error!
<centrx> awful
<centrx> Guest81327, I am not sure what you mean. Ruby does not run inside a the web browser. Neither does PHP.
<bnagy> gtech_: probably can't create the com object
<bnagy> check that autoit is installed correctly and that it works with not-ruby
<Guest81327> i found one such service
<Guest81327> centrx: there are also many other online compilers
<Guest81327> centrx: but they cant import libaries/modules/package like nokogiri
<AlexRussia> dammit, my sequel eval dont work db[:posts].where(:msg.like('%@'+name+'%')).limit(10)
<Guest81327> centrx: hence i am looking for a solution (of course without local set up)
<gtech_> bnagy: trying 64 bit native tools instead, if this doesn't work I'll try to get ffi working heh
<bnagy> gtech_: from memory you just want to send keys to a window, right?
<bnagy> that's annoying but doable with pure ffi and the native api
<gtech_> bnagy: yup yup, au3 was a convenient wrapper for SentInput, that's why I'm using it
<gtech_> SendInput*
<bnagy> check dan berger's gems, also
<centrx> Guest81327, I assume that sends the code to the server and processes it there
<centrx> Guest81327, What exactly are you trying to do?
<bnagy> I am pretty sure there's an ffi project already started for cimple input sending as well, just can't remember
<centrx> Guest81327, That site is just for testing out code, not for real use
<bnagy> the ffi wiki might have links though
<Guest81327> centrx: i want to run/execute/compile a ruby code which requires support/import of libaries
<Guest81327> if i visit some ruby sites/blogs there are some code snippets posted
<centrx> Guest81327, Install Ruby on your computer
<Guest81327> & hence i want to try & see what would be its output after compiling?
<Guest81327> there mustbe alternate
Hobogrammer_ has joined #ruby
aniM has joined #ruby
<centrx> Guest81327, Do you not have a computer or something?
sparrovv has joined #ruby
monkegjinni has joined #ruby
<Guest81327> centrx: it doenst matter; but i guess there must be some way out in today's advance technlogy/internet world
Hobogrammer has quit [Ping timeout: 265 seconds]
<centrx> Guest81327, You could use a cloud service
<Guest81327> centrx: yeah that is an option; which one is free?
<centrx> Guest81327, Otherwise, a site is not going to want you to import all sorts of extra code
hobodave has joined #ruby
joelroa has joined #ruby
<bnagy> does aws still offer a micro instance for free?
slowcon has joined #ruby
<Guest81327> centrx: amazon ec2 requires credit card info whihc i dont want to open.
<Guest81327> centrx: do you use any other clouds?
<bnagy> ok this is getting ridiculous
<centrx> It is like he doesn't have a computer
JasmeetQA has quit [Quit: Leaving.]
<centrx> Yet he is on IRC
<pipework> what is a computer
<Guest81327> centrx: if my query is inappropriate; i would stop further discussion
JasmeetQA has joined #ruby
<pipework> Guest81327: the cloud I use tends to get me all soggy if I play with it too much
vlad_starkov has quit [Ping timeout: 272 seconds]
<Guest81327> pipework: my requirement with cloud is not fast.
rippa has joined #ruby
<Guest81327> pipework: which clouds you use for ruby?
SirAway is now known as SirCmpmn
sparrovv has quit [Ping timeout: 264 seconds]
<pipework> Guest81327: the kinds you find meteorologists speaking about.
monkegjinni has quit [Ping timeout: 260 seconds]
tgkokk has quit [Ping timeout: 260 seconds]
root_empire has quit [Quit: Ex-Chat]
joelroa has quit [Ping timeout: 265 seconds]
<pipework> I don't know of any free 'clouds' that don't require some credit card to use that are worth my time. I 1) Have multiple bitchin' machines, 2) Use a handful of service providers, and 3) don't look for free services all that often.
axl_ has joined #ruby
<pipework> Your best bet that might require a credit card is to use heroku's free tier.
<pipework> Maybe amazon's free tier for a year doesn't require a card?
zcreative has joined #ruby
ringaroses has quit [Ping timeout: 252 seconds]
<Guest81327> pipework: amazon requires CC
<bobdobbs> If I do 'rails new demo', I get an error with a huge list of uninstalled deps. Rather then installing each gem one-by-one, is there a single command that can install all rails deps?
<pipework> bobdobbs: ever hear of bundler? You just `bundle`
Aryasam_ has joined #ruby
<bobdobbs> doesn't that require a gemfile?
<centrx> bundle install
<pipework> centrx: install is unnecessary
<centrx> If you ran rails new, there is a Gemfile
<bobdobbs> ah, ok
<pipework> bobdobbs: If you made a new rails app, doesn't that come with one?
Solnse has quit [Quit: Leaving.]
AlexRussia has quit [Ping timeout: 264 seconds]
aniM has quit [Ping timeout: 265 seconds]
v0n has quit [Ping timeout: 264 seconds]
Aryasam has quit [Ping timeout: 272 seconds]
SirCmpmn is now known as SirCmpwn
Dreamer3 has quit [Quit: Computer has gone to sleep.]
<bobdobbs> The book I'm working with seems to say that 'rails new demo' is the first command in creating an app called demo. But that command errors out with a list of deps. No, it doesn't create a gemfile, even if I run the command without a name for the app. ie, 'rails new'
<pipework> bobdobbs: are you sure you followed their directions and used the same version of rails they're using?
<bobdobbs> Yes, following the books directions. I guess that versioning could be issue.
<pipework> bobdobbs: I'd be more able to help if you gisted the output and the command you used.
slowcon has quit [Quit: slowcon]
<bobdobbs> ok...
<bnagy> bobdobbs: btw there's also #rubyonrails for rails specific help
<bobdobbs> oh cool
nism has joined #ruby
JasmeetQA1 has joined #ruby
<bobdobbs> This is the output of 'rails new demo': http://hastebin.com/hoyepokolu.dos
dodosan has joined #ruby
jwang has quit [Read error: Connection reset by peer]
<benzrf> @@vars are scoped lexically to class blocks right?
JasmeetQA has quit [Ping timeout: 240 seconds]
jzig has joined #ruby
<benzrf> or rather, @@vars are scoped to class objects, but lookup is scoped lexically
<benzrf> or something
<pipework> bobdobbs: You might also want to use a better ruby than your package manager ruby.
<pipework> bobdobbs: I would suggest looking into ruby-install and chruby for a development environment.
<bobdobbs> not an option, I'm afraid. I have to match an environment that I'll be working with
Guest81327 has left #ruby [#ruby]
<pipework> Unfortunately then you'll have to wait for someone far more patient than I. If you're stuck using a broken ruby package, I'll have my warrior clan pray your soul makes it to Valhalla safely.
toasty has joined #ruby
* bobdobbs kills finest goat, burns as offering to norns
<bobdobbs> pipework: how do we know that we have brokenness?
<pipework> bobdobbs: The distro repository package for ruby is packaged wrong.
MattStratton has joined #ruby
Hobogrammer_ has quit [Ping timeout: 272 seconds]
<bobdobbs> oh crap. I just noticed that that error is coming from system ruby, not my rbenv ruby.
jzig has quit [Ping timeout: 260 seconds]
<bobdobbs> I thought I'd completely removed system ruby. I think I have the system ruby that will not die.
<bobdobbs> zombie ruby
tcopp has joined #ruby
<pipework> Feed me, seymour.
* bobdobbs feeds killer alien plant
fijimunkii has joined #ruby
endash_ has quit [Quit: endash_]
dingus_khan has joined #ruby
pierre1_ has joined #ruby
newleaf has quit [Remote host closed the connection]
toasty has quit [Remote host closed the connection]
freezey has joined #ruby
tcopp has quit [Ping timeout: 240 seconds]
mengu has joined #ruby
rubyracer has quit [Quit: Konversation terminated!]
<bobdobbs> looks like installing the deps one-by-one works. kinda tedious thouhg
<centrx> Use bundler
JasmeetQA has joined #ruby
JasmeetQA1 has quit [Ping timeout: 265 seconds]
fgo has joined #ruby
freezey has quit [Ping timeout: 245 seconds]
Vivekananda has quit [Remote host closed the connection]
Xiti has quit [Quit: Leaving]
vlad_starkov has joined #ruby
fgo has quit [Client Quit]
Xiti has joined #ruby
pwh has quit []
jzig has joined #ruby
OrangejuiceJames has quit [Remote host closed the connection]
<pipework> Use bundler
guilleiguaran has quit [Ping timeout: 245 seconds]
pallavi_ has quit [Ping timeout: 245 seconds]
randym_ has quit [Ping timeout: 245 seconds]
cbetta has quit [Ping timeout: 272 seconds]
yacks has joined #ruby
makara has quit [Quit: Leaving]
pallavi_ has joined #ruby
randym_ has joined #ruby
guilleiguaran has joined #ruby
makara has joined #ruby
cbetta has joined #ruby
jzig has quit [Ping timeout: 252 seconds]
kenndel_ has quit [Read error: Connection reset by peer]
aniM has joined #ruby
<bobdobbs> so bundler requires a cofig file, with the names of the deps, right?
kenndel_ has joined #ruby
<lagweezle> Sort of.
shawnjgoff has quit [Ping timeout: 265 seconds]
<pipework> bobdobbs: A Gemfile
<pipework> That comes with your rails application when you generate it.
<bobdobbs> but thats the issue: I can't generate a rails app with the deps
<pipework> bobdobbs: if you install the rails gem, it installs the deps.
mloveless has quit [Remote host closed the connection]
<bobdobbs> huh
axl_ has quit [Quit: axl_]
<bobdobbs> somehow I've been able to install rails without without having the deps installed
yasushi has joined #ruby
<bnagy> #rubyonrails
OdNairy has joined #ruby
petey has joined #ruby
stonevil has joined #ruby
_tpavel has joined #ruby
yasushi has quit [Ping timeout: 252 seconds]
Mon_Ouie has joined #ruby
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby
axl_ has joined #ruby
tcopp has joined #ruby
mweshi has quit [Quit: mweshi]
george2 has quit [Quit: No Ping reply in 180 seconds.]
petey has quit [Ping timeout: 252 seconds]
george2 has joined #ruby
xcv has joined #ruby
stonevil has quit [Ping timeout: 265 seconds]
tagrudev has joined #ruby
tonni has quit [Remote host closed the connection]
heftig has quit [Quit: Quitting]
tvw has joined #ruby
pierre1_ has quit [Ping timeout: 260 seconds]
lxsameer has joined #ruby
tcopp has quit [Ping timeout: 265 seconds]
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
Astralum has joined #ruby
Aryasam_ has quit [Ping timeout: 252 seconds]
failshel_ has joined #ruby
Iravan has joined #ruby
decoponio has joined #ruby
ayaz has joined #ruby
tylersmith has quit [Remote host closed the connection]
tylersmith has joined #ruby
joelroa has joined #ruby
axl_ has quit [Quit: axl_]
vlad_starkov has quit [Ping timeout: 265 seconds]
b00stfr3ak has quit [Read error: Operation timed out]
xcv has quit [Remote host closed the connection]
earthquake has quit [Quit: earthquake]
Aryasam has joined #ruby
funburn has quit [Quit: funburn]
joelroa has quit [Ping timeout: 248 seconds]
tylersmith has quit [Ping timeout: 265 seconds]
tonni has joined #ruby
Hobogrammer_ has joined #ruby
Aryasam has quit [Ping timeout: 260 seconds]
toasty has joined #ruby
subbyyy has quit [Ping timeout: 265 seconds]
sdwrage has quit [Quit: This computer has gone to sleep]
Vivekananda has joined #ruby
mdpatrick_ has quit [Ping timeout: 245 seconds]
vongrippen has quit [Ping timeout: 245 seconds]
failshel_ has quit [Remote host closed the connection]
CaptainJet has quit []
agjacome has joined #ruby
sdwrage has joined #ruby
Mon_Ouie has quit [Read error: Operation timed out]
cheeti has joined #ruby
subbyyy has joined #ruby
cheeti has quit [Client Quit]
cheeti has joined #ruby
cheeti has quit [Client Quit]
aniM has quit [Ping timeout: 265 seconds]
JasmeetQA1 has joined #ruby
toasty has quit [Remote host closed the connection]
MattStratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
aniM has joined #ruby
oso96_2000 is now known as oso|away
kevinykchan has joined #ruby
freezey has joined #ruby
kobain has quit [Ping timeout: 252 seconds]
JasmeetQA has quit [Ping timeout: 260 seconds]
joelroa has joined #ruby
kobain has joined #ruby
fgo has joined #ruby
freezey has quit [Read error: Operation timed out]
subbyyy has quit [Ping timeout: 272 seconds]
vlad_starkov has joined #ruby
Aryasam has joined #ruby
amclain has quit [Quit: Leaving]
<shevy> does one of you guys knows if I could use readline on ruby on windows?
joelroa has quit [Ping timeout: 265 seconds]
<shevy> I can not test here at home because I have only linux :(
<benzrf> woop woop
<benzrf> i wrote a simple minimal macro thing w/ polyglot and stuff
<benzrf> B)
iliketur_ has quit [Quit: Textual IRC Client: www.textualapp.com]
<benzrf> neat.
<shevy> so young
<shevy> so full of energy
<pipework> shevy: make a VM!
jzig has joined #ruby
<shevy> and such a tragic young death
<benzrf> shevy: so old
<benzrf> so full of spite
<benzrf> -smug-
<shevy> and proudly so!!!
<benzrf> defmacro :twice do |e1, e2, body| b1 = body.gsub(s(:call, nil, :_), e1) b2 = body.gsub(s(:call, nil, :_), e2) s(:block, b1, b2)
<benzrf> end
predator117 has joined #ruby
<benzrf> oop
<benzrf> Pasting...
<benzrf> ~macros
<benzrf> shitty ass macros
stonevil has joined #ruby
<benzrf> get hype
<benzrf> what was the other thing that did em actually ok
<centrx> ass macros is new ruby 2.0+ feature
<shevy> god is that perl?
<benzrf> :-D
<pipework> assmacros are inherited from perl
toasty has joined #ruby
dodosan has quit [Remote host closed the connection]
<benzrf> brb writing assmacros.gemspec
venkat_ has quit []
<shevy> k now we know that ruby can look uglier than perl
predator217 has quit [Ping timeout: 265 seconds]
<benzrf> we knew that already
<shevy> s(:call, nil, :_)
tonni has quit [Read error: Connection reset by peer]
<shevy> that's the part that tops it all
<shevy> why did you not use :nil for sake of consistency there?
<shevy> or wait
<shevy> s(:_, :__, :___)
<shevy> there
evilbug has quit [Quit: Leaving]
<shevy> proper assmacroing now
dodosan has joined #ruby
jzig has quit [Ping timeout: 265 seconds]
stonevil has quit [Ping timeout: 240 seconds]
<benzrf> because that's how rubyparser does it
<benzrf> dang
<benzrf> bye now
benzrf has left #ruby [#ruby]
bal has joined #ruby
centrx has quit [Quit: Leaving]
tyl has joined #ruby
tyl has quit [Client Quit]
mehlah has quit [Quit: Leaving...]
tonni has joined #ruby
<shevy> EPIC QUOTE
<shevy> "While Cobol is overly verbose, over used, and has an almost undead market presence. So will Java in 30 years."
Aryasam has quit [Read error: Connection reset by peer]
anarang has joined #ruby
Xeago has joined #ruby
solars has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
tcopp has joined #ruby
aniM has quit [Ping timeout: 265 seconds]
predator117 has quit [Ping timeout: 252 seconds]
kitak has quit [Read error: Connection reset by peer]
kitak has joined #ruby
Aryasam has joined #ruby
gja has joined #ruby
gja has joined #ruby
gja has quit [Changing host]
tonni has quit [Read error: Connection reset by peer]
tcopp has quit [Ping timeout: 245 seconds]
dingus_khan has quit [Remote host closed the connection]
toasty has quit [Remote host closed the connection]
dubios has quit [Excess Flood]
dubios has joined #ruby
dubios has quit [Excess Flood]
Wolland has quit []
sdwrage has quit [Quit: This computer has gone to sleep]
dubios has joined #ruby
predator117 has joined #ruby
tonni has joined #ruby
dubsteph has joined #ruby
jsmoov has joined #ruby
jprovazn has joined #ruby
monkegjinni has joined #ruby
michael_lee has joined #ruby
blaxter_ has joined #ruby
Findegil has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
vlad_starkov has quit [Ping timeout: 252 seconds]
dubsteph has quit [Ping timeout: 248 seconds]
dodosan has quit [Remote host closed the connection]
OdNairy has quit []
michael_lee has quit [Max SendQ exceeded]
aniM has joined #ruby
michael_lee has joined #ruby
monkegjinni has quit [Ping timeout: 265 seconds]
dayepa has joined #ruby
zcreative has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
lurch_ has joined #ruby
parduse has quit [Ping timeout: 245 seconds]
parduse has joined #ruby
parduse has quit [Changing host]
parduse has joined #ruby
gja has quit [Quit: This computer has gone to sleep]
recurrence has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
vlad_starkov has joined #ruby
Xeago has quit [Remote host closed the connection]
mhenrixon|afk is now known as mhenrixon
sski has quit [Remote host closed the connection]
senayar has joined #ruby
sski has joined #ruby
Xeago has joined #ruby
ahawkins has joined #ruby
Xeago has quit [Remote host closed the connection]
michael_lee has quit [Max SendQ exceeded]
tonni has quit [Ping timeout: 245 seconds]
dseitz has quit [Quit: Textual IRC Client: www.textualapp.com]
andikr has joined #ruby
michael_lee has joined #ruby
parduse has quit [Ping timeout: 248 seconds]
djdb has joined #ruby
dodosan has joined #ruby
jonah_k has quit [Remote host closed the connection]
zigomir has joined #ruby
aganov has joined #ruby
parduse has joined #ruby
parduse has left #ruby [#ruby]
parduse has joined #ruby
parduse has joined #ruby
parduse has quit [Changing host]
closer has quit [Ping timeout: 256 seconds]
greenarrow has joined #ruby
tonni has joined #ruby
TMM has joined #ruby
yarou has quit [Remote host closed the connection]
kobain has quit []
ndrei has joined #ruby
RoxasShadowRS has joined #ruby
freezey has joined #ruby
closer has joined #ruby
ktosiek has joined #ruby
Al___ has joined #ruby
joelroa has joined #ruby
toasty has joined #ruby
tungd has quit [Read error: Connection reset by peer]
parduse has quit [Read error: Connection reset by peer]
parduse has joined #ruby
parduse is now known as Guest56028
Guest56028 has left #ruby [#ruby]
freezey has quit [Ping timeout: 252 seconds]
pskosinski_ has joined #ruby
Aryasam has quit [Ping timeout: 252 seconds]
StrongBoy has joined #ruby
StrongBoy has quit []
joelroa has quit [Ping timeout: 240 seconds]
tonni has quit [Remote host closed the connection]
pskosinski has quit [Ping timeout: 240 seconds]
tonni has joined #ruby
jzig has joined #ruby
greenarrow has quit [Quit: 500]
dayepa has quit [Ping timeout: 245 seconds]
jsmoov has left #ruby [#ruby]
dayepa has joined #ruby
jsmoov has joined #ruby
tonni has quit [Read error: Connection reset by peer]
deens has joined #ruby
einarj has joined #ruby
mhenrixon is now known as mhenrixon|afk
Aryasam has joined #ruby
mhenrixon|afk is now known as mhenrixon
stonevil has joined #ruby
OdNairy has joined #ruby
Aryasam has quit [Read error: Connection reset by peer]
pskosinski_ has quit [Ping timeout: 240 seconds]
jzig has quit [Ping timeout: 272 seconds]
Aryasam has joined #ruby
aryaching has joined #ruby
dodosan has quit [Remote host closed the connection]
vlad_starkov has quit [Remote host closed the connection]
parduse has joined #ruby
parduse has quit [Changing host]
parduse has joined #ruby
ndrei has quit [Ping timeout: 245 seconds]
tesuji has joined #ruby
stonevil has quit [Ping timeout: 252 seconds]
ndrei has joined #ruby
Aryasam has quit [Read error: Connection reset by peer]
aryaching has quit [Read error: Connection reset by peer]
dayepa has quit [Quit: dayepa]
petey has joined #ruby
claymore has joined #ruby
aryaching has joined #ruby
aryaching has quit [Read error: Connection reset by peer]
petey has quit [Ping timeout: 260 seconds]
ghr has joined #ruby
camilasan has joined #ruby
ghr has quit [Max SendQ exceeded]
tcopp has joined #ruby
timonv has joined #ruby
rdark has joined #ruby
fgo has quit [Remote host closed the connection]
poulson has joined #ruby
timonv has quit [Remote host closed the connection]
greenarrow has joined #ruby
Ariadeno has joined #ruby
telling has quit [Changing host]
telling has joined #ruby
kitak has quit [Remote host closed the connection]
jackneill has joined #ruby
parduse has quit [Ping timeout: 240 seconds]
toasty has quit [Remote host closed the connection]
tcopp has quit [Ping timeout: 240 seconds]
Al___ has quit [Read error: Connection reset by peer]
mikecmpbll has joined #ruby
Al___ has joined #ruby
aspiers has joined #ruby
<Nilium> I need to plot some sort of scheme to get people interested in my ruby gui gem so I can get other people to work on it for me.
parduse has joined #ruby
parduse has quit [Changing host]
parduse has joined #ruby
tonni has joined #ruby
Al___ has quit [Client Quit]
kitak has joined #ruby
Astralum has quit [Quit: Leaving]
phansch has quit [Quit: Leaving]
claymore has quit [Ping timeout: 260 seconds]
interlude has joined #ruby
heftig has joined #ruby
nvrch has joined #ruby
claymore has joined #ruby
dingus_khan has joined #ruby
mikecmpbll has quit [Quit: i've nodded off.]
robbyoconnor has joined #ruby
robbyoconnor has quit [Changing host]
robbyoconnor has joined #ruby
stonevil has joined #ruby
diegoviola has quit [Quit: WeeChat 0.4.3]
__greg has quit [Quit: __greg]
minivan has joined #ruby
dingus_khan has quit [Ping timeout: 272 seconds]
RoryHughes has joined #ruby
joonty_ has joined #ruby
vlad_starkov has joined #ruby
MrBy has joined #ruby
joonty has quit [Ping timeout: 252 seconds]
yacks has quit [Ping timeout: 252 seconds]
ikaros has joined #ruby
mengu has quit [Ping timeout: 240 seconds]
aryaching has joined #ruby
mikecmpbll has joined #ruby
kennym has joined #ruby
vlad_starkov has quit [Ping timeout: 260 seconds]
ringaroses has joined #ruby
himsin has joined #ruby
<RubyPanther> Nilium: Just make it totally awesome
<Nilium> What I find totally awesome is not guaranteed to be what other people find totally awesome.
tvw has quit [Remote host closed the connection]
olivier_bK has joined #ruby
<Nilium> After all, I think the event propagation stuff I wrote for the gui gem is awesome, but nobody else will probably ever think that.
<RubyPanther> So be more awesome
dangerousdave has joined #ruby
* Nilium hits RubyPanther with a stick
<RubyPanther> lol
<RubyPanther> One problem I see is that Gtk is so awesome already
Ariadeno has quit [Ping timeout: 248 seconds]
fgo has joined #ruby
deens has quit []
batman____ has joined #ruby
<Nilium> One problem I see is that Gtk is boring and doesn't play nice with OS X.
stonevil has quit [Quit: Computer has gone to sleep.]
<Nilium> That said, I'm not writing a native GUI in the first place
krz has quit [Ping timeout: 248 seconds]
monkegjinni has joined #ruby
parduse has quit [Ping timeout: 240 seconds]
francisfish has joined #ruby
batman___ has quit [Ping timeout: 252 seconds]
parduse has joined #ruby
parduse has quit [Changing host]
parduse has joined #ruby
freezey has joined #ruby
fgo has quit [Ping timeout: 265 seconds]
joelroa has joined #ruby
mocfive has quit [Remote host closed the connection]
krz has joined #ruby
francisfish has quit [Ping timeout: 245 seconds]
mocfive has joined #ruby
yacks has joined #ruby
arctaruz has joined #ruby
joelroa_ has joined #ruby
minivan has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
freezey has quit [Ping timeout: 252 seconds]
fgo has joined #ruby
interlude has quit [Quit: Leaving]
apeiros has quit [Remote host closed the connection]
mengu has joined #ruby
sparrovv has joined #ruby
joelroa has quit [Ping timeout: 265 seconds]
jzig has joined #ruby
joelroa has joined #ruby
deadlock has joined #ruby
Astralum has joined #ruby
apeiros has joined #ruby
Advocation has joined #ruby
mocfive has quit [Ping timeout: 248 seconds]
joelroa_ has quit [Ping timeout: 248 seconds]
marr has joined #ruby
pedda has joined #ruby
fgo has quit [Ping timeout: 248 seconds]
mojjojo has joined #ruby
ghr has joined #ruby
ghr has quit [Max SendQ exceeded]
jzig has quit [Ping timeout: 260 seconds]
parduse has quit [Ping timeout: 265 seconds]
joelroa has quit [Ping timeout: 240 seconds]
obs_ has joined #ruby
aryaching has quit [Ping timeout: 252 seconds]
joelroa has joined #ruby
nanoyak has quit [Quit: Computer has gone to sleep.]
parduse has joined #ruby
parduse is now known as Guest81073
ghr has joined #ruby
hrrz has joined #ruby
Guest81073 is now known as parduse
parduse is now known as Guest54318
Jdubs has joined #ruby
dangerousdave has quit [Quit: My Mac Pro has gone to sleep. ZZZzzz…]
timonv has joined #ruby
Findegil has joined #ruby
timonv has quit [Remote host closed the connection]
minivan has joined #ruby
monkegjinni has quit [Remote host closed the connection]
joelroa has quit [Ping timeout: 260 seconds]
monkegjinni has joined #ruby
joelroa has joined #ruby
kennym has quit [Remote host closed the connection]
aniM has quit [Ping timeout: 245 seconds]
MrBy2 has joined #ruby
eddpeterson has joined #ruby
Ariadeno has joined #ruby
RoryHughes has quit []
MrBy has quit [Ping timeout: 265 seconds]
monkegjinni has quit [Ping timeout: 248 seconds]
joelroa has quit [Ping timeout: 252 seconds]
mehlah has joined #ruby
joelroa has joined #ruby
joelroa has quit [Max SendQ exceeded]
tobiasvl has quit [Quit: RHEL6 -> Fedora 20]
vlad_starkov has joined #ruby
tcopp has joined #ruby
joelroa has joined #ruby
claymore has quit [Ping timeout: 260 seconds]
yacks has quit [Ping timeout: 248 seconds]
greenarrow has quit [Quit: 500]
Astralum has quit [Quit: Leaving]
mehlah has quit [Client Quit]
Guest54318 has quit [Ping timeout: 252 seconds]
claymore has joined #ruby
jmeeuwen_ has joined #ruby
jmeeuwen has quit [Read error: Connection reset by peer]
jmeeuwen_ is now known as jmeeuwen
yacks has joined #ruby
Guest54318 has joined #ruby
Guest54318 has left #ruby [#ruby]
parduse has joined #ruby
shaunbaker has joined #ruby
parduse is now known as Guest14740
tcopp has quit [Ping timeout: 265 seconds]
joelroa has quit [Ping timeout: 240 seconds]
nichtdiebohne has joined #ruby
joelroa has joined #ruby
Zai00 has joined #ruby
joelroa_ has joined #ruby
monkegjinni has joined #ruby
shaunbaker has quit [Remote host closed the connection]
jlebrech has joined #ruby
<ixti> why sometimes `extend Forwardable` fails with uninitialized constant error
<ixti> while `extend ::Forwardable` works perfectly
vlad_starkov has quit [Remote host closed the connection]
bleak2 has quit [Ping timeout: 245 seconds]
joelroa has quit [Ping timeout: 240 seconds]
Guest14740 has quit [Ping timeout: 265 seconds]
joelroa has joined #ruby
Hiall has quit [Quit: hiall]
Guest14740 has joined #ruby
[1]Ariadeno has joined #ruby
Guest14740 has left #ruby [#ruby]
parduse has joined #ruby
greenarrow has joined #ruby
<heftig> ixti: the context you're in doesn't inherit from Object. for example, if you're inside a BasicObject
<ixti> heftig: that's true
<ixti> oh
<ixti> stupid me
<ixti> heftig: thanks!
joelroa_ has quit [Ping timeout: 264 seconds]
m1lt0n has joined #ruby
Ariadeno has quit [Ping timeout: 265 seconds]
timonv has joined #ruby
klaut has joined #ruby
shaunbaker has joined #ruby
Jdubs has quit [Remote host closed the connection]
mojjojo has quit [Quit: mojjojo]
joelroa has quit [Ping timeout: 260 seconds]
plexus_ has joined #ruby
joelroa has joined #ruby
mojjojo has joined #ruby
fgo has joined #ruby
joelroa_ has joined #ruby
parduse has quit [Ping timeout: 260 seconds]
toasty has joined #ruby
shaunbaker has quit [Remote host closed the connection]
aaronmcadam has joined #ruby
joelroa has quit [Ping timeout: 252 seconds]
sski has quit [Remote host closed the connection]
joelroa has joined #ruby
aaronmcadam has quit [Remote host closed the connection]
aaronmcadam has joined #ruby
sski has joined #ruby
joelroa_ has quit [Read error: Operation timed out]
shaunbaker has joined #ruby
parduse has joined #ruby
karupanerura is now known as zz_karupanerura
parduse is now known as Guest16372
relix has joined #ruby
zeeraw has joined #ruby
RoryHughes has joined #ruby
Hiall has joined #ruby
toasty has quit [Ping timeout: 248 seconds]
joelroa_ has joined #ruby
joelroa has quit [Ping timeout: 264 seconds]
[gmi] has joined #ruby
sski has quit [Ping timeout: 240 seconds]
sparrovv has quit [Remote host closed the connection]
joelroa has joined #ruby
canton7-mac has joined #ruby
workmad3 has joined #ruby
francisfish has joined #ruby
codenapper has joined #ruby
Guest16372 has quit [Ping timeout: 264 seconds]
Hiall has quit [Client Quit]
monkegji_ has joined #ruby
joelroa_ has quit [Ping timeout: 264 seconds]
Iravan has quit [Ping timeout: 252 seconds]
zarul has quit [Ping timeout: 272 seconds]
joelroa has quit [Ping timeout: 260 seconds]
joelroa has joined #ruby
prc has joined #ruby
monkegji_ has quit [Remote host closed the connection]
yasushi has joined #ruby
fantazo has joined #ruby
freezey has joined #ruby
joelroa_ has joined #ruby
mojjojo has quit [Quit: mojjojo]
monkegjinni has quit [Remote host closed the connection]
OdNairy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
workmad3 has quit [Ping timeout: 265 seconds]
workmad3 has joined #ruby
joelroa has quit [Ping timeout: 260 seconds]
joelroa has joined #ruby
kaliya has joined #ruby
joelroa has quit [Max SendQ exceeded]
ephemerian has joined #ruby
parduse has joined #ruby
parduse has quit [Changing host]
parduse has joined #ruby
popl has joined #ruby
popl has joined #ruby
joelroa_ has quit [Ping timeout: 240 seconds]
freezey has quit [Ping timeout: 264 seconds]
speakingcode has quit [Ping timeout: 240 seconds]
joelroa has joined #ruby
OdNairy has joined #ruby
jonno11 has joined #ruby
jzig has joined #ruby
monkegjinni has joined #ruby
ndrei has quit [Ping timeout: 252 seconds]
zeeraw has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
matrixise has quit [Read error: Operation timed out]
jxport has quit [Read error: Operation timed out]
matrixise has joined #ruby
jxport has joined #ruby
TheNumb has quit [Read error: Operation timed out]
pimpthin1 has quit [Read error: Operation timed out]
pimpthink has joined #ruby
monkegjinni has quit [Remote host closed the connection]
TheNumb has joined #ruby
Jelco has quit [Ping timeout: 246 seconds]
ndrei has joined #ruby
workmad3 has quit [Remote host closed the connection]
Zunonia has quit [Quit: Computer has gone to sleep.]
workmad3 has joined #ruby
mengu has quit [Remote host closed the connection]
kristiandelay has joined #ruby
Zunonia has joined #ruby
toretore has joined #ruby
joonty_ has quit [Quit: WeeChat 0.4.2]
joelroa has quit [Ping timeout: 272 seconds]
parduse has quit [Ping timeout: 252 seconds]
joonty has joined #ruby
joelroa has joined #ruby
dubsteph has joined #ruby
ace_striker has joined #ruby
jzig has quit [Ping timeout: 265 seconds]
minivan has quit [Remote host closed the connection]
parduse has joined #ruby
ace_striker is now known as Guest7797
parduse is now known as Guest3521
mojjojo has joined #ruby
Shidash has quit [Ping timeout: 264 seconds]
Jelco has joined #ruby
Guest3521 has left #ruby [#ruby]
ndrei has quit [Ping timeout: 265 seconds]
joelroa_ has joined #ruby
marr has quit [Ping timeout: 260 seconds]
kristiandelay has quit [Ping timeout: 265 seconds]
Zunonia has quit [Ping timeout: 252 seconds]
parduse has joined #ruby
parduse has left #ruby [#ruby]
parduse has joined #ruby
ndrei has joined #ruby
workmad3 has quit [Read error: Connection reset by peer]
Astralum has joined #ruby
workmad3 has joined #ruby
timonv has quit [Remote host closed the connection]
sski has joined #ruby
joelroa has quit [Ping timeout: 264 seconds]
joelroa has joined #ruby
monkegjinni has joined #ruby
petey has joined #ruby
joelroa_ has quit [Ping timeout: 264 seconds]
alexherbo2 has joined #ruby
joelroa_ has joined #ruby
Astralum has quit [Client Quit]
workmad3 has quit [Ping timeout: 265 seconds]
ephemerian has quit [Read error: Connection reset by peer]
joelroa has quit [Ping timeout: 265 seconds]
joelroa has joined #ruby
petey has quit [Ping timeout: 265 seconds]
workmad3 has joined #ruby
elaptics`away is now known as elaptics
joelroa_ has quit [Ping timeout: 260 seconds]
Hiall has joined #ruby
ephemerian has joined #ruby
tcopp has joined #ruby
joelroa_ has joined #ruby
tyl has joined #ruby
tyl has quit [Client Quit]
bandsaw1961 has joined #ruby
joelroa has quit [Ping timeout: 264 seconds]
MrBy2 has quit [Quit: This computer has gone to sleep]
skaflem has joined #ruby
joelroa has joined #ruby
joelroa_ has quit [Ping timeout: 245 seconds]
Astralum has joined #ruby
tcopp has quit [Ping timeout: 240 seconds]
gozali has quit []
nomenkun has joined #ruby
workmad3 has quit [Ping timeout: 265 seconds]
lkba has quit [Ping timeout: 272 seconds]
joelroa_ has joined #ruby
MrBy2 has joined #ruby
hiall_ has joined #ruby
Astralum has quit [Read error: Connection reset by peer]
<pimpthink> my_array.inject(0) { |n| if n.even? then memo + n else memo end }
<pimpthink> Is there a more idiomatic way of achieving this?
Hiall has quit [Ping timeout: 265 seconds]
hiall_ is now known as hiall
joelroa has quit [Ping timeout: 265 seconds]
Astralum has joined #ruby
joelroa has joined #ruby
timonv has joined #ruby
bandsaw1961 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<plexus_> my_array.select(&:even?).inject(:+) perhaps?
joelroa_ has quit [Ping timeout: 265 seconds]
<plexus_> pimpthink
tvw has joined #ruby
yasushi has quit [Remote host closed the connection]
vlad_starkov has joined #ruby
parduse has quit [Ping timeout: 260 seconds]
mojjojo has quit [Quit: mojjojo]
workmad3 has joined #ruby
joelroa has quit [Ping timeout: 265 seconds]
parduse has joined #ruby
parduse has quit [Changing host]
parduse has joined #ruby
joelroa has joined #ruby
nomenkun has quit [Read error: Connection reset by peer]
nomenkun has joined #ruby
jonno11 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
monkegjinni has quit [Remote host closed the connection]
jonno11 has joined #ruby
<pimpthink> thank you plexus_
<pimpthink> plexus_: why is &:even? needed, but only :+ -- i.e., why not &:+
<pimpthink> General ruby syntax Q
vlad_starkov has quit [Ping timeout: 248 seconds]
<plexus_> yeah almost always you would have to add an &
<pimpthink> when do you not?
<plexus_> it tells ruby that you want to pass the value as a block, so the symbol gets converted to a block
<plexus_> inject is pretty much the only exception I think
<pimpthink> that seems horribly inconsistent :(
<plexus_> if you pass it a symbol and no block it knows what to do
<plexus_> the inject syntax probably predates Symbol#to_proc
<plexus_> people haven't always been using this &:foo syntax, some people came up with it by defining the to_proc method on Symbol
<plexus_> and then it got added to standard Ruby
<plexus_> [1,2,3].inject(&:+) also works BTW
joelroa has quit [Ping timeout: 272 seconds]
joelroa has joined #ruby
Al___ has joined #ruby
<pimpthink> plexus_: i might stick to using & -- not sure if that's stupid
<canton7-mac> plexus_, #inject accepted a symbol before the &: syntax was introduced - it was ahead of its time
workmad3 has quit [Remote host closed the connection]
<plexus_> pimpthink: that's probably fine, like you say it's more consistent, might be less surprising to the next person reading your code
<plexus_> canton7-mac: yeah that's what I thought
joelroa_ has joined #ruby
monkegjinni has joined #ruby
joelroa has quit [Read error: Operation timed out]
monkegjinni has quit [Remote host closed the connection]
joelroa has joined #ruby
workmad3 has joined #ruby
hobodave has quit [Remote host closed the connection]
joelroa_ has quit [Ping timeout: 240 seconds]
shaunbaker has quit [Remote host closed the connection]
sleetdrop has joined #ruby
sleetdrop has left #ruby ["Textual IRC Client: www.textualapp.com"]
Akuma has joined #ruby
lxsameer has quit [Quit: Leaving]
joelroa has quit [Ping timeout: 245 seconds]
rdark has quit [Ping timeout: 248 seconds]
JasmeetQA has joined #ruby
joelroa has joined #ruby
dawkirst has quit [Ping timeout: 260 seconds]
nhhagen has joined #ruby
JasmeetQA1 has quit [Ping timeout: 264 seconds]
asmodlol has joined #ruby
rdark has joined #ruby
prc1 has joined #ruby
shaunbaker has joined #ruby
workmad3 has quit [Ping timeout: 260 seconds]
joelroa_ has joined #ruby
prc has quit [Ping timeout: 248 seconds]
workmad3 has joined #ruby
tharindu has joined #ruby
joelroa has quit [Ping timeout: 240 seconds]
zeeraw has joined #ruby
jsmoov has quit [Remote host closed the connection]
joelroa has joined #ruby
joelroa has quit [Max SendQ exceeded]
endash_ has joined #ruby
freezey has joined #ruby
ringaroses has quit [Ping timeout: 264 seconds]
joelroa_ has quit [Ping timeout: 265 seconds]
raphaelivan has joined #ruby
joelroa has joined #ruby
parduse has quit [Ping timeout: 252 seconds]
prc1 has quit [Ping timeout: 240 seconds]
parduse has joined #ruby
parduse has quit [Changing host]
parduse has joined #ruby
prc has joined #ruby
yasushi has joined #ruby
Deele has quit [Ping timeout: 245 seconds]
joelroa_ has joined #ruby
joelroa_ has quit [Max SendQ exceeded]
freezey has quit [Ping timeout: 248 seconds]
lyanchih_ has quit [Ping timeout: 252 seconds]
aniM has joined #ruby
mengu has joined #ruby
jzig has joined #ruby
joelroa has quit [Ping timeout: 260 seconds]
deadlock has quit [Read error: Connection reset by peer]
dawkirst has joined #ruby
shaunbak_ has joined #ruby
joelroa has joined #ruby
joelroa has quit [Max SendQ exceeded]
yasushi has quit [Remote host closed the connection]
shaunbaker has quit [Ping timeout: 245 seconds]
joelroa has joined #ruby
jonno11 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Guest7797 has quit [Ping timeout: 245 seconds]
Deele has joined #ruby
yasushi has joined #ruby
jzig has quit [Ping timeout: 260 seconds]
guardianx has joined #ruby
Fire-Dragon-DoL has joined #ruby
tedstriker has joined #ruby
<pontiki> something has just gone horribly wrong with pry
parduse has quit [Ping timeout: 272 seconds]
djdb has quit [Quit: Ухожу я от вас (xchat 2.4.5 или старше)]
<pontiki> when i start it up, it just sits there producing no output
joelroa_ has joined #ruby
postmodern has quit [Quit: Leaving]
thomasxie has left #ruby [#ruby]
Al___ has quit [Quit: Al___]
yasushi has quit [Remote host closed the connection]
joelroa has quit [Ping timeout: 272 seconds]
lizzin has joined #ruby
joonty has quit [Ping timeout: 252 seconds]
lizzin has left #ruby [#ruby]
marr has joined #ruby
joelroa has joined #ruby
<pontiki> and it's taking like 100% cpu
newleaf has joined #ruby
andy__ has joined #ruby
LexicalScope has quit [Read error: Connection reset by peer]
sensen_ has quit [Quit: leaving]
LexicalScope has joined #ruby
LexicalScope has joined #ruby
LexicalScope has quit [Changing host]
joelroa_ has quit [Ping timeout: 248 seconds]
ctp has joined #ruby
razibog has joined #ruby
parduse has joined #ruby
parduse has quit [Changing host]
parduse has joined #ruby
joelroa_ has joined #ruby
joelroa has quit [Ping timeout: 248 seconds]
joelroa has joined #ruby
joelroa has quit [Max SendQ exceeded]
sailias has joined #ruby
dubsteph has quit [Ping timeout: 265 seconds]
joelroa_ has quit [Ping timeout: 260 seconds]
phansch has joined #ruby
parduse has quit [Ping timeout: 272 seconds]
joelroa has joined #ruby
JasmeetQA has quit [Ping timeout: 245 seconds]
tcopp has joined #ruby
parduse has joined #ruby
parduse has left #ruby [#ruby]
parduse has joined #ruby
parduse has quit [Changing host]
parduse has joined #ruby
hackeron has quit [Ping timeout: 245 seconds]
joelroa_ has joined #ruby
<jokke> hello
<jokke> following code: https://paste.jreinert.com/6Yu/ruby
sailias has quit [Client Quit]
sailias has joined #ruby
<jokke> i know it's rails but my question has nothing to do with rails specifically
<jokke> the code as is doesn't work as expected because defined? super is always nil
<jokke> is there a way that this would work as i'd expect without having to override the method in sub classes
joelroa has quit [Ping timeout: 264 seconds]
joelroa has joined #ruby
tcopp has quit [Ping timeout: 252 seconds]
rdark has quit [Ping timeout: 245 seconds]
<jokke> you know what
<jokke> i just realized i don't even need rule based authentication
<jokke> so forget that :D
joelroa_ has quit [Ping timeout: 265 seconds]
rdark has joined #ruby
joelroa_ has joined #ruby
<pontiki> huh, uninstalled all pry gems, reinstalled pry, now it's working
ndrei has quit [Ping timeout: 264 seconds]
parduse has quit [Ping timeout: 272 seconds]
joelroa has quit [Ping timeout: 260 seconds]
joelroa has joined #ruby
endash_ has quit [Quit: endash_]
joelroa_ has quit [Ping timeout: 252 seconds]
ndrei has joined #ruby
fgo has quit [Remote host closed the connection]
Guest3483 has joined #ruby
Guest3483 is now known as parduse
parduse is now known as Guest44651
joelroa has quit [Ping timeout: 272 seconds]
monkegjinni has joined #ruby
joelroa has joined #ruby
monkegji_ has joined #ruby
monkegji_ has quit [Client Quit]
ixti has quit [Ping timeout: 252 seconds]
angusiguess has joined #ruby
hackeron has joined #ruby
Deele has quit [Ping timeout: 252 seconds]
joelroa has quit [Ping timeout: 252 seconds]
sparrovv has joined #ruby
apeiros has quit [Remote host closed the connection]
michael_lee has quit [Remote host closed the connection]
dubsteph has joined #ruby
joelroa has joined #ruby
monkegjinni has quit [Ping timeout: 272 seconds]
apeiros has joined #ruby
vlad_starkov has joined #ruby
Guest44651 has quit [Ping timeout: 252 seconds]
aniM has quit [Ping timeout: 264 seconds]
sparrovv has quit [Remote host closed the connection]
joelroa_ has joined #ruby
Guest44651 has joined #ruby
Guest44651 is now known as parduse
apeiros has quit [Ping timeout: 252 seconds]
joelroa has quit [Ping timeout: 264 seconds]
parduse is now known as Guest56483
joelroa has joined #ruby
aniM has joined #ruby
monkegjinni has joined #ruby
fgo has joined #ruby
pudidis has joined #ruby
danshultz has joined #ruby
vlad_starkov has quit [Ping timeout: 260 seconds]
pudidis has left #ruby [#ruby]
senayar has quit [Remote host closed the connection]
pudidis has joined #ruby
joelroa_ has quit [Ping timeout: 240 seconds]
sparrovv has joined #ruby
Guest56483 has quit [Ping timeout: 265 seconds]
Guest56483 has joined #ruby
Guest56483 is now known as parduse
yo61 has quit [Ping timeout: 272 seconds]
parduse is now known as Guest44715
rdark has quit [Ping timeout: 240 seconds]
senayar has joined #ruby
popl has quit [Quit: Touch the frog.]
failshell has joined #ruby
rdark has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
yo61 has joined #ruby
joelroa has quit [Ping timeout: 265 seconds]
e^0_ has joined #ruby
pabloh has joined #ruby
sparrovv has quit [Remote host closed the connection]
MrBy3 has joined #ruby
lkba has joined #ruby
freezey has joined #ruby
e^0__ has joined #ruby
e^0_ has quit [Read error: Connection reset by peer]
MrBy2 has quit [Ping timeout: 265 seconds]
jonno11 has joined #ruby
m1lt0n has quit [Quit: leaving]
mengu has quit [Remote host closed the connection]
sailias has quit [Ping timeout: 240 seconds]
rippa has joined #ruby
Ariadeno has joined #ruby
vagner4work has joined #ruby
Lewix has quit [Remote host closed the connection]
razibog has quit [Quit: Leaving.]
popl has quit [Quit: Touch the frog.]
popl has joined #ruby
popl has quit [Client Quit]
freezey has quit [Ping timeout: 272 seconds]
[1]Ariadeno has quit [Ping timeout: 240 seconds]
razibog has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
jonno11 has quit [Ping timeout: 265 seconds]
jzig has joined #ruby
Ariadeno has quit [Client Quit]
popl has quit [Client Quit]
mengu has joined #ruby
shawnjgoff has joined #ruby
kristiandelay has joined #ruby
senayar_ has joined #ruby
_1_arcady2 has joined #ruby
tkuchiki has quit [Remote host closed the connection]
pudidis has quit [Quit: pudidis]
hrrz has quit [Quit: hrrz]
tcopp has joined #ruby
jzig has quit [Ping timeout: 240 seconds]
popl has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
senayar has quit [Ping timeout: 264 seconds]
tharindu has quit [Quit: Leaving...]
_1_arcady2 has quit [Quit: WhatsChat IRC Android APP]
kristiandelay has quit [Ping timeout: 272 seconds]
eka has joined #ruby
andy__ has quit [Remote host closed the connection]
Liothen has quit [Remote host closed the connection]
LadyRainicorn has joined #ruby
Xeago has joined #ruby
AlexRussia has joined #ruby
petey has joined #ruby
popl has quit [Quit: Touch the frog.]
popl has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
arctaruz has quit [Read error: Operation timed out]
Hanmac1 has joined #ruby
popl has left #ruby [#ruby]
petey has quit [Ping timeout: 245 seconds]
Hanmac has quit [Ping timeout: 260 seconds]
shaunbak_ has quit [Remote host closed the connection]
ndrei has quit [Ping timeout: 248 seconds]
ghr has quit [Read error: Operation timed out]
yasushi has joined #ruby
monkegjinni has quit [Ping timeout: 252 seconds]
tobago has joined #ruby
MrBy3 has quit [Ping timeout: 265 seconds]
leonidlm has joined #ruby
popl has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
zeeraw has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
torstein has joined #ruby
<popl> :|
ZadYree has joined #ruby
yasushi has quit [Ping timeout: 248 seconds]
<ZadYree> Hello, I am beginner to ruby and would like to how how to know a good way to remove baz in the string "foo/bar/baz"
tesuji has quit [Read error: Connection reset by peer]
Xeago has quit [Remote host closed the connection]
<popl> >> "foo/bar/baz".sub("baz","")
<eval-in> popl => "foo/bar/" (https://eval.in/102733)
eka has quit [Quit: My computer has gone to sleep. ZZZzzz…]
razibog has quit [Quit: Leaving.]
<ZadYree> popl, well, it seems I wasn't clear enough. In fact, I would like to remove what is after the last '/'
rdark has quit [Ping timeout: 240 seconds]
ghr has joined #ruby
ghr has quit [Max SendQ exceeded]
ndrei has joined #ruby
Xeago has joined #ruby
Zai00 has quit [Ping timeout: 260 seconds]
<ZadYree> But I guess I can do it w/ .sub & a regex
<ZadYree> thanks anyway
Xeago has quit [Remote host closed the connection]
guardianx has quit [Remote host closed the connection]
rdark has joined #ruby
Zai00 has joined #ruby
ghr has joined #ruby
ghr has quit [Max SendQ exceeded]
krz has quit [Quit: WeeChat 0.4.2]
maximski has joined #ruby
<plexus_> ZadYree: note that you can use %r{} syntax which makes it easier to write regexps with a literal /
arctaruz has joined #ruby
<ZadYree> Ah? May you please show me an example?
nhhagen has quit [Remote host closed the connection]
dangerousdave has joined #ruby
<waxjar> >> require "pathname"; Pathname.new("/foo/bar/baz").dirname
<eval-in> waxjar => #<Pathname:/foo/bar> (https://eval.in/102734)
<plexus_> 'foo/bar/baz'.sub(%r{/[^/]*$}, '')
allanm has joined #ruby
allanm has quit [Client Quit]
tcopp has quit [Ping timeout: 260 seconds]
<ZadYree> Ah, cool!
<elaptics> ZadYree: if it's just a simple strip off the end then you could do this
<elaptics> >> str = "foo/bar/baz"; str[0..str.rindex("/")]
<eval-in> elaptics => "foo/bar/" (https://eval.in/102735)
noop has quit [Ping timeout: 260 seconds]
<ZadYree> Oh, this one looks good aswell
Hanmac has joined #ruby
noop has joined #ruby
<plexus_> or this
<plexus_> >> 'foo/bar/baz'[%r{(.*/)},1]
<eval-in> plexus_ => "foo/bar/" (https://eval.in/102736)
<ZadYree> I see
Hanmac1 has quit [Ping timeout: 265 seconds]
fenak has joined #ruby
Deele has joined #ruby
zeeraw has joined #ruby
fenak has quit [Client Quit]
fenak has joined #ruby
monkegjinni has joined #ruby
IceyEC has joined #ruby
vlad_starkov has joined #ruby
DaniG2k has joined #ruby
monkegjinni has quit [Client Quit]
shaunbaker has joined #ruby
popl has quit [Quit: Touch the frog.]
cmoylan has joined #ruby
joelroa has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
nhhagen has joined #ruby
mwillhite has joined #ruby
vlad_starkov has quit [Ping timeout: 240 seconds]
horrror has joined #ruby
horrror has quit [Client Quit]
mwillhite has quit [Client Quit]
phutch1ns has joined #ruby
<artmann_> Hi, I'm using an offical python lib to parse some game data and I would like to build the rest of my solution using ruby. In one instance I get the following output https://gist.github.com/Artmann/0b1a0382e94a6d4272e5
<artmann_> Is there any easy way to convert this string to a ruby array or object?
DaniG2k has quit [Quit: leaving]
yalue has joined #ruby
v0n has joined #ruby
[krisbulman] is now known as krisbulman
cmoylan has quit [Ping timeout: 245 seconds]
aryaching has joined #ruby
<toretore> artmann_: what format is it?
<artmann_> Some kind of python array/struct
Jetchisel has left #ruby ["Unfortunately time is always against us -- *Morpheus*"]
<toretore> and you can't get it to output a different format?
<artmann_> doesn't seem that way
<toretore> i would write a python script to convert it to something like json
tkuchiki has joined #ruby
tibounise has joined #ruby
<artmann_> that's a great idea
<toretore> parsing that in ruby means parsing python, which is probably not very easy
joelroa has quit [Ping timeout: 240 seconds]
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<tibounise> Hello !
<artmann_> Thanks matey
arctaruz has quit [Read error: Operation timed out]
jmeeuwen has quit [Ping timeout: 245 seconds]
freezey has joined #ruby
Hanmac1 has joined #ruby
yasushi has joined #ruby
popl has quit [Quit: Touch the frog.]
<Ivo> artmann_: call json.dumps on it
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
Hanmac has quit [Ping timeout: 272 seconds]
alexherbo2 has quit [Quit: WeeChat 0.4.2]
alexherbo2 has joined #ruby
freezey has quit [Ping timeout: 260 seconds]
popl has quit [Client Quit]
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
AlSquire has joined #ruby
jzig has joined #ruby
alexherbo2 has quit [Client Quit]
alexherbo2 has joined #ruby
Matriks has joined #ruby
Hamburglr has quit [Quit: Textual IRC Client: www.textualapp.com]
phutch1ns has quit [Ping timeout: 240 seconds]
v0n has quit [Ping timeout: 265 seconds]
jzig has quit [Ping timeout: 248 seconds]
sk87 has joined #ruby
jmeeuwen has joined #ruby
rdark has quit [Quit: leaving]
vlad_starkov has joined #ruby
tonni has quit [Remote host closed the connection]
koell has joined #ruby
tonni has joined #ruby
pedda has quit [Quit: Textual IRC Client: www.textualapp.com]
RaCx has joined #ruby
wallerdev has joined #ruby
stryek has joined #ruby
aniM has quit [Ping timeout: 252 seconds]
sdwrage has joined #ruby
monkegjinni has joined #ruby
nfk has joined #ruby
rdark has joined #ruby
_tpavel has quit [Quit: Leaving]
popl has quit [Quit: Touch the frog.]
tonni has quit [Ping timeout: 265 seconds]
popl has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
bogeyd6 has joined #ruby
RaCx_ has joined #ruby
popl has quit [Client Quit]
vasilakisFiL has joined #ruby
himsin has quit [Quit: himsin]
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
mark_locklear has joined #ruby
RaCx has quit [Ping timeout: 272 seconds]
RaCx_ is now known as RaCx
gbt has joined #ruby
<vasilakisFiL> hey guys/girls.. I have a class which has 4 or 5 inner (nested) classes.. all of them (and the outer) use 3 external modules which has some nice util classes.. How can I avoid including the 3 modules in EACH class ?
banister has joined #ruby
dblessing has joined #ruby
rmorello has joined #ruby
nateberkopec has joined #ruby
tgkokk has joined #ruby
vlad_starkov has quit [Ping timeout: 260 seconds]
slowcon has joined #ruby
ndrei has quit [Ping timeout: 245 seconds]
danshultz has quit [Remote host closed the connection]
<wuest> vasilakisFiL: Let the classes inherit from a common class which includes the modules or include a module which includes the modules.
slowcon has quit [Client Quit]
danshultz has joined #ruby
tonni has joined #ruby
jkamenik has joined #ruby
ndrei has joined #ruby
phutch1ns has joined #ruby
bjorkintosh has joined #ruby
bjorkintosh has left #ruby ["Leaving"]
toretore has quit [Ping timeout: 265 seconds]
axl_ has joined #ruby
tibounise has quit [Quit: WeeChat 0.4.2]
<vasilakisFiL> nice! I like the better first idea
<vasilakisFiL> thanks :)
<wuest> Each has its place :) Happy to help!
Salve has joined #ruby
gja has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
nism has quit [Quit: Leaving]
danshultz has quit [Ping timeout: 260 seconds]
ndrei has quit [Ping timeout: 265 seconds]
OdNairy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
gja has quit [Client Quit]
ctp has quit [Quit: Leaving...]
claymore has quit [Read error: Operation timed out]
sailias has joined #ruby
krz has joined #ruby
ffranz has joined #ruby
pico-pete has quit []
mark_locklear has quit [Ping timeout: 272 seconds]
glen has joined #ruby
trhodes has joined #ruby
<glen> hi, what you suggest here how to do it properly: http://sprunge.us/MWZD ?
e^0__ has quit [Quit: WeeChat 0.4.1]
makara has quit [Quit: Leaving]
trhodes_ has quit [Ping timeout: 245 seconds]
DanBoy has quit [Remote host closed the connection]
heftig has quit [Remote host closed the connection]
DanBoy has joined #ruby
RaCx has joined #ruby
MattStratton has joined #ruby
heftig has joined #ruby
popl has quit [Quit: Touch the frog.]
<pontiki> "sprungeus"?
mark_locklear has joined #ruby
raphaelivan has quit [Quit: Leaving.]
<wuest> glen: parens.
<wuest> pontiki: it's Yet Another Pastebin
RaCx has quit [Client Quit]
* pontiki wonders if there's a domain free
<wuest> glen: your call to .map is applying to the array to which you have it attached, rather than the result of concat. The error message it gave you (saying the problem was in the call to Array#concat) was your hint there.
andy___ has joined #ruby
pico-pete has joined #ruby
andy___ is now known as Guest93894
RaCx has joined #ruby
Vivekananda has quit [Read error: Connection reset by peer]
maroloccio has joined #ruby
platzhirsch has joined #ruby
<platzhirsch> Hello dear laid back Rubyists
tgkokk has quit [Quit: WeeChat 0.4.4-dev]
tgkokk has joined #ruby
kindjal has joined #ruby
mlpinit has joined #ruby
camilasan has quit [Remote host closed the connection]
vpretzel has quit [Ping timeout: 245 seconds]
chinkung has joined #ruby
tvl has joined #ruby
<LadyRainicorn> Hello dearest platzhirsch!
tvl is now known as tobiasvl
<platzhirsch> ^^
claymore has joined #ruby
endash_ has joined #ruby
pudidis has joined #ruby
gbt has quit [Quit: Linkinus - http://linkinus.com]
aniM has joined #ruby
gbt has joined #ruby
kung has quit [Ping timeout: 265 seconds]
<wuest> Hey platzhirsch :)
joelroa has joined #ruby
toretore has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
teenwolf has joined #ruby
bandsaw1961 has joined #ruby
razibog has joined #ruby
sambao21 has joined #ruby
gja has joined #ruby
Vivekananda has joined #ruby
ndrei has joined #ruby
tonni has quit [Read error: Connection reset by peer]
joelroa has quit [Read error: Operation timed out]
monkegji_ has joined #ruby
gja has quit [Client Quit]
tkuchiki has quit [Remote host closed the connection]
monkegjinni has quit [Ping timeout: 272 seconds]
zarul has joined #ruby
Mousse_ has joined #ruby
kevinykchan has quit [Quit: Computer has gone to sleep.]
zeeraw has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
ecualombian has joined #ruby
shaunbaker has quit [Remote host closed the connection]
zachallett has joined #ruby
jerius has joined #ruby
yarou has joined #ruby
asmodlol has quit [Remote host closed the connection]
msmith has joined #ruby
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tkuchiki has joined #ruby
__greg has joined #ruby
ace_striker has joined #ruby
ace_striker is now known as Guest77714
axl_ has quit [Quit: axl_]
vongrippen has joined #ruby
kristiandelay has joined #ruby
joonty has joined #ruby
ndrei has quit [Ping timeout: 260 seconds]
jzig has joined #ruby
tonni has joined #ruby
mjs2600 has joined #ruby
razibog has quit [Read error: Connection reset by peer]
mengu has quit [Remote host closed the connection]
kcombs has joined #ruby
ndrei has joined #ruby
srji_ has quit [Quit: leaving]
<glen> wuest: i do want to iterate the %[] and .map to transform (add prefixes) and then .concat to first array
chipotle_ is now known as chipotle
Guest93894 has quit [Remote host closed the connection]
srji has joined #ruby
bandsaw1961 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
arctaruz has joined #ruby
DanBoy has quit [Ping timeout: 240 seconds]
popl has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
_maes_ has joined #ruby
DanBoy has joined #ruby
jzig has quit [Ping timeout: 245 seconds]
<workmad3> glen: wuest's point is that you've done 'ldap_packages.concat(%w[horde samba courier rfc2739 sudo openssh-lpk eaps].map) do ..., rather than your intended 'ldap_packages.concat(%w[horde samba courier rfc2739 sudo openssh-lpk eaps].map do ... end)'
<wuest> glen: parens are still the answer :) Or, for the sake of readability, breaking your code into map, then concat on its own line.
tgkokk has quit [Ping timeout: 265 seconds]
mengu has joined #ruby
v0n has joined #ruby
<wuest> Remember that Enumerator#map => Enumerator
popl has quit [Client Quit]
lkba has quit [Ping timeout: 248 seconds]
<glen> oh, i just changed %[].map { big_array << "...item" }
devdazed has joined #ruby
tgkokk has joined #ruby
<wuest> It's really tempting to avoid parens because they're "not needed" in ruby. Doing so is a bad habit to get into :)
shaunbaker has joined #ruby
zeeraw has joined #ruby
[gmi] has quit [Ping timeout: 252 seconds]
shaunbak_ has joined #ruby
kitak_ has quit [Remote host closed the connection]
kitak_ has joined #ruby
21WACDZM4 has joined #ruby
msuszczy has quit [Remote host closed the connection]
21WACDZM4 has quit [Remote host closed the connection]
sambao21 has quit [Quit: Computer has gone to sleep.]
andy___ has joined #ruby
RaCx_ has joined #ruby
RaCx has quit [Read error: Connection reset by peer]
RaCx_ is now known as RaCx
andy___ is now known as Guest95094
banister has joined #ruby
wallerdev has quit [Quit: wallerdev]
sski has quit [Remote host closed the connection]
tonni has quit [Ping timeout: 265 seconds]
sambao21 has joined #ruby
sski has joined #ruby
shaunbaker has quit [Ping timeout: 245 seconds]
kindjal has quit [Quit: Computer has gone to sleep.]
shawnjgoff has quit [Ping timeout: 264 seconds]
<platzhirsch> wuest: yeah, it's cool when you start with Ruby, feels like you are the wildest programmer ever, but this fades :D
burlyscudd has joined #ruby
<certainty> we fade to grey
<wuest> platzhirsch: yeah. The spectre of maintainability looms :)
monkegji_ has quit [Remote host closed the connection]
johnmilton has joined #ruby
toretore has quit [Read error: No route to host]
newleaf has quit [Ping timeout: 252 seconds]
dawkirst has quit [Read error: Connection timed out]
slowcon has joined #ruby
sski has quit [Ping timeout: 241 seconds]
hackeron has quit [Remote host closed the connection]
<slowcon> morning guys
[gmi] has joined #ruby
<platzhirsch> slowcon: timezone?
chipotle has quit [Quit: cya]
<slowcon> USA - EST
chipotle has joined #ruby
chipotle has quit [Client Quit]
<wuest> hola slowcon
<slowcon> brb, restart
slowcon has quit [Client Quit]
hackeron has joined #ruby
chipotle has joined #ruby
davedev24 has joined #ruby
davedev24 has quit [Read error: Connection reset by peer]
tonni has joined #ruby
davedev24 has joined #ruby
maletor has joined #ruby
davedev24 is now known as newleaf
chipotle_ has joined #ruby
razibog has joined #ruby
cmoylan has joined #ruby
deadlock has joined #ruby
momomomomo has joined #ruby
tungd has joined #ruby
dawkirst has joined #ruby
eka has joined #ruby
chipotle has quit [Ping timeout: 252 seconds]
pudidis has quit [Quit: pudidis]
failshell has quit []
endash_ has quit [Quit: endash_]
dkamioka has joined #ruby
meatherly has joined #ruby
coderdad_ has joined #ruby
pudidis has joined #ruby
petey_ has joined #ruby
breakingthings has quit []
breakingthings has joined #ruby
vlad_starkov has joined #ruby
tonni has quit [Ping timeout: 265 seconds]
camilasan has joined #ruby
mary5030 has joined #ruby
slowcon has joined #ruby
coderdad_ has quit []
Guest77714 has quit [Ping timeout: 245 seconds]
coderdad has joined #ruby
danshultz has joined #ruby
eddpeterson has quit [Ping timeout: 245 seconds]
aniM has quit [Remote host closed the connection]
pudidis has quit [Client Quit]
<platzhirsch> slowcon: I figured, but wasn't sure, maybe you are PST and just got early on the computer :]
ghr has joined #ruby
ghr has quit [Max SendQ exceeded]
kevinykchan has joined #ruby
pu22l3r has quit [Remote host closed the connection]
<wuest> It's not THAT early in PST. 07:00 is prime hacking time.
pu22l3r has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
tonni has joined #ruby
Matriks has quit [Read error: Connection reset by peer]
dblessing has quit [Read error: Connection reset by peer]
<LadyRainicorn> Timezones are weird.
dblessing has joined #ruby
danshultz has quit [Ping timeout: 272 seconds]
burlyscudd has quit [Quit: Leaving.]
Matriks has joined #ruby
mansi has joined #ruby
petey_ has quit [Remote host closed the connection]
brtdv has joined #ruby
burlyscudd has joined #ruby
petey has joined #ruby
zz_jrhorn424 is now known as jrhorn424
vlad_starkov has quit [Remote host closed the connection]
<platzhirsch> wuest: heh, not for everyone
RaCx has joined #ruby
<slowcon> back
<slowcon> platzhirsch: haha no way, ill take every extra minute of sleep i can
ixti has joined #ruby
vpretzel has joined #ruby
FaresKAlaboud has joined #ruby
hrrz has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
Salve has quit [Remote host closed the connection]
<wuest> LadyRainicorn: They _are_. UTC for all!
Salve has joined #ruby
petey has quit [Ping timeout: 265 seconds]
jerius has quit [Ping timeout: 240 seconds]
tonni has quit [Remote host closed the connection]
sski has joined #ruby
tonni has joined #ruby
kitak_ has quit [Remote host closed the connection]
tonni has quit [Read error: Connection reset by peer]
Salve has quit [Ping timeout: 245 seconds]
sski has quit [Ping timeout: 252 seconds]
tkuchiki has quit [Remote host closed the connection]
_maes_ has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
tylersmith has joined #ruby
razibog has quit [Quit: Leaving.]
s_kilk has joined #ruby
nhhagen has quit [Remote host closed the connection]
wallerdev has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
momomomomo has quit [Quit: momomomomo]
jerius has joined #ruby
maletor has joined #ruby
Vivekananda has quit [Quit: Ex-Chat]
RaCx has joined #ruby
lmickh has joined #ruby
toretore has joined #ruby
<rismoney> is there a cleaner way to do this - array_of_hashes.each { |e| puts e["HOSTNAME"]} ?
interactionjaxsn has joined #ruby
<platzhirsch> great, just sent a cover letter where I forgot to replace the company name at one place
<toretore> rismoney: what's not clean about that?
<certainty> i was going to ask
maletor has quit [Read error: Connection reset by peer]
maletor has joined #ruby
<rismoney> lol - i wanted to search an array of hashes and return all the values of key hostname.
<platzhirsch> rismoney: maybe you want to consider map, altering the result? array.map { |a| a["HOSTNAME"] }
<toretore> that's what map is or
Findegil has quit [Quit: Textual IRC Client: www.textualapp.com]
<rismoney> i think i want map - woot
freezey has joined #ruby
vasilakisFiL has quit [Ping timeout: 240 seconds]
stryek has quit [Ping timeout: 245 seconds]
monkegjinni has joined #ruby
robbyoconnor has quit [Ping timeout: 272 seconds]
koell has quit [Read error: Connection reset by peer]
nhhagen has joined #ruby
<rismoney> if you had to name that method what would you call it, where hostname was an argument? hash_val_enum?
stef_204 has joined #ruby
<toretore> how about "hostnames"?
mercwithamouth has quit [Ping timeout: 272 seconds]
anarang has quit [Quit: Leaving]
<certainty> with facets you could do array.map_send(:fetch,"HOSTNAME")
LexicalScope has quit [Read error: Connection reset by peer]
LexicalScope has joined #ruby
shawnjgoff has joined #ruby
mengu has quit [Remote host closed the connection]
tagrudev has quit [Remote host closed the connection]
baordog has joined #ruby
heftig has quit [Quit: Quitting]
danshultz has joined #ruby
lkba has joined #ruby
LexicalScope has quit [Read error: Connection reset by peer]
LexicalScope has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
kindjal has joined #ruby
baroquebobcat has joined #ruby
deception has joined #ruby
maletor has quit [Read error: Connection reset by peer]
maletor has joined #ruby
hrrz has quit [Quit: hrrz]
platzhirsch has left #ruby [#ruby]
aryaching_ has joined #ruby
tkuchiki has joined #ruby
stryek has joined #ruby
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
LexicalScope has quit [Read error: Connection reset by peer]
rayners has joined #ruby
LexicalScope has joined #ruby
LexicalScope has joined #ruby
LexicalScope has quit [Changing host]
platzhirsch has joined #ruby
aryaching has quit [Ping timeout: 260 seconds]
bluenemo has joined #ruby
eka has quit [Quit: Textual IRC Client: www.textualapp.com]
spyderman4g63 has joined #ruby
eka has joined #ruby
ringaroses has joined #ruby
ianfleeton has joined #ruby
eka has quit [Client Quit]
eka has joined #ruby
jlast has joined #ruby
mary5030 has quit [Remote host closed the connection]
maletor has quit [Ping timeout: 265 seconds]
<certainty> http://lisp-unleashed.de/2012/10/25/pipes_and_filters_in_ruby this is some half assed idea i had about Symbol#to_proc some time back. The names are off as it's not really pipes and filters but anyway :)
tonni has joined #ruby
mary5030 has joined #ruby
sk87 has joined #ruby
Mongey has joined #ruby
gregf has quit [Quit: WeeChat 0.4.3]
mary5030_ has joined #ruby
mary5030_ has quit [Remote host closed the connection]
ringaroses has quit [Client Quit]
nhhagen has quit [Remote host closed the connection]
mary5030_ has joined #ruby
S0da has quit [Read error: Connection reset by peer]
prc has quit [Ping timeout: 265 seconds]
hamakn has quit [Remote host closed the connection]
maletor has joined #ruby
vpretzel_ has joined #ruby
mando has joined #ruby
mary5030 has quit [Ping timeout: 260 seconds]
jprovazn has quit [Quit: Leaving]
tolstoi has quit [Read error: Connection reset by peer]
vpretzel has quit [Disconnected by services]
vpretzel_ is now known as vpretzel
ZadYree has quit [Ping timeout: 256 seconds]
maletor has quit [Ping timeout: 245 seconds]
pushpak has joined #ruby
axl_ has joined #ruby
blaxter_ is now known as dumdedum
Hobogrammer_ has quit [Ping timeout: 252 seconds]
fgo has quit [Remote host closed the connection]
michael_lee has joined #ruby
Sawbones has joined #ruby
michael_lee has quit [Max SendQ exceeded]
boboc has joined #ruby
s_kilk has quit [Quit: Leaving]
vpretzel has quit [Ping timeout: 260 seconds]
bluenemo has quit [Remote host closed the connection]
vpretzel has joined #ruby
arctaruz has left #ruby ["Leaving"]
maletor has joined #ruby
maletor has quit [Read error: Connection reset by peer]
maletor has joined #ruby
hiall_ has joined #ruby
clocKwize has quit [Write error: Broken pipe]
clocKwize has joined #ruby
lolmaus has joined #ruby
hiall has quit [Read error: Operation timed out]
hiall_ is now known as hiall
brtdv has quit [Read error: Operation timed out]
lukeholder has joined #ruby
lukeholder has quit [Max SendQ exceeded]
maletor has quit [Read error: Connection reset by peer]
<lolmaus> For the sake of learning how Ruby internals work, i would like to hijack Hash and make it convert string keys into symbols. `{'foo' => 'bar'} # => {foo: 'bar'}` Is that possible?
vlad_starkov has joined #ruby
lukeholder has joined #ruby
lukeholder has quit [Max SendQ exceeded]
baroquebobcat has quit [Quit: baroquebobcat]
maletor has joined #ruby
_maes_ has joined #ruby
momomomomo has joined #ruby
tonni has quit [Ping timeout: 245 seconds]
<banister> lolmaus in pure ruby or in C?
<banister> lolmaus in C, anythings possible
<banister> in pure ruby, just most things are possible
<lolmaus> banister: in Ruby, by monkey patching the Hash class.
einarj has quit [Remote host closed the connection]
lukeholder has joined #ruby
lukeholder has quit [Max SendQ exceeded]
<banister> lolmaus i doubt it, core classes often call the C functions directly so they can skip the slow ruby method lookups
<banister> lolmaus but you can try to override Hash#initialize but i doubt it'll work
vlad_starkov has quit [Remote host closed the connection]
maximski has quit []
pwh has joined #ruby
<LadyRainicorn> lolmaus: HashWithIndifferentAccess
bal has quit [Ping timeout: 252 seconds]
<LadyRainicorn> or something like that name
<LadyRainicorn> Oh that is Rails only
<mjc_> activesupport
<mjc_> I think
lukeholder has joined #ruby
maletor_ has joined #ruby
lukeholder has quit [Max SendQ exceeded]
maletor has quit [Ping timeout: 264 seconds]
<lolmaus> LadyRainicorn: the aim is not using that but getting hands dirty with Ruby internals to see where the limits are.
casheew has joined #ruby
<banister> lolmaus "ruby internals" is C
<banister> lolmaus if you're just monkeypatching shit, that's not "ruby internals"
<LadyRainicorn> Oh, then it's a trivial mod to Hash.[]=
RaCx has joined #ruby
<lolmaus> banister: well, not internals but low-level Ruby usage
casheew_ has quit [Read error: Connection reset by peer]
<LadyRainicorn> (But be very careful with to_sym.)
<lolmaus> LadyRainicorn: is Hash.[]= used with hash literals?
<LadyRainicorn> Yes.
mansi has quit [Quit: Leaving...]
jsilver has joined #ruby
yasushi has quit [Remote host closed the connection]
dangerousdave has quit [Quit: My Mac Pro has gone to sleep. ZZZzzz…]
<LadyRainicorn> Well, sorts of.
<havenwood> lolmaus: For HashWithSilliness: require 'active_support/core_ext/hash/indifferent_access'
dubsteph has quit [Ping timeout: 264 seconds]
<LadyRainicorn> {'s' => 5} wouldn't work right with just that one method patch.
m00nlight has quit [Quit: Konversation terminated!]
lukeholder has joined #ruby
lukeholder has quit [Max SendQ exceeded]
rayners has quit [Remote host closed the connection]
pabloh has quit [Quit: Saliendo]
gja has joined #ruby
kevind has joined #ruby
vlad_starkov has joined #ruby
axl_ has quit [Quit: axl_]
mansi has joined #ruby
lukeholder has joined #ruby
lukeholder has quit [Max SendQ exceeded]
<certainty> LadyRainicorn: sober again? ;p
maximski has joined #ruby
burlyscudd has quit [Quit: Leaving.]
<LadyRainicorn> :3
robbyoconnor has joined #ruby
tgkokk has quit [Ping timeout: 245 seconds]
robbyoconnor has quit [Changing host]
robbyoconnor has joined #ruby
robbyoconnor has quit [Client Quit]
<LadyRainicorn> may-be
maximski has quit [Max SendQ exceeded]
Sawbones has quit []
lukeholder has joined #ruby
axl_ has joined #ruby
lukeholder has quit [Max SendQ exceeded]
Lewix has joined #ruby
lukehold_ has joined #ruby
Salve has joined #ruby
<certainty> let's see. Walk that line please
aspires has joined #ruby
aspires has quit [Client Quit]
francisfish has quit [Remote host closed the connection]
aspires has joined #ruby
petey_ has joined #ruby
Jdubs has joined #ruby
* LadyRainicorn keeps a close watch on her heart, eyes wide open, and walks the line.
jzig has joined #ruby
<certainty> looks good enough. I'm convinced
vlad_starkov has quit [Ping timeout: 252 seconds]
koell has joined #ruby
Jdubs has quit [Remote host closed the connection]
tylersmith has quit [Remote host closed the connection]
Salve has quit [Ping timeout: 245 seconds]
TheMoonMaster has quit [Excess Flood]
ahawkins has quit [Remote host closed the connection]
baordog has left #ruby [#ruby]
_HolyCow has quit [Quit: Leaving.]
nomenkun has quit [Quit: Leaving...]
JohnBat26 has quit [Ping timeout: 264 seconds]
zoscoy has joined #ruby
<lolmaus> LadyRainicorn: y u no talk korean
TheMoonMaster has joined #ruby
<LadyRainicorn> I have a universal translator.
centrx has joined #ruby
pudidis has joined #ruby
jzig has quit [Ping timeout: 272 seconds]
pietr0 has quit [Quit: pietr0]
maletor_ has quit [Read error: Connection reset by peer]
Mon_Ouie has joined #ruby
boboc has quit []
chrisseaton has joined #ruby
marcdel has quit []
gja has quit [Quit: This computer has gone to sleep]
maletor has joined #ruby
dangerousdave has joined #ruby
petey has joined #ruby
petey_ has quit [Read error: Connection reset by peer]
maletor_ has joined #ruby
aspiers has quit [Ping timeout: 252 seconds]
mary5030 has joined #ruby
Kricir has joined #ruby
maletor has quit [Ping timeout: 248 seconds]
jonah_k has joined #ruby
jcs222 has joined #ruby
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mary5030_ has quit [Ping timeout: 240 seconds]
pudidis has quit [Quit: pudidis]
toasty has joined #ruby
jonah_k has quit [Remote host closed the connection]
interactionjaxsn has quit [Remote host closed the connection]
monkegjinni has quit []
vlad_starkov has joined #ruby
jobewan has joined #ruby
pwh_ has joined #ruby
p8952 has joined #ruby
Salve has joined #ruby
pwh has quit [Ping timeout: 240 seconds]
<ericwood> ol
mansi has quit [Read error: Connection reset by peer]
<ericwood> *lol
burlyscudd has joined #ruby
mansi has joined #ruby
ndrei has quit [Ping timeout: 264 seconds]
monkegjinni has joined #ruby
monkegjinni has quit [Client Quit]
mikepack has joined #ruby
rayners has joined #ruby
Liothen has joined #ruby
vlad_starkov has quit [Ping timeout: 265 seconds]
mjs2600 has quit [Remote host closed the connection]
RoryHughes has quit []
rayners has quit [Remote host closed the connection]
ndrei has joined #ruby
Kricir has quit [Remote host closed the connection]
rayners has joined #ruby
RoryHughes has joined #ruby
apeiros has joined #ruby
mjs2600 has joined #ruby
sdwrage has quit [Quit: This computer has gone to sleep]
<jsilver> new rules: I'll program your nice language, but I am not nice. I do not MINASWAN.
leo-the-manic has joined #ruby
Hanmac has joined #ruby
Kricir has joined #ruby
<jsilver> hell can use ruby just fine and doesn't need to be nice to no one
* centrx revokes jsilver's Ruby badge
<jsilver> nooooo
* jsilver grasps for it
<jsilver> give it back!!
<havenwood> jsilver: A Jedi without MINASWAN is a Sith.
<jsilver> havenwood: precisely
atmosx has joined #ruby
jonah_k has joined #ruby
lolmaus has quit [Read error: Operation timed out]
tjr9898 has joined #ruby
* jsilver flashes on his red lightsaber
Hanmac1 has quit [Ping timeout: 252 seconds]
<ericwood> I'm going to a ruby conf on thursday but I haven't written much ruby in months ;_;
* centrx revokes ericwood's Ruby badge
<ericwood> so much javascript, my Ruby skills are declining and it's sad
* jsilver gives ericwood a counterfeit Sith Ruby badge
<certainty> here's your Javascript badge
<jsilver> welcome
<havenwood> ericwood: Opal!
<jsilver> give him a Sith Javascript badge
<jsilver> havenwood: is anyone using Opal in production tho?
maletor has joined #ruby
<ericwood> on the bright side my JS skills are pretty good right now
<havenwood> jsilver: About the same number that were using CoffeeScript a few years back.
koell has quit [Ping timeout: 245 seconds]
<ericwood> I don't like coffeescript
<jsilver> havenwood: so the relatively small, hipster portion of the already hipster javascript community?
<jsilver> L0L
<ericwood> also I hate it when people use it interchangeably with JS when explaining things or giving talks
coderdad has quit [Remote host closed the connection]
<ericwood> I'm just like, you said this was a JS talk but you're using coffeescript; you lied to me
<jsilver> coffeescripts not bad, but nobody wants it
maletor_ has quit [Ping timeout: 248 seconds]
<ericwood> most of the stuff it adds is stuff I get already by writing JS properly
<certainty> like Mozart/Oz
<havenwood> jsilver: The tens of thousands who use it want it. A salve isn't a cure for Javascript but it may help stop the itching.
<ericwood> and using strict mode
<jsilver> we sith are working on our own solution, known internally as scriptcoffee
<ericwood> sorry I got everyone talking about JS :|
nomenkun has joined #ruby
<jsilver> havenwood: agreed but like others I decided to go back to JS
Hanmac1 has joined #ruby
<jsilver> js proper i mean
RaCx has quit [Quit: Computer has gone to sleep.]
<ericwood> I actually really enjoy writing JS
<certainty> clearly a sith
<ericwood> it's such a simple language, I really love that about it
<centrx> Everyone knows PHP is better than JS
<jsilver> certainty: lol!
<ericwood> maybe it's just stockholm syndrome at this point
maletor_ has joined #ruby
mercwithamouth has joined #ruby
<jsilver> centrx: nothing compares to PHPascript tho
<certainty> endash: if you're held hostage by JS wink twice. We'll call the ruby cops then
rayners has quit [Remote host closed the connection]
Hanmac has quit [Ping timeout: 272 seconds]
<platzhirsch> Is it much to consume 500g coffee a weak?
<certainty> erm ericwood ^
hamakn has joined #ruby
rayners has joined #ruby
Hanmac has joined #ruby
coderdad has joined #ruby
Vivekananda has joined #ruby
<certainty> platzhirsch: depends. You alone?
<ericwood> I pretty much asked for this by specializing in frontend dev
<platzhirsch> certainty: yes
maletor has quit [Ping timeout: 252 seconds]
<toretore> that reminds me. coffee
obs_ has quit [Quit: Konversation terminated!]
<certainty> platzhirsch: nah that's fine. You don't expect to get older than 50, do you?
coderdad has quit [Remote host closed the connection]
<shevy> any of you guys has written a firefox extension?
<ericwood> nope, XUL scares me
<platzhirsch> I expect to get 100
<toretore> 500g that's like one bag of coffee
RaCx has joined #ruby
mrchris_ has joined #ruby
<toretore> xul is awesome
Vivekananda is now known as Karpuragauram
<toretore> it is what html5 should have been
Hanmac1 has quit [Ping timeout: 265 seconds]
<certainty> platzhirsch: i hope your expectations become reality.
burlyscudd has quit [Quit: Leaving.]
<apeiros> xul sounds like the name of a mythical evil
<toretore> it is
<certainty> i was about to say
<platzhirsch> toretore: yeah, a smallish bag :D
<ericwood> apeiros: XML that modifies XML
<ericwood> wait no
<toretore> zuul
<ericwood> that's XSLT
<havenwood> the temple of xul'amithral
razibog has joined #ruby
<ericwood> the very idea of XSLT existing makes me depressed
<atmosx> hello
toasty has quit [Remote host closed the connection]
<havenwood> g'morn
<shevy> hmm
<certainty> cthulhu
<shevy> haha
pu22l3r has quit [Ping timeout: 240 seconds]
maletor_ has quit [Read error: Connection reset by peer]
Solnse has joined #ruby
tonni has joined #ruby
<platzhirsch> XML is dead, has no one get the memo
<certainty> in CHICKEN scheme's internals we actually have a procedure call-with-cthulhu .. nobody touches it :)
rayners has quit [Remote host closed the connection]
maletor has joined #ruby
<shevy> Xul-Sothoth
Jdubs has joined #ruby
maletor has quit [Max SendQ exceeded]
rayners has joined #ruby
hamakn has quit [Ping timeout: 272 seconds]
<shevy> Xul-Sothoth knows the gate.
ayaz has quit [Quit: Textual IRC Client: www.textualapp.com]
<shevy> well
<shevy> he would be mighty scared of XML
<toretore> an epiteth?
maletor has joined #ruby
maletor has quit [Remote host closed the connection]
Cache_Money has quit [Quit: Cache_Money]
<shevy> <em:icon64URL/></Description></RDF>
lolmaus has joined #ruby
<shevy> look at all these tags! if that is not an invocation of Cthulhu then I don't know what is
ext0 has joined #ruby
<certainty> that's why we have sxml
freezey has quit [Remote host closed the connection]
poulson has quit [Remote host closed the connection]
RaCx has quit [Ping timeout: 252 seconds]
aganov has quit [Remote host closed the connection]
OdNairy has joined #ruby
RyanV has joined #ruby
<toretore> i, for one, like xml
vlad_starkov has joined #ruby
zeeraw has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
<ericwood> freak
lurch_ has quit [Quit: lurch_]
tonni has quit [Ping timeout: 252 seconds]
Karpuragauram is now known as vivekananda
vivekananda is now known as Vivekananda
RaCx has joined #ruby
<toretore> it is an elegant and powerful markup language
<toretore> compare it with json, which is not elegant
zigomir has quit [Ping timeout: 265 seconds]
<toretore> (but much easier to deal with)
jobewan has quit [Quit: Leaving]
zigomir has joined #ruby
jobewan has joined #ruby
JustMozzy has joined #ruby
centrx has quit [Quit: Leaving]
Jdubs has quit [Remote host closed the connection]
razibog has quit [Quit: Leaving.]
tgkokk has joined #ruby
pwh_ has quit [Ping timeout: 260 seconds]
philcrissman has joined #ruby
Shidash has joined #ruby
<havenwood> toretore: The equivocation between attributes and elements is a horror to behold. What should be elegant and simple seems frustrating complex without an equivalent win.
mikepack has quit [Remote host closed the connection]
<havenwood> frustratingly*
ndrei has quit [Ping timeout: 265 seconds]
nszceta has joined #ruby
mikepack has joined #ruby
banister has joined #ruby
interactionjaxsn has joined #ruby
<shevy> toretore I think both is ugly
workmad3 has quit [Ping timeout: 252 seconds]
bobdobbs has quit [Ping timeout: 272 seconds]
maximski has joined #ruby
pwh has joined #ruby
<toretore> havenwood: but that's not xml's fault. attributes and elements *are* different
bean has joined #ruby
ndrei has joined #ruby
phansch has quit [Quit: Leaving]
tvw has quit []
toasty has joined #ruby
<havenwood> toretore: But different in a way that in practice causes horrible confusion and convolution. The result is an abomination. I guess the same could be said of REST.
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
chrisseaton has quit []
<toretore> again, not xml's fault, but the way people use it
pwh_ has joined #ruby
<havenwood> I guess I question whether the verbosity and complexity is worth the wins for XML.
rayners has quit [Remote host closed the connection]
<shevy> I agree
<shevy> people should not use XML
rootshift_ has joined #ruby
<ericwood> most of the time xml is overkill
<certainty> machines shouldn't either
andikr has quit [Remote host closed the connection]
<shevy> certainty haha :D
rayners has joined #ruby
camilasan has quit []
sk87 has joined #ruby
<toretore> that's like saying "people should not use threads"
jcs222 has quit [Quit: leaving]
<ericwood> fork everything damnit
jrhorn424 is now known as zz_jrhorn424
geggam has quit [Ping timeout: 265 seconds]
<shevy> but threads don't have elements!
rayners has quit [Remote host closed the connection]
razrunelord has joined #ruby
rayners has joined #ruby
pwh has quit [Ping timeout: 252 seconds]
dx7 has joined #ruby
matchaw has quit [Read error: Operation timed out]
timonv has quit [Remote host closed the connection]
fenak has quit [Remote host closed the connection]
RyanV has quit [Ping timeout: 265 seconds]
coderdad has joined #ruby
IceDragon has joined #ruby
<havenwood> toretore: Yeah, often Threads aren't the right choice due to a similar verbosity and complexity. Sometimes it is worth using Threads. I wonder when it is worth using XML?
rayners has quit [Remote host closed the connection]
tkuchiki has quit [Remote host closed the connection]
<ericwood> havenwood: really complex data; XML has lots of nice things in it. and schemas
nowthatsamatt has joined #ruby
rayners has joined #ruby
<certainty> the java people think xml is a great idea. I don't like it much because of it's verbosity and because data can be represented more easily in other structures better supported by my languages of choice
<havenwood> ericwood: Show me this expressive elegant XML.
<havenwood> ericwood: Unicorns!
e^0 has joined #ruby
<ericwood> havenwood: never said elegant, it just provides features that you can't really do in other markup languages
<ericwood> but I don't really use it ever so icgaf
carraroj has joined #ruby
<ericwood> I just know that there are some things about it that are handy for some situations
RyanV has joined #ruby
RyanV has quit [Client Quit]
<shevy> who said that XML is elegant!!!
<razrunelord> Can some help explain this problem to me ? https://gist.github.com/razrunelord/cb115b687cc38e9d7ecd
<shevy> in java it is ok
RyanV has joined #ruby
<shevy> because it is so verbose that XML looks neat and structured
<shevy> in ECLIPSE EDITOR
<havenwood> ericwood: Like Enterprise. Here's Enterprise Rails which does everything in XML, XSLT and friends: https://github.com/tenderlove/enterprise#readme
Hanmac1 has joined #ruby
TMM has quit [Quit: Ex-Chat]
matchaw has joined #ruby
<havenwood> Nice example of the Ruby code converted to XML: https://github.com/tenderlove/enterprise#synopsis
<ericwood> razrunelord: what *is* the problem?
<havenwood> :P
maximski has quit [Ping timeout: 245 seconds]
snath has quit [Ping timeout: 245 seconds]
<ericwood> you can't have a solution without a problem
toasty has quit [Remote host closed the connection]
<ericwood> or is this some kind of question jeopardy??
<ericwood> that'd be interesting
toasty has joined #ruby
<ericwood> havenwood: oh nice so glad that exists
Hanmac has quit [Ping timeout: 248 seconds]
<razrunelord> ericwood: I found the solution online, I just want to know what line 7 does pretty much.
toasty is now known as toastynerd
troyready has joined #ruby
zeeraw has joined #ruby
<shevy> havenwood too easy to discover it a joke due to the word "tenderlove" alone
_HolyCow has joined #ruby
tobago has quit [Remote host closed the connection]
bandsaw1961 has joined #ruby
lukehold_ has quit [Ping timeout: 252 seconds]
jh_ has joined #ruby
Vovko has joined #ruby
yarou has quit [Remote host closed the connection]
jh_ is now known as Guest54078
Guest95094 has quit [Read error: Connection reset by peer]
Hobogrammer has joined #ruby
interactionjaxsn has quit [Remote host closed the connection]
rayners has quit [Remote host closed the connection]
<ericwood> razrunelord: the | is a set union
<havenwood> rezonanc: What `|` is depends on what it is being called upon. In the case of an array: http://www.ruby-doc.org/core-2.0/Array.html#method-i-7C
<toretore> <users><user> ... </user></users> vs {"users": [{ ... }]} : you can't do this with json without breaking something: <users><user></user><pagination/></users>
<ericwood> lol jinx
thesheff17 has joined #ruby
rayners has joined #ruby
coderdad has quit [Remote host closed the connection]
interact_ has joined #ruby
tolstoi has joined #ruby
tolstoi has quit [Changing host]
tolstoi has joined #ruby
andy__ has joined #ruby
gregf has joined #ruby
<razrunelord> ericwood: Thanks, does it work like a bitwise OR then
forced_request has quit [Ping timeout: 264 seconds]
<ericwood> razrunelord: the documentation explains it
<ericwood> but basically
dubsteph has joined #ruby
zigomir has quit [Remote host closed the connection]
<razrunelord> ericwood: thanks
Czupa has joined #ruby
greenarrow has quit [Quit: 500]
forced_request has joined #ruby
<ericwood> np
<shevy> yaml
tylersmith has joined #ruby
<shevy> users:
<shevy> \o/
kidoz has joined #ruby
freezey has joined #ruby
bean has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<toretore> yaml suffers from trying to be human-readable and computer-readable at the same time
mikecmpbll has quit [Quit: ciao.]
Es0teric has joined #ruby
bean has joined #ruby
keen__ is now known as keen_
jcs222 has joined #ruby
dubsteph has quit [Ping timeout: 240 seconds]
toastynerd has quit [Remote host closed the connection]
nvrch has quit [Quit: nvrch]
dubsteph has joined #ruby
kindjal has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
rayners has quit [Remote host closed the connection]
shaunbak_ has quit [Remote host closed the connection]
rayners has joined #ruby
glen has left #ruby [#ruby]
petey has quit [Remote host closed the connection]
RaCx has quit [Quit: Computer has gone to sleep.]
petey has joined #ruby
alex88 has joined #ruby
<toretore> like html5 where you can skip the closing tag, because "meh, too much work"
RaCx has joined #ruby
ikaros has quit [Quit: Ex-Chat]
Solnse has quit [Remote host closed the connection]
<toretore> </rant>
<ericwood> yaml is neato
VTLob has joined #ruby
<ericwood> I use my own homebrewed markup solution: FML
<shevy> yaml has no closing tags
<ericwood> well it doesn't use "tags"
petey has quit [Read error: Connection reset by peer]
Zai00 has quit [Quit: Zai00]
<alex88> hi guys, I've currently created a buildpack for heroku that builds and installs libvips, running bundle install correctly installs ruby-vips gem, however, trying to require 'vips' gives: /app/vendor/bundle/ruby/2.1.0/extensions/x86_64-linux/2.1.0-static/ruby-vips-0.3.7/vips_ext.so
<ericwood> so of course not
ianfleeton has quit [Quit: ianfleeton]
<alex88> but, that path actually exists
<toretore> oh don't get me started on significant whitespace :P
tungd has quit [Ping timeout: 272 seconds]
<certainty> :)
petey has joined #ruby
<ericwood> is there a heroku channel?
<alex88> how could it be? maybe because during compilation the file wasn't there?
<ericwood> might have better luck there
<shevy> yeah, forced indent has some drawbacks sometimes
<alex88> ericwood: it is but with no talking people :)
jcs222 has quit [Quit: leaving]
<shevy> they are quiet because they are ashamed
<alex88> :D
vlad_starkov has quit [Remote host closed the connection]
timonv has joined #ruby
<shevy> what is libvips?
interact_ has quit [Remote host closed the connection]
<ericwood> a library for vips
<shevy> lol
<alex88> library for image manipulation
<certainty> very important processes
<shevy> "A fast image processing library with low memory needs."
<shevy> imagemagick!!!
kaliya has quit [Quit: Lost terminal]
<alex88> eheheh, yeah, try a couple GB image conversion with imagemagick :D
<alex88> btw, this is what I get http://pastie.org/pastes/8746043/text
toastynerd has joined #ruby
petey has quit [Remote host closed the connection]
<shevy> GB man
RaCx has quit [Ping timeout: 260 seconds]
<shevy> I dont have so much pr0n
<shevy> ruby once had rmagick
<havenwood> alex88: You don't need to `require 'rubygems'` anymore, that was a relic of Ruby 1.8.
petey has joined #ruby
<alex88> k thanks for the tip havenwood
mjs2600 has quit [Remote host closed the connection]
<shevy> alex88 that means the file does not exist OR it could be a wrong ELF perhaps
<alex88> I just did what was in ruby-vips doc
<certainty> alias vips="ps aux |vim -" :)
aspires has quit []
baroquebobcat has joined #ruby
<havenwood> alex88: So this exact file exists at this path?: /app/vendor/ruby-2.1.0/lib/ruby/gems/2.1.0/extensions/x86_64-linux/2.1.0-static/ruby-vips-0.3.7/vips_ext.so
<havenwood> alex88: nm, read
jlebrech has quit [Quit: Konversation terminated!]
ecualombian has quit [Remote host closed the connection]
<alex88> havenwood: yup, that's the point
pudidis has joined #ruby
vlad_starkov has joined #ruby
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
<alex88> these are my steps, the readme "build script" part tells what I've done to build the libraries https://github.com/alex88/heroku-buildpack-vips
<alex88> basically I've set a prefix of /app/vendor/vips on every library and compiled them in sequence
<alex88> /app/vendor/vips contains the usual lib include bin share folders
pietr0 has joined #ruby
roolo has quit [Quit: Linkinus - http://linkinus.com]
petey has quit [Ping timeout: 252 seconds]
ephemerian has left #ruby [#ruby]
nitish has joined #ruby
<alex88> the vips library actually works and is linked fine
nitish has quit [Client Quit]
<alex88> the problem is with the native gme
<alex88> *gem
<shevy> do you guys like UPCASED directory names?
<alex88> which shows that error
<ericwood> I hate upcased anything
<shevy> hmm
<philcrissman> shevy: nooooo
mikepack_ has joined #ruby
dumdedum has quit [Quit: foo]
<shevy> so many o :D
mikepack_ has quit [Read error: Connection reset by peer]
<philcrissman> shevy: nnnnno?
<philcrissman> :P
<shevy> lol
mikepack_ has joined #ruby
<shevy> sounds as if you are stuttering
<philcrissman> Stuttering as a Service is my new startup
roolo has joined #ruby
freezey has quit [Remote host closed the connection]
pwh_ has quit []
chinkung has quit [Read error: Connection reset by peer]
oso|away is now known as oso96_2000
rayners has quit [Remote host closed the connection]
klaut has quit [Remote host closed the connection]
chinkung has joined #ruby
rayners has joined #ruby
chinkung has quit [Max SendQ exceeded]
yarou has joined #ruby
chinkung has joined #ruby
pel_daniel has joined #ruby
yfeldblum has quit [Remote host closed the connection]
freezey has joined #ruby
freezey has quit [Remote host closed the connection]
mikepack has quit [Ping timeout: 260 seconds]
pranny has joined #ruby
rayners has quit [Remote host closed the connection]
mikepack_ has quit [Ping timeout: 245 seconds]
interactionjaxsn has joined #ruby
gbt has quit [Quit: Leaving...]
Guest54078 is now known as jherbst
<shevy> philcrissman the scatman!
rayners has joined #ruby
rayners has quit [Remote host closed the connection]
freezey_ has joined #ruby
freezey_ has quit [Read error: No route to host]
fantazo has quit [Ping timeout: 248 seconds]
freezey has joined #ruby
RoryHughes has quit []
<toretore> ski bi di bi di do bap do do bam do
freezey has quit [Read error: Connection reset by peer]
ndrei has quit [Ping timeout: 245 seconds]
freezey has joined #ruby
<toretore> don't let nothing hold you back, if the scatman can do it so can you
sepp2k has joined #ruby
JustMozzy has quit [Remote host closed the connection]
nszceta has quit [Ping timeout: 260 seconds]
<philcrissman> See, "Scat as a Service" sounds like it might not be so good.
<philcrissman> hmm
Vivekananda has quit [Read error: Connection reset by peer]
<philcrissman> hrm
geggam has joined #ruby
<jsilver> I believe that "innate silliness" should be the preferred characteristic of MINASWAN, not "niceness"
<jsilver> JUST LOOK AT _WHY
brandonjmckay has joined #ruby
sparrovv has joined #ruby
sparrovv has quit [Remote host closed the connection]
<havenwood> jsilver: it isn't MIISSWAIS
sdwrage has joined #ruby
rafaelmagu has joined #ruby
phansch has joined #ruby
<havenwood> jsilver: nice is just one aspect, _why disembodies another
<jsilver> havenwood: yeah thats better
<jsilver> MIISSWAIS FOR LIFE
<jsilver> disembodies? like he severs the head of it?
<jsilver> lol
aspires has joined #ruby
<havenwood> jsilver: frees the spirit from the body
hrrz has joined #ruby
rayners has joined #ruby
<hrrz> /j rubyonrails
<hrrz> huh
<jsilver> YOU GAIL
<jsilver> i gail too
tonni has joined #ruby
subbyyy has joined #ruby
Authenticator has joined #ruby
aaronmcada has joined #ruby
aaronmcada has quit [Client Quit]
momomomomo has quit [Quit: momomomomo]
RaCx has joined #ruby
yacks has quit [Quit: Leaving]
rayners has quit [Remote host closed the connection]
tonni has quit [Ping timeout: 240 seconds]
koell has joined #ruby
pudidis has quit [Quit: pudidis]
mikepack has joined #ruby
aaronmcadam has quit [Ping timeout: 260 seconds]
thumpba has quit [Remote host closed the connection]
aspires has quit [Read error: No route to host]
txdv has quit [Read error: Connection reset by peer]
txdv has joined #ruby
sailias has quit [Quit: Leaving.]
aspires has joined #ruby
x77686d has joined #ruby
Phrogz_ has joined #ruby
litone_ has quit [Quit: Lost terminal]
Phrogz_ is now known as Phrogz
heftig has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
tonni has joined #ruby
<shevy> haha
interactionjaxsn has quit [Remote host closed the connection]
<alex88> damn
<alex88> you haven't told me I had to look at the left file
<alex88> not the right one
<shevy> are you blind on your left eye
kidoz has quit [Quit: Ухожу я от вас]
bean has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<alex88> :D
<alex88> now with LD_LIBRARY_PATH set it works fine ;)
jhass|off is now known as jhass
<shevy> apeiros lower your shields! the EU will get the swiss chocolate even after the referendum!
senayar_ has quit [Read error: Connection reset by peer]
gigetoo has quit [Remote host closed the connection]
senayar has joined #ruby
hrrz has quit [Remote host closed the connection]
DanBoy has quit [Ping timeout: 240 seconds]
joelroa has joined #ruby
asmodlol has joined #ruby
troyready has quit [Ping timeout: 264 seconds]
stef_204 has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
coderdad has joined #ruby
tylershipe has joined #ruby
mocfive has joined #ruby
pietr0 has quit [Quit: pietr0]
gigetoo has joined #ruby
<shevy> how do you guys document your methods
<shevy> do you use headers and/or titles
pietr0 has joined #ruby
<havenwood> shevy: document what classes and modules do with the methods inside them
<havenwood> shevy: :P
canton7-mac has quit [Quit: Leaving]
joelroa_ has joined #ruby
<havenwood> shevy: Name things to explain what they do.
alex88 has quit [Quit: Leaving...]
e^0 has quit [Quit: WeeChat 0.4.1]
rdark has quit [Quit: leaving]
DanBoy has joined #ruby
<havenwood> shevy: And if it really is unclear, a comment!
<shevy> hmm
<havenwood> shevy: Or TomDoc doesn't take long to fill in, though i think it makes it hard to find the comments that matter and harder to see the code.
<havenwood> shevy: http://tomdoc.org/
kennym has joined #ruby
kennym has joined #ruby
joelroa has quit [Ping timeout: 265 seconds]
timonv has quit [Remote host closed the connection]
burlyscudd has joined #ruby
j416 has quit [Quit: o/]
pwh has joined #ruby
plexus_ has quit [Ping timeout: 260 seconds]
tgkokk_ has joined #ruby
pwh has quit [Max SendQ exceeded]
aaronmcadam has joined #ruby
joelroa has joined #ruby
pwh has joined #ruby
pwh has quit [Remote host closed the connection]
nomenkun has quit [Ping timeout: 248 seconds]
coderdad has quit [Ping timeout: 265 seconds]
tgkokk has quit [Ping timeout: 240 seconds]
<mary5030> anyone know of a great source to get up to speed with ruby?
RyanV has quit [Quit: Computer has gone to sleep.]
sambao21 has joined #ruby
<havenwood> mary5030: If you haven't checked it out yet, tryruby.org is good to go through. There are some other nice resources here: https://www.ruby-lang.org/en/documentation/
joelroa_ has quit [Ping timeout: 264 seconds]
<havenwood> mary5030: There are whimsical books that come with soundtracks, technical manuals that cover the dark corners of the stdlib, interactive online games, meditations on testing, many options depending on what you're looking for
joelroa_ has joined #ruby
chihhsin has quit [Quit: leaving]
bleak has joined #ruby
jhass is now known as jhass|off
<havenwood> mary5030: And this channel is good for questions.
joelroa has quit [Read error: Operation timed out]
<mary5030> i know basic ruby but i am hoping to get a bit more proficient at it
<mary5030> thank you yes this channel has been helpful
Salve_ has joined #ruby
Salve has quit [Read error: Connection reset by peer]
<havenwood> mary5030: Chris Pine's Learn to Program is very basic. The Ruby Programming Language and second edition Well Grounded Rubyist (in beta) are great.
chihhsin has joined #ruby
<existensil> mary5030: you might also learn quickly by trying to compete in a ruby fight club http://www.meetup.com/Ruby-Fight-Club/
joelroa has joined #ruby
<existensil> :-)
ringaroses has joined #ruby
dreamchaser has joined #ruby
dreamchaser has joined #ruby
dreamchaser has quit [Changing host]
sambao21 has quit [Ping timeout: 260 seconds]
tharindu has joined #ruby
caveat- has quit [Ping timeout: 264 seconds]
ringaroses has quit [Read error: Connection reset by peer]
<mary5030> thank you
petey has joined #ruby
e12energy has joined #ruby
joelroa_ has quit [Ping timeout: 265 seconds]
<e12energy> guys i need to find a proper way to generate numbers for lottery game
<havenwood> e12energy: What numbers do you want in your game?
<shevy> use 42
<e12energy> i heard rand is predictable
<shevy> omg
caveat- has joined #ruby
<e12energy> havenwood:between 1 and 30
<certainty> shevy: yeah that's one of the best
<shevy> certainty it's higher than 30 :(
<certainty> damn
<e12energy> 42?
<shevy> e12energy can we start from 42 and go down to 1 and 30?
joelroa_ has joined #ruby
<e12energy> i am not sure what you mean :)
lethjakman has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
<e12energy> 42 is a gem or something?
<certainty> shevy: we can generate numbers between 42 and 72 and just substract 41 from the result
<shevy> I think it is a number
joelroa has quit [Ping timeout: 252 seconds]
<havenwood> e12energy: require 'securerandom'; SecureRandom.random_number(30).succ
intuxicated has joined #ruby
<shevy> certainty: wikipedia even has an entry http://en.wikipedia.org/wiki/42_%28number%29
<lethjakman> how is this: [1, 2, 3, 4].tap(&:reverse!) different from this: [1, 2, 3, 4].reverse! ?
<e12energy> havenwood:SecureRandom works better than rand?
<lethjakman> I don't think I understand that to_proc thing
<shevy> lethjakman first looks uglier
<lethjakman> aside from that...
<lethjakman> lol
<certainty> >> 42.is_a?(Fixnum)
<eval-in> certainty => true (https://eval.in/102829)
<certainty> looks like it
<lethjakman> does &: just run it on the original object?
<olivier_bK> i have a question maybe is stupid
joelroa has joined #ruby
<shevy> lethjakman runs to_proc on your elements
<Phrogz> lethjakman: They are the same.
<shevy> lethjakman see:
<certainty> shevy: what?
<Phrogz> (In terms of end results.)
<olivier_bK> with ruby we can creat game for android ans ios ?
<lethjakman> shevy: that's blank?
<Phrogz> In terms of perf, clearly [1,2,3,4].reverse! will be a hair faster. :p
havenwood has quit [Remote host closed the connection]
<shevy> >> ["abc\n","def\n"].map(&:chomp)
<eval-in> shevy => ["abc", "def"] (https://eval.in/102831)
<shevy> I have no idea what is blank
<shevy> is that rails?
RoryHughes has joined #ruby
<shevy> > "".blank?
<e12energy> how is rand different from SecureRandom.random_number ?
* Phrogz has never seen someone use .tap(&:foo) before.
<shevy> >> "".blank?
<eval-in> shevy => undefined method `blank?' for "":String (NoMethodError) ... (https://eval.in/102833)
havenwood has joined #ruby
koell has quit [Read error: Connection reset by peer]
<certainty> yeah that's something from activesupport
<Phrogz> I suppose you could array.tap(&:shift).chain_away
ndrei has joined #ruby
joelroa_ has quit [Ping timeout: 264 seconds]
kindjal has joined #ruby
joelroa__ has joined #ruby
vagner4work has quit [Remote host closed the connection]
joelroa_ has joined #ruby
gregf has quit [Quit: WeeChat 0.4.3]
gregf has joined #ruby
<e12energy> anybody?
roolo has quit [Quit: Leaving...]
joelroa has quit [Ping timeout: 260 seconds]
saarinen has joined #ruby
SHyx0rmZ has joined #ruby
jsmoov has joined #ruby
havenwood has quit [Ping timeout: 240 seconds]
rayners has joined #ruby
pudidis has joined #ruby
jsmoov has quit []
rayners has quit [Remote host closed the connection]
alexherbo2 has quit [Quit: WeeChat 0.4.3-dev]
sepp2k1 has joined #ruby
zcreative has joined #ruby
<lethjakman> shevy: your see: had nothing after it
<lethjakman> sorry, thank you for the example
<existensil> e12energy: SecureRandom tries to use your platforms secure random number generator source, so its randomness is likely better on reasonable platforms than Random#rand
gbt has joined #ruby
joelroa__ has quit [Ping timeout: 248 seconds]
zcreative has quit [Client Quit]
mehlah has joined #ruby
<certainty> lethjakman: you understand now how Symbol#to_proc works?
sepp2k has quit [Ping timeout: 272 seconds]
<atmosx> is random number gnerator used in anything other than crypto?
<lethjakman> I think I'm just starting to understand it. it turns it into a lambda with x{x.foo}
<certainty> atmosx: sure. I use one to generate test input
<certainty> in quicktest like tests
<atmosx> certainty: and you care about the randomness level?
<existensil> atmosx: of course. its used it games, testing, genetic algorithms, etc.
<existensil> tons of stuff requires some randomness
<atmosx> genetic algorithms
<atmosx> I missed that.
<atmosx> okay
<certainty> atmosx: nope
Vovko_ has joined #ruby
sparrovv has joined #ruby
mjs2600 has joined #ruby
plexus_ has joined #ruby
yfeldblum has joined #ruby
yfeldblum has quit [Remote host closed the connection]
yfeldblum has joined #ruby
Vovko__ has joined #ruby
kevinykchan has quit [Read error: Connection reset by peer]
<certainty> lethjakman: yes basically
kevinykchan has joined #ruby
<existensil> psuedo-random number generators, which Random is, usually have pretty solid distribution when reasonably seeded, so for almost everything but crypto those rands are sufficient
withnale has joined #ruby
Vovko has quit [Ping timeout: 248 seconds]
rayners has joined #ruby
mikepack has quit [Remote host closed the connection]
<withnale> Hello. Is there a syntax for accessing a class variable without prior knowledge of the class name?
mikepack has joined #ruby
<withnale> i.e. with just an instance.
<certainty> yeah roulette wheel selection :) https://github.com/certainty/ai-playground/blob/master/genetic-n-queens.scm that was fun :)
kobain has joined #ruby
<existensil> foo.class.class_variable_get(:@@some_var)
<withnale> urgh. I guess that does it - not an elegant syntax - thx
bandsaw1961 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Lewix has quit [Remote host closed the connection]
<lethjakman> certainty: is that : required?
hiall has quit [Ping timeout: 265 seconds]
rayners has quit [Remote host closed the connection]
<existensil> well, no, its not elegant. you are trying to access a protected instance variable within an unknown class. that is generally not something you should be doing and should probably look ugly.
mdpatrick has joined #ruby
nanoyak has joined #ruby
Vovko_ has quit [Ping timeout: 272 seconds]
<certainty> lethjakman: sure it denotes a symbol.
<existensil> the ugliness of that statement conveys the ugliness of what youa re doing
decoponio has quit [Quit: Leaving...]
interactionjaxsn has joined #ruby
coderdad has joined #ruby
joonty has quit [Quit: WeeChat 0.3.8]
vlad_starkov has joined #ruby
Vovko__ has quit [Ping timeout: 272 seconds]
mansi has quit [Read error: Connection reset by peer]
Vovko has joined #ruby
tgkokk_ has quit [Ping timeout: 272 seconds]
mansi has joined #ruby
sailias has joined #ruby
nanoyak has quit [Read error: Connection reset by peer]
IceDragon_ has joined #ruby
nanoyak has joined #ruby
<Phrogz> lethjakman: method( &xxx ) calls xxx.to_proc and passes the result as the block to the method. xxx could be a symbol :foo, or a method, or really any object that implements a #to_proc method.
rethus has joined #ruby
krz has quit [Quit: WeeChat 0.4.2]
IceDragon has quit [Ping timeout: 241 seconds]
shaunbaker has joined #ruby
LastWhisper has joined #ruby
shaunbaker has quit [Remote host closed the connection]
shadoi has joined #ruby
<Phrogz> For example, you can define a class's to_proc method such that %w[Bob Jim Jan].map(&Person) would invoke Person.new("Bob") etc. on each item.
troyready has joined #ruby
<rethus> hi, i have installed redmine with bitnami-stack. then i have replace the htdocs/redmine with a new version. Now i got this error:http://pastebin.com/VRm0Kaxt
ecualombian has joined #ruby
<rethus> can somebody help me to solve this gem/bundle error? I have no experiences with ruby
<rethus> maybe here the full log http://188.40.37.134:8080/redmine/
sk87 has joined #ruby
gja has joined #ruby
<toretore> rethus: have you run bundle install?
<lpvn> rethus, obviously you don't have that specific rake version installed, did you run bundle install?
Sawbones has joined #ruby
<rethus> toretore: yes i have run it
<rethus> even with --system
<lpvn> rethus, specify the rake version in your Gemfile
<rethus> bundle env give this:
tgkokk_ has joined #ruby
mloveless has joined #ruby
<slowcon> hey guys, having some trouble selecting a column from a sql database using sequel gem. http://pastebin.com/ubfDBMUk
sk87 has quit [Client Quit]
<toretore> rethus: where did you run it from?
<rethus> that is the gemfile in the redmine-root: http://paste.kde.org/p3y3bdmzm
<rethus> redmine-root
<rethus> htdocs
<existensil> slowcon: you have provided no indication of what errors you have gotten
Jdubs has joined #ruby
CaptainJet has joined #ruby
Jdubs has quit [Remote host closed the connection]
swaglord546 has joined #ruby
sdwrage has quit [Quit: This computer has gone to sleep]
kirun has joined #ruby
deadlock has quit [Read error: Operation timed out]
rubyracer has joined #ruby
lurch_ has joined #ruby
<slowcon> existensil: not getting errors, just cant get it to pass the data to an array.
plexus_ has quit [Ping timeout: 240 seconds]
andy__ has quit [Read error: Connection reset by peer]
<existensil> slowcon: what is in g_sub at your puts statement?
rayners has joined #ruby
<lpvn> rethus, gem install rake -v 10.1.1
andy has joined #ruby
<lpvn> rethus, and remove the other versions
deadlock has joined #ruby
<lpvn> rethus, I guess this works
<rethus> how can i remove them
<slowcon> existensil: new variable telling sequel to select the :genre_id column of the genres table
<existensil> slowcon: i'm not super familiar with sequel, but what if you did g_sub.to_a ?
timonv has joined #ruby
<slowcon> existensil: tried and got a in `initialize': SQLite3::CantOpenException error
andy has quit [Read error: Connection reset by peer]
olivier_bK has quit [Ping timeout: 252 seconds]
<Phrogz> slowcon: Step 1: put your DB file next to your Ruby script and see if Sequel.sqlite('clublandlv.sqlite') works
<rethus> gem install rake -v 10.1.1 - installed 1gem.
andy has joined #ruby
<slowcon> phrogz: it does work
nanoyak has quit [Read error: Connection reset by peer]
<rethus> lpvn: how can i remove other one?
swaglord546 has quit [Read error: Connection reset by peer]
<Phrogz> slowcon: How about Sequel.sqlite( '/Users/...' ) ?
nanoyak has joined #ruby
<lpvn> gem uninstall rake -v <your_version>
<Phrogz> (Is there any reason you need to use the .connect method?
<lethjakman> I thouhght there was a good method t hat removed whatever characters you denoted from either side of a string. does anyone know what that's called?
mjs2600 has quit [Remote host closed the connection]
<slowcon> Phrogz: no, only used it because that was in the example of how to connect to a local DB
vpretzel has quit [Quit: Adios!]
<Phrogz> slowcon: Great! So you're unblocked?
<Phrogz> lethjakman: #strip will remove leading/trailing whitespace.
<rethus> lpvn: how can i see which other versions on the system? rake --version show only the 10.1.1
<lpvn> gem list
<slowcon> Phrogz: the database can be written to, i am using it to scrape genres from a website. i now want to pass the values it scrapes to an array to be iterated through
mikepack has quit [Remote host closed the connection]
mjs2600 has joined #ruby
<Phrogz> slowcon: OK...what's the problem?
<slowcon> Phrogz: when i run g_sub, its returning the SQL statement
<rethus> lpvn: got this question, by trying to delete-: http://paste.kde.org/pduijjhmb
<Phrogz> slowcon: genres = DB[:genres].select_map(:genre_id) #http://sequel.jeremyevans.net/rdoc/classes/Sequel/Dataset.html#method-i-select_map
<slowcon> Phrogz: not the values
<slowcon> Phrogz: checking
<Phrogz> slowcon: You need to call .all on a Dataset to get an array of the Hashes, or call .map or .select_map or such to convert to an Array.
jprovazn has joined #ruby
<lethjakman> Phrogz: is there a way to do that for a's?
<Phrogz> Or you can call .each() on the dataset to iterate through the values.
<lethjakman> it LOOKS like strip will accept a value in the source but apparently it doesn't.
<lethjakman> at least I can't seem to get it to.
<lethjakman> "abcda".strip 'a'
<Phrogz> lethjakman: Not as a dedicated method to my knowledge. I'd str.gsub!( /\Aa+|a+\z/, '' )
<lethjakman> ahhh ok
<lethjakman> fair enouhg
chrisja has joined #ruby
<rethus> lpvn: exactly the same error: http://188.40.37.134:8080/redmine/
Advocation has quit [Quit: Advocation]
gnephiak has quit [Quit: Konversation terminated!]
DrShoggoth has joined #ruby
Matriks has quit [Remote host closed the connection]
Vovko has quit [Remote host closed the connection]
dubsteph has quit [Ping timeout: 240 seconds]
billy_ran_away has quit [Ping timeout: 252 seconds]
Guest44715 has quit [Ping timeout: 245 seconds]
interactionjaxsn has quit [Remote host closed the connection]
Guest44715 has joined #ruby
<certainty> lethjakman: there is also String#delete
Guest44715 has left #ruby [#ruby]
parduse has joined #ruby
ylluminate has joined #ruby
<Phrogz> certainty: But that kills them everywhere, not just leading/trailing.
billy_ran_away has joined #ruby
<certainty> Phrogz: yeah
jrist has quit [Read error: Connection reset by peer]
<lpvn> rethus, well... the only rake version you have installed is 10.1.1 and it still can't find it
<lpvn> rethus, weird
<certainty> Oh sorry, didn't read carefully
<rethus> lpvn: maybe some env wrong?
Kricir has quit [Remote host closed the connection]
<lpvn> rethus, I don't know really
<slowcon> Phrogz: that works, but weird. when i run it in my IDE it works fine. when i run it in pry i gte a Sequel::Database connecton error
xcv has joined #ruby
mehonoshin has joined #ruby
lethjakman has quit [Quit: WeeChat 0.4.0]
<rethus> sombody else here could give me a hint to got this running
<jsilver> "London is the home of 73 per cent of the UK’s wealth and 93 per cent of its twats. Letting the city sink beneath the waves will be an enormous net gain for the rest of Britain."
<jsilver> that is all
<rethus> lpvn: still have try bundle install --system
bklane has joined #ruby
<rethus> also found this page, but didn't help me
<Phrogz> slowcon: That's odd. I've used Pry + Sequel with Postgres before; never tried with SQLite. Is your path absolute?
<slowcon> Phrogz: /sequel/adapters/sqlite.rb:101:in `initialize': SQLite3::CantOpenExceptio n: unable to open database file (Sequel::DatabaseConnectionError)
<Phrogz> slowcon: What if you require Pry after setting up your DB.
<Phrogz> Or are you using the Pry interactive console?
koell has joined #ruby
Vivekananda has joined #ruby
<slowcon> Phrogz: yupp path is absolute. im running the program via command prompt "Ruby /path/to/script/script.rb"
<slowcon> which opens pry when i add the binding, but giving the DB error
<Phrogz> slowcon: So, you are manually requiring 'pry', and thus can try putting it after you access the DB?
sambao21 has joined #ruby
<slowcon> yeah i tried that, nothin
jcs222 has joined #ruby
ffranz has quit [Ping timeout: 245 seconds]
Nowaker has quit [Ping timeout: 265 seconds]
<Phrogz> Post your code, I can try to repro?
Advocation has joined #ruby
Nowaker has joined #ruby
jrist has joined #ruby
<Phrogz> If it repros, I'd recommend posting on sequel-talk; Jeremy is usually super responsive.
<slowcon> Phrogz: yeah jeremy is awesome at answering questions
mehonoshin is now known as vic736
<slowcon> Phrogz: sure let me paste the code up
ZadYree has joined #ruby
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
petey has quit [Remote host closed the connection]
vlad_starkov has quit [Remote host closed the connection]
burlyscudd has quit [Read error: Connection reset by peer]
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
burlyscudd1 has joined #ruby
petey has joined #ruby
gja has quit [Quit: This computer has gone to sleep]
gamegenius86 has joined #ruby
benzrf has joined #ruby
petey_ has joined #ruby
<benzrf> hello
noop has quit [Ping timeout: 265 seconds]
petey has quit [Read error: Connection reset by peer]
<benzrf> what's the diff between 'Foo = Struct.new do' and 'class Foo < Struct.new'
maletor has joined #ruby
swaglord546 has joined #ruby
<jsilver> benzrf: in the first one, you set "Foo" to a new instance of the struct class passed a block
<Phrogz> slowcon: FWIW it works for me: http://pastie.org/8746321
gja has joined #ruby
<benzrf> well i know the difference in what it's doin
<jsilver> benzrf: in the second one, you define a class Foo which inherits from "Struct.new" which may be a syntax error
<apeiros> benzrf: one level of inheritance is the difference
<jsilver> because you should probably be doing Foo < Struct
<benzrf> im asking if there's any semantic difference in how Foo will behave
<jsilver> but idk
Matriks has joined #ruby
<Phrogz> ++apeiros
<jsilver> benzrf: possibly, if you extended Foo in the inheritance once
<apeiros> benzrf: consider: Foo = Struct.new; class Bar < Foo…
burlyscudd1 has quit [Read error: Connection reset by peer]
jonah_k has quit [Remote host closed the connection]
<apeiros> jsilver: please, don't use extended as synonym for subclassing in ruby.
mikepack has joined #ruby
<jsilver> why not? i forgot what it really means
burlyscudd has joined #ruby
<jsilver> lul
<toretore> anyone managed to make objects of two different classes appear the same to Hash#[] ?
* jsilver braces himself
<apeiros> jsilver: see Object#extend
<jsilver> k,
nanoyak has quit [Read error: Connection reset by peer]
<apeiros> toretore: sure, it's easy
<toretore> apeiros: teach me
<Phrogz> toretore: You gotta define a couple methods.
<apeiros> toretore: #hash must return the same value, and #eql? must return true
nanoyak has joined #ruby
ioion has quit [Read error: Operation timed out]
interactionjaxsn has joined #ruby
<toretore> yes, that should do it, but it doesn't
<apeiros> toretore: show code
<Phrogz> pastie thy evidence
bean has joined #ruby
jherbst has quit [Quit: Textual IRC Client: www.textualapp.com]
<toretore> apeiros: few secs
bean has quit [Changing host]
bean has joined #ruby
vpretzel has joined #ruby
ianfleeton has joined #ruby
momomomomo has joined #ruby
jh_ has joined #ruby
rethus has left #ruby ["Konversation terminated!"]
jh_ is now known as Guest84062
Guest84062 is now known as jherbst
<apeiros> works for me, pastie upcoming
tharindu has quit [Quit: Leaving...]
vic736 has quit [Quit: leaving]
banister has joined #ruby
<apeiros> toretore: http://pastie.org/8746332
<apeiros> cheapest way possible :)
swaglord546 has quit [Quit: Byebye...]
Hobogrammer has quit [Remote host closed the connection]
ephemerian has joined #ruby
<toretore> apeiros: yes, but those are the same class
<withnale> I was to write a debug logging function that outputs some debug lines including the line at which the debug function is called from. Is there a way of doing this without putting __FILE__ as one of the parameters to each call?
<apeiros> toretore: doesn't matter. I can do it with different classes too.
<benzrf> withnale: there's caller
<benzrf> >> def foo; p caller[-2]; end; foo
<eval-in> benzrf => nil ... (https://eval.in/102879)
<toretore> apeiros: that's what you'd think, but i can't make it work
<benzrf> ??
<apeiros> toretore: you forgot #hash
ffranz has joined #ruby
<toretore> oops, i'll add it
<withnale> benzrf: thanks
mrchris_ has quit [Ping timeout: 245 seconds]
<toretore> apeiros: ok, reload
aaronmcadam has quit [Quit: Leaving...]
<benzrf> withnale: np :)
<benzrf> hmm
workmad3 has joined #ruby
<apeiros> toretore: o.eql(v) <-- srsly? :)
<apeiros> anyway, I see the gist of what you want to do. let me check.
Notte has joined #ruby
<benzrf> is there a way to get the binding for a calling scope without having it pass a block?
axsuul has joined #ruby
<axsuul> Is there any way to make this more DRY? https://gist.github.com/anonymous/e0966729ea05c01099ae
jonahR has joined #ruby
<benzrf> (@destinations[endpoint.destination] ||= []) << ".#{endpoint.domain}"
<benzrf> p common idiom i think
<Nilium> Depends on what you mean by that.
<toretore> apeiros: oops. BUT, that typo revealed something: in 2.x it never gets to the else
<toretore> which is probably the source of the problem
<toretore> (*is*, as i checked)
<toretore> so it's not Hash
<apeiros> toretore: because it's the wrong way round
<Nilium> You could do what benzrf suggested, but readability suffers
<apeiros> toretore: "hi".eql?(yourthing)
<apeiros> d'oh, no code of yours is run
maletor has quit [Quit: Computer has gone to sleep.]
<axsuul> benzrf: is there any way to put the @destinations[endpoint.destination] in another reference
<axsuul> variable
<apeiros> the eql? must work both way round. a.eql?(b) && b.eql?(a)
philcrissman has quit [Remote host closed the connection]
deadlock has quit [Ping timeout: 248 seconds]
<benzrf> axsuul: huh?
philcrissman has joined #ruby
<benzrf> axsuul: edest = (@destinations[endpoint.destination] ||= [])
nanoyak has quit [Quit: Computer has gone to sleep.]
nszceta has joined #ruby
* Phrogz has certainly used (@foo ||= []) << bar in the past.
nanoyak has joined #ruby
freezey has quit [Remote host closed the connection]
<apeiros> toretore: http://pastie.org/8746360
saarinen has quit [Quit: saarinen]
<axsuul> benzrf: something like this, any way to DRY this up? https://gist.github.com/anonymous/84d6de6e7bb636d9e2b4
nanoyak has quit [Read error: Connection reset by peer]
echevemaster has quit [Ping timeout: 264 seconds]
nanoyak has joined #ruby
echevemaster has joined #ruby
<benzrf> axsuul: you could use edest like i wrote
<benzrf> or you could chain shovels
<benzrf> [1, 2, 3] << 4 << 5
samuel02 has joined #ruby
<benzrf> you could use concat
<benzrf> [1, 2, 3].concat [34, 34, 34]
vic736 has joined #ruby
<axsuul> ah ok thanks
<benzrf> np =]
<axsuul> but what you cant do, is edest << "foo" right?
<benzrf> of course you can o-o
<benzrf> it's the same list innit
gja has quit [Quit: This computer has gone to sleep]
<toretore> apeiros: sorry, brain's a little fried.. you are right of course, that which object will receive eql? depends on which is given to Hash#[]
<toretore> (probably)
<axsuul> benzrf: thakns
nanoyak has quit [Ping timeout: 245 seconds]
Atrumx has quit [Quit: quit]
<benzrf> happytohelp
<apeiros> toretore: should just go both ways. that's the best.
Phrogz_ has joined #ruby
Phrogz has quit [Ping timeout: 245 seconds]
artisangoose has joined #ruby
CaptainJet has quit []
<artisangoose> I know absolutely ZERO ruby, and am trying to accomplish PHP's array_merge behavior with two YAML hashes... Can anyone assist?
Phrogz_ is now known as Phrogz
Hobogrammer has joined #ruby
<benzrf> artisangoose: merge?
<Phrogz> artisangoose: Please describe what array_merge does
<benzrf> >> h = {a: 1, b: 2}; h2 = {c: 3}; h.merge h2; h
<eval-in> benzrf => {:a=>1, :b=>2} (https://eval.in/102880)
<apeiros> array_merge - is that the one with 200 options?
<benzrf> wait what
<benzrf> >> h = {a: 1, b: 2}; h2 = {c: 3}; h.merge! h2; h
<eval-in> benzrf => {:a=>1, :b=>2, :c=>3} (https://eval.in/102881)
<shevy> you want .merge or .update artisangoose
<Phrogz> benzrf: merge! or h = h.merge
armyriad has quit [Ping timeout: 245 seconds]
<apeiros> careful guys… been almost a decade. but iirc array_merge took a bazillion of options, determining how exactly merging happened.
<artisangoose> shevy well shit, that was easy...
<benzrf> php does not have arrays
<artisangoose> lol thanks!
<artisangoose> benzrf Yes it does.... lol
swaglord546 has joined #ruby
reset has joined #ruby
<benzrf> it has bizarre combo data structures that act like arrays, hashes, sets, and sparse arrays
<benzrf> all at once
gja has joined #ruby
<benzrf> or as a mixture
<benzrf> it's pretty terrible
gja has joined #ruby
gja has quit [Changing host]
<artisangoose> benzrf Or it's remarkable... :)
<benzrf> it's remarkably terrible, yes
spyderman4g63 has quit [Read error: Connection reset by peer]
maletor has joined #ruby
<toretore> apeiros: yes.. but something's changed between 1.9 and 2: https://gist.github.com/toretore/9078144 - in 2+ Foo#eql never gets called
<Phrogz> slowcon: Works for me (with minor modification to .sqlite path). Either our Ruby/gem/SQLite versions are different, or this is an OS-specific problem.
<toretore> er, Foo#eql?
<Phrogz> slowcon: I recommend you pare it down to absolute minimal test case and head to sequel-talk
spyderman4g63 has joined #ruby
<benzrf> artisangoose: just like a car that has wings and an outboard engine, which takes 10x more fuel and sometimes starts flying when you're trying to drive!
peoplee has joined #ruby
<benzrf> remarkable!
<Phrogz> Now now, we can keep the PHP bashing to a minimum. Most of us believe it is an abomination on many levels, but no need to convince others.
randomnick_ has joined #ruby
<slowcon> Phrogz: error is happening at the " genre_table = DB[:genres].select_map(:genre_id)" line
<slowcon> Phrogz: dont get it though, script works. will ask jeremy
blackmesa has joined #ruby
<toretore> apeiros: but my dream of having a class that can always be considered equal to some internal value is busted :/
artisangoose has left #ruby ["Textual IRC Client: www.textualapp.com"]
shevy has quit [Ping timeout: 260 seconds]
<Phrogz> slowcon: That's the first time the DB attempts to be accessed for real. Up until then it's a notional concept. You could try just p DB.tables and likely see the same results.
burlyscudd has quit [Quit: Leaving.]
skaflem has quit [Quit: Leaving]
axsuul has quit [Ping timeout: 272 seconds]
swaglord546 has quit [Quit: Byebye...]
jonah_k has joined #ruby
elaptics is now known as elaptics`away
vlad_starkov has joined #ruby
OdNairy has quit [Ping timeout: 260 seconds]
<apeiros> toretore: why?
Advocation has quit [Quit: Advocation]
burlyscudd has joined #ruby
swaglord546 has joined #ruby
zz_jrhorn424 is now known as jrhorn424
<apeiros> toretore: oh, your @v isn't necessarily a string. you want it generic?
<toretore> yup
<apeiros> that's tricky.
<benzrf> just use to_s
<benzrf> :D
axsuul has joined #ruby
<toretore> could override Object#eql? but there are certainly classes where it doesn't call super
<apeiros> that wouldn't help
<toretore> actually, most probably don't
<apeiros> yupp
jrhorn424 is now known as zz_jrhorn424
<toretore> it doesn't even make sense :)
<apeiros> most core classes at least
<benzrf> hmm, i am writing a class for signatures, and I dunno whether to make it Signature#signs? or Signature#sign?
<benzrf> the latter conforms to matz's standard, but it sounds weird as shit
OdNairy has joined #ruby
<toretore> and it's the core i care most about
<apeiros> benzrf: ruby isn't consistent itself
<apeiros> benzrf: just go with signs?
<benzrf> k
moted has joined #ruby
<platzhirsch> sign?
<platzhirsch> you mean #signed?
swaglord546 has quit [Client Quit]
* Phrogz has no idea what a_signature.sign? means.
<apeiros> toretore: you're probably better off subclassing/delegating Hash instead
vic736 has quit [Ping timeout: 265 seconds]
burgess has joined #ruby
<toretore> apeiros: yeah, i'm already delegating to it so it should work out fine
<platzhirsch> benzrf: You mean #signed?, change it
jackneill has quit [Ping timeout: 260 seconds]
artisangoose has joined #ruby
thumpba has joined #ruby
<artisangoose> shevy
<benzrf> platzhirsch: no, i use it like this:
TMM has joined #ruby
<benzrf> some_sig.signs? block
artisangoose has left #ruby ["Textual IRC Client: www.textualapp.com"]
nhhagen has joined #ruby
<benzrf> then i will make a mixin that lets you say block.signed/
<benzrf> but you'll still be able to use signature independently
<benzrf> more flexible that way
<platzhirsch> ok, I still don't get the semantic but it sounds pretty laid back
<platzhirsch> anyway, create an alias
<platzhirsch> there is also File.exist and File.exists
petey_ has quit [Remote host closed the connection]
<e12energy> is rubycoin.org related to this community in anyway?
<platzhirsch> This way you support verb inflection, which will make your code fucking readable
axsuul has quit [Ping timeout: 260 seconds]
Azure has quit [Quit: My MBP went to sleep.]
petey has joined #ruby
ndrei has quit [Ping timeout: 252 seconds]
jonah_k has quit [Remote host closed the connection]
danshultz has quit [Remote host closed the connection]
<apeiros> e12energy: I don't think it is related. at least I hear of it the first time.
ppcsee has joined #ruby
<Nilium> I'd guess rubycoin is some stupid bitcoin thing for the internet libertarians/weirdos to obsess over and not at all related.
<benzrf> whoa im writing a cryptocoin in ruby
<benzrf> not a practical one
<benzrf> but still, huh
CaptainJet has joined #ruby
alvaro_o has joined #ruby
shevy has joined #ruby
<platzhirsch> e12energy: Why are you asking?
Jdubs has joined #ruby
danshultz has joined #ruby
<e12energy> cuz i am curious
<e12energy> they got almost the same logo
<apeiros> the page doesn't seem to have a whole lot of information about it…
freezey has joined #ruby
ndrei has joined #ruby
Xeago has joined #ruby
<platzhirsch> same logo? This channel doesn't have a logo, does it?
petey__ has joined #ruby
<toretore> it's the same as the ruby logo
petey has quit [Ping timeout: 248 seconds]
<toretore> somebody is trying to get in on the ponzi action
<apeiros> curious whether they're legally allowed to use that logo there
Advocation has joined #ruby
armyriad has joined #ruby
<toretore> "The Ruby Logo is Copyright © 2006, Yukihiro Matsumoto; licensed under the terms of the CC BY-SA 2.5."
<platzhirsch> e12energy: So you come here and advertise rubycoin? :P
<apeiros> does creative commons require attribution?
<platzhirsch> yes, unless it is CC-zero
<platzhirsch> which is public domain
<toretore> "Attribution — You must give appropriate credit"
<platzhirsch> The attribution is inherently to the data/work being open and the license being an open license
<toretore> so their use of the logo does not follow the licence
<platzhirsch> I used the logo, too in my presentation. I didn't attribute it either https://speakerdeck.com/platzhirsch/assessment-and-visualization-of-metadata-quality-for-open-government-data
theRoUS has quit [Remote host closed the connection]
<apeiros> platzhirsch: you criminal!
RaCx has quit [Ping timeout: 248 seconds]
<platzhirsch> apeiros: and my presentation was even about open data, lol
<platzhirsch> Some people just want to see the world burn
<e12energy> platzhirsch: no... i found out about rubycoin last night by doing /list *coin* just to see what coins there are. and i've been using ruby for years.. so i just got curious if it's related in anyway
<e12energy> especially after seeing the logo
<platzhirsch> e12energy: well nice sales pitch, not buying it
lurch_ has quit [Quit: lurch_]
<e12energy> haha
<platzhirsch> ^
<e12energy> couldn't get less about rubycoin
<e12energy> :P
sambao21 has quit [Quit: Computer has gone to sleep.]
<platzhirsch> e12energy: so do you have Twitter?
tgkokk_ has quit [Ping timeout: 245 seconds]
<e12energy> platzhirsch:nope.. i only got FB and Google+
<e12energy> why?
<platzhirsch> uhm,.. just asking
louism2wash has joined #ruby
mikepack has quit [Remote host closed the connection]
<toretore> "Only 60 million will exist." "And we've mined the first 20 million before letting you drive up the price for us"
mloveless has quit [Remote host closed the connection]
phutch1ns has quit [Ping timeout: 240 seconds]
Kricir has joined #ruby
<jsilver> so can I open up irb in a coin
<platzhirsch> Man, accessing my wallet with Pry.
tacos1de has quit [Remote host closed the connection]
<shevy> platzhirsch the joker would be using perl
<shevy> batman would use python
tacos1de has joined #ruby
nanoyak has joined #ruby
<louism2wash> Can anyone help me? I feel like I'm losing my mind!!!!!! Why is it that when I push an item into the array at index 1 that it replicates to all remaining arrays? https://gist.github.com/louism2/9079079
<apeiros> louism2wash: arr = Array.new(13,[]) # <-- creates an array with 13 times *the same* array
<apeiros> >> Array.new(13,[]).map(&:object_id)
<eval-in> apeiros => [542003840, 542003840, 542003840, 542003840, 542003840, 542003840, 542003840, 542003840, 542003840, 542003840, 542003840, 542003840, 542003840] (https://eval.in/102886)
<apeiros> you want Array.new(13) { [] }
theRoUS has joined #ruby
theRoUS has quit [Changing host]
theRoUS has joined #ruby
<louism2wash> apeiros: I'll give that a shot
<louism2wash> thanks
sdwrage has joined #ruby
sdwrage has quit [Client Quit]
deadlock has joined #ruby
alexherbo2 has joined #ruby
mikepack has joined #ruby
<e12energy> chuck norris uses ruby
Vovko has joined #ruby
<louism2wash> apeiros: thanks
<louism2wash> apeiros: I was losing my f*$king mind
Vivekananda has quit [Ping timeout: 272 seconds]
sailias has quit [Quit: Leaving.]
Vivekananda has joined #ruby
sambao21 has joined #ruby
<shevy> how to get all values of constants in a module when you dont know the names? module Foo; BLA = 5; BLE 6; end
<shevy> forgot a =
RoryHughes has quit []
<benzrf> oh dang im pretty confused!
einarj has joined #ruby
theRoUS has quit [Quit: Coyote finally caught me]
<benzrf> i have a keypair
<benzrf> but if I do:
Vovko has quit [Ping timeout: 260 seconds]
<benzrf> OpenSSL::PKey::RSA.new(priv).public_key
vlad_starkov has quit [Ping timeout: 272 seconds]
<benzrf> it is not the same as the public key stored in file!
<benzrf> wut??
<benzrf> wait wtf
<benzrf> OpenSSL::PKey::RSA.new(pub).public_key
<benzrf> ^that gives a different thing from pub!!
aspires has quit []
ianfleeton has quit [Quit: ianfleeton]
<benzrf> wat
<platzhirsch> I am still not used to read the Ruby source code, please throw some documentation on it
<lagweezle> Is that from a Ruby Gem?
Kricir has quit [Ping timeout: 252 seconds]
dingus_khan has joined #ruby
<apeiros> shevy: Module#constants + #const_get, enjoy
<lagweezle> benzrf: http://www.ruby-doc.org/stdlib-1.9.3/libdoc/openssl/rdoc/OpenSSL.html is the thing you are working with?
bleak has quit [Ping timeout: 272 seconds]
theRoUS has joined #ruby
theRoUS has joined #ruby
theRoUS has quit [Changing host]
kevinykchan has quit [Quit: Computer has gone to sleep.]
<benzrf> yep
<lagweezle> benzrf: You are trying to load a key from file?
<shevy> hmm
<shevy> >> module Foo; class Bar; end; end; Object.const_get 'Foo::Bar'
<eval-in> shevy => Foo::Bar (https://eval.in/102887)
<shevy> damn, ruby 1.9.x is too dumb for this :(
<platzhirsch> For instance, what hashing algorithm is uses for Hash? https://github.com/ruby/ruby/blob/58f800a278b8b70463f4afdbb23a918d8ab441ff/hash.c
wereHams1er has quit [Remote host closed the connection]
<benzrf> lagweezle: i already did
<benzrf> when i create a key object from the pem, the resulting key object contains different base64 from the original file
<benzrf> allmywut
jcs222 has quit [Read error: Connection reset by peer]
<benzrf> if i plug the different base64 back in though it comes out unchanged
<benzrf> ?!
jcs222 has joined #ruby
bettyclamp has left #ruby [#ruby]
<platzhirsch> toretore: oh \o/
kindjal has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
<platzhirsch> I feel like the dog who is pressed into its own poop because it misbehaved
* jsilver shoves platzhirsch face in the poop. BAD DOG!
<lagweezle> benzrf: I think you are using the wrong approach... OpenSSL::PKey::RSA.new generates a new key from the ether; it does not create an object using a pre-existing key file.
<platzhirsch> jsilver: Yes Master JavaSilver
<jsilver> >> "hi".class
<eval-in> jsilver => String (https://eval.in/102890)
RoryHughes has joined #ruby
<jsilver> platzhirsch: lmao
goganchic has joined #ruby
<benzrf> lagweezle: that's only if you don't give it a string though
<jsilver> its JavascriptSilver
<jsilver> JavaSilver is my dad
goganchic has quit [Client Quit]
<shevy> lol
<shevy> JavaDad sugar daddy
wereHamster has joined #ruby
sdwrage has joined #ruby
gja has quit [Quit: This computer has gone to sleep]
<lagweezle> benzrf: Seeing what happens when I poke about.
<lagweezle> benzrf: It is definitely not the behavior I expected.
<benzrf> :|
burlyscudd has quit [Quit: Leaving.]
RaCx has joined #ruby
<benzrf> >> require 'openssl'; OpenSSL::PKey::RSA.new
<eval-in> benzrf => #<OpenSSL::PKey::RSA:0x40cab42c> (https://eval.in/102891)
<benzrf> hm
<platzhirsch> Without actual parallel execution (like MRI) it's not really a problem to access a data structure from different threads, no?
<benzrf> you mean async
<benzrf> ?
aryaching has joined #ruby
<benzrf> if the access is atomic then definitely
<benzrf> if not... idk
<benzrf> it depends on how it's threaded
<benzrf> i think
<benzrf> ianae
gja has joined #ruby
<platzhirsch> oh atomic is an issue, true
<slowcon> Phrogz: problem was that the database was locked. being used by another process, just closed out everything and reopened. good to go
<platzhirsch> so the threads could switch
carraroj has quit [Quit: Konversation terminated!]
<platzhirsch> while the data structure is manipulated
<Phrogz> slowcon: Yay! :) Yet another downside of SQLite, I suppose (as fun and convenient as it is)
<lagweezle> benzrf: In my case, it may be because the ky is not encrypted post-load.
<benzrf> atomicity!
<benzrf> mutexes aren't very hard tho
<benzrf> just put your access in a mutex.synchronize block
<benzrf> done
<benzrf> :)
<toretore> platzhirsch: you have the same problems as with "real" threads
<platzhirsch> benzrf: yeah I was just thinking
* Phrogz likes how simple Ruby makes threading, even if it's not green.
peoplee has quit [Ping timeout: 245 seconds]
Jdubs has quit [Remote host closed the connection]
aryaching_ has quit [Ping timeout: 265 seconds]
axl_ has quit [Quit: axl_]
Mongey has quit [Quit: Mongey]
<Phrogz> er, green and not native, that is
<benzrf> man i rly rly suck at concurrency
<platzhirsch> What is more, Ruby has Fibres
RaCx has quit [Quit: Computer has gone to sleep.]
<platzhirsch> MRI with its GIL is a piece of shit
<Phrogz> benzrf: That's OK, just about everyone does. Including me.
cpruitt has joined #ruby
dingus_khan has quit [Remote host closed the connection]
LexicalScope has quit [Read error: Connection reset by peer]
<benzrf> my cleverest moment: naming a mutex that prevented concurrent calls to a text-to-speech program 'conch'
<benzrf> :3
<Phrogz> lol
<Phrogz> Nice!
LexicalScope has joined #ruby
<Phrogz> That's actually a really nice mental model. I assume it's heavily used in intro documents.
* Phrogz goes a-Googling.
<benzrf> o:
<platzhirsch> so where do I learn about the current MRI Threading implementation?
<Phrogz> "For example, in “The Lord of the Flies” a group of children use a conch as a mutex. To speak, you have to hold the conch. As long as only one child holds the..."
mando has quit [Ping timeout: 240 seconds]
<Phrogz> 11.6k hits for "conch" "mutex"
<benzrf> and here i thought i was being original
<benzrf> ;-;
<Phrogz> We are none of us unique snowflakes.
<platzhirsch> Concurrency fascinates me, do you know Hoare Calculus?
itadder has joined #ruby
<benzrf> >implying snowflakes are unique
<Phrogz> platzhirsch: In the source code? :|
<lagweezle> benzrf: I guess the /real/ test is to make sure that the key actually can decode properly.
nszceta has quit [Ping timeout: 272 seconds]
aspires has joined #ruby
<benzrf> it can o-o
<Phrogz> platzhirsch: You mean beyond the descriptions of the GIL (Global Interpreter Lock)?
<lagweezle> benzrf: I'm guessing the key encryption is a big piece of the odd behavior.
<platzhirsch> Phrogz: How the thread scheduler works
samuel02 has quit []
phansch has quit [Quit: Leaving]
<Phrogz> FWIW; I know nothing of the implementation, or topics related to scheduling, so don't take my lack of knowledge to mean that no such good descriptions exist.
krisbulman is now known as [krisbulman]
burlyscudd has joined #ruby
phansch_ has joined #ruby
<platzhirsch> are the threads preemted
poikon_ has joined #ruby
<platzhirsch> preempted
kindjal has joined #ruby
phansch_ has quit [Client Quit]
IceDragon_ is now known as IceDragon
jonah_k has joined #ruby
phansch has joined #ruby
maletor has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
maletor has joined #ruby
<platzhirsch> YARV Thread Design https://github.com/ruby/ruby/blob/trunk/thread.c
toastynerd has quit [Remote host closed the connection]
momomomomo has quit [Quit: momomomomo]
<slowcon> Phrogz: ughhh, now im not so sure i foudn the problem. same error, trying to run from cmd prompt i get the DB error, run from the IDE, no error.
<platzhirsch> There are three models described,... so which one is implemented, gnaah
toastynerd has joined #ruby
felixjet_ has quit [Quit: Leaving]
toastynerd has quit [Remote host closed the connection]
felixjet has joined #ruby
<platzhirsch> Threads are native in the case of GIL
maletor has quit [Remote host closed the connection]
Advocation has quit [Quit: Advocation]
klaut has joined #ruby
burlyscudd1 has joined #ruby
burlyscudd has quit [Ping timeout: 245 seconds]
charliesome has joined #ruby
<platzhirsch> Ruby 1.8 had green threads
ianfleeton has joined #ruby
nanoyak has quit [Quit: Computer has gone to sleep.]
<platzhirsch> so whether it is preempting or what the OS does decide
aloitius_ has joined #ruby
Vovko has joined #ruby
klaut has quit [Ping timeout: 240 seconds]
oracal has joined #ruby
nanoyak has joined #ruby
<platzhirsch> so it seems like YARV is planning to destroy the GIL and use finer grained locking in the future
prc has joined #ruby
RaCx has joined #ruby
<apeiros> "is planning". they take their time. yarv is ~10y old now.
<mjc_> seems unlikely the GIL will go away anytime soon
burlyscudd1 has quit [Quit: Leaving.]
Azure has joined #ruby
<platzhirsch> I still don't understand why that is
<mjc_> for one, fine-grained locking could easily be a performance loss
<mjc_> for another C extension compatibility is very difficult to get right
Lewix has joined #ruby
<platzhirsch> Or with other words why the JVM doesn't need a GIL, because of the way code is interpreted?
RaCx has quit [Client Quit]
<mjc_> rubinius doesn't have a GIL either
Hobogrammer has quit [Ping timeout: 245 seconds]
shadoi has quit [Quit: Leaving.]
saarinen has joined #ruby
RaCx has joined #ruby
stryek has quit [Ping timeout: 248 seconds]
<shevy> ur mom doesn't have a GIL either!
mansi has quit [Read error: Connection reset by peer]
danshultz has quit [Read error: Connection reset by peer]
Astralum has quit [Quit: Leaving]
phansch has quit [Quit: WeeChat 0.4.2]
mansi has joined #ruby
phansch has joined #ruby
danshultz has joined #ruby
<platzhirsch> ah right. For one the garbager collector is a big problem
vic736 has joined #ruby
shadoi has joined #ruby
<platzhirsch> GC and Threading interferes heavily
zigomir has joined #ruby
<Phrogz> Aye, Rubinius has fully native threads.
ringaroses has joined #ruby
<platzhirsch> Fully? So has MRI
tvw has joined #ruby
<platzhirsch> >= 1.9
<toretore> not the ones it lets you use
<toretore> you are using green threads
<Phrogz> platzhirsch: I mean fully native with no GIL in Rubinius.
mansi has quit [Read error: Connection reset by peer]
timonv has quit [Remote host closed the connection]
mansi has joined #ruby
<platzhirsch> toretore: I reckon these are no green threads then. The classes are just an interface. Green Threads or Native Threads are implementation details, the other thing is just the API
daidoji has joined #ruby
<toretore> sure
<Phrogz> JRuby, too, has no GIL
bklane has quit [Remote host closed the connection]
<platzhirsch> That's because the JVM's GC is sophisticated
ageis has quit [Quit: http://ageispolis.net]
aaronmcadam has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
<platzhirsch> it has some locking though, there are safepoints, which is effectively a barrier
pfg has joined #ruby
yalue has quit [Quit: Leaving]
ringaroses has quit [Ping timeout: 252 seconds]
Hobogrammer has joined #ruby
mocfive has quit [Remote host closed the connection]
vic736 has quit [Ping timeout: 272 seconds]
Amnesia has joined #ruby
aryaching has quit [Ping timeout: 248 seconds]
RaCx has joined #ruby
tomshafer has joined #ruby
<Amnesia> does anyone over here know a library similar to scapy that enables you to inject packets using ruby/.
sn0wb1rd has quit [Ping timeout: 272 seconds]
<Amnesia> ?*
<Amnesia> >
louism2wash has quit [Quit: This computer has gone to sleep]
danshultz has quit [Read error: Connection timed out]
momomomomo has joined #ruby
danshultz has joined #ruby
sn0wb1rd has joined #ruby
Aryasam has joined #ruby
<Amnesia> I have found packetfu, but it's kinda outdated
freezey has quit [Remote host closed the connection]
ineb has joined #ruby
<platzhirsch> Why has my gem been "downloaded" so often? http://rubygems.org/gems/aquanaut are these crawlers
<AntelopeSalad> is there a way to determine the max number of child directories a provided directory has?
<pontiki> anyone know of any gems that split full names in two intelligently?
pushpak has quit [Ping timeout: 248 seconds]
<apeiros> AntelopeSalad: count
<AntelopeSalad> i'm thinking i would just walk the directory and compare the previous result to the current result and the max is when they match?
txdv has quit [Ping timeout: 245 seconds]
<platzhirsch> Someone wrote that thread-safety is not a proper property of data structure, that really pissed me off
<AntelopeSalad> apeiros: count on what tho?
<platzhirsch> (on SO)
axl_ has joined #ruby
aryaching has joined #ruby
<apeiros> AntelopeSalad: the thing you want to know the max of
Aryasam has quit [Client Quit]
<AntelopeSalad> apeiros: so there's no built in to get the max # of child dirs of a target dir?
<apeiros> don't know what max has to do with "previous result"
<apeiros> AntelopeSalad: ok, now I'm not sure anymore what you're after at all
<AntelopeSalad> well
* platzhirsch brings out his chainsaw 'wrrooooooom...wrooooom'
<toretore> platzhirsch: it is not a property of the datastructure
<platzhirsch> toretore: but of its implementation
<AntelopeSalad> imagine if you were to provide some directory -- let's say /tmp/foo
txdv has joined #ruby
<toretore> platzhirsch: arguably
<AntelopeSalad> the result is getting an integer back that is the maximum depth of childen folders in /tmp/foo
<ineb> hello, can someone help me with this? https://gist.github.com/anonymous/9080243 i dont know why this rspec is not working
<platzhirsch> Otherwise all the data structures from java.util.concurrent would make no sense
<AntelopeSalad> so if /tmp/foo/bar existed then it would return 1
itadder has quit [Remote host closed the connection]
<AntelopeSalad> and /tmp/foo/bar/baz would return 2
DrShoggoth has quit [Ping timeout: 245 seconds]
kpshek has joined #ruby
Hobogrammer has quit [Read error: Connection reset by peer]
itadder has joined #ruby
<toretore> AntelopeSalad: simple recursion
kpshek has quit [Remote host closed the connection]
stryek has joined #ruby
<apeiros> AntelopeSalad: then indeed, walk and count
jonah_k has quit [Remote host closed the connection]
RaCx has quit [Quit: Computer has gone to sleep.]
claymore has quit [Quit: Leaving]
<AntelopeSalad> if you glob a directory and go past its max then it will just give up
DrShoggoth has joined #ruby
<apeiros> and now "hu?" again
Czupa has quit [Read error: Operation timed out]
<AntelopeSalad> that's where the previous and current came into play -- the array of dirs you get back is the same whether you reached the max or went beyond it
Notte has quit []
bennylope has joined #ruby
<ineb> okay, for me even 'expect { "success" }.to eql("success")' is not working. what am i missing here?
hstalev has joined #ruby
mando has joined #ruby
hstalev has left #ruby [#ruby]
itadder has quit [Ping timeout: 264 seconds]
zigomir has quit [Read error: Operation timed out]
vlad_starkov has joined #ruby
zigomir has joined #ruby
thesheff17 has quit [Ping timeout: 252 seconds]
Kricir has joined #ruby
petey__ has quit [Remote host closed the connection]
<ineb> 'expect("success").to eql("success")' is working. can someone tell me where the difference between expect() and expect{} is?
diegovio1 has joined #ruby
thesheff17 has joined #ruby
petey has joined #ruby
centrx has joined #ruby
<benzrf> ineb: the latter passes a block?
claymore has joined #ruby
* Phrogz wonks unhelpful benzrf
vlad_starkov has quit [Ping timeout: 245 seconds]
quatron has joined #ruby
axsuul has joined #ruby
<apeiros> wonking… sounds like an innuendo
<Phrogz> ineb: I know nothing about RSpec (except that I personally don't like it), but I Googling turns up this: http://myronmars.to/n/dev-blog/2012/06/rspecs-new-expectation-syntax
jherbst has quit [Quit: Textual IRC Client: www.textualapp.com]
VTLob has quit [Quit: VTLob]
jonah_k has joined #ruby
petey has quit [Ping timeout: 265 seconds]
bennylope has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<shevy> wonking wonking wonking
* Phrogz is a minitest kind of guy
<shevy> every day I am wonking it
<shevy> every day I am shuffling it
<YourBestFriend> what's the point of requiring 'rubygems'? serious question
<shevy> YourBestFriend it is outdated
<shevy> unless you use good old 1.8.x
<shevy> 1.8.x was so sweet :)
<Phrogz> YourBestFriend: A very very long time ago it was available as a patch to require.
<Phrogz> 1.8.6 forevah
freezey has joined #ruby
Matriks has quit [Remote host closed the connection]
<apeiros> YourBestFriend: as of 1.9, none.
<shevy> YourBestFriend are you my best friend?
<apeiros> (as of ruby 1.9)
petey has joined #ruby
bennylope has joined #ruby
armyriad has quit [Ping timeout: 272 seconds]
<ineb> Phrogz: thank you. i fixed my tests now. i didnt know that there is a difference between 'expect("success").to eql("success")' and 'expect ("success").to eql("success")' (note the space after the second expect)
zeeraw has quit [Remote host closed the connection]
jkamenik has left #ruby [#ruby]
OdNairy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Phrogz> Optional parens strikes again!
<ineb> i got a warning, but i didnt recognized it.. its too late
<toretore> if in doubt, add parens
danshultz has quit [Remote host closed the connection]
platzhirsch has quit [Ping timeout: 260 seconds]
danshultz has joined #ruby
<shevy> ack
<shevy> lazy people omit parens
<shevy> lazy people deserve errors!
<toretore> but, but, but.. isn't lazyness a virtue??
venkat_ has joined #ruby
waheedi has joined #ruby
<shevy> guys - would you use this or this for a new project that disables colours
<shevy> require 'nocolors'
<shevy> require 'no_colors'
<waheedi> disable what?
<shevy> toretore yeah, most of the time it is good
<shevy> Waheedi COLORS
nszceta has joined #ruby
<waheedi> oh man what a grey life u have
jprovazn has quit [Quit: Odcházím]
<shevy> sometimes you need to cater to the colorblind
<toretore> shevy: as long as it's consistent with gem name, class name and directory it doesn't matter
<shevy> hmm
<shevy> ok but
<shevy> should it then be
<shevy> module Nocolors
<shevy> module NoColors
aspires has quit []
acoyfellow has joined #ruby
<toretore> well, forget i said that
<shevy> I spend most of my time not writing ruby code (because that is so easy) but instead thinking of things like that
nszceta has quit [Remote host closed the connection]
<shevy> I need answers! I have a "mkdir" pending and don't know what to input...
<toretore> gem install 'no-colors'; and then require 'nocolors' would leave a bad taste in my mouth
<shevy> hmm
<shevy> you can not use underscore there?
<apeiros> IMO require and gemname should match
Kricir has quit [Ping timeout: 272 seconds]
<apeiros> I hate the gems where it doesn't
Amnesia has left #ruby [#ruby]
<toretore> of course, that's what i'd expect
<shevy> yeah that is ok
<benzrf> i favor dashed names for gems and therefore requires
danshultz has quit [Ping timeout: 252 seconds]
<apeiros> and I want to kick the face of coders who don't mention the proper require in the readme even more.
<shevy> so I guess the tendency is towards 'nocolours' without - or _ right ?
<ineb> gem rest-client and require 'rest_client' has that same problem
<shevy> damn
<toretore> that is exactly what i expect
<benzrf> in python, module names must be valid identifiers, therefore import names must not have -, therefore packages should not either
<toretore> filenames should use underscores, but gem names should use hyphens
Kricir has joined #ruby
<shevy> okokok you convinced me just now... no - and no _ and it will be Nocolors
<ineb> i would go for nocolors, because thats the name of the project
<shevy> hehe
<toretore> class should still be NoColors
<shevy> hmmmmmmm
<shevy> I was just about to commit the mkdir command now toretore ...
<toretore> directory is still nocolors
<shevy> but why is the c Upcased suddenly
ianfleeton has quit [Quit: ianfleeton]
<toretore> because it makes sense
<toretore> Nocolors doesn't
<toretore> this thing people have with class names matching the file name is stupid
<ineb> say that to java folks
<toretore> you get stuff like require 'api-thingamajig' and ApiThingamajig when it should be APIThingamajig
poikon_ has quit []
<toretore> er, require 'api_...'
korzybski has joined #ruby
<shevy> heh I just wondered why there was a -
<shevy> I already thought we totally eliminated -
<ineb> now we are back at no-colors
<toretore> gem name will use it
<shevy> are there any gems that have foo-bar as require line to use?
<shevy> for the actual require command that is
<shevy> require 'bla-client'
<toretore> gem install 'json-parser'; require 'json_parser'; JSONParser.parse(data);
<shevy> well, the require is downcased, I can see that the gem name is different which is ugly, but at least the require is not a -
<slash_nick> shevy: i'd hope it'd be require 'foo/bar'
<shevy> hmm yeah, I think there are many with / ... cant recall any with -
ndrei has quit [Ping timeout: 272 seconds]
<ineb> toretore: is that a convention?
<toretore> it's my convention at least
mansi has quit [Read error: Connection reset by peer]
<toretore> and i see lots of others using it
<slash_nick> i think that breaks convention
mansi has joined #ruby
<toretore> this JsonParser nonsense was something rails introduced to do autoloading
korzybski has quit [Client Quit]
<shevy> see, apeiros already ruled on it :D
<shevy> <apeiros> IMO require and gemname should match
<shevy> btw JSONParser that is a damn ugly name
ndrei has joined #ruby
<shevy> and it is a bit weird to see Parse.parse() hmm
zachallett has quit [Remote host closed the connection]
<slash_nick> if the gem is json-parser, it oughta be require "json/parser" and JSON::Parser.parse(...)
Vivekananda has quit [Ping timeout: 240 seconds]
<shevy> hmm
<toretore> it's just an example..
<shevy> as long as it is not require "json-parser"
Phrogz has quit [Ping timeout: 245 seconds]
snath has joined #ruby
<slash_nick> is that ^ not a known convention?
ghostfaceskrilla has joined #ruby
<toretore> replace it with any other name with acronyms
burgess has quit [Quit: ^zzz]
s2013 has joined #ruby
<toretore> gem install 'xml-simple'; require 'xml_simple'; XMLSimple.parse(xml)
<toretore> (what it should be :)
io_syl has joined #ruby
Kricir has quit [Remote host closed the connection]
<slash_nick> respectfully, no way :)
mocfive has joined #ruby
<ineb> should it be gem install 'no-colors'; require 'no_colors'; NoColors.suchGray?
<shevy> guys I lied
maletor has joined #ruby
<shevy> I WILL USE COLOURS, NOT COLOURS!!!
<shevy> damn
<shevy> *COLORS
<ineb> such_gray ofc
<shevy> yeah
<toretore> don't use colours
<shevy> but that is a method name
<toretore> that's another stupid thing people do
<toretore> nobody expects you to
<slowcon> Phrogz: so i got the script to pull the array, and to iterate through each instance of the array. problem with the way i want it to insert the main ID. http://pastebin.com/3f9PBqMT
<shevy> method names are much easier than module / class / scope / directory layouts
<slash_nick> ineb: no
<shevy> toretore we had to learn UK spelling! :(
<slash_nick> toretore, ineb ^
<waheedi> shevy: colorful
<shevy> well
<toretore> slash_nick: i can live with that, as long as everyone follows it
platzhirsch has joined #ruby
<shevy> they do drive their cars the wrong way ...
Hobogrammer has joined #ruby
kcombs has quit [Remote host closed the connection]
tylershipe has quit [Ping timeout: 264 seconds]
lurch_ has joined #ruby
<apeiros> slash_nick: funny, I actually think json-parser -> json/parser a good choice
Xeago has quit [Remote host closed the connection]
<slash_nick> toretore: i have been for a while... join me:)
<apeiros> and even more funny - I did that myself without realizing it
RoryHughes has quit []
<slash_nick> apeiros: that is what I would do... and the class, JSON::Parser
mjs2600 has quit [Remote host closed the connection]
<ineb> okay, i will keep that in mind
<slash_nick> no_colors, require "no_colors"; NoColors.whatev
<toretore> though i dislike gems adding stuff to other gems' classes and modules
<apeiros> with json_parser I'd expect require 'json_parser' and JsonParser (JSONParser is acceptable too, but worse than JSON::Parser)
<slash_nick> toretore: that's how you keep a library neatly organized... a basegem with namespaced plugins
<toretore> i don't see the need for that
<bodie_> ruby is awful
<shevy> slash_nick yeah but only if we use a _ there!
RoryHughes has joined #ruby
dingus_khan has joined #ruby
<bodie_> y'all mofos need perl
<shevy> bodie_ and so is ur mom but still u are here to cheer with us!
<shevy> name a feature perl can do and ruby can not
sambao21 has quit [Quit: Computer has gone to sleep.]
<centrx> Has anyone had any success compiling Ruby with C profiling support (-pg) ?
ghostfaceskrilla has quit []
<bodie_> have sentences that make sense in the proper direction
olivier_bK has joined #ruby
<waheedi> shevy: colorful has no underscores "_"
<shevy> bodie_ [x] Done. Anything else?
sed_life_better has joined #ruby
<shevy> Waheedi yeah... colourful is a nice word
<bodie_> so I can write Ruby that goes SVO?
<shevy> you can write ruby that goes to venus if you want to
deception has quit [Remote host closed the connection]
ghostfaceskrilla has joined #ruby
leo-the-manic has quit [Remote host closed the connection]
<bodie_> *narrows eyes*
<shevy> *narrows ass*
bklane has joined #ruby
<bodie_> #typicalruby
<waheedi> lol
<shevy> #typicalbodie_
ghostfaceskrilla has left #ruby [#ruby]
_HolyCow has quit [Quit: Leaving.]
<bodie_> true
<shevy> what comes in must come out
<benzrf> bodie_: ruby rools perl droolz woot woot\
<shevy> bodie_ can I use perl 6
<bodie_> lol
<shevy> wat! :(
nfk has quit [Quit: yawn]
<shevy> you are not very chatty
<waheedi> seriously any idea where to find good ruby people?
geggam has quit [Ping timeout: 272 seconds]
<shevy> benzrf is a good man
<shevy> I have trust in him
<bodie_> definitely not in #ruby
<bodie_> try at #perl
<shevy> no bodie_ do not insult benzrf
<waheedi> open to hire work/contractors :)
<shevy> he used to use python
<shevy> and haskell
<benzrf> still use haskell
<benzrf> and i know perl
<shevy> now he is here AND HE ALREADY CREATED GEMS
<benzrf> perl r dum
<benzrf> it is a hot mess
<bodie_> a hot dumb awesome mess
<centrx> Waheedi, I guess #ruby is not good enough for you?
<shevy> bodie_ help me convince benzrf that haskell is a mess
Mongey has joined #ruby
Vovko has quit [Remote host closed the connection]
nhhagen has quit []
<benzrf> perl is like php if php weren't bad enough for me to rant about it when people mention it
<bodie_> I don't know enough about badskell to convince anyone anything about it, except that when I look at it, I want to punch a baby
<shevy> hehe
sambao21 has joined #ruby
<shevy> but tiobe says that php is the best scripting language
<benzrf> bodie_: that's your own shortcoming
<waheedi> centrx: there is no direct way to know if people here are interested in such thing :)
dingus_khan has quit [Ping timeout: 260 seconds]
<benzrf> bodie_: just because you are too dumb for haskell doesn't make it not incredibly awesome
<shevy> bodie_ ok man you just sulk about not knowing enough, GET TO LEARN
<bodie_> hahaha
<shevy> no ignore haskell
<benzrf> >tfw monads
<shevy> use javascript
kirun has quit [Quit: Client exiting]
<benzrf> >tfw applicatives
<benzrf> >tfw functors
<benzrf> >tfw lenses
<shevy> damn bodie_ you got him started ...
<bodie_> I'm sure all of those words mean something on whatever planet you're from
<benzrf> >tfw prisms
<benzrf> >tfw traversals
<shevy> he is from #haskell bodie_ can you go there and leave here?
<benzrf> >tfw monad transformers
<bodie_> lol
tommylommykins has quit [Remote host closed the connection]
<bodie_> I'm just stepping through Why's guide for the first time :)
<bodie_> this language is silly
<shevy> dude
<shevy> _why left
<shevy> like 8 years ago
<shevy> you are looking at ancient history of a CARTOON
<shevy> a CARTOON man
<shevy> don't you get it?!
<bodie_> where'd he leave to
jherbst has joined #ruby
<shevy> who knows
<benzrf> bodie_: a monad is just a type constructor T plus a function return of type (a -> T a) plus a function bind of type (m a -> (a -> m b) -> m b)
<shevy> he quitraged and removed his projects
<bodie_> #perl, I bet
<benzrf> what is so hard here
<shevy> nobody knows bodie_
<bodie_> I didn't say it was hard
<shevy> haskell is only for elite hackers
<benzrf> *T a -> (a -> T b) -> T b
<benzrf> 2used to m
<centrx> Waheedi, The other general Ruby channels on Freenode are #ruby-lang and #rubyonrails
<bodie_> gosh
phansch has quit [Quit: WeeChat 0.4.2]
<bodie_> you are so smart
<benzrf> oh and it has to follow the monad laws of course
<shevy> lol centrx
RaCx has joined #ruby
<benzrf> i am not smart for understanding it
<shevy> yeah bodie_ can you go to #ruby-lang? it is the official channel. no kidding
einarj_ has joined #ruby
<benzrf> it is u who is dumb for not understanding it
<benzrf> man!
<bodie_> ignorance is not the same thing as dumbness :)
nfk has joined #ruby
tommylommykins has joined #ruby
einarj has quit [Ping timeout: 264 seconds]
<bodie_> I choose to remain ignorant of Haskell because there is no incentive for me to spend even a single drop of energy learning it
<shevy> true
ner0x has joined #ruby
<benzrf> spoken like a true blub programmer
gamegenius86 has quit [Ping timeout: 240 seconds]
nfk has quit [Client Quit]
<bodie_> is haskell the ad-hominem language?
<shevy> bodie_ may be totally incompetent but he has a point here benzrf
<shevy> no, haskell is a language where you shuffle pure functions
<benzrf> haskell is the ad-fucking awesome language
<shevy> and you have to download more than 100MB to even use it
danshultz has joined #ruby
<bodie_> now you're tempting me a wee tiny bit
<shevy> no man
<bodie_> but why should I take your word for it
<shevy> don't go haskell
<benzrf> that's just because of some kind of dumb thing where it has 5 different versions of stages of compilation for each thing in the libs and compiler and stuff
teenwolf has quit [Ping timeout: 272 seconds]
ner0x has quit [Client Quit]
aloitius_ has quit [Ping timeout: 245 seconds]
<shevy> you'll end up as an elitist
<benzrf> i dont even know why they need that i mean rly
<shevy> yeah I dont know
<benzrf> im not an elitist i just have ~class~
<shevy> in 2005 or 2006 I got the haskell ghc and haskell was working
<benzrf> >haskell glasgow haskell compiler
<shevy> some years later I think in 2010 or something along those lines, I tried anew and it did not work
ghostfaceskrilla has joined #ruby
<bodie_> hmm... become an elitist? the temptation grows
<bodie_> but I could just be an elitist by being too elite to learn haskell
<shevy> god bodie_ you'll end up like ulrich drepper that way
ghostfaceskrilla has left #ruby [#ruby]
einarj_ is now known as einarj
<benzrf> haskell is so leet that it doesnt even have side effects
<bodie_> that's not unique
<benzrf> that's right every single function in haskell is referentially transparent!!
solars has quit [Ping timeout: 252 seconds]
<benzrf> yeah but it's the only -practical- language like that
<benzrf> everything else is for math only p much afaik
<bodie_> define "practical" lol
<benzrf> usable to write programs that people other than math majors will run
IceyEC has quit [Quit: IceyEC]
<shevy> wait
jokke has quit [Read error: Operation timed out]
<shevy> math majors love haskell
<shevy> so something is wrong here
<bodie_> so... like... math majors and IRC trolls will use my programs? awesome
<shevy> nah
<shevy> people don't use haskell
<benzrf> i didnt say that math majors wont run haskell
<shevy> so you would not reach IRC trolls bodie_
<benzrf> just that other people will too
aloitius_ has joined #ruby
<benzrf> look at xmonad !
<bodie_> good point
<shevy> elitist WM
<bodie_> then again, that implies irc trolls are people
<shevy> ruby has a WM too bodie_
<benzrf> haskell has leet performance
<shevy> C is faster
<bodie_> C is faster than everything
<bodie_> by definition
<benzrf> AND it has a strong static type system with near-perfect inference!
<benzrf> if you leave off type annotations nearly the only error you can get is ambiguous instance
nfk has joined #ruby
nfk has joined #ruby
<benzrf> 90% of problems with haskell programs show up as type errors
<benzrf> true leetness rite there
<benzrf> plus you dont have to write type annotations how awesome is that
<benzrf> none of java's bullshit verbosity
<bodie_> I read a breakdown somewhere saying that haskell isn't actually as fast as claimed since it has to be very carefully tailored to get the most out of its optimizations
<bodie_> and that the kind of haskell that is optimal isn't very... haskelly
Vovko has joined #ruby
MarcWeber has quit [Ping timeout: 252 seconds]
axl_ has quit [Quit: axl_]
endash_ has joined #ruby
diegovio1 is now known as diegoviola
<bodie_> I have to say though, that's definitely a huge plus (if not hugest) for the language (really good inference and error catching)
nfk has quit [Remote host closed the connection]
ecualombian has quit [Remote host closed the connection]
<bodie_> benzrf -- have you checked out Rust at all?
MarcWeber has joined #ruby
<slowcon> could you guys take a look at my script. i got the script to pull an array from a DB, and to iterate through each instance of the array. kind of hard to explain, but attached a picture for visual representation. http://pastebin.com/3f9PBqMT
<benzrf> a little bit
jokke has joined #ruby
<benzrf> bodie_: haskell is absolutely wonderful for bottom-up design btw
<benzrf> and it will explode your brain
<benzrf> unless you like, already know pure fp well
<bodie_> i like exploding my brain, but there are other languages for that
<bodie_> no, I don't but I'm getting interested
<bodie_> I was thinking about taking the approach via Scala since it's somewhat practical in real-world terms
<centrx> slowcon, Use Sequel's #where clause with update
<centrx> slowcon, dataset.where('price < ?', 100).update(:active => true)
<bodie_> I'd looked through Rust, Erlang, and Clojure, but none of them were able to get a grip on my time since I don't really have time to devote to sitting down and learning a language for fun
alvaro_o has quit [Ping timeout: 252 seconds]
<bodie_> shevy, any suggestions for a guide besides Why's? if that's dated
elaptics`away is now known as elaptics
aryaching_ has joined #ruby
<shevy> well, there is a better guide but it is also outdated, so :(
shadoi has quit [Quit: Leaving.]
zoscoy has quit [Quit: KVIrc 4.1.3 Equilibrium http://www.kvirc.net/]
<shevy> I came to ruby in 2004, things were quite ok back then
<banister> benzrf what's an applicative functor
<shevy> I could not even say how people today learn ruby
<benzrf> banister: its complicated
<benzrf> ill tell u in a sec hold on o-o
<slowcon> taking a look now, thanks centrx
MattStratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<bodie_> I wouldn't even be doing it if it wasn't for the fact that somehow EVERY SINGLE JOB that doesn't suck uses ruby
<shevy> no please
<shevy> bodie_ you refer to rails yes?
ianfleeton has joined #ruby
<shevy> please go over to #RubyOnRails at once
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ghostfaceskrilla has joined #ruby
<YourBestFriend> should I use alias or alias_method
<shevy> and QUIT HERE
<bodie_> I'm more of a Python / C / Go type guy, but the job market beckons
<YourBestFriend> what's the difference
<shevy> YourBestFriend alias, when possible
<ghostfaceskrilla> i like turtles
<YourBestFriend> shevy: WHY
<bodie_> too entry level to get a job in C or Go
<shevy> you use python? why change from one scripting language to another bodie_
<shevy> pfft a million go to Go, ask bnagy here
<centrx> YourBestFriend, Use alias_method to avoid problems
<shevy> YourBestFriend well the differences are subtle
<bodie_> I hadn't until just now. a friend has a connection with a shop that uses Rails so I'm taking a crack at it.
endash_ has quit [Quit: endash_]
<shevy> YourBestFriend, this is the best answer to it http://stackoverflow.com/questions/4763121/should-i-use-alias-or-alias-method but I almost always use alias myself
nfk has joined #ruby
nfk has joined #ruby
jonahR has quit [Quit: jonahR]
<benzrf> banister: applicative functors
<shevy> bodie_ omg this is too painful to hear, your poor friend! now go to #RubyOnRails
aryaching has quit [Ping timeout: 272 seconds]
<bodie_> not a rails fan eh?
<benzrf> banister: an applicative is a type constructor T plus a function pure of type `a -> T a` plus a function <*> of type `T (a -> b) -> T a -> T b`
<shevy> why did funk music die :(
rootshift_ has quit [Quit: My MacBook has decided to go to sleep. Zzzz..]
<shevy> bodie_, sure I love railsers but only if you aggregate on another channel!
<bodie_> because the soul died
nfk has quit [Client Quit]
<shevy> soul was cool
Kricir has joined #ruby
<banister> benzrf right :) i'd prefer a more intuitive explanation than one copy-pasted from a math journal ;)
<shevy> K.C.!
ghostfaceskrilla has quit []
<bodie_> well, for now I'm learning (and complaining) about Ruby before getting started with the web apps..... sigh
<shevy> soultrain
<shevy> nonono
<shevy> that is the wrong approach
<benzrf> banister: i was just givin u the spex
<shevy> you dont need ruby for rails
<benzrf> banister: how much haskell do you know?
<bodie_> wat
<shevy> just go into rails and ignore ruby
<shevy> lemme try to remember who did that here...
<bodie_> this sounds like a bad move
<bodie_> I should go into Ruby and ignore Rails
<shevy> AntelopeSalad <-- this guy
<banister> benzrf a fair amount actually, haven't done it in a while, but i read about it, and i've done quite a bit in the past
<shevy> AntelopeSalad, say something
<benzrf> banister: cool
<benzrf> banister: you know Functors yes?
<shevy> bodie_ only if you need to use ruby but you dont
<banister> benzrf Yeah
<shevy> you'll be a railser so you will be web-stuff only
<bodie_> *cries*
<shevy> you will learn the ecosystem of rails and that was it
<banister> benzrf and i actually understand applicative functors too, i was just wanting to hear your explanation, as i always learn a lot from fresh/different perspectives, and there's a lot of differnet want sof thinking about it i think
<bodie_> I want a job that doesn't suck. Anyone? lol
<benzrf> banister: applicatives are basically for mapping over multiple functors
<benzrf> ah
<AntelopeSalad> what's going on
<shevy> it's a good thing bodie_! you dont need to know ruby for rails
<shevy> AntelopeSalad you were the guy who learned rails first right?
<benzrf> banister: the idea is that fmap is sufficient to alter the insides of a functor without altering the structure
IceyEC has joined #ruby
<bodie_> this is me wrinkling up my nose in disgust at web frameworks for non-scientists
<shevy> bodie_ the truth is most jobs suck
<AntelopeSalad> shevy: no, not really
<benzrf> banister: applicative functors are for merging multiple functor values
<shevy> hmmm
<AntelopeSalad> i at least ready through eloquent ruby before touching rails
RaCx has quit [Quit: Computer has gone to sleep.]
<benzrf> banister: the structures are merged by the instance definition, the insides are merged by the function given
<shevy> aaaah ok
<slowcon> centrx: got it, subgenre_table.where(:subgenre_id => subgenre_links).update(:genre => new_g_id)
<bodie_> i'm told there is a secret golden city of scala jobs somewhere where the only currency they use is bitcoin
justinxreese has quit [Ping timeout: 246 seconds]
<shevy> bodie_ well I almost got it right... seems he learned a tiny bit of ruby before he dived in...
leonidlm has quit [Ping timeout: 240 seconds]
<slowcon> centrx: i think that was the fastest i figured something out. thanks brother
<AntelopeSalad> but reading it once and not really spending time with ruby before using rails wasn't really enough imo
<bodie_> AntelopeSalad, any pointers toward the right path?
<centrx> Glorious!
<AntelopeSalad> bodie_: yeah, definitely look at ruby's std lib in addition to reading at least 1 book or do a bunch of exercises in ruby first
justinxreese has joined #ruby
armyriad has joined #ruby
vlad_starkov has joined #ruby
aspires has joined #ruby
bandsaw1961 has joined #ruby
xcv has quit [Remote host closed the connection]
Vovko has quit [Remote host closed the connection]
hiall has joined #ruby
Vovko has joined #ruby
alvaro_o has joined #ruby
mark_locklear has quit [Quit: Leaving]
Al___ has joined #ruby
coderdad has quit [Remote host closed the connection]
vlad_starkov has quit [Ping timeout: 272 seconds]
andy has quit [Remote host closed the connection]
geggam has joined #ruby
Galgorth has joined #ruby
shadoi has joined #ruby
bennylope has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Vovko_ has joined #ruby
olivier_bK has quit [Ping timeout: 246 seconds]
Vovko has quit [Read error: Connection reset by peer]
RaCx has joined #ruby
claymore has quit [Ping timeout: 245 seconds]
zigomir has quit [Remote host closed the connection]
thesheff17 has quit [Quit: Leaving]
iamsean has joined #ruby
ppcsee has quit [Quit: Leaving]
thesheff17 has joined #ruby
zigomir has joined #ruby
jonah_k has quit [Remote host closed the connection]
Vovko_ has quit [Remote host closed the connection]
dkamioka has quit [Remote host closed the connection]
e12energy has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
<unholycrab> how do i use an object defined within the main app, within a function defined within the main app?
<unholycrab> example: log = Logger.new -- def function log.error "some error" end
petey has quit [Read error: Operation timed out]
<unholycrab> it says that log is undefined
<atmosx> unholycrab: @log = Logger.new
stryek has quit [Ping timeout: 260 seconds]
<atmosx> then use @log.error, these are called instance variables.
<atmosx> if you are using a class that is
jonah_k has joined #ruby
Wolland has joined #ruby
petey has joined #ruby
Vovko has joined #ruby
nfk has joined #ruby
nfk has quit [Changing host]
nfk has joined #ruby
axl_ has joined #ruby
<unholycrab> the new function doesn't inherit the objets from main?
<unholycrab> its parent object (err, might be using the wrong terms)
zigomir has quit [Ping timeout: 245 seconds]
aryaching_ has quit [Ping timeout: 272 seconds]
<bricker> unholycrab: it's not a question of inheritance, it's a question of variable scope
<jsilver> >> puts "export #{vars.map { |k, v| %{#{k}="#{v}"} }.join(" ")}"
<eval-in> jsilver => undefined local variable or method `vars' for main:Object (NameError) ... (https://eval.in/102894)
Vovko has quit [Remote host closed the connection]
pu22l3r has joined #ruby
<unholycrab> thanks bricker atmosx
<jsilver> >> exit
<eval-in> jsilver => exit (SystemExit) (https://eval.in/102895)
<jsilver> lol
<jsilver> there's no way to fuck up eval-in?
<jsilver> lol
<jsilver> just for fun I mean
pu22l3r has quit [Remote host closed the connection]
<jsilver> of course not silly jsilver
<jsilver> >> `uname -a`
<eval-in> jsilver => (https://eval.in/102896)
pyx has joined #ruby
<jsilver> heh
<jsilver> >> a=`uname -a`; puts a;
<eval-in> jsilver => (https://eval.in/102897)
<jsilver> meh
pu22l3r has joined #ruby
<jsilver> >> `ls`
<eval-in> jsilver => (https://eval.in/102898)
nfk has quit [Client Quit]
meatherly has quit [Remote host closed the connection]
<jsilver> im guessing i cant break it
<jsilver> ok
<jsilver> magic
meatherly has joined #ruby
pyx has quit [Client Quit]
<atmosx> unholycrab: https://gist.github.com/atmosx/9081927 a code sample
<jsilver> >> puts "#{RUBY_VERSION}-p#{RUBY_PATCHLEVEL}"
<eval-in> jsilver => 2.1.0-p0 ... (https://eval.in/102901)
aryaching has joined #ruby
<unholycrab> yup, got it atmosx
rayners has quit [Ping timeout: 240 seconds]
<atmosx> nice :-)
IceyEC has quit [Quit: IceyEC]
Vovko has joined #ruby
<jsilver> >> puts "#{$SAFE}"
<eval-in> jsilver => 0 ... (https://eval.in/102902)
jbueza has joined #ruby
Jdubs has joined #ruby
<jsilver> i give up
<jsilver> lol
axl_ has quit [Quit: axl_]
swaglord546 has joined #ruby
aryaching_ has joined #ruby
<benzrf> >> eval '3'
<eval-in> benzrf => 3 (https://eval.in/102903)
meatherly has quit [Ping timeout: 265 seconds]
magoo has joined #ruby
aryaching has quit [Ping timeout: 265 seconds]
bricker has quit [Quit: leaving]
nfk has joined #ruby
nfk has joined #ruby
nfk has quit [Changing host]
bandsaw1961 has quit [Quit: Textual IRC Client: www.textualapp.com]
nfk has quit [Client Quit]
kindjal has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
nanoyak has quit [Quit: Computer has gone to sleep.]
brandonjmckay has quit [Quit: Lingo - http://www.lingoirc.com]
nfk has joined #ruby
nfk has joined #ruby
nfk has quit [Changing host]
venkat_ has quit [Remote host closed the connection]
nanoyak has joined #ruby
venkat_ has joined #ruby
nfk has quit [Client Quit]
Sawbones has quit []
codenapper has quit [Quit: codenapper]
ZadYree has quit [Ping timeout: 256 seconds]
bobdobbs` has joined #ruby
rootshift_ has joined #ruby
deadlock has quit [Read error: Connection timed out]
<shevy> >> eval 'benzrf likes lolcats'
<eval-in> shevy => undefined local variable or method `lolcats' for main:Object (NameError) ... (https://eval.in/102904)
wald0 has quit [Quit: Lost terminal]
venkat_ has quit [Ping timeout: 248 seconds]
cpruitt has quit [Quit: cpruitt]
gja has quit [Quit: This computer has gone to sleep]
<bodie_> >> eval 'puts %w{ asdf fdsa qwerty }'
RaCx has quit [Quit: Computer has gone to sleep.]
<eval-in> bodie_ => asdf ... (https://eval.in/102905)
ndrei has quit [Ping timeout: 260 seconds]
nfk has joined #ruby
jlast has quit [Remote host closed the connection]
freezey has quit [Ping timeout: 240 seconds]
mary5030 has quit [Ping timeout: 240 seconds]
jlast has joined #ruby
dangerousdave has quit [Quit: My Mac Pro has gone to sleep. ZZZzzz…]
nfk has quit [Client Quit]
bricker has joined #ruby
ndrei has joined #ruby
kewubenduben has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
ageis has joined #ruby
iamsean has quit [Quit: iamsean]
burgess has joined #ruby
danshultz has quit [Remote host closed the connection]
danshultz has joined #ruby
jlast has quit [Ping timeout: 252 seconds]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mansi has quit [Quit: Leaving...]
nfk has joined #ruby
S0da has joined #ruby
DrShoggoth has quit [Quit: Leaving]
shawnjgoff has quit [Ping timeout: 272 seconds]
tfittsy has joined #ruby
tfitts has quit [Read error: Connection reset by peer]
funburn has joined #ruby
rootshift_ has quit [Quit: My MacBook has decided to go to sleep. Zzzz..]
yasushi has joined #ruby
jhass|off is now known as jhass
<benzrf> yo is there something like pstore but where each key is 1 file
danshultz has quit [Ping timeout: 252 seconds]
aryaching has joined #ruby
pinage404 has quit [Quit: Screw you guys i'm going home ! KMP ! ZNC - http://znc.in]
figgleberry has joined #ruby
<unholycrab> benzrf: why not create multiple pstore objects?
slowcon has quit []
<benzrf> because im doing lookup by keys
<benzrf> i guess i could just roll my own solution or something >_>
destruct1re has joined #ruby
rubyracer has quit [Quit: Konversation terminated!]
joelroa_ has quit [Ping timeout: 240 seconds]
<waheedi> i though u were going to roll something else
* benzrf whaps Waheedi on the head with a rolled-up newspaper
aryaching_ has quit [Ping timeout: 248 seconds]
<waheedi> lol
gja has joined #ruby
burlyscudd has joined #ruby
xargoon has quit [Ping timeout: 245 seconds]
<waheedi> I'm using my pipe nowadays
f3ttX] has joined #ruby
<waheedi> must seen video music for massive attack lovers http://www.youtube.com/watch?v=c61jlHO3rVM
aaronmcadam has quit [Quit: Leaving...]
nfk has quit [Quit: yawn]
ageis_ has joined #ruby
einarj has quit [Remote host closed the connection]
lmickh_ has joined #ruby
aryaching_ has joined #ruby
<YourBestFriend> must I call the parent class constructor in my constructor?
aryaching has quit [Ping timeout: 264 seconds]
<benzrf> why?
<benzrf> *wuould you have to
Soliah has quit [Quit: Soliah]
kebabski has joined #ruby
<YourBestFriend> well is it automatically called if I don't call it?
RoryHughes has quit []
xargoon has joined #ruby
dingus_khan has joined #ruby
nfk has joined #ruby
diegoviola has quit [Quit: WeeChat 0.4.3]
caesura has joined #ruby
vlad_starkov has joined #ruby
Vivekananda has joined #ruby
aspiers has joined #ruby
Jdubs_ has joined #ruby
unholycrab is now known as herosake
herosake is now known as unholycrab
_HolyCow has joined #ruby
interactionjaxsn has quit [Remote host closed the connection]
gregf1 has joined #ruby
interactionjaxsn has joined #ruby
destructure has quit [Ping timeout: 260 seconds]
atmosx has quit [Quit: Lost in trance]
jokke has quit [Ping timeout: 260 seconds]
subbyyy has quit [Ping timeout: 260 seconds]
ageis has quit [Ping timeout: 260 seconds]
kewubenduben has quit [*.net *.split]
Jdubs has quit [*.net *.split]
alexherbo2 has quit [*.net *.split]
vpretzel has quit [*.net *.split]
philcrissman has quit [*.net *.split]
gregf has quit [*.net *.split]
sepp2k1 has quit [*.net *.split]
apeiros has quit [*.net *.split]
devdazed has quit [*.net *.split]
lmickh has quit [*.net *.split]
AlSquire has quit [*.net *.split]
LadyRainicorn has quit [*.net *.split]
daidoji has quit [*.net *.split]
adeponte has quit [*.net *.split]
firefly2013 has quit [*.net *.split]
esuave has quit [*.net *.split]
Tarential has quit [*.net *.split]
multi_io has quit [*.net *.split]
defrag has quit [*.net *.split]
verto has quit [*.net *.split]
yeltzooo has quit [*.net *.split]
LiquidInsect has quit [*.net *.split]
hl has quit [*.net *.split]
soulcake has quit [*.net *.split]
awkisopen has quit [*.net *.split]
netf has quit [*.net *.split]
Caius has quit [*.net *.split]
v0n has quit [Ping timeout: 245 seconds]
Jdubs_ has quit [Remote host closed the connection]
devdazed has joined #ruby
lkba has quit [Ping timeout: 265 seconds]
lurch_ has quit [Quit: lurch_]
alexherbo2 has joined #ruby
vpretzel has joined #ruby
adeponte has joined #ruby
apeiros has joined #ruby
firefly2013 has joined #ruby
philcrissman has joined #ruby
AlSquire has joined #ruby
LadyRainicorn has joined #ruby
Tarential has joined #ruby
multi_io has joined #ruby
defrag has joined #ruby
esuave has joined #ruby
verto has joined #ruby
sepp2k1 has joined #ruby
LiquidInsect has joined #ruby
yeltzooo has joined #ruby
soulcake has joined #ruby
Caius has joined #ruby
netf has joined #ruby
awkisopen has joined #ruby
vlad_starkov has quit [Read error: Connection reset by peer]
yeltzooo has quit [Max SendQ exceeded]
Vivekananda has quit [Remote host closed the connection]
vlad_starkov has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
yeltzooo has joined #ruby
macclearich has joined #ruby
hl has joined #ruby
adeponte has quit [Ping timeout: 260 seconds]
Vivekananda has joined #ruby
<jsilver> hey you guys know the best way to say of course is OV CORZE right?
<jsilver> ov corze it is
interactionjaxsn has quit [Ping timeout: 245 seconds]
LexicalScope has quit [Read error: Connection reset by peer]
<Sloggerkhan> How do I reference self from a module in such a way that it references the class the module is included in instead of the scope the module is defined in? Or is inheritance the only way to share a class method?
RoryHughes has joined #ruby
LexicalScope has joined #ruby
bricker_ has joined #ruby
<centrx> SloggerKhan, What would be the natural way to do it?
bricker has quit [Ping timeout: 265 seconds]
<Sloggerkhan> centrx: I'd lean towards module since there are a few other related non-class methods and the code will be used in several unrelated classes, but I could always register the classes and then extend them as startup initialization.
Al___ has quit [Quit: Al___]
Vovko has quit [Remote host closed the connection]
adeponte has joined #ruby
Zackio has quit [Ping timeout: 272 seconds]
<Sloggerkhan> centrx: I'm not sure if I'm missing something, though.
gigetoo has quit [Ping timeout: 272 seconds]
ccooke has quit [Ping timeout: 272 seconds]
mosez has quit [Ping timeout: 272 seconds]
mosez has joined #ruby
ccooke has joined #ruby
sambao21 has joined #ruby
gigetoo has joined #ruby
bricker has joined #ruby
<centrx> SloggerKhan, Can't you use self.class ?
bogeyd6 has quit [Ping timeout: 264 seconds]
Zackio has joined #ruby
relix has joined #ruby
<Sloggerkhan> In a module it won't reference the right self even once included.
<toretore> SloggerKhan: what do you mean by reference?
rmorello has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
<toretore> do you have an example?
bricker_ has quit [Ping timeout: 252 seconds]
<Sloggerkhan> 1 sec.
aspiers has quit [Ping timeout: 252 seconds]
<YourBestFriend> >> if true then puts 'test' end
<eval-in> YourBestFriend => test ... (https://eval.in/102925)
shadoi has quit [Quit: Leaving.]
<YourBestFriend> >> if true; puts 'test' end
<eval-in> YourBestFriend => test ... (https://eval.in/102926)
<centrx> >> puts 'test' if true
<eval-in> centrx => test ... (https://eval.in/102927)
<YourBestFriend> >> def method then puts 'test' end
<eval-in> YourBestFriend => /tmp/execpad-6d3ce7965558/source-6d3ce7965558:2: syntax error, unexpected keyword_then, expecting ';' or '\n' ... (https://eval.in/102928)
<platzhirsch> I am too dense to understand my RubyProf results
sambao21 has quit [Client Quit]
<Sloggerkhan> https://gist.github.com/anonymous/b352cad719fc27781971 is the naive version that I'm sure doesn't work.
|jemc|_ has joined #ruby
aryaching_ has quit [Read error: Connection reset by peer]
<centrx> SloggerKhan, So what you really mean is you want to define a class method in the module
aryaching has joined #ruby
<platzhirsch> My method does 1 Mechanize.get and multiple Mechanize.head. The .get is attributed with 88% total time and the .head with 83% ... how does that add up?
<Sloggerkhan> centrx: yes
<Sloggerkhan> I think that's what I said
<centrx> Not sure how we get there from "How do I reference self from a module in such a way that it references the class the module is included in instead of the scope the module is defined in?"
ndrei has quit [Ping timeout: 245 seconds]
<centrx> Classic XY problem
andy has joined #ruby
dblessing has quit [Quit: dblessing]
<Sloggerkhan> anyway, yeah I guess what I asked was needlessly overcomplicated
chinkung has quit [Ping timeout: 272 seconds]
weems has quit [Read error: Connection reset by peer]
weeems has joined #ruby
<centrx> SloggerKhan, Follow the idiom at the top of http://api.rubyonrails.org/classes/ActiveSupport/Concern.html
<|jemc|_> anybody having played the field with this topic a bit have a suggestion for NoSQL server that plays nicely with Ruby, supports subscriptions, and has low latency times for small data sizes when not crossing into the WAN?
axsuul has quit [Quit: Textual IRC Client: www.textualapp.com]
weeems has quit [Max SendQ exceeded]
<|jemc|_> both small sizes for overall data stored and for individual values
weems has joined #ruby
<Sloggerkhan> thanks! I think I'm on the right track.
johnmilton has quit [Remote host closed the connection]
<Sloggerkhan> (Now.)
ndrei has joined #ruby
<jsilver> hey guys
<jsilver> almost time to (105*4)
<jsilver> >> 105*4
<eval-in> jsilver => 420 (https://eval.in/102930)
<jsilver> yes that's right eval-in! exactly right!
thams has joined #ruby
weems has quit [Max SendQ exceeded]
weems has joined #ruby
pu22l3r_ has joined #ruby
freezey has joined #ruby
weems has quit [Max SendQ exceeded]
weems has joined #ruby
bean has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
freezey has quit [Remote host closed the connection]
<jsilver> >> 84*5 + "weed"
<eval-in> jsilver => String can't be coerced into Fixnum (TypeError) ... (https://eval.in/102931)
pu22l3r has quit [Ping timeout: 245 seconds]
<jsilver> BobMarleyError
venkat_ has joined #ruby
pu22l3r_ has quit [Ping timeout: 246 seconds]
venkat_ has quit [Client Quit]
mercwithamouth has quit [Ping timeout: 260 seconds]
discord_ has joined #ruby
andy has quit [Remote host closed the connection]
<benzrf> jsilver: braev
msmith has quit []
Jetchisel has joined #ruby
<discord_> I'm trying to use string.index to match '<li class "product-list-title"><a href="' , but the matches are not happening. I am aware there are libraries made for working with html, and I know some regular expressions, but I'd like to know what might be causing index not to match. Any suggestions
jherbst has quit [Ping timeout: 260 seconds]
<discord_> ?
<centrx> Substring is not in string?
petey has quit [Read error: Connection reset by peer]
<discord_> centrx: I think I get null
caesura has quit [Quit: i'm no simpleton]
<discord_> nil
petey has joined #ruby
<benzrf> discord_: you cannot parse html with regex
<benzrf> then consider the consequences of your actions
petey has quit [Remote host closed the connection]
<discord_> I didn't think I was using regex, I thought I was using a string
randomnick_ has quit [Quit: Leaving]
<discord_> I wanted to use index with a string
nfk has quit [Quit: yawn]
<discord_> sorry i said match
tjr9898 has quit []
pudidis has quit [Ping timeout: 245 seconds]
<discord_> this is my string '<li class "product-list-title"><a href="'
ndrei has quit [Ping timeout: 260 seconds]
mlpinit has quit [Remote host closed the connection]
sambao21 has joined #ruby
Beoran has quit [Ping timeout: 264 seconds]
<discord_> start_pos=page.index('<li class "product-list-title"><a href="')
pudidis has joined #ruby
Thanatermesis has quit [Quit: ɯlɐɔ uı ʞɹoʍ oʇ ƃuıoƃ]
<centrx> String#index returns nil if substring is not found in string.
<discord_> </div>
<discord_> <ul class="description">
<discord_> <li class="product-list-vendor"><a href=
fveillette has quit []
blackmesa has quit [Ping timeout: 240 seconds]
ndrei has joined #ruby
Wolland has quit [Remote host closed the connection]
lkba has joined #ruby
vlad_starkov has joined #ruby
Vivekananda has quit [Remote host closed the connection]
andy has joined #ruby
toastynerd has joined #ruby
nfk has joined #ruby
mehlah has quit [Quit: Leaving...]
shadoi has joined #ruby
bleak has joined #ruby
meatherly has joined #ruby
Thanatermesis has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
aryaching_ has joined #ruby
magoo has quit [Quit: WeeChat 0.4.2]
vlad_starkov has joined #ruby
discord_ has quit [Ping timeout: 272 seconds]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
nfk has quit [Client Quit]
brandonjmckay has joined #ruby
burlyscudd has quit [Quit: Leaving.]
toastynerd has quit []
burlyscudd has joined #ruby
meatherly has quit [Ping timeout: 272 seconds]
aryaching has quit [Ping timeout: 252 seconds]
<TigerWolf> Can you combine 2 lambdas?
<centrx> What do you mean
<centrx> You can compose two lambdas...
vlad_starkov has quit [Ping timeout: 260 seconds]
Jdubs has joined #ruby
Vovko has joined #ruby
<benzrf> engwind
<benzrf> part of gweat bwitain
<centrx> blorjab
<TigerWolf> Yeah thats what Im looking to do. Thanks centrx, now for some more blogs to read
shaado has joined #ruby
ktosiek has quit [Ping timeout: 260 seconds]
gmi_ has joined #ruby
awarner has joined #ruby
mven_ has joined #ruby
Vivekananda has joined #ruby
charliesome has joined #ruby
charliesome has quit [Read error: Connection reset by peer]
Adawerk__ has quit [Read error: Connection reset by peer]
postmodern has joined #ruby
charliesome has joined #ruby
charliesome has quit [Read error: Connection reset by peer]
burlyscudd has quit [Ping timeout: 246 seconds]
Beoran has joined #ruby
platzhirsch has left #ruby [#ruby]
binaryhat has joined #ruby
charliesome has joined #ruby
charliesome has quit [Read error: Connection reset by peer]
nateberkopec has quit [Quit: Linkinus - http://linkinus.com]
charliesome has joined #ruby