havenwood changed the topic of #ruby to: Rules & more: http://ruby-community.com || Ruby 2.3.0; 2.2.4; 2.1.8; 2.0.0-p648: https://ruby-lang.org || Paste >3 lines of text on https://gist.github.com || log @ http://irclog.whitequark.org/ruby/
<Radar> is this some kind of joke?
<apeiros> (and a rationale is usually a good idea too, because the following will happen anyway)
<apeiros> why?
<eam> Array.new(2).map { array[rand(array.length)] }
<Radar> >> 2.times.map { array[rand(array.length)] }
<ruboto> Radar # => undefined local variable or method `array' for main:Object (NameError) ...check link for more (https://eval.in/497890)
<Radar> ruboto: Shhh
<apeiros> eam: why map?
<Radar> array = [1,2,3,4,5]; 2.times.map { array[rand(array.length)] }
<apeiros> Array.new takes a block just fine
_Tariq has quit [Remote host closed the connection]
<wolffles> lol
<apeiros> and Array.new(2) IMO communicates intent much better than 2.times.map
<Radar> >> array = [1,2,3,4,5]; 2.times.map { array[rand(array.length)] }
<ruboto> Radar # => [3, 3] (https://eval.in/497891)
<eam> apeiros: good point
<eam> what's the cleanest way to write: a = []; a.push a
blackmesa has quit [Ping timeout: 250 seconds]
<apeiros> I have nothing to offer beyond `a = []; a << a`
ibouvousaime has quit [Ping timeout: 255 seconds]
<Radar> eam: Ox0dea probably has a solution involving $
livcd has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
<eam> I have a deep seated dislike for using the bitshift operator in an overloaded fashion
<apeiros> Radar: eam asked for cleaner
<eam> I'll take $ solutions too
<eam> always welcome
<eam> does ruby maintain the $[ equiv?
<eam> (change arrays from being zero-indexed to $[ indexed)
<wolffles> thanks peeps
<wolffles> last question. when your reading “Integer#times” Returns the reciever …what does the # stand for?
<Radar> instance method
<wolffles> i see
<apeiros> :: would be used for class method
janebootydoe2 has quit [Quit: Leaving]
cschneid_ has quit [Remote host closed the connection]
crdpink has joined #ruby
crdpink has left #ruby [#ruby]
firstdayonthejob has quit [Ping timeout: 256 seconds]
pawnbox has joined #ruby
IlluminatiConfir has joined #ruby
<Radar> Or Class.method
<IlluminatiConfir> How can I call a method inside a method
<IlluminatiConfir> ?
<Radar> IlluminatiConfir: What have you tried?
<IlluminatiConfir> def method name
<IlluminatiConfir> action
<IlluminatiConfir> other method()
<IlluminatiConfir> end
mdw has quit [Quit: Sleeping Zzzzz]
IlluminatiConfir is now known as IlluminatiConf
IlluminatiConf is now known as Illuminati
Illuminati is now known as LordOfAllLords
<LordOfAllLords> Anyone?
pawnbox has quit [Ping timeout: 260 seconds]
CloCkWeRX has joined #ruby
<Ebok> Uh
<Radar> other method()? what
<Ebok> You call methods inside methods all the time...
<Radar> LordOfAllLords: no fake code please
<LordOfAllLords> I am new to Ruby (and programming) I want to run another method
<Ebok> Be more specific
<Ebok> Give an example in English at the bear minimum
<Ebok> bare
<shevy> the bear minimum! down with the bears!
<Ebok> lol
<LordOfAllLords> I defined a method that askes for an action, than a method for said action asks for some information, stores it in a variable, and then I ant to go back to first method
<shevy> show code LordOfAllLords?
<LordOfAllLords> want*
c355e3b has quit [Quit: Connection closed for inactivity]
<Radar> LordOfAllLords: Please provide the code for your problem.
zeroDivisible has quit [Quit: WeeChat 1.3]
<Ebok> How new are you to ruby?
m1dnight_ has joined #ruby
Coldblackice has quit [Read error: Connection reset by peer]
<LordOfAllLords> Rader hold up a min.
<m1dnight_> How can I install ruby gems with ruby2.0? Im afraid to break stuff by resymlinking ruby to ruby2.0
<m1dnight_> and I need to install jekyll which requires 2.0
<LordOfAllLords> Pretty new, can do some basics
<Radar> m1dnight_: install with chruby.
<Radar> Whoops, ruby-install
<Radar> m1dnight_: What OS are you on?
n_blownapart has joined #ruby
Coldblackice has joined #ruby
<m1dnight_> ubuntu 14.04 (Server)
<Radar> m1dnight_: Yup, ruby-install will install Ruby for you.
DonOtreply has quit [Ping timeout: 260 seconds]
hxegon has quit [Ping timeout: 276 seconds]
kith has joined #ruby
DonOtreply has joined #ruby
freerobby has joined #ruby
colegatron has quit [Ping timeout: 246 seconds]
lipoqil has quit [Quit: Connection closed for inactivity]
<m1dnight_> but does that allow me to install gems with the newest ruby?
<m1dnight_> Ill give it a shot
baweaver has joined #ruby
<LordOfAllLords> radar I just tried it again and it sems to be working, i'll implemet it into my code later and get back if it still dosent work
<Radar> LordOfAllLords: ok
cmolenda has joined #ruby
<Radar> m1dnight_: yes it does
<m1dnight_> Ill give it a shot, thanks
LordOfAllLords has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
ziyadb has quit [Quit: Connection closed for inactivity]
Nahra``` has quit [Read error: Connection reset by peer]
haraigo has joined #ruby
Nahra``` has joined #ruby
rrichardsr3 has quit [Quit: Apparantly my attempt to stay awake has failed...]
dfockler has joined #ruby
<m1dnight_> Hmm, seems like the bin files are not being copied to /usr/local/bin
blackgoat has quit [Quit: WeeChat 1.3]
<Ox0dea> m1dnight_: Do you want to have multiple versions of Ruby installed?
NoTroutAboutIt has joined #ruby
Lucky__ has joined #ruby
<m1dnight_> Well, I just don't want to break stuff. That is all.
<m1dnight_> I just did `ruby-install --latest`, we'll see what happens.. I guess :p
<m1dnight_> I can always go back I think by chaning the symlink
<m1dnight_> (I think)
ellistaa has quit [Quit: ellistaa]
blackgoat has joined #ruby
mistermo_ has joined #ruby
agent_white has quit [Quit: brbfarmstuff]
blackgoat has quit [Client Quit]
<m1dnight_> Right, gitlab was the one that was acting up with some ruby versions. Let's see how it goes..
baweaver has quit [Remote host closed the connection]
chipotle has quit [Quit: cheerio]
kalopsian has joined #ruby
<shevy> the cautious on tippy toes :D
atomical has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
iateadonut has joined #ruby
mistermo_ has quit [Ping timeout: 256 seconds]
colegatron has joined #ruby
mary5030 has quit [Remote host closed the connection]
karapetyan has quit [Remote host closed the connection]
Lucky__ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
karapetyan has joined #ruby
LordOfAllLords has joined #ruby
RegulationD has joined #ruby
weemsledeux has joined #ruby
pwnd_nsfw has quit [Ping timeout: 260 seconds]
karapetyan has quit [Ping timeout: 260 seconds]
zotherstupidguy has quit [Ping timeout: 246 seconds]
kfpratt has quit [Remote host closed the connection]
whippythellama has quit [Quit: WeeChat 1.3]
chouhoulis has quit [Remote host closed the connection]
blackgoat has joined #ruby
chouhoulis has joined #ruby
RegulationD has quit [Ping timeout: 276 seconds]
chouhoulis has quit [Remote host closed the connection]
<m1dnight_> I got it working!
DonOtreply has quit [Quit: DonOtreply]
<m1dnight_> I didnt have to use the ruby-install though. I had it installed and all, but it turned out I just had to point /usr/bin/gem to /usr/bin/gem2.0
<m1dnight_> not sure if I broke something important now..
zotherstupidguy has joined #ruby
<Radar> I have a CSV file which is this: https://gist.github.com/radar/3260e7a958044f10baea Is there something I can pass to CSV.parse to make it ignore the first line?
drys has quit [Ping timeout: 240 seconds]
<Radar> That CSV was generated with CSV.generate, so I'm assuming CSV.parse has something to do that.
aibot has quit [Ping timeout: 240 seconds]
<Radar> Actually, it's generated by another library. Please ignore me :)
Lucky__ has joined #ruby
mloy has quit [Quit: Leaving]
Lucky__ has quit [Client Quit]
ruby-lang427 has joined #ruby
scottschecter has joined #ruby
pwnd_nsfw has joined #ruby
ruby-lang427 has quit [Ping timeout: 252 seconds]
pawnbox has joined #ruby
<cmolenda> Just in case it helps with whatever you end up doing, a very easy way to ignore the first element of an array (the first line of a file, if pulled in via CSV or readlines) is using a range of 1..-1. E.g. filearray[1..-1]
<cmolenda> (Radar)
<Radar> cmolenda: Yeah, that's effectively what this library is doing
<Radar> it's the excel_csv gem. I was generating it with that gem, but trying to read it with the stdlib CSV
<cmolenda> Ah
SCHAAP137 has joined #ruby
finisherr has quit [Quit: finisherr]
<apeiros> Radar: still need a solution?
<Radar> na, got it
<apeiros> ok
pawnbox has quit [Ping timeout: 260 seconds]
zenlot2 has joined #ruby
bensarz has quit [Quit: Textual IRC Client: www.textualapp.com]
ur5us has joined #ruby
ta has joined #ruby
zenlot1 has quit [Ping timeout: 260 seconds]
crystalmaiden has quit [Ping timeout: 240 seconds]
<Ox0dea> >> [1,2,3].drop(1) # cmolenda
<ruboto> Ox0dea # => [2, 3] (https://eval.in/497904)
<Ox0dea> (For your bag of tricks.)
<apeiros> I wish drop(1) would return an Enumerator
<apeiros> or at least Enumerator#drop(1) would do that
<cmolenda> Huh, didn't even know drop was a method, thanks Ox0dea
<Ox0dea> Sure thing.
dfockler has quit [Ping timeout: 256 seconds]
MattV has quit [Ping timeout: 276 seconds]
<Ox0dea> apeiros: That would require an implementation of Enumerator#prev, no?
<Ox0dea> It's essentially gotta invoke #next to perform the first step of the enumeration.
<Ox0dea> Which it would have to "rewind" to get you back to the start.
<Ox0dea> And I now realize there's Enumerator#rewind...
ta has quit [Ping timeout: 250 seconds]
DLSteve has joined #ruby
<Ox0dea> Still, Enumerator#prev would be nice, but probably pretty crazy.
<apeiros> Ox0dea: no, it just needs to remember how many elements to skip
<apeiros> no need for #prev
<Ox0dea> Skipping doesn't work.
<Ox0dea> Enumerations can be stateful.
<apeiros> an example where it wouldn't work?
<Ox0dea> When the next value relies on some previous one and/or external state.
NoTroutAboutIt has quit [Ping timeout: 260 seconds]
marr has quit [Ping timeout: 256 seconds]
<apeiros> any concrete example? :)
n_blownapart has quit []
<Ox0dea> How is that of any pertinence, though? It would obviously have to work in the general case to go into the language.
<apeiros> because frankly, I doubt you're right
ruid has joined #ruby
ruid has quit [Changing host]
ruid has joined #ruby
<apeiros> [1,2,3].drop(1).other_enum should be just like [2,3].other_enum
<apeiros> state doesn't come into play
<Ox0dea> apeiros: https://eval.in/497905
<Ox0dea> How do you suppose "skipping" would work there?
mjbjr has joined #ruby
nettoweb has joined #ruby
crystalmaiden has joined #ruby
stryek has joined #ruby
<apeiros> e.drop(2).each would call .next twice before yielding
<Ox0dea> Exactly.
<Ox0dea> That's not "skipping".
<apeiros> that's text-book definition of skipping
nettoweb has quit [Max SendQ exceeded]
CloCkWeRX has left #ruby [#ruby]
<apeiros> even if you go all pedantic
<Ox0dea> apeiros: Consider an Enumerator that writes to a file in #next, for whatever reason.
<apeiros> that'd have weird effects with pretty many enumerator functions
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Ox0dea> Which ones come to mind?
<apeiros> as side effects in general would
<apeiros> try peek
<apeiros> and relatives
<apeiros> try rewind
<Ox0dea> But that Enumerators *can* have side effects is why Enumerator#drop can't Do the Right Thing in the general case.
<apeiros> if you arbitrarily define "the right thing", sure.
babblebre has quit [Quit: Connection closed for inactivity]
<apeiros> skipping is easily good enough.
pwnd_nsfw has quit [Ping timeout: 250 seconds]
mary5030 has joined #ruby
<apeiros> and if you have side effects in such an enumerator and fail to read the docs - well, cry me a river.
bkxd has joined #ruby
nettoweb has joined #ruby
<Ox0dea> "Skip" and "ignore" don't strike me as even remotely synonymous, but okay.
<apeiros> that'd be because they aren't.
<Ox0dea> But you're using them synonymously?
<apeiros> ignoring has no relation to order.
ruid has quit [Quit: Leaving]
nettoweb has quit [Max SendQ exceeded]
CloCkWeRX has joined #ruby
CloCkWeRX has left #ruby [#ruby]
mistermocha has quit [Remote host closed the connection]
<mjbjr> just did a fresh gentoo install of ruby... for gems, is the current best pactice to use 'gem install some_gem' or to use 'emerge some_gem' directly?
<Ox0dea> To "skip" the enumeration would (rather obviously) be to not do it; you're suggesting that Enumerator#drop could perform the enumeration and ignore its result/effects.
shinnya has quit [Ping timeout: 255 seconds]
gregf has quit [Quit: WeeChat 1.3]
<Ox0dea> mjbjr: Does Portage repackage every single gem?
shadoi has quit [Quit: Leaving.]
guacamol_ has joined #ruby
guacamol_ has quit [Client Quit]
guacamol_ has joined #ruby
<apeiros> mjbjr: depends. as Ox0dea insinuates, you might not have the newest or all packages. otoh using gem will mean that you use two package managers. in most cases, using gem is probably less painful.
bkxd has quit [Ping timeout: 255 seconds]
guacamole has quit [Ping timeout: 246 seconds]
MattV has joined #ruby
<apeiros> Ox0dea: I find your notion of skipping broken. ary.each.drop(2) does in no way imply that the .each would *not* go over all elements. all it implies is that *after* the drop(2), you get 2 less from the *result*
<apeiros> so IMO your whole argument holds no water.
<mjbjr> apeiros: roger that, is there a 'gem cmd some_gem' where it will give me details about the gem without installing it? In the past the 'pg' gem had fallen behind the code in an 'emerge pg'.
<apeiros> it should neither be the aim, nor be expected to suppress iteration before the dropping.
pawnbox has joined #ruby
astrobu__ has joined #ruby
<apeiros> mjbjr: gem help commands
astrobu__ has quit [Remote host closed the connection]
<mjbjr> thanks
<apeiros> I rarely use anything besides gem install, sorry.
kfpratt has joined #ruby
guacamole has joined #ruby
<Ox0dea> apeiros: Iteration and enumeration are subtly different things.
<mjbjr> apeiros: ok, good to know
<Ox0dea> A simple array can be indexed into; that just isn't true for an enumerator.
<apeiros> I think gem search -d does. but gem search does a wildcard search. if you want for the precise name, use '^name$'
<apeiros> Ox0dea: does not change a single thing about what I said.
<apeiros> the expression before can be a filter, a generator or an iterator. it does not matter.
gregf has joined #ruby
<Ox0dea> It'd just be weird for a "subtractive" operation like #drop to be stateful.
<apeiros> the expression before is not expected to not go through all values it enumerates.
wolffles has quit [Quit: wolffles]
<Ox0dea> Huh?
<apeiros> Ox0dea: it's just as stateful as each_cons or each_slice.
<apeiros> not weird at all.
<apeiros> or .first(n) or .last(n)
guacamol_ has quit [Ping timeout: 245 seconds]
<apeiros> .last(n) being a nice example of your way of thinking to utterly fail.
dlitvak has quit [Remote host closed the connection]
<apeiros> because that too will just iterate through all values, retaining n values. so if you expect that to not invoke the expression before it for all values for the first length-n items…
<Ox0dea> >> Enumerator.instance_methods.include? :last # apeiros
<ruboto> Ox0dea # => false (https://eval.in/497908)
pawnbox has quit [Ping timeout: 260 seconds]
<apeiros> bruh, do it right.
<Ox0dea> ?
pwnd_nsfw has joined #ruby
<apeiros> oh, hah, right. Enumerable#last is a patch.
<Ox0dea> Because it doesn't belong.
paradisaeidae has joined #ruby
<Ox0dea> Enumeration != iteration. You have some reading to do, and that's a good thing.
<apeiros> only in your weird world where a subsequent expression must suppress what a previous expression does
dlitvak has joined #ruby
mary5030 has quit [Remote host closed the connection]
<apeiros> which makes zero sense.
<Ox0dea> My weird world... and Ruby.
hewhomust has joined #ruby
<Ox0dea> I mean, do you think I somehow managed to trick ruboto into responding `false` there?
<apeiros> any suggestions for said reading? which preferably contradicts anything I said…
<Ox0dea> apeiros: Why doesn't Enumerator have #last?
<apeiros> > Ox0dea: Enumeration != iteration
<Ox0dea> Is it because it can't be defined in the general case?
<apeiros> that's correct. an enumerator can be infinite. which would cause last(n) to not hold.
<BraddPitt> W 2
<BraddPitt> oops, sorry folks
<apeiros> guess what, there's other expressions for which that applies.
<BraddPitt> W 2
<apeiros> BraddPitt: fail 2?
<BraddPitt> ahaha, yes
<BraddPitt> new keyboard
<apeiros> ^^
<LordOfAllLords> What should I be researching if I want to store information using Ruby. I want to store a database with titles and contents. SQL?
<apeiros> Ox0dea: btw., I'm pretty sure an enumerator with a side effect fails the definition of an enumerator.
SCHAAP137 has quit [Remote host closed the connection]
<Ox0dea> >> :Ruby == :Haskell
<ruboto> Ox0dea # => false (https://eval.in/497910)
<apeiros> Ox0dea: you can't have your cake and eat it too
<shevy> :)
icarus has quit [Ping timeout: 265 seconds]
<apeiros> on one hand you try to argue with purity, on the other hand you drop it the second it bites your argument
aibot has joined #ruby
icarus has joined #ruby
<Ox0dea> apeiros: I wasn't arguing for parity, but rather against *unintended* side effects.
BTRE has quit [Remote host closed the connection]
<apeiros> I maintain: drop(n) does not have to change what the enumerator it is chained to does. it's effect is for the chain which follows. if you build an enumerator which has side-effects and need a construct to not execute the side-effects of the first N enumerations, drop(N) would be the wrong tool.
blackgoat has quit [Ping timeout: 265 seconds]
kies^ has quit [Ping timeout: 276 seconds]
<LordOfAllLords> What should I be researching if I want to store information using Ruby. I want to store a database with titles and contents. SQL?
gatman_ has quit []
<Ox0dea> apeiros: Should there be Enumerator#skip?
<apeiros> Enumerable#skip. I see no reason to use a new name.
<apeiros> i.e. #drop returning an enumerator would suffice.
<apeiros> Ox0dea: another question: Should the current Enumerator#drop not execute the first N enumerations?
kfpratt has quit [Remote host closed the connection]
krz has joined #ruby
<apeiros> your argument implies that the current implementation of #drop is already broken.
solocshaw has quit [Ping timeout: 240 seconds]
<Ox0dea> apeiros: Looks "broken" to me: https://eval.in/497911
slash_quit is now known as slash_nick
nanoz has joined #ruby
<Ox0dea> As you've suggested, it "should" return an Enumerator, but an appeal to generality decrees that it can't.
<apeiros> Ox0dea: is that a "yes, current drop is already broken"?
<apeiros> Ox0dea: Enumerator#to_a too, yes?
<apeiros> because that won't like your infinite enumerators either
<Ox0dea> All of the Enumerator methods that don't return Enumerators are "broken"; we agree on this point.
<apeiros> oh, no, we don't
<apeiros> I wouldn't want .first() return an enumerator. that makes no sense.
<apeiros> I do like .to_a on it.
<Ox0dea> I was overly inspecific, but I'd hoped you'd catch the gist.
<apeiros> just because there are cases where it *can't* work does not refute its utility.
<Ox0dea> Sure, and I maintain that #drop is such a case.
<apeiros> and a .last(n) is just as fine on Enumerator as a .to_a or a .drop
<apeiros> (in its current form)
<Ox0dea> Then why doesn't it exist?
tenseiten has joined #ruby
<apeiros> and changing .drop to return an Enumerator would not change anything about your previously cited issue.
tenseiten has quit [Client Quit]
<Ox0dea> How come Enumerator#last isn't a thing?
<apeiros> Ox0dea: why did Array#to_h not exist before 2.2?
<apeiros> it's a nonsensical question
LordOfAllLords has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
<Ox0dea> apeiros: Could you show me your Enumerator#last patch?
<Ox0dea> Is it just `to_a[-1]`?
<apeiros> either nobody decided it should go in, or somebody expressly decided it was too much, or - but that I doubt - somebody decided it did not belong.
<apeiros> Ox0dea: mostly. it checks for .reverse_each to optimize.
frem has quit [Quit: Connection closed for inactivity]
freerobby has quit [Quit: Leaving.]
<apeiros> great. seems I don't have that on my imac and my laptop is in the sleeping room. can't show you the code now. but the patch is indeed just a respond_to?(:reverse_each) -> reverse_each.first(n).reverse, else -> .each, accumulate n, shift/push until end
yfeldblum has quit [Remote host closed the connection]
<Ox0dea> Nifty.
pietr0 has quit [Quit: pietr0]
pawnbox has joined #ruby
<apeiros> oh, right, special case for no-arg
<apeiros> since that returns single element. there with .reverse_each it's .reverse_each do |x| return x end
<apeiros> and without reverse_each it's obviously just rv=nil; each do |x| rv = x; end
<apeiros> so your infinite enumerator wouldn't run out of memory from the to_a, it's just not halt
govg has joined #ruby
rkazak has joined #ruby
yfeldblum has joined #ruby
pawnbox has quit [Ping timeout: 260 seconds]
NoTroutAboutIt has joined #ruby
Lucky__ has joined #ruby
<Radar> How can I make this regex match only the first code block? http://rubular.com/r/CiUvEsGLkI
<Radar> it shouldn't be matching the title from the second code block
icarus has quit [Read error: Connection reset by peer]
<apeiros> Radar: but your regex specifies "match {…} block, then match all lines which start with whitespace, then match first line which does not start with whitespace"
weemsledeux has joined #ruby
<apeiros> and the first line without whitespace is the second {…} block
icarus has joined #ruby
<Radar> apeiros: yeah
<apeiros> so I'm not quite sure what it is supposed to match
<Radar> I think I can get away with /^({[^}]*})$(\s{4}.*)/m
<Radar> apeiros: It should match the {title ... } and then the indented code block underneath it, and then stop
<apeiros> ok
<apeiros> that I can show you :D
plantigrade has quit [Quit: WeeChat 1.0.1]
avelldiroll has joined #ruby
<Radar> :D
ruby-lang134 has joined #ruby
<Radar> Here's another example with some text following the codeblocks that shouldn't be matched: http://rubular.com/r/ZESMFS1BQy
<apeiros> one way, if all blocks are indented
<apeiros> it has more parens than necessary if you don't need the indented block in a match
<Radar> apeiros: that's the same URL that I gave you. You have to click the URL you generate.
waka has quit [Remote host closed the connection]
guacamol_ has joined #ruby
<apeiros> hm, I copied too quickly http://rubular.com/r/a8uQPOF3Qh
scripore has quit [Read error: Connection reset by peer]
<Radar> And it doesn't match text after the fact. Nice :)
<Ox0dea> Is that too brittle?
guacamol_ has quit [Client Quit]
<Radar> Ox0dea: Yeah. Not always guaranteed to end in end
<Radar> These are code blocks from my book
bithon has quit [Ping timeout: 265 seconds]
guacamol_ has joined #ruby
guacamole has quit [Ping timeout: 265 seconds]
ruby-lang134 has quit [Ping timeout: 252 seconds]
scripore has joined #ruby
<apeiros> ^({[^}]*})$\n((?:(?:(?=\s).*)\n?)*) if you don't want that newline in the second capture
<Ox0dea> apeiros: That catches the "Text goes here".
<Ox0dea> This boils down to matching properly nested parentheses, where ( = indent and ) = dedent.
<apeiros> no?
<apeiros> did you… try it?
<apeiros> or did you only prove it to match? :)
<Ox0dea> Ah.
guacamole has joined #ruby
<Ox0dea> apeiros is a strong, independent Rubyist who don't need no /m flag.
bkxd has joined #ruby
<apeiros> I fail to spot the difference :-S
<apeiros> ah, right
<apeiros> yeah, I removed the m flag in mine.
n0xff has joined #ruby
kfpratt has joined #ruby
poguez_ has quit [Quit: Connection closed for inactivity]
guacamol_ has quit [Ping timeout: 265 seconds]
<apeiros> night :)
crystalmaiden has quit [Ping timeout: 272 seconds]
bkxd has quit [Ping timeout: 240 seconds]
crystalmaiden has joined #ruby
veg has joined #ruby
solocshaw has joined #ruby
howdoi has joined #ruby
Bloomer has joined #ruby
terminalrecluse has joined #ruby
veg__ has quit [Ping timeout: 246 seconds]
bithon has joined #ruby
veg has quit [Client Quit]
hahuang61 has joined #ruby
BTRE has joined #ruby
hahuang65 has quit [Ping timeout: 240 seconds]
mistermocha has joined #ruby
amclain has quit [Quit: Leaving]
ixti has joined #ruby
ixti has quit [Client Quit]
mjbjr has left #ruby ["Leaving"]
djbkd has quit [Remote host closed the connection]
kfpratt has quit [Remote host closed the connection]
kfpratt has joined #ruby
<Radar> :)
<Radar> thanks apeiros
woodruffw has quit [Quit: And then he took off.]
<Darmani> Ox0dea: Breh
<Radar> Tests all pass.
<Radar> \o/ \o/ \o/
<Darmani> Why isn't this the same as this?
veg has joined #ruby
<Darmani> What am I missing here.
<Radar> Darmani: bro
<Radar> Darmani: The cool kids all use Gist to paste code
<Darmani> lmao
<Darmani> Gist is overrated
<Radar> no u
<Darmani> and I don't know how to use it =P
<Radar> ?gist-usage
<ruboto> https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
mistermocha has quit [Ping timeout: 276 seconds]
<Radar> ruboto: you fail
<Radar> here is an illustrated guide to gist https://github.com/radar/guides/blob/master/using-gist.markdown
<Darmani> Can you just look at the code I posted? -__-
<Radar> no
<Darmani> I don't care about that right now
<Radar> I have work to do
<Darmani> fine
woodruffw has joined #ruby
<blub> my_alll? is any, not all
ss_much has quit [Quit: Connection closed for inactivity]
RegulationD has joined #ruby
<Darmani> blub: ok..
<Darmani> This logic is hurting my head T.T
<Ox0dea> Darmani: But... why? :<
<Darmani> I don't know... It just seems the same to me...
<Darmani> Unless I'm reading it wrong.
<Ox0dea> `false unless` is indeed the same as `true if`, which is not what you want. :P
kfpratt has quit [Remote host closed the connection]
<Darmani> It's not what I want??
<Darmani> What do I want.
<Ox0dea> One of these should be called #my_any?, right?
<Radar> probably false if
<Radar> or true unless
<Radar> *shrug*
<Darmani> my_any
<Darmani> Nooo
<Darmani> I haven't gotten there yet
<Darmani> I restarted to scratch to practice writing the logic.
<Ox0dea> Well, `false unless` == `true if`, but the semantics change in the context of an early return from a loop.
bmurt has joined #ruby
<blub> you might try unrolling it
<Ox0dea> So, yeah, the code's fine, but #my_alll? should be called #my_any?.
<Ox0dea> You won, but only accidentally.
<Darmani> Ox0dea: No waittt. Let me explain myself better.
<Ox0dea> I dare you.
RegulationD has quit [Ping timeout: 250 seconds]
BSaboia has quit [Ping timeout: 250 seconds]
woodruffw has quit [Quit: And then he took off.]
woodruffw has joined #ruby
<Darmani> I know the code works with return false unless yield(i). I thought return true if yield(i) was the same thing. Ox0dea.
woodruffw has quit [Client Quit]
hanmac has quit [Ping timeout: 250 seconds]
<Darmani> So I thought both of those versions of my_all would do the same thing.
woodruffw has joined #ruby
<Darmani> They should shouldn't they???
<Darmani> That's what I don't get.
<Ox0dea> It's the `return` that changes things.
govg has quit [Ping timeout: 240 seconds]
<Darmani> Well what am I missing?
<Ox0dea> >> (1 if true) == (1 unless false)
<ruboto> Ox0dea # => true (https://eval.in/497913)
rkazak has quit [Quit: Sleep.....ing....]
shakes has joined #ruby
<Ox0dea> #my_all? will bail early with `false` if any element fails to satisfy the predicate, which is good.
<Ox0dea> #my_alll? will win early with `true` as soon as if finds a matching element, so it should be called #my_any?.
<Ox0dea> *it finds
<Darmani> ohhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
<Ox0dea> Yay!
<Ox0dea> That looks like grokking if I've ever seen it.
<Darmani> That's why.
joonty has joined #ruby
<Darmani> wow.
<Darmani> Can't believe I didn't notice that.
<Darmani> Ox0dea: Thank you sir. You are a god among men.
shakes has quit [Client Quit]
<Ox0dea> Darmani: That's the third time I've been told as much in as many IRC sessions.
voodo has joined #ruby
<Ox0dea> You blasphemers just need to stop.
<Darmani> Ox0dea: If you're serious I won't mention it again lol
<Ox0dea> Darmani: I fuckin' love it. :P
<Darmani> Lmaoo okay
<Ox0dea> Jokes aside, I'm glad I could help.
<Darmani> I can never tell with you
<Ox0dea> Me neither.
* Darmani slaps Ox0dea
guacamol_ has joined #ruby
<Ox0dea> "That's gonna smart in the mornin'!"
<Darmani> who says that. ouch that smarts. lmao
<Ox0dea> Haha.
arescorpio has joined #ruby
<Ox0dea> Oh, wow, I apparently got that from Jim Carrey in the Lemony Snicket movie.
hahuang61 has quit [Ping timeout: 260 seconds]
janebootydoe has joined #ruby
janebootydoe has quit [Max SendQ exceeded]
joonty has quit [Ping timeout: 255 seconds]
<Darmani> Ox0dea: Jim Carrey would say something like that.
<Ox0dea> I'm sure I've seen it somewhere since for it to have gone into long-term.
guacamo__ has joined #ruby
<Darmani> It's one of those older expressions that don't exist anymore
janebootydoe has joined #ruby
janebootydoe has quit [Max SendQ exceeded]
niemcu has quit [Ping timeout: 246 seconds]
<Darmani> like 'Darn tootin".
<Darmani> or.. "Cowabunga".
govg has joined #ruby
janebootydoe has joined #ruby
guacamole has quit [Ping timeout: 265 seconds]
finisherr has joined #ruby
dbugger has quit [Remote host closed the connection]
<Ox0dea> Darmani: So, uh, how's #my_reduce coming along?
dlitvak has quit [Remote host closed the connection]
<eam> gnarly colloquialisms buddy, don't get edged 'cause I'm weazin all your grindage just chill
<Ox0dea> Holy Clockwork Orange, Batman!
render___ has joined #ruby
<Darmani> lmao
renderfu_ has quit [Ping timeout: 240 seconds]
<Darmani> Ox0dea: I'll get there eventually.
guacamol_ has quit [Ping timeout: 265 seconds]
<Darmani> I'm kind of afraid to get there lol
<Ox0dea> What does that mean?
Jardayn has quit [Read error: Connection reset by peer]
<Darmani> reduce, inject, those seem hard.
hxegon has joined #ruby
<Ox0dea> They're the same thing.
<Ox0dea> #inject is a holdover from a bygone era.
<Darmani> a bygone era.
<Darmani> Meaning?
<Ox0dea> Smalltalk.
davedev24 has quit []
<Ox0dea> Imagine if MapReduce had been called CollectInject.
<Darmani> Ah.
<Darmani> I guess.
hanmac has joined #ruby
shakes has joined #ruby
Mia has quit [Read error: Connection reset by peer]
<Ox0dea> Ruby was not born in a vacuum.
<Ox0dea> It takes inspiration from many other languages, Smalltalk second-chief among them.
<Darmani> Is this a lecture? Lol
<havenwood> Ox0dea: I think I'll drop my fancy preference for inject come to think of if.
govg has quit [Ping timeout: 260 seconds]
<Ox0dea> Darmani: Do you want it to be?
<havenwood> Darmani: Yes. Listen closely so that you may learn!
<Darmani> Ox0dea god no lol
<Zarthus> :(
<Ox0dea> Hi, Zarthus.
<Zarthus> Hello.
<havenwood> Ox0dea: Reduce I will.
<Ox0dea> havenwood: Huzzah!
* Darmani waves at Zarthus & havenwood
<Ox0dea> Reductions for the transducer god!
<havenwood> Indeed!
<havenwood> The One True Transducer.
<Zarthus> o/
<Ox0dea> A "transjector" sounds like it'd be dangerous.
guacamo__ has quit [Quit: Textual IRC Client: www.textualapp.com]
ellistaa has joined #ruby
janebootydoe has quit [Quit: Leaving]
Porfa has joined #ruby
lacuna has quit [Remote host closed the connection]
<Ox0dea> Darmani: What do I do with this?
<Darmani> Well it's music.
<Porfa> puts “yo” * 99
ta has joined #ruby
<Darmani> People typically listen to music.
<Ox0dea> Darmani: I prefer to feel it.
<Ox0dea> Will I feel this one?
<Darmani> Ox0dea: Lol that's up to you xD
DLSteve has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Ox0dea> > learn from the ones we hate the most
<Ox0dea> Should I make something of that?
<Darmani> Ox0dea: You could.
<Ox0dea> I might.
<Darmani> You said you wanted to feel =P
<Ox0dea> I'm feeling it now, Mr. Darmani.
penne12 has joined #ruby
<Darmani> Ox0dea: Mission Accomplished
freerobby has joined #ruby
jbrhbr has quit [Ping timeout: 255 seconds]
<penne12> hello
<blub> hi penne12
* Darmani waves to penne12
<penne12> I feel popular
<Darmani> Or the people here are genuinely welcoming.
<Darmani> Which has nothing to do with you.
<penne12> D:
<penne12> Thanks, btw
<Darmani> <33
psy_ has quit [Read error: No route to host]
<Ox0dea> > Hello, babies. Welcome to Earth. It's hot in the summer and cold in the winter. It's round and wet and crowded. At the outside, babies, you've got about a hundred years here. There's only one rule that I know of, babies — "God damn it, you've got to be kind."
ta has quit [Ping timeout: 264 seconds]
<Darmani> Ox0dea: Is that a song?
<Ox0dea> Vonnegut.
* Darmani is 22 years old
* Darmani thinks that was before his time
hxegon has quit [Quit: BRB]
<Nilium> You should read Vonnegut.
<Darmani> Oh that's an author?
psy_ has joined #ruby
<Nilium> Kurt Vonnegut, yes.
<Ox0dea> Darmani: They don't make you kids read Slaughterhouse-Five anymore?
<Darmani> With a title like that I can't imagine why xP
<Nilium> Every time I re-read that I'm amazed by how much of it I've forgotten
<Ox0dea> I read it in a sitting...
d0nn1e has quit [Ping timeout: 250 seconds]
haraigo has quit [Ping timeout: 256 seconds]
<Darmani> How does one change their nickname?
<Ox0dea> /nick ohai
<Darmani> o.o
Bloomer has quit []
Darmani is now known as Majora
voodo has quit [Quit: Leaving...]
<Majora> nuuu
<Majora> Wait
<Majora> Oh it worked.
<Nilium> I wonder how long it'd take to do Gravity's Rainbow in a sitting and how many pillows I'd need to sit on
<Majora> Cool.
<Ox0dea> Nilium: You're crazy.
<Ox0dea> Pynchon is crazy.
<Nilium> Yeah.
<Majora> These are books I've never heard of....
<Majora> They must be old.
<Nilium> Pynchon's pretty famous.
ellistaa has quit [Quit: ellistaa]
<blub> you don't sound very literate
d0nn1e has joined #ruby
<Nilium> That doesn't seem like a nice thing to say.
<Majora> blub: I suppose not by your standards.
<eam> littering is a crime
<Majora> bulb: Obviously since I haven't heard of any of these books I must not be very smart at all.
<Ox0dea> Just uncultured.
<Majora> Ox0dea: That I can handle =P
yqt has quit [Quit: KVIrc 4.0.4 Insomnia http://www.kvirc.net/]
govg has joined #ruby
terminal_ has joined #ruby
FooMunki has quit [Quit: FooMunki]
terminalrecluse has quit [Ping timeout: 264 seconds]
agent_white has joined #ruby
dorei has quit []
crystalmaiden has quit [Ping timeout: 255 seconds]
thomcom has joined #ruby
krobzaur has joined #ruby
hxegon has joined #ruby
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Majora> whyy is this happening.
<Ox0dea> Majora: Who're you and what have you done with Darmani?
<Majora> lmao.
Majora is now known as Darmani
<Darmani> Ox0dea http://ideone.com/51ob1Q
<Ox0dea> Majora: You're not defining #my_map in a way that it's accessible on Arrays.
<Ox0dea> Darmani: Same goes for you.
<agent_white> Evenin'
<Ox0dea> What's with the backslide?
<Ox0dea> agent_white: Ahoy!
* Darmani waves to agent_white
<agent_white> How goes it?
weemsledeux has joined #ruby
<Darmani> Ox0dea: How do I fix this?
Darmani is now known as Majora
<Ox0dea> Majora: You were doing just fine before?
<Majora> yeah... but I don't remember how I did that.
<Ox0dea> This means you've pretty much just been typing rather than programming. :<
<Majora> that's not true -__-
<Ox0dea> It so is doe.
<Majora> I started rewriting all the methods from the beginning.
<Majora> to practice.
<Ox0dea> And you forget all that back there about modules and #include and the like?
thomcom has quit [Client Quit]
<Majora> I supposed trying to figure out modules and just started writing the methods.
<Majora> stopped*
blackgoat has joined #ruby
<Ox0dea> Majora: As you have it, you'd need to say `my_map([1,2,3]) { |i| i == 2 }`, but Ruby is an object-oriented language.
<Ox0dea> Er, you'd also need to define #my_map to take a parameter, but don't do that.
<Majora> yeah. I didn't do that before.
<Ox0dea> That's because you put #my_foo in the right place such that it could be invoked on objects of the appropriate type.
baweaver has joined #ruby
<Majora> Ox0dea: I didn't? o.o
<Ox0dea> You did.
<Majora> oh.
sankaber has joined #ruby
hxegon has quit [Quit: BRB]
<Ox0dea> Seems it's high time you stuck a toe into the pOOl.
<Majora> p00l
<Ox0dea> 0bject-0riented
<Majora> gr3at
NoTroutAboutIt has quit [Ping timeout: 250 seconds]
kalopsian has quit [Ping timeout: 256 seconds]
nanoz has quit [Read error: Connection reset by peer]
tmtwd has joined #ruby
crdpink has joined #ruby
kobain has quit [Quit: KVIrc 4.1.3 Equilibrium http://www.kvirc.net/]
NoTroutAboutIt has joined #ruby
niotoan has quit [Read error: Connection reset by peer]
AndChat|20400 has joined #ruby
molay has joined #ruby
kfpratt has joined #ruby
<molay> I'm stumped, I get this warning when I try to install gems "WARNING: You don't have /home/molay/.gem/ruby/2.3.0/bin in your PATH, gem executables will not run."
pawnbox has joined #ruby
<molay> help me #ruby, you're my only hope
<penne12> type `echo $PATH`
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
kfpratt has quit [Remote host closed the connection]
<penne12> actually, can you type this instead: echo $PATH | ruby -e "puts STDIN.gets.chomp.split(\":\")"
krz has quit [Ping timeout: 240 seconds]
pawnbox has quit [Ping timeout: 246 seconds]
<penne12> Thanks
<molay> no, thank you
<molay> yeah, I've tried everything I could find
<penne12> hmm
<molay> maybe some context might help?
<penne12> looks like you defiantly have /home/molay/.gem/ruby/2.3.0/bin on your PATH
<penne12> sure, molay
<molay> I did a clean install of linux mint
<molay> then
<penne12> how did you install ruby?
<molay> I installed ruby via apt-get... but realized it was version 1.9
<molay> so I uninstalled it
<molay> and built 2.3.0 from source
<penne12> oh
<molay> before my reinstall I had ruby 2.2
<molay> and installed that from a repository, everything worked fine
mkosaki has joined #ruby
aadam21 has joined #ruby
<molay> I just can't seem to get my executable path to be used
waka has joined #ruby
<penne12> Im also stumped.
<penne12> Let me think
<Ox0dea> Looks like RVM has stricken again.
<molay> yeah i think i might have figured something out
<molay> i just ran gem install rubygems-update
<molay> and update_rubygems
<molay> now my - EXECUTABLE DIRECTORY: /usr/local/bin
krobzaur has quit [Ping timeout: 272 seconds]
<penne12> Are you using rvm?
<penne12> If so, you might want to look at this: https://rvm.io/integration/gnome-terminal
<molay> yes
mjuszczak has joined #ruby
mary5030 has joined #ruby
<molay> i'm using another terminal galled tilda
pawnbox has joined #ruby
gix has quit [Ping timeout: 260 seconds]
al2o3-cr has quit [Ping timeout: 264 seconds]
devbug has joined #ruby
<mjuszczak> I'm trying to figure out if the file ".gitignore" contains a file, via Ruby. What's the best way to do this? Is there a simple way to parse the .gitignore file using ruby?
<molay> do you think I might be better off removing ruby and rvm completely and then reinstalling from a repo?
phredus has joined #ruby
<penne12> mjuszczak, can you use bash?
<mjuszczak> penne12: no reason why I can't shell out. Execute git check-ignore?
<penne12> You can pipe a file in "cat .gitignore | ruby yourfile.rb"
<penne12> I don't know if that's a good idea, though
gix has joined #ruby
<penne12> open the .gitignore file, it's seperated by newlines
al2o3-cr has joined #ruby
<penne12> you can use the file class
PsionTheory has quit [Remote host closed the connection]
arup_r has joined #ruby
<mjuszczak> that'll work! Just wanted to make sure there wasn't something simple I was missing.
<Ox0dea> mjuszczak, penne12: .gitignore directives can contain special characters that you'd want to treat, well, specially.
skcin7_ has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<mjuszczak> understood
<mjuszczak> thank you!
<Ox0dea> There's the Shellwords standard library, but alas, no `Shellwords.shellexpand` method. :<
<mjuszczak> hrmph
<mjuszczak> I'll just shell out to git check-ignore
<Ox0dea> Seems perfectly reasonable.
<Ox0dea> "Reinvent only that you would improve the wheel."
terminalrecluse has joined #ruby
terminalrecluse has quit [Client Quit]
aadam21 has quit [Remote host closed the connection]
shakes has quit [Quit: Leaving]
aadam21 has joined #ruby
agent_white has quit [Read error: Connection reset by peer]
terminal_ has quit [Ping timeout: 255 seconds]
bmurt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
duncannz has joined #ruby
krz has joined #ruby
rkazak has joined #ruby
aadam21 has quit [Ping timeout: 272 seconds]
veg has quit []
astrobun_ has joined #ruby
agent_white has joined #ruby
bkxd has joined #ruby
zast has joined #ruby
scripore has quit [Quit: This computer has gone to sleep]
scripore has joined #ruby
joonty has joined #ruby
niftylettuce has joined #ruby
bkxd has quit [Ping timeout: 240 seconds]
yfeldblum has quit [Ping timeout: 240 seconds]
cmolenda has quit [Remote host closed the connection]
akkad has quit [Excess Flood]
ceej has quit [Ping timeout: 264 seconds]
<molay> Ox0dea: you made a remark about RVM earlier... would you advise against using it?
bb010g has joined #ruby
TheHodge has quit [Quit: Connection closed for inactivity]
ellistaa has joined #ruby
<Ox0dea> molay: I can only offer an outsider's perspective, but it seems to do more harm than good.
arescorpio has quit [Quit: Leaving.]
ellistaa has quit [Client Quit]
<Ox0dea> It sticks its fingers in too many cookie jars, but I suppose some people might prefer that.
cmolenda has joined #ruby
<molay> Ox0dea: oh ok.. so you're an outsider with regards to RVM or with regards to Ruby?
<Ox0dea> molay: RVM. :P
akkad has joined #ruby
<molay> Ox0dea: haha yeah figured. more curious what your answer was gonna be
joonty has quit [Ping timeout: 260 seconds]
rrichardsr3 has joined #ruby
scripore has quit [Quit: This computer has gone to sleep]
skcin7 has joined #ruby
<Ox0dea> molay: I like simple things kept simple, and for that there's chruby.
mjuszczak has quit []
psy_ has quit [Remote host closed the connection]
mistermocha has joined #ruby
astrobun_ has quit [Remote host closed the connection]
<molay> Ox0dea: me too.. I will check it out
penne12 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
molay has quit [Quit: Leaving]
mistermocha has quit [Ping timeout: 245 seconds]
hxegon has joined #ruby
scottschecter has quit [Ping timeout: 265 seconds]
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
pawnbox has quit [Remote host closed the connection]
hxegon is now known as hxegon_AFK
hxegon_AFK is now known as hxegon
cmolenda has quit [Remote host closed the connection]
NoTroutAboutIt has quit [Ping timeout: 260 seconds]
djbkd has joined #ruby
cscheib has quit [Quit: leaving]
freerobby has quit [Quit: Leaving.]
domgetter has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
pawnbox has joined #ruby
ellistaa has joined #ruby
<greenhat> I used to manually compile rubies and manually update symlinks. Then I discovered RVM and it was great. Then bundler made most of RVM unnecessary for me and I switched to chruby and ruby-build and it is great.
<greenhat> I hope one day native OS packages will get their act together and I won't need any ruby version managers at all, and it will be great.
mary5030 has quit [Remote host closed the connection]
<Ox0dea> $ pacman -Si ruby | grep V
<Ox0dea> Version : 2.3.0-1
<Ox0dea> Just sayin'.
pawnbox has quit [Remote host closed the connection]
<greenhat> Yeah. Gentoo does a fair job too. But arch and gentoo are fairly niche :)
<greenhat> I do use the brightbox ppa in production.
<greenhat> I guess I should re-phrase that to "when osx gets its act together".
Dimik has quit [Ping timeout: 240 seconds]
rrichardsr3 has quit [Quit: Apparantly my attempt to stay awake has failed...]
ellistaa has quit [Quit: ellistaa]
hxegon is now known as hxegon_AFK
makenoise has joined #ruby
hxegon_AFK is now known as hxegon
pawnbox has joined #ruby
Melpaws1 has joined #ruby
MattV has quit [Quit: Leaving.]
niotoan has joined #ruby
AndChat|20400 has quit [Read error: Connection reset by peer]
djbkd has quit [Remote host closed the connection]
cscheib has joined #ruby
astrobun_ has joined #ruby
kfpratt has joined #ruby
bestbrents has joined #ruby
ta has joined #ruby
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
UtkarshRay has joined #ruby
BTRE has quit [Remote host closed the connection]
moei has quit [Quit: Leaving...]
hakunin has quit []
yes`r has quit [Ping timeout: 245 seconds]
ta has quit [Ping timeout: 260 seconds]
aadam21 has joined #ruby
arup_r has quit [Remote host closed the connection]
ceej has joined #ruby
darkf has joined #ruby
<havenwood> greenhat: 2.3.0 on brew or macports already.
UtkarshRay has quit [Quit: Leaving]
<havenwood> greenhat: Even fink too.
yardenbar has quit [Ping timeout: 240 seconds]
BTRE has joined #ruby
hxegon is now known as hxegon_AFK
<havenwood> greenhat: OS X seems well covered.
Majora has quit [Ping timeout: 252 seconds]
arup_r has joined #ruby
poguez_ has joined #ruby
karapetyan has joined #ruby
djbkd has joined #ruby
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
Respek has quit [Quit: gone to sleep. ZZZzzz…]
hxegon_AFK has quit [Quit: BRB]
karapetyan has quit [Ping timeout: 260 seconds]
howdoi has quit [Quit: Connection closed for inactivity]
fly5566 has joined #ruby
ur5us has quit [Ping timeout: 240 seconds]
jobewan has joined #ruby
user083 has quit [Read error: Connection reset by peer]
drys has joined #ruby
yfeldblum has joined #ruby
yfeldblum has quit [Remote host closed the connection]
LMity has joined #ruby
yfeldblum has joined #ruby
yes`r has joined #ruby
djbkd has quit [Remote host closed the connection]
hxegon has joined #ruby
astrobun_ has quit [Remote host closed the connection]
sigurding has joined #ruby
djbkd has joined #ruby
aadam21 has quit [Ping timeout: 250 seconds]
dlitvak has joined #ruby
pawnbox has quit [Read error: Connection reset by peer]
pawnbox has joined #ruby
rdavila has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
makenoise has quit []
Coldblackice has quit [Ping timeout: 260 seconds]
bkxd has joined #ruby
Palaver has joined #ruby
govg has quit [Ping timeout: 264 seconds]
icarus has quit [Read error: Connection reset by peer]
icarus has joined #ruby
dlitvak has quit [Ping timeout: 255 seconds]
govg has joined #ruby
rkazak has quit [Quit: Sleep.....ing....]
BTRE has quit [Quit: Leaving]
bkxd has quit [Ping timeout: 265 seconds]
astrobun_ has joined #ruby
Feyn has joined #ruby
Feyn has quit [Client Quit]
Feyn has joined #ruby
astrobun_ has quit [Read error: Connection reset by peer]
astrobun_ has joined #ruby
LMity has quit [Ping timeout: 265 seconds]
blackgoat has quit [Ping timeout: 246 seconds]
rkazak has joined #ruby
Feyn has quit [Client Quit]
darkf_ has joined #ruby
LMity has joined #ruby
fly5566 has quit [Remote host closed the connection]
darkf has quit [Disconnected by services]
darkf_ is now known as darkf
toretore has joined #ruby
Feyn has joined #ruby
astrobun_ has quit [Ping timeout: 240 seconds]
hxegon has quit [Quit: BRB]
mary5030 has joined #ruby
govg has quit [Ping timeout: 276 seconds]
govg has joined #ruby
mary5030 has quit [Ping timeout: 260 seconds]
astrobun_ has joined #ruby
dionysus69 has joined #ruby
paradisaeidae has quit [Ping timeout: 260 seconds]
astrobun_ has quit [Read error: Connection reset by peer]
astrobun_ has joined #ruby
paradisaeidae has joined #ruby
tubuliferous_ has quit [Ping timeout: 260 seconds]
govg has quit [Ping timeout: 264 seconds]
krzkrz has joined #ruby
krz has quit [Read error: Connection reset by peer]
drys has quit [Read error: Connection reset by peer]
tubuliferous_ has joined #ruby
soahccc has quit [Ping timeout: 240 seconds]
Palaver has quit [Quit: Palaver]
dionysus69 has quit [Quit: dionysus69]
aadam21_ has joined #ruby
tmtwd has quit [Ping timeout: 260 seconds]
lacuna has joined #ruby
colegatron has quit [Ping timeout: 260 seconds]
govg has joined #ruby
Ishido has joined #ruby
aganov has joined #ruby
viperman has joined #ruby
sigurding has quit [Quit: sigurding]
lacuna has quit [Remote host closed the connection]
djbkd has quit [Quit: My people need me...]
trautwein has joined #ruby
juddey has joined #ruby
icarus has quit [Read error: Connection reset by peer]
symm- has joined #ruby
icarus has joined #ruby
paradisaeidae has quit [Quit: ChatZilla 0.9.92 [Firefox 43.0.3/20151223140742]]
symm- has quit [Client Quit]
mary5030 has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
lacuna has joined #ruby
jam_ has joined #ruby
DonOtreply has joined #ruby
lacuna has quit [Read error: Connection reset by peer]
viperman has quit [Remote host closed the connection]
colegatron has joined #ruby
lacuna has joined #ruby
lacuna has quit [Changing host]
lacuna has joined #ruby
claw has quit [Ping timeout: 240 seconds]
mary5030 has quit [Remote host closed the connection]
charliesome has joined #ruby
pawnbox has quit [Remote host closed the connection]
danielpclark has joined #ruby
lxsameer has joined #ruby
LMity has quit [Quit: Nettalk6 - www.ntalk.de]
zast has quit [Remote host closed the connection]
pawnbox has joined #ruby
haraigo has joined #ruby
dionysus69 has joined #ruby
greenride has joined #ruby
dlitvak has joined #ruby
<greenride> Are there any Ruby frameworks that use a persistent connection to push data to a web browser from a server? Ideally, the framework would be compatible with a Postgres database.
RegulationD has joined #ruby
<Ox0dea> greenride: Sounds like you want ActionCable.
yardenbar has joined #ruby
<greenride> Ox0dea: Cool! I didn't realize this was merged into Rails.
n00bdev has joined #ruby
aadam21__ has joined #ruby
<greenride> Has anyone done load tests on the maximum number of open connections this can support?
dlitvak has quit [Ping timeout: 256 seconds]
baweaver has quit [Remote host closed the connection]
<Ox0dea> I suspect somebody has.
claw has joined #ruby
RegulationD has quit [Ping timeout: 240 seconds]
framling has joined #ruby
sigurding has joined #ruby
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
choke has joined #ruby
krzkrz has quit [Ping timeout: 272 seconds]
choke has quit [Read error: Connection reset by peer]
radgeRayden has joined #ruby
rkazak has quit [Quit: Sleep.....ing....]
aadam21_ has quit [Remote host closed the connection]
aadam21_ has joined #ruby
jas02 has joined #ruby
Ox0dea has quit [Ping timeout: 245 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
SOLDIERz has joined #ruby
aadam21_ has quit [Remote host closed the connection]
aadam21 has joined #ruby
rkazak has joined #ruby
weemsledeux has joined #ruby
Asher has quit [Ping timeout: 246 seconds]
niftylettuce has quit [Quit: Connection closed for inactivity]
yfeldblum has quit [Read error: Connection reset by peer]
yfeldblum has joined #ruby
moei has joined #ruby
howdoi has joined #ruby
ByronJoh1son has quit [Remote host closed the connection]
hahuang61 has joined #ruby
ByronJoh1son has joined #ruby
ibouvousaime has joined #ruby
claw has quit [Read error: Connection reset by peer]
choke has joined #ruby
nofxx has quit [Ping timeout: 272 seconds]
kies has joined #ruby
peeja has joined #ruby
lxsameer has quit [Ping timeout: 245 seconds]
smactive has quit [Remote host closed the connection]
startupality has joined #ruby
ta has joined #ruby
lxsameer has joined #ruby
ascarter has joined #ruby
peeja has quit [Ping timeout: 260 seconds]
claw has joined #ruby
viperman has joined #ruby
pawnbox has quit [Remote host closed the connection]
rkazak has quit [Quit: Sleep.....ing....]
pawnbox has joined #ruby
aadam21 has quit [Remote host closed the connection]
govg has quit [Ping timeout: 276 seconds]
ta has quit [Ping timeout: 255 seconds]
domgetter has joined #ruby
aadam21__ has quit [Ping timeout: 256 seconds]
dextertzu has quit [Read error: Connection reset by peer]
symm- has joined #ruby
krzkrz has joined #ruby
bkxd has joined #ruby
bMalum has joined #ruby
rkazak has joined #ruby
govg has joined #ruby
bkxd has quit [Ping timeout: 240 seconds]
Asher has joined #ruby
Dimik has joined #ruby
pdoherty has quit [Ping timeout: 255 seconds]
mdw has joined #ruby
firstdayonthejob has joined #ruby
bubbys has joined #ruby
mdw has quit [Client Quit]
choke has quit [Read error: Connection reset by peer]
ibouvousaime has quit [Ping timeout: 265 seconds]
rippa has joined #ruby
blub` has joined #ruby
skade has joined #ruby
dlitvak has joined #ruby
mdw has joined #ruby
n00bdev has quit []
blub has quit [Ping timeout: 260 seconds]
gagrio has joined #ruby
dlitvak has quit [Ping timeout: 250 seconds]
kies has quit [Ping timeout: 264 seconds]
sandstrom has joined #ruby
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
juddey has quit [Ping timeout: 256 seconds]
jobewan has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
roshanavand has joined #ruby
LMity has joined #ruby
ur5us has joined #ruby
roshanavand has quit [Remote host closed the connection]
roshanavand has joined #ruby
aufi has joined #ruby
niotoan has quit [Ping timeout: 240 seconds]
allenn has joined #ruby
allenn has joined #ruby
roshanavand has quit [Remote host closed the connection]
juddey has joined #ruby
mary5030 has joined #ruby
allenn has quit [Remote host closed the connection]
lxsameer has quit [Read error: Connection timed out]
codecop has joined #ruby
lxsameer has joined #ruby
rns has quit [Ping timeout: 264 seconds]
roshanavand has joined #ruby
ta has joined #ruby
Puffball_ has quit [Read error: Connection reset by peer]
Puffball has joined #ruby
roshanavand has quit [Remote host closed the connection]
roshanavand has joined #ruby
pawnbox has quit [Remote host closed the connection]
Coral has joined #ruby
mary5030 has quit [Ping timeout: 240 seconds]
pawnbox has joined #ruby
roshanavand has quit [Remote host closed the connection]
roshanavand has joined #ruby
Luke-Du has joined #ruby
juddey has quit [Ping timeout: 260 seconds]
nunchuck has quit [Ping timeout: 255 seconds]
arup_r has quit []
saneax_AFK is now known as saneax
gigetoo has quit [Ping timeout: 276 seconds]
saneax is now known as Guest98346
sandstrom has quit [Quit: My computer has gone to sleep.]
kies has joined #ruby
roshanavand has quit [Ping timeout: 265 seconds]
gigetoo has joined #ruby
dn` has joined #ruby
justinmcp_ has quit [Read error: Connection reset by peer]
justinmcp has joined #ruby
cornerman has quit [Read error: Connection reset by peer]
cornerman has joined #ruby
choke has joined #ruby
glenny has joined #ruby
dlitvak has joined #ruby
joonty has joined #ruby
startupality has quit [Ping timeout: 255 seconds]
mark2 has joined #ruby
symm- has quit [Ping timeout: 260 seconds]
justinmcp has quit [Remote host closed the connection]
justinmcp has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
dlitvak has quit [Ping timeout: 260 seconds]
joonty has quit [Ping timeout: 255 seconds]
aadam21 has joined #ruby
DoubleMalt has joined #ruby
<adaedra> Hi
TomyWork has joined #ruby
<agent_white> iH
SCHAAP137 has joined #ruby
<Luke-Du> Hello
choke_ has joined #ruby
choke has quit [Read error: Connection reset by peer]
yes`r has quit [Ping timeout: 240 seconds]
CloCkWeRX has joined #ruby
bkxd has joined #ruby
startupality has joined #ruby
pawnbox_ has joined #ruby
pawnbox has quit [Read error: Connection reset by peer]
dwfait has joined #ruby
<shevy> yo Luke Duke
choke_ has quit [Read error: Connection reset by peer]
choke has joined #ruby
bkxd has quit [Ping timeout: 265 seconds]
startupality has quit [Client Quit]
brunto has joined #ruby
kies^ has joined #ruby
choke has quit [Read error: Connection reset by peer]
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sandstrom has joined #ruby
<agent_white> I am moving today/tomorrow :)
<agent_white> No more anomalies/intermittent disconnects in internet usage.
firstdayonthejob has quit [Ping timeout: 272 seconds]
rkazak has quit [Excess Flood]
steffkes has joined #ruby
<shevy> moving to?
steffkes has quit [Changing host]
steffkes has joined #ruby
<shevy> JAPAN?
<agent_white> The city :) I've been watching cows for 2 years. Back to watching humans!
anisha has joined #ruby
<agent_white> I wish :(
sigurding has quit [Quit: sigurding]
Porfa has quit [Quit: Porfa]
Mia has joined #ruby
Mia has quit [Changing host]
Mia has joined #ruby
yes`r has joined #ruby
charliesome has joined #ruby
LMity has quit [Quit: Nettalk6 - www.ntalk.de]
azgil has joined #ruby
solars has joined #ruby
charliesome has quit [Client Quit]
icarus has quit [Read error: Connection reset by peer]
mistermocha has joined #ruby
icarus has joined #ruby
DoubleMalt has quit [Remote host closed the connection]
patchedmonkey has joined #ruby
blackmesa has joined #ruby
Hounddog has joined #ruby
RegulationD has joined #ruby
mistermocha has quit [Ping timeout: 245 seconds]
startupality has joined #ruby
baweaver has joined #ruby
astrobun_ has quit [Remote host closed the connection]
aadam21 has quit [Ping timeout: 240 seconds]
Dimik has quit [Ping timeout: 276 seconds]
RegulationD has quit [Ping timeout: 246 seconds]
<shevy> haha
<shevy> cows
lacuna has quit [Remote host closed the connection]
agent_wh1te has joined #ruby
agent_white has quit [Disconnected by services]
agent_wh1te is now known as agent_white
astrobun_ has joined #ruby
baweaver has quit [Ping timeout: 260 seconds]
thoma has joined #ruby
thoma has left #ruby [#ruby]
elaptics`away is now known as elaptics
TheHodge has joined #ruby
Marsupermammal has joined #ruby
glenny has quit [Ping timeout: 245 seconds]
blackmesa has quit [Ping timeout: 246 seconds]
_joes_ has joined #ruby
einarj has joined #ruby
ibouvousaime has joined #ruby
karapetyan has joined #ruby
lkba_ has joined #ruby
kies^ has quit [Ping timeout: 250 seconds]
patchedmonkey has quit [Quit: Textual IRC Client: www.textualapp.com]
karapetyan has quit [Ping timeout: 260 seconds]
lkba has quit [Ping timeout: 255 seconds]
_joes___ has joined #ruby
_joes_ has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
haraigoshi has joined #ruby
haraigo has quit [Ping timeout: 250 seconds]
joonty has joined #ruby
einarj has quit []
timonv has quit [Quit: WeeChat 1.3]
timonv has joined #ruby
einarj has joined #ruby
bigkevmcd has quit [Ping timeout: 260 seconds]
bigkevmcd has joined #ruby
timonv has quit [Client Quit]
kp666 has quit [Quit: Leaving]
roshanavand has joined #ruby
timonv has joined #ruby
timonv has quit [Client Quit]
cmolenda has joined #ruby
kam270 has joined #ruby
kam270 has quit [Max SendQ exceeded]
timonv has joined #ruby
bigkevmcd has quit [Ping timeout: 272 seconds]
timonv has quit [Client Quit]
roshanavand has quit [Ping timeout: 240 seconds]
charliesome has joined #ruby
zz_denym_ is now known as denym_
SHyx0rmZ has quit [Remote host closed the connection]
Luke-Du has quit [Ping timeout: 256 seconds]
timonv has joined #ruby
rdark has joined #ruby
rdark has quit [Client Quit]
rdark has joined #ruby
Snowy has joined #ruby
SHyx0rmZ has joined #ruby
timonv has quit [Client Quit]
kies has quit [Ping timeout: 260 seconds]
pandaant has joined #ruby
BaNzounet has quit [Quit: leaving]
marr has joined #ruby
startupality has quit [Quit: startupality]
karapetyan has joined #ruby
icarus has quit [Read error: Connection reset by peer]
icarus has joined #ruby
bubbys has quit [Ping timeout: 250 seconds]
roshanavand has joined #ruby
n00bdev has joined #ruby
choke has joined #ruby
ibouvousaime has quit [Ping timeout: 265 seconds]
DEA7TH has joined #ruby
ur5us has quit [Remote host closed the connection]
n00bdev has quit [Client Quit]
roshanavand has quit [Ping timeout: 240 seconds]
lkba_ has quit [Ping timeout: 272 seconds]
solars has quit [Ping timeout: 250 seconds]
Jackneill has joined #ruby
tvw has joined #ruby
jam_ has quit [Remote host closed the connection]
niemcu has joined #ruby
DoubleMalt has joined #ruby
aadam21 has joined #ruby
baweaver has joined #ruby
duncannz has quit [Read error: Connection reset by peer]
lkba has joined #ruby
yes`r has quit [Ping timeout: 245 seconds]
rodfersou has joined #ruby
icarus has quit [Read error: Connection reset by peer]
icarus has joined #ruby
bubbys has joined #ruby
Coldblackice has joined #ruby
baweaver has quit [Ping timeout: 255 seconds]
blackmesa has joined #ruby
yes`r has joined #ruby
roshanavand has joined #ruby
jaxxstorm has quit [Quit: Textual IRC Client: www.textualapp.com]
blackgoat has joined #ruby
lipoqil has joined #ruby
SenpaiSilver has quit [Read error: Connection reset by peer]
roshanavand has quit [Ping timeout: 260 seconds]
SenpaiSilver has joined #ruby
shevy has quit [Ping timeout: 244 seconds]
MyMind has joined #ruby
sigurding has joined #ruby
timonv has joined #ruby
xet7 has quit [Quit: Leaving]
jam_ has joined #ruby
Sembei has quit [Ping timeout: 265 seconds]
timonv has quit [Client Quit]
timonv has joined #ruby
timonv has quit [Client Quit]
greenride has quit [Quit: Leaving.]
timonv has joined #ruby
timonv has quit [Client Quit]
DoubleMalt has quit [Remote host closed the connection]
DoubleMalt has joined #ruby
jam_ has quit [Ping timeout: 265 seconds]
choke has quit [Ping timeout: 245 seconds]
huyderman has joined #ruby
arup_r has joined #ruby
rdark has quit [Ping timeout: 240 seconds]
aadam21 has quit [Ping timeout: 265 seconds]
xet7 has joined #ruby
roshanavand has joined #ruby
skcin7 has quit [Quit: Textual IRC Client: www.textualapp.com]
Jet4Fire has joined #ruby
scripore has joined #ruby
cmolenda has quit [Remote host closed the connection]
Xeago has joined #ruby
bkxd has joined #ruby
roshanavand has quit [Ping timeout: 240 seconds]
timonv has joined #ruby
timonv has quit [Client Quit]
timonv has joined #ruby
nerfando has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
bkxd has quit [Ping timeout: 246 seconds]
voodo has joined #ruby
sgambino has joined #ruby
timonv has quit [Client Quit]
timonv has joined #ruby
nerfando has joined #ruby
platzhirsch has joined #ruby
haraigoshi has quit [Ping timeout: 245 seconds]
startupality has joined #ruby
roshanavand has joined #ruby
rdark has joined #ruby
cmolenda has joined #ruby
scripore has quit [Quit: This computer has gone to sleep]
acalewin has joined #ruby
SenpaiSilver has quit [Quit: Leaving]
marr has quit [Ping timeout: 250 seconds]
DEA7TH has quit [Quit: DEA7TH]
dorei has joined #ruby
Nahra``` has quit [Changing host]
Nahra``` has joined #ruby
j2k has quit [Quit: bai]
DonOtreply has quit [Quit: DonOtreply]
SenpaiSilver has joined #ruby
DoubleMalt has quit [Ping timeout: 255 seconds]
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
j2k has joined #ruby
roshanavand has quit [Remote host closed the connection]
DoubleMalt has joined #ruby
j2k has quit [Client Quit]
Xeago has quit [Remote host closed the connection]
astrobun_ has quit [Remote host closed the connection]
rrichardsr3 has joined #ruby
Xeago has joined #ruby
j2k has joined #ruby
roshanav_ has joined #ruby
rns has joined #ruby
voodo has quit [Quit: Linkinus - http://linkinus.com]
minimalism has quit [Quit: minimalism]
yashinbasement has joined #ruby
<silverdust> Using the String#slice how can I select from an index to the end of the string without specifying a number of characters
<silverdust> Like I thought for f = "crisp", f[1..] will give "risp"
<silverdust> but that's invalid
joonty has quit [Read error: Connection reset by peer]
<yorickpeterse> >> "hello world"[2..-1]
<ruboto> yorickpeterse # => "llo world" (https://eval.in/498032)
<yorickpeterse> silverdust: ^
karapetyan has quit [Remote host closed the connection]
<silverdust> thanks
karapetyan has joined #ruby
joonty has joined #ruby
chussenot has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
poguez_ has quit [Quit: Connection closed for inactivity]
bkxd has joined #ruby
FooMunki has joined #ruby
arup_r has quit [Remote host closed the connection]
devbug has quit [Read error: Connection reset by peer]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ascarter has joined #ruby
Xeago has quit [Remote host closed the connection]
rrichardsr3 has quit [Quit: Apparantly my attempt to stay awake has failed...]
cmolenda_ has joined #ruby
roshanavand has joined #ruby
roshanav_ has quit [Read error: Connection reset by peer]
arup_r has joined #ruby
* pontiki waves o/
cmolenda has quit [Ping timeout: 245 seconds]
Xeago has joined #ruby
aadam21 has joined #ruby
roshanavand has quit [Read error: Connection reset by peer]
roshanavand has joined #ruby
phredus has quit [Remote host closed the connection]
DEA7TH has joined #ruby
DEA7TH has quit [Client Quit]
Xeago has quit [Remote host closed the connection]
sandstrom has quit [Quit: My computer has gone to sleep.]
danielpclark has quit [Quit: Leaving]
karapetyan has quit [Remote host closed the connection]
rns has quit [Ping timeout: 265 seconds]
karapetyan has joined #ruby
dangerousdave has joined #ruby
blackmesa has quit [Ping timeout: 256 seconds]
karapetyan has quit [Remote host closed the connection]
anisha_ has joined #ruby
platzhirsch has left #ruby [#ruby]
roobee has joined #ruby
Xeago has joined #ruby
dlitvak has joined #ruby
cmolenda has joined #ruby
<roobee> Hello guys, this is a relatvely simple question, can anyone help me please? Here's the code (with explanation with what I get and what I want to get) thanks!
roshanav_ has joined #ruby
Feyn has quit [Quit: Leaving]
roshanavand has quit [Ping timeout: 240 seconds]
<roobee> anyone? :)
cmolenda_ has quit [Ping timeout: 260 seconds]
<canton7> you might have to wait longer than 3 minutes ;)
sankaber has joined #ruby
dlitvak has quit [Remote host closed the connection]
Marsupermammal has quit [Quit: Textual IRC Client: www.textualapp.com]
dlitvak has joined #ruby
<roobee> >canton7 I understand, not in a hurry anyway :)
dlitvak has quit [Remote host closed the connection]
krzkrz has quit [Read error: Connection reset by peer]
<apeiros> roobee: you iterate over the whole text for each redacted word
<apeiros> roobee: you should have the text_words as the outer loop. and as the inner loop, you test whether you want to print the word, or redacted (which you'll have to do a bit differently from how you try now)
anisha_ has quit [Quit: Leaving]
FernandoBasso has joined #ruby
justinmcp has quit [Quit: justinmcp]
yfeldblum has quit [Ping timeout: 260 seconds]
ledestin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
brunto has quit [Ping timeout: 265 seconds]
<roobee> apeiros I don't know what an outer/inner loop is. Is that just the order they appear?
_joes___ has quit []
_joes___ has joined #ruby
cmolenda_ has joined #ruby
<niemcu> roobee: yes, basically.
cmolenda has quit [Read error: Connection reset by peer]
<roobee> ok. thanks
aadam21 has quit [Ping timeout: 256 seconds]
krzkrz has joined #ruby
baweaver has joined #ruby
_joes___ has quit [Client Quit]
<apeiros> roobee: outer.each do |x| inner.each do |y| …
_joes_ has joined #ruby
<apeiros> if you'd properly indent, you'd see it visually too (yes, that's a hint with a sledge-hammer, take it :-p)
m8 has joined #ruby
<niemcu> yes, and I'd call that pretty important point.
c355e3b has joined #ruby
<roobee> what identation rules did I break? I'm basically a 2-hour experience beginner, been writing on the codeacademy console
BSaboia has joined #ruby
<niemcu> anytime you open new block of code, you should indent.
ibouvousaime has joined #ruby
baweaver has quit [Ping timeout: 255 seconds]
<niemcu> it helps understand what parts are responsible for specific things, and makes code a lot more readable
blub` is now known as blub
<niemcu> hint: you don't want this two ends in one column ;)
xet7 has quit [Quit: Leaving]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<roobee> well now I have 3 in one column, time to go fix that xD
ascarter has joined #ruby
<niemcu> definitely!
Xeago has quit [Remote host closed the connection]
<roobee> oooh now I see the outer loops! thanks guys
<roobee> yes, it got 10 times easier
DEA7TH has joined #ruby
cmolenda_ has quit [Remote host closed the connection]
phredus has joined #ruby
roshanav_ has quit [Remote host closed the connection]
xet7 has joined #ruby
pawnbox_ has quit [Remote host closed the connection]
<roobee> I was thinking of assigning a variable to each array element but, before even knowing how to do that, I have no way of knowing how many elements the array will have. so that's not it :/
dlitvak has joined #ruby
<bob_f> Is there an equivalent short-hand to `a.map(:&method)` for hash access, i.e. a.map { |x| x["key"] } ?
astrobun_ has joined #ruby
sigurding has quit [Quit: sigurding]
bigkevmcd has joined #ruby
mdw has quit [Quit: Sleeping Zzzzz]
jam___ has joined #ruby
Phage has left #ruby ["Textual IRC Client: www.textualapp.com"]
astrobun_ has quit [Ping timeout: 276 seconds]
lipoqil has quit [Quit: Connection closed for inactivity]
Kiedisticelixer has joined #ruby
jam___ has quit [Ping timeout: 250 seconds]
roshanavand has joined #ruby
roobee has quit [Ping timeout: 252 seconds]
RegulationD has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
Guest82 has joined #ruby
<Guest82> Hello
<Guest82> I am doing Ruby exercise
<Guest82> What this question means?
<Guest82> There is array of colours. $colours = (“black”, “orange”, “yellow”, “white”, “green”). Write
<Guest82> the output “The grass is green”.
nixmaniack has joined #ruby
nixmaniack has quit [Changing host]
nixmaniack has joined #ruby
ruby-lang801 has joined #ruby
<ruby-lang801> Hello
<ruby-lang801> I am doing Ruby exercise
<ruby-lang801> What does this question means?
<pontiki> sounds like everyone is
<ruby-lang801> There is array of colours. $colours = (“black”, “orange”, “yellow”, “white”, “green”). Write the output “The grass is green”.
dlitvak has joined #ruby
<toretore> ruby-lang801, link to excercise
<Guest82> its in PDF
<Guest82> no link
<pontiki> that's not ruby syntax, either of you
RegulationD has quit [Ping timeout: 260 seconds]
<toretore> >> puts "The grass is green"
<ruboto> toretore # => The grass is green ...check link for more (https://eval.in/498048)
colegatron has quit [Ping timeout: 256 seconds]
<Guest82> the questions are not must be in syntax
blackmesa has joined #ruby
pawnbox has joined #ruby
<Guest82> i dont get it ruboto
<pontiki> Guest82: have you read anything about ruby?
<Guest82> the question is write the output? first it gives array of colors
<Guest82> actually what the question wants?
ruby-lang801 has quit [Ping timeout: 252 seconds]
<toretore> Guest82, we can't help without more information
<Guest82> ok i will give link
krzkrz has quit [Read error: Connection reset by peer]
prestorium has joined #ruby
<niemcu> it wants you to write "The grass is <the fifth element of array>"
krzkrz has joined #ruby
<Guest82> ok niemcu, so the answer is like what ruboto gave?
<Guest82> toretore, this is the link
<Guest82> qestion number 3
<toretore> why ar eyou doing this excercise?
<niemcu> no
<niemcu> do you know what an array is?
sigurding has joined #ruby
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
karapetyan has joined #ruby
nofxx has joined #ruby
nofxx has quit [Changing host]
nofxx has joined #ruby
Guest82 has quit [Ping timeout: 260 seconds]
dlitvak has quit [Read error: Connection reset by peer]
<gregf_> >> require "prime";p [*1..100].inject(0){ |s, v| Prime.prime?(v) ? s+v : s }
<ruboto> gregf_ # => 1060 ...check link for more (https://eval.in/498054)
joonty has quit [Ping timeout: 250 seconds]
icarus has quit [Read error: Connection reset by peer]
<Kiedisticelixer> Q: In my game Im drawing five layers: 1 and 2 is map, 3 is player and 4 is map but above player. But I want my fog to be below the player but above the highest map layer, any ideas?
icarus has joined #ruby
<Kiedisticelixer> Im adjusting all with Z
<bob_f> toretore: Had to step out for a sec, thanks for the answer.
<domgetter> Kiedisticelixer: maintain an array of layers, and draw them in order every time
karapetyan has quit [Ping timeout: 260 seconds]
dlitvak has joined #ruby
<Kiedisticelixer> Aw, thats slightly beyond my expertise, but I will try, thank you
<domgetter> Kiedisticelixer: what library are you using to make a game? Or are you doing it from scratch in Ruby?
karapetyan has joined #ruby
bluOxigen has joined #ruby
colegatron has joined #ruby
<Kiedisticelixer> Using RGSS
zotherstupidguy has quit [Quit: WeeChat 1.3]
<niemcu> interesting, never heard of that one
bluOxigen has quit [Ping timeout: 240 seconds]
startupality has quit [Quit: startupality]
kalopsian has joined #ruby
bluOxigen has joined #ruby
Snowy has quit [Remote host closed the connection]
brunto has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
mistermocha has joined #ruby
<Kiedisticelixer> Ruby Game Scripting System,if you have heard of that
bluOxigen has left #ruby [#ruby]
leksster has joined #ruby
aadam21 has joined #ruby
lidenbrock has joined #ruby
blackmesa has quit [Ping timeout: 276 seconds]
peeja has joined #ruby
dlitvak has joined #ruby
Mon_Ouie has joined #ruby
bithon has quit [Ping timeout: 245 seconds]
steerio has joined #ruby
<steerio> hi, does anyone know where to find HTTP::Response::STATUS_CODES, which gem?
<steerio> it seems like reel somehow forgets to depend on it
<SCHAAP137> nokogiri maybe?
ibouvousaime has quit [Ping timeout: 256 seconds]
DEA7TH has quit [Ping timeout: 246 seconds]
<steerio> nope, nokogiri is in my gemfile.lock
<steerio> and requiring it explicitly doesn't seem to define HTTP either
nixmaniack has quit [Remote host closed the connection]
nixmaniack has joined #ruby
mistermocha has quit [Ping timeout: 276 seconds]
<steerio> weirdly enough, google is no help either
DEA7TH has joined #ruby
yes`r has quit [Ping timeout: 265 seconds]
lidenbrock has quit [Ping timeout: 252 seconds]
<niemcu> Rack::Utils module?
peeja has quit [Ping timeout: 250 seconds]
<bob_f> steerio: Tried grepping your gems directory for "STATUS_CODES" ?
<jhass> how about the http gem?
<jhass> let's ask omniref I guess
<steerio> jhass: yeah that's what I got
sgambino has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<steerio> so yeah, HTTP::Response exists, but HTTP::Response::STATUS_CODES (looked for by Reel) doesn't
<jhass> version conflict?
<steerio> apparently reel never bothered to update its deps, it depends on >=0.6, but we're now at http 1.0.1
sankaber has joined #ruby
<steerio> the proper dep would be <1
<steerio> i'll file a bug report there
<bob_f> Man I hate deps like that.
<steerio> latest commit May 2015, oh boy.
ibouvousaime has joined #ruby
dlitvak has quit [Remote host closed the connection]
dlitvak has joined #ruby
<steerio> time to fork :D
<adaedra> good idea, i'll spoon then.
sankaber has quit [Client Quit]
tvw has quit [Remote host closed the connection]
spooq|2 has joined #ruby
bithon has joined #ruby
peeja has joined #ruby
bkxd_ has joined #ruby
ibouvousaime has quit [Ping timeout: 265 seconds]
bkxd has quit [Ping timeout: 256 seconds]
ibouvousaime has joined #ruby
dlitvak has quit [Ping timeout: 264 seconds]
niemcu has quit [Ping timeout: 260 seconds]
dlitvak has joined #ruby
spooq has quit [Ping timeout: 255 seconds]
x-user has joined #ruby
Snowy has joined #ruby
bkxd_ has quit [Ping timeout: 255 seconds]
kalopsian has quit [Ping timeout: 240 seconds]
CloCkWeRX has quit [Quit: Leaving.]
atmosx has joined #ruby
Snowy has quit [Ping timeout: 240 seconds]
ibouvousaime has quit [Ping timeout: 260 seconds]
yes`r has joined #ruby
yashinbasement has quit [Ping timeout: 260 seconds]
gregf has quit [Ping timeout: 240 seconds]
cmolenda has joined #ruby
phredus has quit [Remote host closed the connection]
webus has joined #ruby
RubieNewbie has joined #ruby
<RubieNewbie> Replace this sentence into ifelse statements. “I work from Mondays to Fridays if there is
<RubieNewbie> no public holidays”.
<RubieNewbie> hello
<ljarvis> wat
<RubieNewbie> Replace this sentence into ifelse statements. “I work from Mondays to Fridays if there is
<RubieNewbie> no public holidays”.
<ljarvis> RubieNewbie: you've written that once already, please provide some context or give us the code you're trying
<ljarvis> since you are of course trying to write this yourself before asking for help
<RubieNewbie> ok wait
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<apeiros> that sounds like homework?
<ljarvis> yeah assuming that too, lets see how the follow up looks
<apeiros> sure. the target is to get them to figure out how to do it themselves either way :)
spooq|2 has quit [Read error: Connection timed out]
<ljarvis> aye :)
dlitvak_ has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
Jardayn has joined #ruby
ibouvousaime has joined #ruby
mduca_ has quit [Ping timeout: 260 seconds]
ixti has joined #ruby
ixti has quit [Client Quit]
rns has joined #ruby
solars has joined #ruby
shevy has joined #ruby
<RubieNewbie> if Monday to Friday != Public Holiday
<RubieNewbie> puts "I work"
<RubieNewbie> end
<RubieNewbie> is that correct?
<ljarvis> does it work?
aadam21 has quit [Ping timeout: 256 seconds]
<ljarvis> I don't actually understand the question, since it doesn't make any sense. You want to see if a specific week includes a public holiday, or?
<apeiros> RubieNewbie: is the result supposed to be ruby code or pseudo code?
arup_r has quit [Remote host closed the connection]
<RubieNewbie> apeiros, the question is just that
<RubieNewbie> Replace this sentence into ifelse statements. “I work from Mondays to Fridays if there is
<RubieNewbie> no public holidays”.
<RubieNewbie> it can be in ruby code (preferrable) or pseudo code
<apeiros> and from where do you have that question then?
<RubieNewbie> its homework
<ljarvis> that's a ridiculous questions
peeja has quit [Ping timeout: 260 seconds]
<RubieNewbie> so my answer is wrong?
<ljarvis> RubieNewbie: read your answer out loud
<apeiros> I'd agree that the question is badly phrased. but trying to go with its spirit, I'd say your answer is wrong RubieNewbie
<Bish> hey, can rvm somehow set some ruby version default globally?
<ljarvis> "if monday to friday is not a public holiday" does that make any sense?
<Bish> i f* hate debian/ubuntu
<ljarvis> Bish: #rvm
<shevy> Bish :D
<Bish> ljarvis: okay
<apeiros> Bish: define "globally". for your user, yes: rvm use X --default
gregf has joined #ruby
<RubieNewbie> another question i dont understand
<RubieNewbie> There is array of colours. $colours = (“black”, “orange”, “yellow”, “white”, “green”). Write
<RubieNewbie> the output “The grass is green”.
<Bish> globally for one user? what is locally then? dafuq?
<ljarvis> we didn't get past the last question yet
<ljarvis> one question at a time
<ljarvis> the colours one actually makes sense
<ljarvis> but, that isn't Ruby, so..
<apeiros> "ruby preferably" but the example is non-ruby?
<apeiros> I'm inclined to say you're in the wrong channel and actually probably should better ask your classmates.
<ljarvis> I concur
<apeiros> (not my opinion as an op, i.e. I won't moderate this)
<ljarvis> not yet, anyway :)
<RubieNewbie> sigh...
rgtk has joined #ruby
rgtk has quit [Client Quit]
rgtk has joined #ruby
Kiedisticelixer has quit [Ping timeout: 252 seconds]
bkxd has joined #ruby
roshanav_ has joined #ruby
roshanavand has quit [Read error: Connection reset by peer]
timonv1 has joined #ruby
sandstrom has joined #ruby
timonv1 has quit [Client Quit]
karapetyan has quit [Remote host closed the connection]
timonv has quit [Quit: WeeChat 1.3]
rdavila has joined #ruby
choke has joined #ruby
timonv has joined #ruby
timonv has quit [Client Quit]
build22 has joined #ruby
build22 has left #ruby [#ruby]
arup_r has joined #ruby
bkxd has quit [Ping timeout: 256 seconds]
bigkevmcd has quit [Quit: Outta here...]
anisha_ has joined #ruby
timonv has joined #ruby
platzhirsch has joined #ruby
blackmesa has joined #ruby
tvw has joined #ruby
x-user has quit [Quit: x-user]
FernandoBasso has quit [Quit: Leaving]
dangerousdave has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tjad has quit [Remote host closed the connection]
dlitvak_ has quit [Read error: Connection reset by peer]
dlitvak has joined #ruby
x-user has joined #ruby
blackgoat has quit [Quit: WeeChat 1.3]
x-user has quit [Max SendQ exceeded]
choke has quit [Read error: Connection reset by peer]
x-user has joined #ruby
thevishy has joined #ruby
<thevishy> anyone using fluentd here?
x-user has quit [Read error: Connection reset by peer]
lxsameer has quit [Quit: Leaving]
choke has joined #ruby
pdoherty has joined #ruby
blackmesa has quit [Ping timeout: 245 seconds]
baweaver has joined #ruby
DoubleMalt has quit [Remote host closed the connection]
yes`r has quit [Quit: WeeChat 1.3]
GarethAdams has joined #ruby
dstarh has joined #ruby
aryaching has joined #ruby
baweaver has quit [Ping timeout: 255 seconds]
phredus has joined #ruby
scripore has joined #ruby
<ljarvis> ?anyone
<ruboto> Just ask your question, if anyone has or can, they will respond.
rodfersou is now known as rodfersou|lunch
ta has quit [Read error: Connection reset by peer]
ta has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
user083 has joined #ruby
kies has joined #ruby
atomical has joined #ruby
choke has quit [Ping timeout: 265 seconds]
dlitvak has joined #ruby
roshanav_ has quit [Remote host closed the connection]
sdothum has joined #ruby
Snowy has joined #ruby
jam___ has joined #ruby
Xeago has joined #ruby
<apeiros> I think anyone uses inarticulated. But someone uses fluentd. ask someone.
Snowy has quit [Ping timeout: 250 seconds]
yoshyn has joined #ruby
ta0 has joined #ruby
jam___ has quit [Ping timeout: 265 seconds]
GarethAdams has quit [Quit: Linkinus - http://linkinus.com]
Melpaws1 has quit [Quit: Leaving.]
ellistaa has joined #ruby
ibouvousaime_ has joined #ruby
roshanavand has joined #ruby
ibouvousaime has quit [Ping timeout: 256 seconds]
futilegames has joined #ruby
Snowy has joined #ruby
<shevy> ?someone
<ruboto> I don't know anything about someone
<shevy> ?somebody
<ruboto> I don't know anything about somebody
roshanav_ has joined #ruby
<shevy> hmmm weird
futilegames has quit [Client Quit]
<shevy> who was jhass again?
<steerio> I am someone and I think anyone is just an innocent way of addressing a pool of people.
<ljarvis> ?jhass
<ruboto> jhass is anybody. They're a member of the op staff in #ruby, contributor to ruboto and ruby-community.com
aadam21 has joined #ruby
Guest98346 is now known as saneax_AFK
<shevy> oh right
<ljarvis> ?ljarvis
<ruboto> I know everything about ljarvis
<shevy> lol
roshanavand has quit [Read error: Connection reset by peer]
yoshyn has left #ruby ["Leaving..."]
roshanav_ has quit [Remote host closed the connection]
RegulationD has joined #ruby
<steerio> this could be extended, like, if someone's talking to themselves, it could be eigenone
<steerio> or to a group of people, that's multione. no, that's any-n.
<ljarvis> >> RUBY_VERSION
<ruboto> ljarvis # => "2.2.0" (https://eval.in/498134)
<ljarvis> apeiros: how longggg
<thevishy> I am just thinking if fluentd only accepts JSON
aegis3121 has joined #ruby
ziyadb has joined #ruby
<thevishy> someone is an expert, anyone can be an expert!
RubieNewbie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
FooMunki has quit [Quit: FooMunki]
RubieNewbie has joined #ruby
FooMunki has joined #ruby
RegulationD has quit [Ping timeout: 255 seconds]
<Bish> why the f is it so hard to get a ruby2+ working on ubuntu, what did they smoke?! ( not a real question, just mad ).
mic_e has joined #ruby
<blub> lol
<ljarvis> its not hard
RubieNewbie has quit [Client Quit]
slackbotgz has joined #ruby
<ljarvis> install chruby, ruby-install, build ruby 2, point chruby at it
DoubleMalt has joined #ruby
<Bish> how is it not hard!? standard is 1.9, if you install 2.0 GREAT the binaries just lay there
<Bish> oh great whe have "update alternatives" which never works
<ljarvis> huh?
TomPeed has joined #ruby
<ljarvis> why even use aptitude?
<ljarvis> build it yourself if the package manager doesn't work
<ljarvis> this is difficult if you make it difficult
<Bish> because what else is there? i never liked ubuntu, but every mf uses it on his servers for some reason
<Bish> well, i feel like, it could get worse if i install stuff around the package manager
<Bish> it makes it untidy and unreliable
RubieNewbie has joined #ruby
kgirthofer has joined #ruby
<Lloyd> eh?
<ljarvis> I disagree
RubieNewbie has quit [Client Quit]
<Bish> well i have no clue what other sh* ubuntu does, maybe it walks over the files it does who knows what with it
<ljarvis> many package managers aren't great. The Ruby code is provided to you by the Ruby authors. Just build it yourself
<Bish> how can you be sure, if you install ruby with make install, it won't get overwritten by some update
<ljarvis> Bish: stop with this language please, even if it's not explicit, it's not welcome here
smactive has joined #ruby
<Lloyd> just make your own package and install it through apt
<Lloyd> then you don’t need to worry
<ljarvis> Bish: you get to decide those things as you're building it, though
<Bish> yeah learn how to build packages for the package manager i hate
<ljarvis> i.e install it into ~/ruby if you want
<Bish> im pretty sure i would lose my mind if i did that
phreakocious has quit [Quit: gotta go]
<Bish> ljarvis: i did this with rvm, but now i want to use it with sudo, and hell breaks loose
<ljarvis> yeah I wouldn't recommend using apt if you don't like it, so I recommend building yourself or using a third party tool which is built to save you from these kind of scenarios
<ljarvis> why the heck would you use it with sudo?
<ljarvis> also, I strongly discourage use of rvm
<Bish> yeah i will never use it again, its crap
<Bish> sorry for language
<Bish> didn't think
<atmosx> ljarvis: rvm discourages sudo too heh
<ljarvis> so, to reiterate; install chruby
chipotle has joined #ruby
<Lloyd> I view rvm as a development tool, not for use in production
<Bish> aehh thing is, i wanted ruby to handle bounces from postfix
<ljarvis> atmosx: yeah that's not a problem I have with it :)
<Bish> which worked juuuuust fine, on a decent distribution
<atmosx> ljarvis: I'm quite with rvm but I don't wanna change the topic of the conversation :-P
duckpuppy has joined #ruby
<Bish> (postfix usually usese "nobody" to execute the script.. which worked fine on my machine because ruby management is much better,)
Xeago has quit [Remote host closed the connection]
<ljarvis> what machine is that?
<Bish> gentoo
<ljarvis> ah, gentoo <3
malconis has joined #ruby
<Bish> idd.
<atmosx> gentoo++
<atmosx> hehe
smactive has quit [Ping timeout: 240 seconds]
<atmosx> I wonder if anyone is using gentoo in production servers
<ljarvis> I did a 14 hour stage-1 install back when I was young enough to not have to work for a living
<Bish> i did/done htat
<ljarvis> anyway we're going offtopic a bit now :)
bkxd has joined #ruby
<thevishy> Can anyone who uses fluentd in here - please tell me if I could load normal logs? Or do I need to JSONify it?
<Bish> atmosx: but after a while.. i got sick of the installation routine :D, but ljarvis is right, kinda offtopic, but they have been the best servers there are i loved them like my childs
<Bish> .oO(i don't have children)
gusTester has joined #ruby
<atmosx> ljarvis: I used gentoo as my desktop OS for like 5 years
krobzaur has joined #ruby
freerobby has joined #ruby
<atmosx> Bish: I can imagine heh
ellistaa has quit [Quit: ellistaa]
<ljarvis> yeah me too, maybe longer
<atmosx> ljarvis: and what OS you using now as desktop?
bkxd has quit [Ping timeout: 240 seconds]
bMalum has quit [Ping timeout: 276 seconds]
nixmaniack has quit [Remote host closed the connection]
<Bish> http://stackoverflow.com/a/21067059 <= now this is just crazy, why would i not use linux from scratch if i have to do this to get a not even new version of ruby to run
ibouvousaime_ has quit [Ping timeout: 255 seconds]
<Bish> jesus
<Bish> sorry, i gonna stop now.
<ljarvis> atmosx: OSX
hxegon has joined #ruby
sgambino has joined #ruby
<atmosx> ljarvis: me too
<Lloyd> the brightbox ruby ppa is opinionated
ibouvousaime_ has joined #ruby
roshanavand has joined #ruby
agent_white has quit [Remote host closed the connection]
whippythellama has joined #ruby
babblebre has joined #ruby
jmignault has joined #ruby
x-user has joined #ruby
haylon has joined #ruby
roshanavand has quit [Ping timeout: 260 seconds]
marcoecc has quit [Read error: Connection reset by peer]
marcoecc has joined #ruby
nixmaniack has joined #ruby
<timonv> Would advise for production usage to just compile from source
anisha_ has quit [Quit: Leaving]
weemsledeux has joined #ruby
roshanavand has joined #ruby
ellistaa has joined #ruby
bubbys has quit [Ping timeout: 260 seconds]
Coldblackice has quit [Ping timeout: 240 seconds]
sankaber has joined #ruby
x-user has quit [Quit: x-user]
phreakocious has joined #ruby
bigkevmcd has joined #ruby
mistermocha has joined #ruby
* Bish downloads a ubuntu server iso, burns it to a dvd, and burns it in his oven
aadam21 has quit [Ping timeout: 260 seconds]
SenpaiSilver has quit [Read error: Connection reset by peer]
scripore has quit [Quit: This computer has gone to sleep]
houhoulis has joined #ruby
marcoecc has quit [Ping timeout: 260 seconds]
scripore has joined #ruby
TomPeed has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
scripore has quit [Remote host closed the connection]
kobain has joined #ruby
TomPeed has joined #ruby
ubear has joined #ruby
tjohnson has joined #ruby
mistermocha has quit [Ping timeout: 240 seconds]
slackbotgz has quit [Remote host closed the connection]
slackbotgz has joined #ruby
<Bish> woop woop got ruby 2.0 running, welcome to 2013
sergey_makagon has joined #ruby
ubear has quit [Client Quit]
aadam21 has joined #ruby
aspire has joined #ruby
chouhoulis has joined #ruby
Mon_Ouie has quit [Quit: WeeChat 1.3]
chipotle has quit [Read error: Connection reset by peer]
chipotle has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
huyderman has quit [Remote host closed the connection]
brunto has quit [Read error: Connection reset by peer]
solars has quit [Ping timeout: 260 seconds]
dlitvak has joined #ruby
brunto has joined #ruby
sergey_makagon has quit [Remote host closed the connection]
leksster has quit [Remote host closed the connection]
sumark has quit [Remote host closed the connection]
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
dionysus69 has quit [Ping timeout: 250 seconds]
nixmaniack has quit [Read error: Connection reset by peer]
penne12 has joined #ruby
sumark has joined #ruby
frem has joined #ruby
scripore has joined #ruby
bubbys has joined #ruby
atmosx has quit [Quit: Lost in trance]
sergey_makagon has joined #ruby
penne12 has quit [Client Quit]
aspire has quit [Quit: Leaving]
zenlot2 is now known as zenlot
ryotarai has quit [Ping timeout: 260 seconds]
nug has quit [Max SendQ exceeded]
lacuna has joined #ruby
nug has joined #ruby
<Bish> havenwood: thank you, will maybe try it in future installations
SenpaiSilver has joined #ruby
<havenwood> Bish: Brightbox makes nice Ruby packages and keep them pretty up-to-date with latest stable.
pandaant has quit [Remote host closed the connection]
<havenwood> Bish: Ah, it was already mentioned. I'm too late!
<havenwood> ruby-install --latest ruby :D
roshanavand has quit [Read error: Connection reset by peer]
domgetter has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
roshanavand has joined #ruby
cold_zero has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mary5030 has joined #ruby
<cold_zero> Hi. I need help with OptionParser. Could someone help me, please?
lacuna has quit [Remote host closed the connection]
dlitvak_ has joined #ruby
<havenwood> cold_zero: Say more?
thevishy has quit [Read error: Connection reset by peer]
dlitvak has quit [Read error: Connection reset by peer]
karapetyan has joined #ruby
<cold_zero> I try to take list of files that I want to exclude from search like this
gheegh has joined #ruby
<cold_zero> opts.on('-e', '--exclusion file1,file2,file3', Array, "Specify files that will be ingnored during search") do |list|
ryotarai has joined #ruby
<cold_zero> and I have to provide them as file1,file2,file3
<cold_zero> as arguments
Marsupermammal has joined #ruby
<cold_zero> I'd like to know is it possible to have spaces after comma or even eliminate commas entirely, but preserve spaces
<cold_zero> ?
aganov has quit [Remote host closed the connection]
<Bish> and how do i tell ruby to use global gems on ubuntu?
kalopsian has joined #ruby
thevishy has joined #ruby
mary5030 has quit [Remote host closed the connection]
PaulCapestany has quit [Quit: .]
troulouliou_div2 has joined #ruby
FooMunki has quit [Quit: FooMunki]
FooMunki has joined #ruby
<Bish> since without environment ruby doesn't seem to know, sigh
karapetyan has quit [Ping timeout: 260 seconds]
arup_r has quit [Remote host closed the connection]
lacuna has joined #ruby
lacuna has joined #ruby
ellistaa has quit [Quit: ellistaa]
PaulCapestany has joined #ruby
<havenwood> cold_zero: Slop is simpler to use (but yeah, not in stdlib): https://github.com/leejarvis/slop#arrays
<havenwood> Bish: How'd you install Ruby? Where'd you install it to?
<gheegh> hey all, i've got an activerecord object.. that i'm trying to set some values on, but it doesn't seem to let me.. here's the gist of what i'm trying to do.. https://gist.github.com/wflanagan/9de9b7160b6bfddd0ab3
<cold_zero> havenwood: thank you. Do you think it will help me with my case?
mrtomme has quit [Ping timeout: 246 seconds]
<Bish> havenwood: i just used brightbox ppa, to install it
<havenwood> cold_zero: I think it would, at least I'd have an easier time using slop.
<Bish> i installed both global gem(with root) and locally (with --user-install)
<cold_zero> havenwood: thank you :-)
<Bish> which actually works, but not if i do a "sudo" ( im not actually using sudo, postfix invokes the script as the right user )
<Bish> which seems in resulting ruby not to know where to find gems
mrtomme has joined #ruby
emilianork has joined #ruby
<Ebok> gheed: did you add the eval method to the class Agent?
<Ebok> Agent doesnt appear to have the eval method, so I'm just wondering
<havenwood> Bish: Hrm, that's odd. At least I'd have expected just switching to the Brightbox package with ruby-switch then using sudo to suffice: https://www.brightbox.com/docs/ruby/ubuntu/#switching-the-default-ruby-version
<havenwood> Bish: Do you have --user-local set in a gemrc or something?
mistermocha has joined #ruby
<havenwood> Bish: You could always use chruby to keep gem bin/ in PATH with your RUBY_ env vars set correctly!
<havenwood> That's pretty much all chruby does. :)
<emilianork> Hello,
<havenwood> emilianork: hi
<Bish> havenwood: i don't have a .gemrc
PaulCape_ has joined #ruby
<Bish> can i tell ruby to use the global gem thingie?
<Ebok> Er.. I mispelled his name
<havenwood> Bish: Did you switch to your Brightbox Ruby with ruby-switch or you only have one Ruby installed?
<Ebok> gheegh: I dont see the #eval method declared without your new Object Agent
<Ebok> within*
mary5030 has joined #ruby
finisherr has quit [Quit: finisherr]
<gheegh> I thought eval was a part of the base class in ruby ?
PaulCapestany has quit [Ping timeout: 245 seconds]
<Ebok> I've never used it, so, I suspect it's time to go find out
<Bish> havenwood: i only have one ruby installed
ibouvousaime_ has quit [Ping timeout: 240 seconds]
dlitvak_ has quit [Read error: Connection reset by peer]
slackbotgz has quit [Remote host closed the connection]
dlitvak has joined #ruby
<gheegh> Ebok: Maybe I need instance_eval?
<havenwood> Bish: Wait, I'm confused. You want non-sudo to install to a system location?
<havenwood> Bish: Or it's sudo that's not properly installing to the system location?
baweaver has joined #ruby
<havenwood> if (( UID != 0 )); then
jas02 has quit [Quit: jas02]
<Bish> i install gems with root, and i cannot simply require them as user
emilianork has quit [Ping timeout: 252 seconds]
<Bish> that's the issue i am having
bkxd has joined #ruby
<Bish> even though Gem.default_dir="/var/lib.."
<Ebok> Honestly, gheegh, I've been learning code for 2 months. I'm not entire sure ^_^. You'r right though, it is within the Object class.
<Bish> well, i see what the reason is
futilegames has joined #ruby
platzhirsch has left #ruby [#ruby]
thevishy has left #ruby ["WeeChat 1.4-rc1"]
<Bish> fml.. rvm wrote Gem.dir
krzkrz has quit [Ping timeout: 272 seconds]
BSaboia has quit [Ping timeout: 256 seconds]
ibouvousaime_ has joined #ruby
* havenwood goes in search of coffee
chouhoulis has quit [Remote host closed the connection]
<cold_zero> havenwood: one more question about "slop". Do you know is it possible to specify possible types of value provided for flags. For example for "-e" flag I can provide list of files like "file1 file2 file3" or REGEX like "*.txt"
chouhoulis has joined #ruby
<Bish> it's still not working jesus christ
baweaver has quit [Ping timeout: 255 seconds]
kies^ has joined #ruby
hakunin has joined #ruby
bkxd has quit [Ping timeout: 260 seconds]
Snowy has quit [Read error: Connection reset by peer]
<aegis3121> cold_zero: the docs appear to suggest yes, sort of.
<aegis3121> I think if you're looking for a custom option (i.e. one that accepts both), you'd need to make...your own custom option class, as it suggests.
<cold_zero> aegis3121: thank you :)
lacuna has quit [Remote host closed the connection]
Snowy has joined #ruby
roshanav_ has joined #ruby
roshanavand has quit [Read error: Connection reset by peer]
ibouvousaime_ has quit [Ping timeout: 260 seconds]
Snowy has quit [Remote host closed the connection]
marcoecc has joined #ruby
<Bish> havenwood: well thank you, you helped alot
domgetter has joined #ruby
s00pcan has quit [Ping timeout: 260 seconds]
sankaber has quit [Remote host closed the connection]
sankaber has joined #ruby
s00pcan has joined #ruby
rodfersou|lunch is now known as rodfersou
aegis3121 has quit [Ping timeout: 265 seconds]
catphish has joined #ruby
arup_r has joined #ruby
psy_ has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
gusTester has quit [Ping timeout: 246 seconds]
<catphish> i have a really silly question, how do i send data using UDPSocket? the documentation talks about #send, but #send has a totally different meaning (it tries to call a method)
gusTester has joined #ruby
Snowy has joined #ruby
sergey_makagon has quit [Remote host closed the connection]
ellistaa has joined #ruby
dlitvak has joined #ruby
roshanav_ has quit [Remote host closed the connection]
dhollinger has joined #ruby
jgpawletko has joined #ruby
treehug88 has joined #ruby
rrichardsr3 has joined #ruby
karapetyan has joined #ruby
rrichardsr3 has quit [Max SendQ exceeded]
FooMunki has quit [Quit: FooMunki]
<catphish> never mind, #send works
<Bish> >> UDPSocket.new.send "hi",0,"127.0.0.1",4000
<ruboto> Bish # => uninitialized constant UDPSocket (NameError) ...check link for more (https://eval.in/498178)
<Bish> :(
FooMunki has joined #ruby
rrichardsr3 has joined #ruby
Yiota has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<adaedra> You have to require socket, Bish. But I don't think eval.in will let you socket like that.
<adaedra> By the way
<adaedra> >> RUBY_VERSION
<catphish> Bish: i did exactly that, but i ignored the uninitialized constant error, and tried to call "send" on nil, which confused me because stupidity :)
<ruboto> adaedra # => "2.2.0" (https://eval.in/498179)
<adaedra> :(
howdoi has quit [Quit: Connection closed for inactivity]
rippa has joined #ruby
Yiota has joined #ruby
denym_ is now known as zz_denym_
marcoecc has quit [Read error: Connection reset by peer]
marcoecc has joined #ruby
marcoecc is now known as Guest32319
Marsupermammal has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
futilegames has quit [Quit: futilegames]
<Zarthus> Should I report this segfault?
troulouliou_div2 has quit [Quit: Leaving]
<Zarthus> the assumption is 'yes', but maybe the response is 'you're doing it wrong'. In either case, I figure segfaults are never desired.
mary5030 has quit [Remote host closed the connection]
mark2 has quit [Quit: Leaving.]
yardenbar has quit [Ping timeout: 264 seconds]
Marsupermammal has joined #ruby
ellistaa has quit [Quit: ellistaa]
JazzyVariable227 has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
PaulCape_ has quit [Quit: .]
futilegames has joined #ruby
ellistaa has joined #ruby
thisistesting has joined #ruby
PaulCapestany has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
mistermocha has quit [Remote host closed the connection]
tvw has quit [Remote host closed the connection]
sandstrom has joined #ruby
sandstrom has quit [Client Quit]
celly has joined #ruby
<Zarthus> i reported it anyways, figured it'll be closed if they consider it normal behaviour
ellistaa has quit [Client Quit]
gagrio has quit [Ping timeout: 245 seconds]
RegulationD has joined #ruby
Guest32319 has quit [Ping timeout: 246 seconds]
ellistaa has joined #ruby
jackjackdripper has joined #ruby
thisistesting has quit [Remote host closed the connection]
jobewan has joined #ruby
FooMunki has quit [Quit: FooMunki]
dlitvak has joined #ruby
weemsledeux has joined #ruby
gambl0re has quit [Ping timeout: 260 seconds]
<apeiros> Zarthus: segfaults are always bugs
<apeiros> no pure ruby code should produce a segfault
<Zarthus> yeah, that was my thinking.
<apeiros> so reporting it was the proper course of action :)
<Zarthus> I figured if it wasn't expected behaviour a threadingerror would probably be thrown instead.
cschneid_ has joined #ruby
<Zarthus> I actually came across it whilst debugging, exiting early by just printing some output xP
phredus has quit [Remote host closed the connection]
r0bby_ has joined #ruby
JazzyVariable227 has quit [Remote host closed the connection]
robbyoconnor has quit [Ping timeout: 265 seconds]
bensarz has joined #ruby
agentmeerkat has joined #ruby
shinnya has joined #ruby
sepp2k has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
lucasb has joined #ruby
dlitvak has joined #ruby
mistermocha has joined #ruby
Yiota has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
musl has quit [Quit: WeeChat 1.1.1]
scampbell has joined #ruby
mistermocha has quit [Remote host closed the connection]
mistermocha has joined #ruby
tvw has joined #ruby
pdoherty has quit [Ping timeout: 240 seconds]
SCHAAP137 has quit [Remote host closed the connection]
ESpiney has joined #ruby
ellistaa has quit [Quit: ellistaa]
Yiota has joined #ruby
lxsameer has joined #ruby
lxsameer has joined #ruby
Xeago has joined #ruby
cold_zero has quit [Quit: Ex-Chat]
FernandoBasso has joined #ruby
mjuszczak has joined #ruby
krzkrz has joined #ruby
lacuna has joined #ruby
lacuna has quit [Changing host]
lacuna has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
einarj has quit [Remote host closed the connection]
sandstrom has joined #ruby
symm- has joined #ruby
fourq is now known as fourq|away
TomyWork has quit [Ping timeout: 246 seconds]
MattV has joined #ruby
fourq|away is now known as fourq
podman has joined #ruby
krzkrz has quit [Ping timeout: 240 seconds]
Lucky__ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dlitvak has joined #ruby
krzkrz has joined #ruby
Guest32319 has joined #ruby
BSaboia has joined #ruby
lacuna has quit [Remote host closed the connection]
[Butch] has joined #ruby
fwes has joined #ruby
duckpuppy has quit [Ping timeout: 255 seconds]
brunto has quit [Ping timeout: 260 seconds]
jbrhbr has joined #ruby
fwes has quit [Read error: Connection reset by peer]
agentmeerkat has quit [Ping timeout: 240 seconds]
uri_ has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
mary5030 has joined #ruby
dlitvak has joined #ruby
nixmaniack has joined #ruby
nixmaniack has quit [Changing host]
nixmaniack has joined #ruby
ibouvousaime_ has joined #ruby
karapetyan has quit [Remote host closed the connection]
scripore has quit [Quit: This computer has gone to sleep]
wldcordeiro has quit [Ping timeout: 240 seconds]
Lucky___ has joined #ruby
lurch_ has joined #ruby
DonOtreply has joined #ruby
cschneid_ has quit [Ping timeout: 272 seconds]
Macaveli has joined #ruby
celly has quit [Remote host closed the connection]
trautwein has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
mjuszczak has quit []
celly has joined #ruby
celly has quit [Remote host closed the connection]
scripore has joined #ruby
finisherr has joined #ruby
SOLDIERz has quit [Ping timeout: 265 seconds]
dlitvak has quit [Read error: Connection reset by peer]
scripore has quit [Client Quit]
aggiejosh06 has joined #ruby
karapetyan has joined #ruby
mjuszczak has joined #ruby
Yiota has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
pietr0 has joined #ruby
dlitvak has joined #ruby
lacuna has joined #ruby
lacuna has quit [Changing host]
lacuna has joined #ruby
ziyadb has quit [Quit: Connection closed for inactivity]
FernandoBasso has quit [Ping timeout: 240 seconds]
amclain has joined #ruby
yardenbar has joined #ruby
rgtk has left #ruby ["ERC (IRC client for Emacs 24.5.1)"]
choke has joined #ruby
d0nn1e has quit [Ping timeout: 260 seconds]
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
TomyLobo has joined #ruby
d0nn1e has joined #ruby
azggil has joined #ruby
choke_ has joined #ruby
Xeago has quit [Remote host closed the connection]
DoubleMalt has quit [Remote host closed the connection]
JazzyVariable227 has joined #ruby
futilegames has quit [Quit: futilegames]
choke__ has joined #ruby
webus has quit [Ping timeout: 246 seconds]
choke has quit [Ping timeout: 265 seconds]
huyderman has joined #ruby
choke has joined #ruby
Xeago has joined #ruby
choke_ has quit [Ping timeout: 265 seconds]
jbrhbr has quit [Quit: Leaving.]
krzkrz has quit [Quit: WeeChat 1.2]
sameerynho has joined #ruby
dlitvak_ has joined #ruby
kalopsian has quit [Ping timeout: 272 seconds]
choke__ has quit [Ping timeout: 265 seconds]
dwfait has quit [Remote host closed the connection]
choke_ has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
FernandoBasso has joined #ruby
Marsupermammal has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
JazzyVariable227 has quit [Remote host closed the connection]
govg has quit [Ping timeout: 250 seconds]
framling has quit [Ping timeout: 265 seconds]
ellistaa has joined #ruby
bb010g has quit [Quit: Connection closed for inactivity]
lxsameer has quit [Ping timeout: 255 seconds]
govg has joined #ruby
choke__ has joined #ruby
bluOxigen_ has joined #ruby
choke has quit [Ping timeout: 265 seconds]
DoubleMalt has joined #ruby
dionysus69 has joined #ruby
choke has joined #ruby
CorySimmons has joined #ruby
choke_ has quit [Ping timeout: 265 seconds]
<ellistaa> can somenoe help me understand what this is saying http://postimg.org/image/dzn0nnomd/
RegulationD has quit [Remote host closed the connection]
DoubleMalt has quit [Remote host closed the connection]
kies^ has quit [Ping timeout: 240 seconds]
choke__ has quit [Ping timeout: 265 seconds]
jpfuentes2 has joined #ruby
<domgetter> ellistaa: they want you to add up bits in an array. but they want you to modify each one before you add it up. the modification is "the bit value (0 or 1) multiplied by -2 raised to where the bit is in the array (its index)"
choke has quit [Ping timeout: 265 seconds]
ascarter has joined #ruby
<domgetter> so [1, 0, 1] would be 1*(-2)^(0) + 0*(-2)^(1) + 1*(-2)^(2)
<ellistaa> dogmetter: but whats with the ‘for i = 0 N-1’ doesn’t that mean i is always the length of the array?
cschneid_ has joined #ruby
<domgetter> you can see that the power I'm raising -2 by is increasing for every bit
ta has quit [Read error: Connection reset by peer]
<domgetter> up to the length of the array minus one, yes
<domgetter> i in that case is whatever index we're at for that bit
<ellistaa> ok i was squaring it based on the length of the array minus 1 not the index value
DoubleMalt has joined #ruby
<domgetter> you can see that for the second bit in my 101 example, that we raise to 1 since 1 is the second index of an array
rontec76 has joined #ruby
mary5030 has quit [Remote host closed the connection]
dlitvak_ has quit [Read error: Connection reset by peer]
dlitvak has joined #ruby
uri_ has quit [Quit: --]
wldcordeiro has joined #ruby
<domgetter> of course, that's only half the problem. the other thing is that they want you to spit out negative numbers?
troulouliou_div2 has joined #ruby
celly has joined #ruby
ta has joined #ruby
baweaver has joined #ruby
rontec76 has left #ruby [#ruby]
houhoulis has quit [Remote host closed the connection]
bkxd has joined #ruby
mattr__ has joined #ruby
ronplastic has joined #ruby
lacuna has quit [Remote host closed the connection]
elektronaut has joined #ruby
bluOxigen has joined #ruby
bluOxigen_ has quit [Ping timeout: 260 seconds]
lucasb has quit [Quit: leaving]
CorySimmons has quit [Quit: Bye!]
dgarstang has joined #ruby
baweaver has quit [Ping timeout: 256 seconds]
choke has joined #ruby
bkxd has quit [Ping timeout: 240 seconds]
peeja has joined #ruby
<dgarstang> Where can I find good examples of how to use the ruby aws sdk? Specifically I get to get cloudformation stack outputs. Theres a lot of examples for python boto3 but if you google the equivalent operatons for ruby, there's very very little except API references which makes it hard for people to start using it
finisherr_ has joined #ruby
<azggil> seems need multiply 2
lacuna has joined #ruby
lacuna has quit [Changing host]
lacuna has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
Xeago has quit [Remote host closed the connection]
Macaveli has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
finisherr has quit [Ping timeout: 246 seconds]
finisherr_ is now known as finisherr
lacuna has quit [Remote host closed the connection]
jackjackdripper has quit [Ping timeout: 265 seconds]
jobewan has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<azggil> its easy, read again
kies^ has joined #ruby
<dgarstang> azggil: I've read it numerous times. "client = Aws::CloudFormation::StackOutput()" ... tried that, that doesn't work
Macaveli has joined #ruby
shadoi has joined #ruby
sandstrom has joined #ruby
<speakingcode> dgarstang: did you construct the class first?
<azggil> you found docs for version 1
gatman has joined #ruby
<speakingcode> ^^ that too
<azggil> is it relly what you need?
<dgarstang> speakingcode: No, how do I do that? Where does that doc tell me how to do that?
<dgarstang> azggil: I found the v2 docs
<speakingcode> well still looking at the v1 docs, it describes the constructor
<dgarstang> ^ allegedly v2
<azggil> try that
catphish has quit [Quit: Leaving]
celly has quit [Remote host closed the connection]
<dgarstang> azggil: That's S3
<speakingcode> should be pretty similar tho
tjohnson has quit [Quit: Connection closed for inactivity]
uri_ has joined #ruby
<dgarstang> speakingcode: yes but what comes before that?
<speakingcode> look at the top of that doc
icarus has quit [Read error: Connection reset by peer]
<dgarstang> speakingcode: "client = Aws::CloudFormation::Client()
<dgarstang> ... doesn't work
<speakingcode> "Clas: AWS....::Client Overview: an api client for AWS CloudFormation. To construct a cleint you need to configure a :region and :credentials" example follows
<dgarstang> (that's whats at the top of the doc)
<speakingcode> do you have much ruby experience
<speakingcode> ?
Snowy has quit []
<speakingcode> you construct with .new()
<dgarstang> speakingcode: No. I hate it, but I gotta use it
<choke> I can confirm that it's pretty similar. I've got something similar that talks to S3, CodeDeploy and AppStream
jackjackdripper has joined #ruby
Xeago has joined #ruby
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
DEA7TH has quit [Quit: DEA7TH]
* choke gasps... hate.. ruby?!?
<speakingcode> dgarstang: not trying to be an ass, but you would probably greatly benefit from brushing up on some basic ruby chops, particularly Object Oriented stuff
poguez_ has joined #ruby
<dgarstang> tacking a .new on the end won't help, as it reports "undefined method `Client' for Aws::CloudFormation:Module (NoMethodError)"
Yiota has joined #ruby
<choke> the syntax is so pretty though
choke has quit [Read error: Connection reset by peer]
<speakingcode> codecademy.com may be a good place to start if you like interactive practice, or the pickaxe book from dave thomas, or the ruby koans
<dgarstang> speakingcode: I've been doing python for 15 years. ruby makes my eyes bleed. Trust me, I've tried many many times and it just makes no sense to me
rdavila has quit [Quit: Textual IRC Client: www.textualapp.com]
<apeiros> dgarstang: you're struggling for 6 months with the aws-sdk?
Kruppe has quit [Quit: ZNC - http://znc.in]
choke has joined #ruby
<azggil> 15 years Oo
icarus has joined #ruby
<dgarstang> apeiros: not sure where you got 6 months from, but I always struggle with the aws sdk for ruby. python is fine. there's docs and examples
<speakingcode> dgarstang: well i don't want to get into a language debate, i'm just saying going back to basics would probably help you because your confusion seems to stem from not understanding some basics of classes and instantiation
<apeiros> dgarstang: time to write a cheatsheet so you remember?
<speakingcode> if you look at the very top of that doc
<dgarstang> speakingcode: No, it's the ruby implementation of it
<speakingcode> cloudformation = Aws::CloudFormation::Client.new(...)
sigurding has quit [Quit: sigurding]
<dgarstang> speakingcode: Thanks.
<speakingcode> and it expects some config arguments, which the #initialize (http://docs.aws.amazon.com/sdkforruby/api/Aws/CloudFormation/Client.html#initialize-instance_method) api describes
crazydiamond has joined #ruby
axsuul has joined #ruby
<kspencer> Am I able to see what page is being loaded in a way to let me give certain css via a layout.erb so that I can put them in a external file?
nspeare has joined #ruby
Porfa has joined #ruby
<dgarstang> sigh
jbrhbr has joined #ruby
DoubleMalt has quit [Remote host closed the connection]
Kruppe has joined #ruby
minimalism has joined #ruby
framling has joined #ruby
domgetter has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
<speakingcode> what you have to understand dgarstang is initialize is a CLASS method, that returns an instance object of its class, and is called via new()
<dgarstang> speakingcode: sure, python does the same thing. it's the ruby syntax that grates me
<apeiros> speakingcode: uh, initialize is an instance method. new is a class method.
<dgarstang> speakingcode: in python it's foo = Object(...). In ruby it's a lot more complicated
<azggil> use python
<dgarstang> azggil: it's chef. Can't
<azggil> kill him and use right tool
<apeiros> in ruby it's foo = Object.new. truly complicated indeed.
<speakingcode> apeiros: err yeah, sorry got it backwards
<apeiros> speakingcode: happens
<dgarstang> apeiros: you mean Aws::CloudFormation::Client.new()
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
<speakingcode> dgarstang: yes.
baweaver has joined #ruby
DoubleMalt has joined #ruby
<apeiros> dgarstang: possibly. I haven't looked at AWS' API
<speakingcode> the () are optional
<dgarstang> Don't suppose anyone knows the way to get cfn stack outputs via the sdk
Hounddog has quit [Ping timeout: 250 seconds]
<speakingcode> for aws sdk specific questions you might try the chef or aws channels as well
<dgarstang> it's not clear (no examples) if I can just call a method on the Cfn object or if I have to dig down several object levels, which means trying to interpret that API doc
<speakingcode> whats the Cfn object?
nspeare has left #ruby [#ruby]
troulouliou_div2 has quit [Ping timeout: 260 seconds]
<dgarstang> speakingcode: cloudformation
aryaching has quit [Ping timeout: 245 seconds]
nspeare has joined #ruby
icarus has quit [Ping timeout: 276 seconds]
<speakingcode> i don't see a cloud formation object in here
<speakingcode> that's a module
<azggil> interesting task
<dgarstang> oh boy
<speakingcode> it's like a package/namespace so to speak
<speakingcode> i forget what the python equiv is
ascarter has joined #ruby
<dgarstang> so...
<azggil> about (-2)^n+(-2)^(n-1)...
baweaver has quit [Remote host closed the connection]
<choke> by "stack outputs" what exactly do you mean
inukshuk_ has joined #ruby
<dgarstang> well I got some sort of an object because I'm pretty sure I haven't assigned a module reference to a variable here
icarus has joined #ruby
<apeiros> azggil: if that's your ruby code for the base -2 problem, note that ^ is XOR, not power. ** is power.
<dgarstang> choke: CloudFormation stacks have well defined outputs
scottschecter has joined #ruby
<nspeare> quit
duckpuppy has joined #ruby
nspeare has quit [Client Quit]
lacuna has joined #ruby
lacuna has quit [Changing host]
lacuna has joined #ruby
<azggil> seems possibly shorten to (x^2n+x^2n-2...)-(x^2n-1-x^2n-3...)
stannard_ has joined #ruby
pdoherty has joined #ruby
<dgarstang> so it looks like the CloudFormation 'module' has a Stack class... which has an outputs attribute.... but how to get it...
icarus has quit [Client Quit]
<choke> and these outputs are what exactly? I don't use CloudFormation so I don't know... Looking @ the API docs however... you've got methods such as list_stacks, describe_stack_*
<speakingcode> so dgarstang back to the 'Client' class doc
<speakingcode> at the top it shows you how to construct a client object
inukshuk_ has quit [Client Quit]
<dgarstang> speakingcode: How do I get a Stack object from that?
<choke> look @ instance attribute summary -- and click on what you want to know
<dgarstang> choke: yes I'm there, but that doesn't help me
<dgarstang> speakingcode: I don't want to call describe stacks do I? i just want to get outputs for a particular stack
<dgarstang> oh i see
<dgarstang> guess I do
stannard has quit [Ping timeout: 245 seconds]
<dgarstang> time to go update IAM. Ugh
<speakingcode> there's a list_stacks method also, but i don't have AWS experience so i don't know the semantic meaning of that stuff
aegis3121 has joined #ruby
lacuna has quit [Read error: Connection reset by peer]
sonOfRa has quit [Quit: Bye!]
ibouvousaime_ has quit [Ping timeout: 272 seconds]
<dgarstang> speakingcode: I think I'm good now, thanks.... until the next ruby eye bleed inducement
lacuna has joined #ruby
lacuna has quit [Changing host]
lacuna has joined #ruby
dlitvak has quit [Remote host closed the connection]
lurch_ has quit [Quit: lurch_]
sonOfRa has joined #ruby
<speakingcode> sonOfRa: cool name
lurch_ has joined #ruby
lurch_ has quit [Client Quit]
<speakingcode> dgarstang: it looks like describe_stacks() returns a DescribeStacksOutput object, which has a method stacks() that returns an array of Stack objects
anisha_ has joined #ruby
<choke> list_stacks does essentially the same thing, but can be told to only achieve ones with a specific stack_status
Porfa has quit [Quit: Porfa]
aufi has quit [Quit: Konversation terminated!]
Porfa has joined #ruby
<choke> But, time for me to head in to the office.. so see you all later
jam_ has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
haylon has quit [Quit: Leaving]
Ebok has quit [Quit: Internet is down or Computer is restarting. I'll be back.]
nspeare has joined #ruby
jam_ has quit [Ping timeout: 250 seconds]
baweaver has joined #ruby
ht__ has joined #ruby
nertzy has joined #ruby
Xeago has quit [Remote host closed the connection]
Zackio has quit [Quit: C-x C-c]
benlieb has joined #ruby
guacamole has joined #ruby
webus has joined #ruby
wolffles has joined #ruby
Zackio has joined #ruby
PsionTheory has joined #ruby
lacuna_ has joined #ruby
lacuna has quit [Ping timeout: 250 seconds]
geekbri has joined #ruby
<wolffles> method to add an array of fix numbers?
<azggil> sample?
DoubleMalt has quit [Remote host closed the connection]
<wolffles> array = %w[1 8 27]
<aegis3121> What do you mean by "add an array of fix numbers"?
<wolffles> sum of the integers
JazzyVariable227 has joined #ruby
<wolffles> sorry i worded it wrong
<nspeare> quit
<aegis3121> Have you checked if a method on Array or Enumerable would work?
nspeare has quit [Quit: WeeChat 0.3.8]
craysiii has quit [Ping timeout: 260 seconds]
<aegis3121> #reduce would be what you want, I imagine
<wolffles> the methods i know all return arrays
<aegis3121> did you check Reduce?
<wolffles> i mean i can do it logically but just wondering if theres a method to simplify it
wald0 has joined #ruby
<wolffles> never seen Reduce
<aegis3121> docs are beautiful
dlitvak has joined #ruby
colegatron has quit [Ping timeout: 276 seconds]
brunto has joined #ruby
<wolffles> ahh aegis3121: that was exactly what i was looking for
blackmesa has joined #ruby
arup_r has quit []
SCHAAP137 has joined #ruby
JazzyVariable227 has quit [Ping timeout: 260 seconds]
sigurding has joined #ruby
<azggil> smart coder
mistermo_ has joined #ruby
<azggil> he could understand doc
<wolffles> i was searching docs
RegulationD has joined #ruby
<wolffles> but looking under arrays
<wolffles> derp :]
nspeare has joined #ruby
<baweaver> Enumerable
<baweaver> but still, no need to be mean
<eam> it'd be a fantastic feature for class docs to also show inherited methods
<eam> or I should rather say it's a misfeature that they don't
<aegis3121> wolffles: no problem
B1n4r10 has joined #ruby
<aegis3121> Enumerable is (at least to help me think about it) the definition of Ruby's idea of a collection. Any collection I would hope includes it, and I would probably assume it does.
bricker has joined #ruby
Kruppe has quit [Quit: ZNC - http://znc.in]
roshanavand has joined #ruby
sandstrom has joined #ruby
mistermo_ has quit [Ping timeout: 256 seconds]
<eam> it's a broad problem, not specifically related to enumerable
RegulationD has quit [Ping timeout: 264 seconds]
<eam> people want to operate on an object and there's no good place to find all methods associated with it
sigurding has quit [Quit: sigurding]
<aegis3121> I know that ruby-doc.org tells you which Modules have been included.
stamina has joined #ruby
<azggil> inject and reduce are synonims?
dlitvak_ has joined #ruby
<aegis3121> yep
jbrhbr has quit [Quit: Leaving.]
<aegis3121> As are collect and map, I think.
Kruppe has joined #ruby
friendofkiwi has joined #ruby
friendofkiwi has left #ruby [#ruby]
<wolffles> never knew that
roshanavand has quit [Ping timeout: 260 seconds]
techietrash has quit [Max SendQ exceeded]
techietrash has joined #ruby
Xeago has joined #ruby
<azggil> creaters didnot read docs
<azggil> carefully
celly has joined #ruby
dlitvak has quit [Ping timeout: 276 seconds]
prestorium has quit [Quit: Leaving]
colegatron has joined #ruby
JazzyVariable227 has joined #ruby
JazzyVariable227 has quit [Remote host closed the connection]
anisha_ has quit [Quit: Leaving]
<azggil> damn niggers
mahlon_ is now known as mahlon
<apeiros> !kick azggil language
azggil was kicked from #ruby by ruboto [language]
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
RegulationD has joined #ruby
wprice has joined #ruby
azggil has joined #ruby
<azggil> rr
<eam> what's the best way to inspect the build parameters of a ruby binary?
<apeiros> eam: RbConfig probably
<drbrain> yep
<apeiros> not sure, though
<drbrain> everything you should need (for linking to ruby after install) is in RbConfig
symm- has quit [Quit: Leaving...]
<eam> I want to see if -DHAVE_SENDFILE=0 was set
cdg has joined #ruby
araujo has quit [Quit: Leaving]
techietrash has quit [Max SendQ exceeded]
zeroDivisible has joined #ruby
KnownSyntax has quit [Ping timeout: 256 seconds]
techietrash has joined #ruby
techietrash has quit [Changing host]
techietrash has joined #ruby
<eam> aha success RbConfig::CONFIG.values.grep /SEND/ thanks much
choke has quit [Read error: Connection reset by peer]
paultreny has quit [Max SendQ exceeded]
guacamol_ has joined #ruby
paultreny has joined #ruby
paultreny is now known as Guest68983
techietrash has quit [Client Quit]
<eam> it appears that ruby still calls sendfile() even with that disabled
Guest68983 has quit [Remote host closed the connection]
<eam> it only disables some paths to that syscall, but not all
araujo has joined #ruby
araujo has quit [Changing host]
araujo has joined #ruby
davedev24 has joined #ruby
jbrhbr has joined #ruby
dfockler has joined #ruby
guacamole has quit [Ping timeout: 250 seconds]
choke has joined #ruby
ur5us has joined #ruby
nertzy has quit [Quit: This computer has gone to sleep]
FernandoBasso has quit [Quit: Leaving]
dlitvak_ has quit [Remote host closed the connection]
mistermocha has quit [Remote host closed the connection]
dionysus69 has quit [Quit: dionysus69]
baweaver has quit [Remote host closed the connection]
rdark has quit [Ping timeout: 255 seconds]
firstdayonthejob has joined #ruby
Marsupermammal has joined #ruby
mistermocha has joined #ruby
nertzy has joined #ruby
startupality has joined #ruby
HowardwLo has joined #ruby
isjaylee has joined #ruby
Porfa has quit [Quit: Porfa]
Porfa has joined #ruby
haraigoshi has joined #ruby
finisherr_ has joined #ruby
finisherr has quit [Ping timeout: 265 seconds]
finisherr_ is now known as finisherr
<hxegon> is there a way to force something into bool other than double negation (!!)?
<azggil> what is better to be a super pro in one technology or exploring different tech areas but without depp knowledges
cdg has quit [Remote host closed the connection]
<hxegon> azggil well, it depends. Personally I'd say be a generalist, but being a specialist pays more IMO
<azggil> so generalist is cooler
spider-mario has joined #ruby
bb010g has joined #ruby
Xeago has quit [Remote host closed the connection]
<hxegon> again, it depends on your personal goals.
paultreny has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
RegulationD has quit [Remote host closed the connection]
paultreny is now known as Guest36836
techietrash has joined #ruby
techietrash has quit [Changing host]
techietrash has joined #ruby
choke has quit [Read error: Connection reset by peer]
<eam> any sufficiently advanced specialist becomes an adept generalist as well
<eam> due to domain overlap
<wolffles> when yall were learning ruby did you make flash cards of the methods? is that something i should do or just keep doing problems
<azggil> i dont agree
choke has joined #ruby
Guest36836 has quit [Changing host]
Guest36836 has joined #ruby
<hxegon> azggil in what way?
<azggil> you need time to investigate different things
<aegis3121> wolffles: I would say just keep going. You'll pick up on more and get more comfortable navigating the docs, too :)
<azggil> but if u advanced how you learn others
<apeiros> oh hey hxegon
<apeiros> sorry, hadn't seen your email promptly
<hxegon> wolffles do you really need to memorize them? I just look up methods until I remember the more useful ones
<hxegon> apeiros it's all good. Not like it's a pressing matter :P
<wolffles> i would assume you guys memorized them but i guess its through experience like aegis3121 said
<aegis3121> hxegon agreed. You remember the more important, critical ones. You also start to get a new sense of "Hmm, this feels like a solved problem. I bet Ruby already does this for me." and you get good at guessing that it's out there.
<wolffles> lol guess you said it too hxegon
<apeiros> wolffles: I read through ruby core docs once
karapetyan has quit [Remote host closed the connection]
<apeiros> and then a couple of lookups later
yashinbasement has joined #ruby
<apeiros> that helped a lot
<eam> I learned perl, and then I just assume that the perl functions exist attached to the similar ruby types (which is usually true)
<apeiros> and I think by now I should probably repeat it. enough new methods I simply haven't paid attention to :)
karapetyan has joined #ruby
Xeago has joined #ruby
celly has quit [Remote host closed the connection]
jbrhbr has quit [Quit: Leaving.]
nertzy has quit [Quit: This computer has gone to sleep]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
baweaver has joined #ruby
stamina has quit [Ping timeout: 265 seconds]
Guest36836 has quit [Quit: ¯\_(ツ)_/¯]
dfockler has quit [Ping timeout: 245 seconds]
celly has joined #ruby
isjaylee has left #ruby [#ruby]
sepp2k has quit [Read error: Connection reset by peer]
northfurr has joined #ruby
sepp2k has joined #ruby
yashinbasement has quit [Ping timeout: 272 seconds]
wolffles has quit [Quit: wolffles]
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
gheegh has quit [Ping timeout: 240 seconds]
baweaver has quit [Remote host closed the connection]
<azggil> what for
<azggil> simply use in location bar "g i want sort/reduce/find something stuff"
startupality has quit [Quit: startupality]
baweaver has joined #ruby
jackjackdripper has quit [Quit: Leaving.]
blackmesa has joined #ruby
jobewan has joined #ruby
aegis3121 has quit [Ping timeout: 250 seconds]
darkf has quit [Quit: Leaving]
futilegames has joined #ruby
ascarter has joined #ruby
tuzz has joined #ruby
tuzz has left #ruby [#ruby]
brunto_ has joined #ruby
brunto has quit [Ping timeout: 240 seconds]
bithon has quit [Ping timeout: 264 seconds]
<greenhat> Review the docs for Enumerable, Array, and Hash and you are well on your way.
choke_ has joined #ruby
choke has quit [Ping timeout: 272 seconds]
sgambino_ has joined #ruby
charliesome has joined #ruby
sgambino has quit [Read error: Connection reset by peer]
JDiPierro has joined #ruby
valkyrka has joined #ruby
choke_ has quit [Read error: Connection reset by peer]
baweaver has quit [Remote host closed the connection]
lacuna_ has left #ruby [#ruby]
choke has joined #ruby
agentmeerkat has joined #ruby
cmolenda has quit [Remote host closed the connection]
paultreny_ has joined #ruby
Xeago has quit [Remote host closed the connection]
lacuna has joined #ruby
lacuna has quit [Changing host]
lacuna has joined #ruby
dlitvak has joined #ruby
konr has joined #ruby
charliesome has quit [Client Quit]
arup_r has joined #ruby
Ox0dea has joined #ruby
bigkevmcd has quit [Ping timeout: 260 seconds]
choke has quit [Read error: Connection reset by peer]
aibot has quit [Ping timeout: 260 seconds]
baweaver has joined #ruby
bkxd has joined #ruby
dlitvak has quit [Ping timeout: 240 seconds]
bigkevmcd has joined #ruby
choke has joined #ruby
yashinbasement has joined #ruby
bithon has joined #ruby
mjuszczak has quit []
choke has quit [Read error: Connection reset by peer]
Xeago has joined #ruby
baweaver has quit [Ping timeout: 260 seconds]
choke has joined #ruby
bkxd has quit [Ping timeout: 260 seconds]
ellistaa has quit [Quit: ellistaa]
DEA7TH has joined #ruby
JazzyVariable227 has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
choke has quit [Read error: Connection reset by peer]
sigurding has joined #ruby
guacamol_ has quit [Quit: Textual IRC Client: www.textualapp.com]
<eam> scratch that re USE_SENDFILE, turns out HAVE_SENDFILE is the relevant flag, sigh
guacamole has joined #ruby
stamina has joined #ruby
rrichardsr3 has quit [Quit: Apparantly my attempt to stay awake has failed...]
JazzyVariable227 has quit [Ping timeout: 245 seconds]
mary5030 has joined #ruby
dangerousdave has joined #ruby
craysiii has joined #ruby
choke has joined #ruby
RegulationD has joined #ruby
hobodave has joined #ruby
Dimik has joined #ruby
ht__ has quit [Quit: Konversation terminated!]
brunto_ has quit [Ping timeout: 260 seconds]
ht__ has joined #ruby
mistermocha has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
dangerousdave has quit [Ping timeout: 260 seconds]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
kirun has joined #ruby
kadoppe has quit [Ping timeout: 260 seconds]
ht__ has quit [Client Quit]
ht__ has joined #ruby
kadoppe has joined #ruby
choke has quit [Ping timeout: 272 seconds]
ht__ has quit [Client Quit]
ht__ has joined #ruby
FernandoBasso has joined #ruby
jbrhbr has joined #ruby
spastorino has quit []
choke has joined #ruby
spastorino has joined #ruby
Snowy has joined #ruby
mistermocha has joined #ruby
whippythellama has quit [Ping timeout: 240 seconds]
KnownSyntax has joined #ruby
KnownSyntax has quit [Changing host]
KnownSyntax has joined #ruby
xet7 has quit [Ping timeout: 276 seconds]
elaptics is now known as elaptics`away
decoponio has quit [Quit: Leaving...]
paultreny_ has quit [Changing host]
paultreny_ has joined #ruby
karapetyan has quit [Remote host closed the connection]
paultreny_ is now known as paultreny
karapetyan has joined #ruby
Snowy has quit []
juddey has joined #ruby
vroomvroomvroom has joined #ruby
<vroomvroomvroom> who knows mac and linux?
uri_ has quit [Ping timeout: 240 seconds]
<havenwood> vroomvroomvroom: Is this a riddle?
tvw has quit [Remote host closed the connection]
duckpuppy has quit [Ping timeout: 276 seconds]
shadoi has quit [Quit: Leaving.]
bewie has quit [Quit: leaving]
rodfersou has quit [Quit: leaving]
<vroomvroomvroom> no i just want to know what the open (osx) command is in ubuntu
<vroomvroomvroom> havenwood
ellistaa has joined #ruby
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
<Ox0dea> vroomvroomvroom: xdg-open
<vroomvroomvroom> thanks
<vroomvroomvroom> can we change it to just open?
dlitvak has joined #ruby
nspeare has left #ruby ["WeeChat 0.3.8"]
<Ox0dea> No.
<Ox0dea> That is forbidden.
valkyrka has quit [Quit: valkyrka]
mary5030 has quit [Remote host closed the connection]
wolffles has joined #ruby
ec^ is now known as ELLIOTTCABLE
baweaver has joined #ruby
bmurt has joined #ruby
hxegon is now known as hxegon_AFK
shadoi has joined #ruby
centrx has joined #ruby
jam_ has joined #ruby
Phage has joined #ruby
Phage has left #ruby ["Textual IRC Client: www.textualapp.com"]
huyderman has quit [Remote host closed the connection]
choke has quit [Read error: Connection reset by peer]
pawnbox has quit [Remote host closed the connection]
choke has joined #ruby
pawnbox has joined #ruby
xet7 has joined #ruby
<shevy> lol
aegis3121 has joined #ruby
sameerynho has quit [Quit: Leaving]
webus_ has joined #ruby
jackjackdripper has joined #ruby
jam_ has quit [Ping timeout: 246 seconds]
ht__ has quit [Quit: Konversation terminated!]
pawnbox has quit [Ping timeout: 246 seconds]
Highsen has joined #ruby
bithon has quit [Ping timeout: 264 seconds]
jackjackdripper has quit [Client Quit]
jackjackdripper has joined #ruby
webus has quit [Ping timeout: 260 seconds]
iateadonut has quit [Quit: Leaving.]
barajasfab has joined #ruby
<yorickpeterse> vroomvroomvroom: alias open='xdg-open'
<vroomvroomvroom> thank you yorickpeterse
choke has quit [Ping timeout: 272 seconds]
aibot has joined #ruby
choke has joined #ruby
Majora_ has joined #ruby
<Majora_> Good morning beautiful people<33
<azgil> hey baby
ht__ has joined #ruby
<Majora_> azgil: sup girl??<3
<azgil> what?
<Majora_> what?
<azgil> who is sup
<Majora_> sup = whats up
<Majora_> 1 <= 2
<blub> huh
* Majora_ waves to blub
JazzyVariable227 has joined #ruby
postmodern has joined #ruby
<azgil> 1≤2 baby
jobewan has quit [Ping timeout: 250 seconds]
<Ox0dea> That 2's about to lose its knee.
sepp2k has quit [Quit: Leaving.]
ht__ has quit [Client Quit]
<Ox0dea> Fun fact: the crocodile in Peter Pan is a grill.
<Majora_> Ox0dea: Mylove<33
ht__ has joined #ruby
shadoi has quit [Quit: Leaving.]
peeja has quit [Ping timeout: 245 seconds]
<Majora_> Ox0dea: Fun fact: My real name is actually Peter xP
Xeago has joined #ruby
camilasan has quit [Remote host closed the connection]
<azgil> #fuckedtecheylover haha
Dimik has quit [Ping timeout: 264 seconds]
momomomomo has joined #ruby
bithon has joined #ruby
lucasb has joined #ruby
hxegon_AFK is now known as hxegon
cschneid_ has quit [Ping timeout: 272 seconds]
davedev2_ has joined #ruby
<azgil> cool , what still do u know
camilasan has joined #ruby
mustmodify has joined #ruby
<mustmodify> just ran across this code when looking to convert a javascript thing to ruby.
<azgil> what else
<mustmodify> ouch.
guacamol_ has joined #ruby
guacamole has quit [Ping timeout: 245 seconds]
<Ox0dea> mustmodify: And how did you translate it? :)
<shevy> mustmodify pretty ugly
chussenot has quit [Ping timeout: 260 seconds]
<shevy> do they not use true and false in javascript so that they must use 'y' or 'n'?
<mustmodify> Ox0dea: I thought, Hm... let me see if I can void that entirely. :)
<mustmodify> If nothing else, I think if I have code that returns "valid" where valid is the character "n", someone could fairly say I was off track.
davedev24 has quit [Ping timeout: 260 seconds]
choke has quit [Read error: Connection reset by peer]
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
mjuszczak has joined #ruby
mjuszczak has quit [Max SendQ exceeded]
<mustmodify> of course they mean is_valid but whatever.
<mustmodify> unreadable.
JazzyVariable227 has quit [Remote host closed the connection]
hxegon has quit [Ping timeout: 240 seconds]
<Ox0dea> mustmodify: valid = c.all? { |n| n == n }
mjuszczak has joined #ruby
<Ox0dea> NaN, by definition, doesn't even equal itself.
<lucasb> oh, ruby doesn't have NaN (?)
<Ox0dea> >> Float::NAN
<ruboto> Ox0dea # => NaN (https://eval.in/498289)
<mustmodify> Ox0dea: while cool, that would be too magical for me.
<Ox0dea> mustmodify: ?
<Ox0dea> This is #ruby.
<centrx> I AM NOT A NUMBER. I AM A FREE MAN!
<lucasb> ah, must use the fully qualified name :) thanks Ox0dea
ht__ has quit [Client Quit]
ht__ has joined #ruby
<Ox0dea> lucasb: Sure thing.
<Ox0dea> You could always `include Float`, I suppose, but that's crazy.
<mustmodify> Yeah, I'm replacing that with Color#valid? which tests red, green and blue attributes to see if they are in range.
lacuna has quit [Read error: Connection reset by peer]
<Ox0dea> mustmodify: In that case, you can just return `rgb.all? { |c| 0..255 === c }`.
bestbrents_ has joined #ruby
jbrhbr has quit [Quit: Leaving.]
JazzyVariable227 has joined #ruby
choke has joined #ruby
uri_ has joined #ruby
lacuna has joined #ruby
guacamole has joined #ruby
codecop has quit [Remote host closed the connection]
BSaboia has quit [Ping timeout: 256 seconds]
dgarstang has quit [Quit: WeeChat 1.3]
guacamol_ has quit [Ping timeout: 260 seconds]
peeja has joined #ruby
jfo has joined #ruby
<azgil> time to dance and drink
<mustmodify> VALID_RGB_VALUES = (0..255); rgb.all?{|color| VALID_RGB_VALUES.include?( c ) }
<azgil> right now an Orthodox xmas
bestbrents has quit [Ping timeout: 240 seconds]
<mustmodify> extra code but more readable, IMO
Xeago has quit [Remote host closed the connection]
lacuna has quit [Read error: Connection reset by peer]
Macaveli has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
lacuna has joined #ruby
lacuna has quit [Changing host]
lacuna has joined #ruby
JazzyVariable227 has quit [Ping timeout: 246 seconds]
geekbri has quit []
Hammy_Work has joined #ruby
dpg_ has joined #ruby
<Ox0dea> >> (0..255).include? 3.14 # mustmodify: Uh-oh.
<ruboto> Ox0dea # => true (https://eval.in/498290)
<dpg_> I'm trying to write a ruby gem, what's a good tut on gems + oo ruby ?
<mustmodify> Well, they're all guaranteed to be integers, otherwise that would be a good point.
<dpg_> Keep getting "playa_device_client.rb:5:in `initialize': uninitialized constant PlayaDeviceClient::Boot (NameError)" and I don't know how to fix it. :D
<azgil> did you see coll dance from russian neurocoders https://www.youtube.com/watch?v=9YpKeUIEKDk
<Ox0dea> dpg_: This was a pretty good Tut: https://en.wikipedia.org/wiki/Tutankhamun
<dpg_> r-d-r-r
jmignault has quit [Ping timeout: 260 seconds]
momomomomo has quit [Quit: momomomomo]
<dpg_> the funny thing is I copied/pasted that url without reading it. mfw.
<Ox0dea> dpg_: Most people click links?
choke has quit [Ping timeout: 272 seconds]
<Ox0dea> /script install urlgrab.py
<Ox0dea> /alias add u /url
<Ox0dea> And then `/u 1` to open the most recent link in your browser.
guacamole has quit [Quit: Textual IRC Client: www.textualapp.com]
<Ox0dea> Computers love you and want to help.
frog0909 has quit [Remote host closed the connection]
<adaedra> Prove it.
aadam21 has quit [Remote host closed the connection]
mistermocha has quit [Read error: Connection reset by peer]
mjuszczak has quit []
mjuszczak has joined #ruby
<shevy> a python script!
mistermocha has joined #ruby
MercutioX has joined #ruby
<MercutioX> Hi, all.
davedev24 has joined #ruby
yashinbasement has quit [Ping timeout: 264 seconds]
<Ox0dea> Hello, MercutioX.
robbyoconnor has joined #ruby
<Ox0dea> Nice comma. <3
davedev24 has quit [Remote host closed the connection]
blackmesa has quit [Ping timeout: 264 seconds]
guacamole has joined #ruby
davedev2_ has quit [Ping timeout: 250 seconds]
mjuszczak has quit [Client Quit]
choke has joined #ruby
davedev24 has joined #ruby
MercutioX has quit [Client Quit]
B1n4r10 has quit [Quit: Lost terminal]
mjuszczak has joined #ruby
futilegames has quit [Quit: futilegames]
<dpg_> Ox0dea: eh, I'm in a terminal. I can't click here.
whippythellama has joined #ruby
DEA7TH has quit [Quit: DEA7TH]
mjuszczak has quit [Client Quit]
blackgoat has joined #ruby
mjuszczak has joined #ruby
jpfuentes2 has quit [Quit: Textual IRC Client: www.textualapp.com]
<adaedra> Modern terms allow to clicks links nowadays.
jmignault has joined #ruby
ta_ has joined #ruby
ta_ has quit [Remote host closed the connection]
ta has quit [Read error: Connection reset by peer]
mary5030 has joined #ruby
mrgrieves has joined #ruby
<Ox0dea> Where "modern" means post-1995 or so.
<adaedra> (sssh.)
ta has joined #ruby
choke has quit [Ping timeout: 272 seconds]
gambl0re has joined #ruby
lucasb has quit [Quit: leaving]
<mrgrieves> hi, how can I split a string where I have "more" than a single space?
<ljarvis> mrgrieves: split takes 2 params
<Ox0dea> mrgrieves: How do you mean?
<ljarvis> oh wait
<ljarvis> heh
<ljarvis> yeah, that's a better question
karapetyan has quit [Remote host closed the connection]
<ljarvis> anyway, probably \s{2,}
choke has joined #ruby
<Ox0dea> >> "foo \s\t\n bar \s\t\n baz".split # mrgrieves
<ruboto> Ox0dea # => ["foo", "bar", "baz"] (https://eval.in/498301)
karapetyan has joined #ruby
* ljarvis read as "only more than 1 single space"
<Ox0dea> #split without an argument splits on runs of whitespace.
<mrgrieves> i.e. "something like this should be splitted" => ['something like', 'this should', 'be splitted']
<ljarvis> >> "something like this should be splitted".split /\s{2,}/
<ruboto> ljarvis # => ["something like", "this should", "be splitted"] (https://eval.in/498302)
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
webus_ has quit [Ping timeout: 246 seconds]
<mrgrieves> ljarvis: cheers!
<ljarvis> and yes you can write that regexp a million different ways
<ljarvis> before someone inevitably "fixes" it
<Ox0dea> Well, I was gonna golf it.
<Ox0dea> / +/
<Ox0dea> Looks scary, though.
<mrgrieves> thanks guys
<ljarvis> yeah i had that to start with, made me feel uncomfortable
kappy has quit [Quit: leaving]
nixmaniack has quit [Remote host closed the connection]
nixmaniack has joined #ruby
kappy has joined #ruby
uri_ has quit [Quit: --]
Xeago has joined #ruby
arup_r has quit []
sigurding has quit [Quit: sigurding]
kappy has quit [Client Quit]
choke has quit [Read error: Connection reset by peer]
kappy has joined #ruby
vroomvroomvroom has quit [Ping timeout: 252 seconds]
chadhs has joined #ruby
choke has joined #ruby
northfurr has quit [Quit: northfurr]
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
spooq has joined #ruby
uri_ has joined #ruby
celly has quit [Read error: Connection timed out]
aibot has quit [Ping timeout: 265 seconds]
shiver has quit [Ping timeout: 260 seconds]
baweaver has quit [Remote host closed the connection]
celly has joined #ruby
mustmodify has left #ruby [#ruby]
choke has quit [Read error: Connection reset by peer]
choke has joined #ruby
mary5030 has quit [Remote host closed the connection]
baweaver has joined #ruby
pdoherty has quit [Ping timeout: 264 seconds]
shadoi has joined #ruby
djbkd has joined #ruby
symm- has joined #ruby
Snowy has joined #ruby
rrichardsr3 has joined #ruby
SenpaiSilver has quit [Read error: Connection timed out]
freerobby has quit [Quit: Leaving.]
TrueDD has joined #ruby
chussenot has joined #ruby
<yorickpeterse> we're doing regex golf?
<yorickpeterse> clearly what you need here is a state machine
<yorickpeterse> directly in your ActiveRecord model
cmolenda has joined #ruby
Marsupermammal has quit [Quit: Textual IRC Client: www.textualapp.com]
Majora_ has quit [Ping timeout: 252 seconds]
minimalism has quit [Quit: minimalism]
tenderlove has joined #ruby
momomomomo has joined #ruby
bb010g has quit [Quit: Connection closed for inactivity]
<adaedra> and XML
Marsupermammal has joined #ruby
<yorickpeterse> Hey that shit's legit
<yorickpeterse> ask any Java dev
<adaedra> Nothing is complete without XML.
tenseiten has joined #ruby
rrichardsr3 has quit [Ping timeout: 260 seconds]
cmolenda has quit [Remote host closed the connection]
choke has quit [Read error: Connection reset by peer]
rrichardsr3 has joined #ruby
Porfa has quit [Ping timeout: 240 seconds]
rrichardsr3 has quit [Max SendQ exceeded]
choke has joined #ruby
rrichardsr3 has joined #ruby
JazzyVariable227 has joined #ruby
gregf has quit [Quit: WeeChat 1.3]
bkxd has joined #ruby
momomomomo has quit [Quit: momomomomo]
<shevy> ant files for the win
tenseiten has quit [Quit: "For a good time, try: 'curl -L http://bit.ly/10hA8iC | bash' ;)"]
JazzyVariable227 has quit [Ping timeout: 240 seconds]
wolffles has quit [Quit: wolffles]
ta has quit [Remote host closed the connection]
snockerton has joined #ruby
dpg_ has quit [Ping timeout: 240 seconds]
steffkes has quit [Ping timeout: 256 seconds]
bkxd has quit [Ping timeout: 265 seconds]
neanderslob has quit [Ping timeout: 265 seconds]
hanmac has quit [Ping timeout: 260 seconds]
neanderslob has joined #ruby
akem has joined #ruby
yfeldblum has joined #ruby
Marsupermammal has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
lemur has joined #ruby
chussenot has quit [Quit: chussenot]
Marsupermammal has joined #ruby
bkxd has joined #ruby
Marsupermammal has quit [Max SendQ exceeded]
<Ox0dea> yorickpeterse: Regular expressions *are* state machines.
ht__ has quit [Quit: Konversation terminated!]
lemur has quit [Ping timeout: 255 seconds]
<yorickpeterse> I'm aware of that
bluOxigen has quit [Ping timeout: 272 seconds]
bkxd has quit [Ping timeout: 250 seconds]
blackmesa has joined #ruby
Scoopfinder has joined #ruby
choke has quit [Read error: Connection reset by peer]
Jackneill has quit [Remote host closed the connection]
aegis3121 has quit [Ping timeout: 260 seconds]
yqt has joined #ruby
kirun has quit [Quit: Client exiting]
whippythellama has quit [Ping timeout: 250 seconds]
aadam21 has joined #ruby
gregf has joined #ruby
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
jgpawletko has quit [Quit: jgpawletko]
choke has joined #ruby
davedev2_ has joined #ruby
davedev24 has quit [Ping timeout: 260 seconds]
jbrhbr has joined #ruby
hanmac has joined #ruby
bensarz has quit [Quit: Textual IRC Client: www.textualapp.com]
ur5us has quit [Ping timeout: 250 seconds]
momomomomo has joined #ruby
DonOtreply has quit [Quit: DonOtreply]
jfo has quit [Remote host closed the connection]
rrichardsr3 has quit [Quit: Apparantly my attempt to stay awake has failed...]
mistermocha has quit [Remote host closed the connection]
bestbrents__ has joined #ruby
bmurt_ has joined #ruby
JDiPierro has quit [Remote host closed the connection]
blub` has joined #ruby
dravine_ has joined #ruby
infinitone_ has joined #ruby
renderf__ has joined #ruby
mistermocha has joined #ruby
diprotic has joined #ruby
diprotic has quit [Changing host]
diprotic has joined #ruby
zenspider_ has joined #ruby
blub has quit [Disconnected by services]
TomyLobo has quit [Disconnected by services]
fqulvqknpnwwaygt has joined #ruby
blackgoat_ has joined #ruby
fqulvqknpnwwaygt is now known as ddxopiyosxhcvjjk
blub` is now known as blub
ddxopiyosxhcvjjk is now known as TomyLobo
choke has quit [Read error: Connection reset by peer]
Rutix`away has joined #ruby
Rutix`away has quit [Changing host]
Rutix`away has joined #ruby
davedev24 has joined #ruby
peeja_ has joined #ruby
mistermocha has quit [Read error: Connection reset by peer]
MiracleBlue__ has joined #ruby
whippythellama has joined #ruby
angiebadillo_ has joined #ruby
peeja has quit [Ping timeout: 240 seconds]
zenspider has quit [Ping timeout: 240 seconds]
AckZ has quit [Ping timeout: 240 seconds]
avenj has quit [Ping timeout: 240 seconds]
BackEndCoder has quit [Ping timeout: 240 seconds]
catbusters has quit [Ping timeout: 240 seconds]
Amnez777 has quit [Ping timeout: 240 seconds]
jpinnix______ has quit [Ping timeout: 240 seconds]
Coraline has quit [Excess Flood]
ellistaa has quit [Ping timeout: 240 seconds]
agentmeerkat has quit [Ping timeout: 240 seconds]
render___ has quit [Ping timeout: 240 seconds]
NightMonkey has quit [Ping timeout: 240 seconds]
jmcc_____ has quit [Ping timeout: 240 seconds]
MiracleBlue_ has quit [Ping timeout: 240 seconds]
angiebadillo has quit [Ping timeout: 240 seconds]
valeri_ufo has quit [Read error: Connection reset by peer]
mistermocha has joined #ruby
jpinnix_______ has joined #ruby
mroth_ has joined #ruby
valeri_ufo has joined #ruby
cstrahan_ has joined #ruby
davedev2_ has quit [Ping timeout: 240 seconds]
blackgoat has quit [Ping timeout: 240 seconds]
Rutix has quit [Ping timeout: 240 seconds]
infinitone has quit [Ping timeout: 240 seconds]
monoprotic has quit [Ping timeout: 240 seconds]
Guest64162 has quit [Ping timeout: 240 seconds]
sjums has quit [Ping timeout: 240 seconds]
stuartb has quit [Ping timeout: 240 seconds]
Coraline has joined #ruby
angiebadillo_ is now known as angiebadillo
sjums has joined #ruby
bestbrents_ has quit [Ping timeout: 240 seconds]
bmurt has quit [Ping timeout: 240 seconds]
d0nn1e has quit [Ping timeout: 240 seconds]
dravine has quit [Ping timeout: 240 seconds]
skarn has quit [Ping timeout: 240 seconds]
tinnvec has quit [Ping timeout: 240 seconds]
jsrn has quit [Ping timeout: 240 seconds]
mroth has quit [Ping timeout: 240 seconds]
ElderFain has quit [Ping timeout: 240 seconds]
dravine_ is now known as dravine
Amnez777 has joined #ruby
Amnez777 has quit [Max SendQ exceeded]
podman has quit [Ping timeout: 240 seconds]
atumzin has quit [Ping timeout: 240 seconds]
alem0lars has quit [Ping timeout: 240 seconds]
cstrahan has quit [Ping timeout: 240 seconds]
ytti has quit [Ping timeout: 240 seconds]
mahk has quit [Ping timeout: 240 seconds]
tinnvec has joined #ruby
jmcc_____ has joined #ruby
atumzin has joined #ruby
atumzin has quit [Changing host]
atumzin has joined #ruby
marr has joined #ruby
Amnez777 has joined #ruby
Amnez777 has quit [Max SendQ exceeded]
bmurt_ has quit [Client Quit]
ytti has joined #ruby
sgambino_ has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
agentmeerkat has joined #ruby
djbkd has quit [Remote host closed the connection]
mroth_ is now known as mroth
Amnez777 has joined #ruby
Amnez777 has quit [Max SendQ exceeded]
gatman has quit []
symm- has quit [Quit: Leaving...]
Amnez777 has joined #ruby
gatman has joined #ruby
mostlybadfly has quit [Quit: Connection closed for inactivity]
baweaver has quit [Ping timeout: 260 seconds]
cstrahan_ is now known as cstrahan
podman has joined #ruby
gatman has quit [Client Quit]
d0nn1e has joined #ruby
stuartb has joined #ruby
stannard_ has quit [Remote host closed the connection]
mistermocha has quit [Ping timeout: 272 seconds]
smactive has joined #ruby
AckZ has joined #ruby
DarkBushido has joined #ruby
bmurt has joined #ruby
ElderFain has joined #ruby
BackEndCoder has joined #ruby
jsrn has joined #ruby
mahk has joined #ruby
minimalism has joined #ruby
ellistaa has joined #ruby
choke has joined #ruby
<ellistaa> i need to write an algorithm that takes an input and an expected output, like this 314159265358 = 27182 , and somehow makes combinations to the input using +,-,*,/ to get the output e.g. 3 + 1 - 415 * 92 + 65358 = 27182. looks like i have to try every combination but i’m not sure how to do that
scripore has joined #ruby
mic_e has quit [Ping timeout: 255 seconds]
<centrx> You want to redefine pi?
stannard has joined #ruby
<ellistaa> centrx i guess its for a coding challenge
catbusters has joined #ruby
ur5us has joined #ruby
<Scoopfinder> Hey, the question has already been asked here, but I was wondering if you could explain to me this snippet again (the comments might be wrong) : https://gist.github.com/RBdevelop/1059b866ce066e308d4b
sergey_makagon has joined #ruby
<Scoopfinder> The question has also been asked here, but the anwser was slightly different from what is written on the snippet (http://logs.ryanbigg.com/p/ruby-lang260)
framling has quit [Ping timeout: 240 seconds]
jam_ has joined #ruby
treehug88 has quit [Quit: Textual IRC Client: www.textualapp.com]
Coldblackice has joined #ruby
wprice has quit [Quit: wprice]
cschneid_ has joined #ruby
skarn has joined #ruby
<centrx> Scoopfinder, Looks like it just converts all the keys to symbols, kind of like Rails/ActiveSupport's Hash#deep_symbolize_keys
KingAbdullah has joined #ruby
Porfa has joined #ruby
celly has quit [Remote host closed the connection]
<Scoopfinder> centrx, Ox0de' said the same several months ago ^^ But the explanations in comment on the gist got me a bit confused
choke has quit [Read error: Connection reset by peer]
* apeiros actually said the same thing
mistermocha has joined #ruby
Snowy has quit [Read error: Connection reset by peer]
<Scoopfinder> oh apeiros, I did not see it ^^'
<ellistaa> does anyone know the equation to figure out how many combinations can be made with a ten digit number and 4 operators?
jam_ has quit [Ping timeout: 276 seconds]
<apeiros> actually said it even before Ox0dea…
rrichardsr3 has joined #ruby
<apeiros> the comments are your own?
Snowy has joined #ruby
<Scoopfinder> apeiros, nope nope I just found it while googling the function
<Ox0dea> apeiros: Hm?
<KingAbdullah> Beginner here, I want to make a program that asks a user for some input (Title and input body) and than saves it in some sort of file/database or even directly to the code. What am I looking for?
<adaedra> KingAbdullah: from a console?
<KingAbdullah> yes
<Ox0dea> apeiros: Disregard. I didn't notice the previous mention.
<adaedra> &ri gets KingAbdullah
<apeiros> KingAbdullah: Kernel#print, #puts, #gets (potentially $stdin.gets, though), File.write
<adaedra> Mh, ignore `derpy, got the wrong method.
<apeiros> adaedra: I thought you core > stdlibbed?
<Ox0dea> I think KingAbdullah is looking for something like {,G,S,Y}DBM.
nixmaniack has quit [Remote host closed the connection]
Snowy_ has joined #ruby
djbkd has joined #ruby
<apeiros> KingAbdullah: I'd go trying to save to a db only once you managed to save to a file$
<adaedra> apeiros: `ri gets` returns CSV's gets before core's one apparently ¯\_(ツ)_/¯
<apeiros> -$
rrichard_ has joined #ruby
<apeiros> shame on the ri then!
Snowy has quit [Read error: Connection reset by peer]
<adaedra> indeed.
<adaedra> I have to look at how I can fix that, because it looks fixable.
<adaedra> hop, to the to-do list.
Snowy has joined #ruby
<KingAbdullah> Apeiros I know how to save to file but I want to be able to search it for a title and bring up the included body text
choke has joined #ruby
centrx has quit [Quit: If you meet the Buddha on the road, kill him.]
<Ox0dea> KingAbdullah: A Hash, then.
<Ox0dea> Which can be serialized to disk quite easily.
rrichard_ has quit [Max SendQ exceeded]
<adaedra> What's wrong with the db already?
<KingAbdullah> Ah in middle of learning about Hash, So it can write it right into the file as a hash?
brunto has joined #ruby
<apeiros> KingAbdullah: we don't know what you know unless you tell us. if you say beginner, I assume you don't know.
alem0lars has joined #ruby
<apeiros> KingAbdullah: see YAML
<adaedra> KingAbdullah: there are serializations formats to do that (json, yaml, xml, ...)
rrichard_ has joined #ruby
rrichardsr3 has quit [Ping timeout: 250 seconds]
sandstrom has quit [Quit: My computer has gone to sleep.]
mary5030 has joined #ruby
Snowy_ has quit [Ping timeout: 245 seconds]
chadhs has quit [Quit: Textual IRC Client: www.textualapp.com]
Snowy has quit [Read error: Connection reset by peer]
ronplastic has quit []
Dimik has joined #ruby
Snowy has joined #ruby
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Xeago has quit [Remote host closed the connection]
momomomomo has quit [Ping timeout: 260 seconds]
<ellistaa> how can i access op which is coming from line 5 https://gist.github.com/ellismarte/5f47f6a859db6a5afd03#file-calc-rb-L9
gambl0re has quit [Ping timeout: 240 seconds]
dstarh has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sergey_makagon has quit []
<ellistaa> i tried .to_sym
aggiejosh06 has quit [Quit: Page closed]
barajasfab has quit [Quit: Leaving]
volty has joined #ruby
pietr0 has quit [Ping timeout: 260 seconds]
stannard has quit [Remote host closed the connection]
akem has quit [Remote host closed the connection]
<adaedra> Question to people with the knowledge: When doing &ri gets, should Kernel#gets or IO#gets be the first result?
pdoherty has joined #ruby
mistermo_ has joined #ruby
phutchins has quit [Read error: Connection reset by peer]
barajasfab has joined #ruby
<Ox0dea> ellistaa: Line 5 contains lots of invalid syntax.
<ellistaa> Ox0dea: how do i put operators in an array?
<ellistaa> can i add them as strings and turn them into operators when i need them?
jottr has joined #ruby
KingAbdullah has quit [Ping timeout: 252 seconds]
<Ox0dea> ellistaa: You'll want to use #send to dynamically invoke them, and that accepts the method name as either a String or a Symbol.
pietr0 has joined #ruby
<Ox0dea> >> 17.send '+', 25
<ruboto> Ox0dea # => 42 (https://eval.in/498318)
choke has quit [Ping timeout: 272 seconds]
<Ox0dea> They really should be Symbols, though.
<adaedra> public_send*
<ellistaa> Ox0dea: thanks
<Ox0dea> >> %i[+ - * /] # ellistaa
<ruboto> Ox0dea # => [:+, :-, :*, :/] (https://eval.in/498319)
justinmcp has joined #ruby
mistermo_ has quit [Ping timeout: 245 seconds]
bkxd has joined #ruby
choke has joined #ruby
aadam21 has quit [Remote host closed the connection]
karapetyan has quit [Remote host closed the connection]
zenlot has quit [Ping timeout: 256 seconds]
karapetyan has joined #ruby
zenlot has joined #ruby
Xeago has joined #ruby
mustmodify has joined #ruby
ur5us has quit [Remote host closed the connection]
bkxd has quit [Ping timeout: 250 seconds]
ur5us has joined #ruby
whippythellama has quit [Ping timeout: 240 seconds]
mjuszczak has quit []
ChameleonSix4 has joined #ruby
ChameleonSix4 has left #ruby [#ruby]
karapetyan has quit [Ping timeout: 260 seconds]
Vertroa has joined #ruby
chris2 has quit [Ping timeout: 245 seconds]
jmignault has quit [Ping timeout: 276 seconds]
BTRE has joined #ruby
ur5us has quit [Ping timeout: 260 seconds]
dlitvak has quit [Remote host closed the connection]
ur5us has joined #ruby
TomPeed has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
choke has quit [Ping timeout: 272 seconds]
phutchins has joined #ruby
Vertroa has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
krobzaur has quit [Ping timeout: 272 seconds]
BSaboia has joined #ruby
f00dMonsta_ has joined #ruby
rrichard_ has quit [Quit: Apparantly my attempt to stay awake has failed...]
Melpaws has joined #ruby
Scoopfinder has quit [Quit: *pouf*]
hobodave has quit [Quit: Computer has gone to sleep.]
choke has joined #ruby
Vertroa has joined #ruby
agentmeerkat has quit [Ping timeout: 264 seconds]
<shevy> adaedra hmm is one an alias to the other?
chris2 has joined #ruby
Vertroa has quit [Client Quit]
baweaver has joined #ruby
toretore has quit [Ping timeout: 260 seconds]
f00dMonsta__ has quit [Ping timeout: 240 seconds]
Xentil has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
dhollinger has quit [Quit: WeeChat 1.3]
whippythellama has joined #ruby
gusTester has left #ruby [#ruby]
gambl0re has joined #ruby
konr has quit [Quit: Connection closed for inactivity]
ur5us has quit [Remote host closed the connection]
klingeldraht has quit [Ping timeout: 250 seconds]
ur5us has joined #ruby
hxegon has joined #ruby
DonOtreply has joined #ruby
stamina has quit [Quit: WeeChat 1.3]
nerfando has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
scripore has quit [Quit: This computer has gone to sleep]
ur5us has quit [Read error: No route to host]
ur5us_ has joined #ruby
peeja_ has quit [Ping timeout: 265 seconds]
Highsen has quit [Ping timeout: 276 seconds]
klingeldraht has joined #ruby
DonOtreply has quit [Quit: DonOtreply]
choke has quit [Ping timeout: 272 seconds]
RegulationD has quit [Remote host closed the connection]
ellistaa has quit [Quit: ellistaa]
mjuszczak has joined #ruby
DonOtreply has joined #ruby
ur5us_ has quit [Ping timeout: 246 seconds]
saneax_AFK is now known as saneax
guacamol_ has joined #ruby
saneax is now known as Guest73286
guacamol_ has quit [Client Quit]
guacamol_ has joined #ruby
choke has joined #ruby
scripore has joined #ruby
guacamole has quit [Ping timeout: 240 seconds]
DonOtreply has quit [Ping timeout: 260 seconds]
Ishido has quit [Remote host closed the connection]
<kspencer> Does anyone here work with json/etc apis where I can dump output from a script into a json string
TomyLobo has quit [Ping timeout: 264 seconds]
peeja has joined #ruby
m8 has quit [Quit: Sto andando via]
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
pawnbox has joined #ruby
baweaver has quit [Read error: Connection reset by peer]
last_staff has joined #ruby
DonOtreply has joined #ruby
Xeago has quit [Remote host closed the connection]
f00dMonsta__ has joined #ruby
BTRE has quit [Quit: Leaving]
pawnbox has quit [Ping timeout: 250 seconds]
bestbrents__ has quit [Quit: Leaving]
f00dMonsta_ has quit [Ping timeout: 245 seconds]
<hxegon> kspencer not sure what you mean
f00dMonsta__ has quit [Ping timeout: 240 seconds]
[Butch] has quit [Quit: I'm out . . .]
mistermocha has quit [Remote host closed the connection]
choke has quit [Ping timeout: 272 seconds]
cmolenda has joined #ruby
last_staff has quit [Read error: Connection reset by peer]
mistermocha has joined #ruby
choke has joined #ruby
wald0 has quit [Quit: Changing server]
whippythellama has quit [Quit: WeeChat 1.3]
<kspencer> hxegon: I have a ruby web script, but want to be able to also call it via something to bring the info into another program, say cinch or w/e bot and have it output it but formatted, and the easiest way to format is to go by use heirarchy, which involves serialization
chipotle has quit [Quit: cheerio]
dlitvak has joined #ruby
<mustmodify> kspencer: OOOOOOooooohkkkkkkkkkkk
spider-mario has quit [Remote host closed the connection]
<mustmodify> wowza
<mustmodify> YOu want to do some AJAXy kind of stuff?
mistermocha has quit [Ping timeout: 240 seconds]
volty has quit [Quit: Konversation terminated!]
moei has quit [Quit: Leaving...]
wldcordeiro has quit [Ping timeout: 240 seconds]
brunto has quit [Ping timeout: 240 seconds]
<kspencer> more api kind of stuff, think cloudflare api and its responses, you could format that, but I want to format my hierarchy of my uptime script
<mustmodify> ok
<mustmodify> so you want an API
<mustmodify> what's your question?
mistermocha has joined #ruby
<mustmodify> I'm guessing it's "How do I do that."
<Ox0dea> kspencer: Er, are you asking how to parse JSON with Ruby?
mary5030 has quit [Remote host closed the connection]
<kspencer> right now I have it outputting html, I want it to output json
last_staff has joined #ruby
<mustmodify> kspencer: and is this Rails?
uri_ has quit [Quit: --]
<kspencer> not made with rails persay but its apache+passenger+sinatra
<kspencer> i say that because I didn't use rails as a command to build the 'app'
<Ox0dea> kspencer: Could you clarify how it is you're displaying a Hash as HTML?
peeja has quit [Ping timeout: 255 seconds]
<mustmodify> so you need to detect the request type and then say, "If they are requesting HTML, render this view. If they are requesting JSON, spit out JSON."
moei has joined #ruby
<kspencer> right mustmodify, but given my script I need to know how to set up the heirarchy, and yes I will gist the code
blackmesa has quit [Ping timeout: 256 seconds]
baweaver has joined #ruby
Ebok has joined #ruby
ruby[bot] has joined #ruby
houhoulis has joined #ruby
choke has quit [Ping timeout: 272 seconds]
freerobby has joined #ruby
choke has joined #ruby
<kspencer> mustmodify: Ox0dea hxegon https://gist.github.com/anonymous/7b95f6df52cf7d90b97d
ruby[bot] has left #ruby [#ruby]
davzie has joined #ruby
<davzie> Are there any frameworks out there, for a relative Ruby beginner (not a programming beginner) that would be a good fit for a REST API?
celly has joined #ruby
<davzie> Rails seems like overkill for this task, but again, I lack experience and perspective.
cmolenda has quit [Read error: Connection reset by peer]
<mustmodify> ACK! SSH.exec! in your views...
<mustmodify> at least it's hard coded.
<mustmodify> I'm pretty sure that's in a file somewhere that you can read.
<mustmodify> instead of doing SSH.exec!
<hxegon> davzie sinatra
<mustmodify> Oh I see. Net::SSH
<mustmodify> so you ... geez.
<Ox0dea> kspencer: Right, you'll need to parse the output of `uptime`, stick the results in a Hash, and then you'll be able to call #to_json on that.
baweaver has quit [Ping timeout: 255 seconds]
cmolenda has joined #ruby
<davzie> hxegon: Thanks H-man
<mustmodify> Yeah, create an UptimeReport class. Then UptimeReport.new.to_hash
<hxegon> davzie no prob, D
cmolenda has quit [Read error: Connection reset by peer]
ur5us has joined #ruby
<kspencer> the uptime i can fix with different commands, was more the 'type' and 'server' sections i don't know how to work in
ellistaa has joined #ruby
cmolenda has joined #ruby
projer has joined #ruby
dlitvak_ has joined #ruby
cmolenda has quit [Read error: Connection reset by peer]
cmolenda has joined #ruby
<Ox0dea> kspencer: Just stick those in the Hash as well.
Yzguy has joined #ruby
pdoherty has quit [Ping timeout: 240 seconds]
dlitvak has quit [Ping timeout: 250 seconds]
rodfersou has joined #ruby
justinmcp has quit [Remote host closed the connection]
firstdayonthejob has quit [Ping timeout: 246 seconds]
justinmcp has joined #ruby
<projer> In ruby, can I leave implementation of a base method to the child class, while calling it in the parent would call the child? Something similar to the template method pattern
ta has joined #ruby
<Ox0dea> projer: You sure can.
<projer> Ox0dea: a better question would be how, and it is it in some way an anti pattern in ruby, because from what I read on stackoverflow it isn't used that often in the Ruby community
choke has quit [Ping timeout: 272 seconds]
BTRE has joined #ruby
celly has quit [Remote host closed the connection]
<Ox0dea> projer: Well, consider Enumerable, for instance. It asks only that a subclass implement #each, and then it piggy-backs on that to provide a plethora of other functionality.
dlitvak_ has quit [Remote host closed the connection]
choke has joined #ruby