apeiros_ changed the topic of #ruby to: Ruby 2.1.2; 2.0.0-p481; 1.9.3-p545: http://ruby-lang.org || Paste >3 lines of text on http://gist.github.com || this channel is logged at http://irclog.whitequark.org, other public logging is prohibited
<csmrfx> java libraries
spastorino has joined #ruby
sepp2k has quit [Ping timeout: 260 seconds]
<ari-_-e> Sigma00: \n is 0xA
<Sigma00> ah, thanks for that
<ari-_-e> and \r is 0xD
<atmosx> shevy: block likes lambdas?
Hanmac has quit [Ping timeout: 265 seconds]
<Sigma00> ari-_-e is right on the money, you need value to be non-greedy
<shevy> atmosx I think in javascript you can call a function only in the way it was defined, you can't pass a block to it
timonv has quit [Ping timeout: 260 seconds]
Fire-Dragon-DoL has quit [Quit: Leaving.]
<atmosx> shevy: I see
mikepack has joined #ruby
<atmosx> shevy: I've no idea, I picked my book from amazon
<atmosx> and now I'm looking at it, seems pretty straight forward
<atmosx> it's a huge one btw
bradhe has quit [Ping timeout: 240 seconds]
Kryptonical has quit [Read error: Connection reset by peer]
jhulten has joined #ruby
<atmosx> I need 2 ruby books to match this one, hm but I think it's so big becuase of the reference material
<csmrfx> which book was that?
<shevy> "rails for pr0n-starters"
<atmosx> I didn't go through chapter 10 of the rails book
<atmosx> blah
<csmrfx> it is a good javascript book, ime
vali has quit [Ping timeout: 240 seconds]
<csmrfx> even teaches how to implement classes in js
<atmosx> yeah, seems like a complete ref
<csmrfx> lel
<atmosx> csmrfx: you read it?
<csmrfx> yup
<atmosx> cool, what do you programmer?
<csmrfx> or, did the examples
LACP has quit [Ping timeout: 240 seconds]
<csmrfx> I learneded ecma 5
sivoais has quit [Ping timeout: 260 seconds]
mikepack has quit [Ping timeout: 276 seconds]
<csmrfx> teh ecmascript reference is a good read after that
<atmosx> out of curiosity
stnly has quit [Ping timeout: 276 seconds]
<havenwood> Dart
<atmosx> say you need to write a website, with a database, etc. Can you do that without looking at any reference/online resource at all?
dc has quit []
<atmosx> I mean is tht ever evn possible
<tectonic> "I want to build a website but I don't want to learn anything"?
<csmrfx> well curiosity, and also, did tons of little ecma web stuff
mikesplain has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<atmosx> tectonic: nah, I know the shit out of all I wanna use
<ari-_-e> atmosx: no
aantix has quit [Quit: aantix]
<ari-_-e> atmosx: there's no point in rote memorization when you can look things up
<atmosx> :-( I had the feeling that at some point I'll stop searching 'how to do this and how to do that'
<ari-_-e> you'll often wind up remembering some things just because you use them a lot
<ari-_-e> well, the things you look up will get more complex
<atmosx> yeah, like today after the 5th I didn't have to check out the views... I knew what worked and what not.
<csmrfx> at this point complexity is still increasing
<atmosx> but if I don't work on my code for 4 days, it's gone
r0bby has quit [Remote host closed the connection]
<ari-_-e> atmosx: you'll find that you remember concepts, but you might not remember the name of a specific method or something like that
r0bby has joined #ruby
<atmosx> objects in JS are hashes in ruby? hehe
<ari-_-e> not quite
<sdegutis> ruby hashes are more like swift dictionaries
<ari-_-e> objects in JS can only have string keys
<havenwood> i think Ruby copied this Swift lang
<sdegutis> havenwood: heavily
<tectonic> lol
blackgoat has joined #ruby
<atmosx> havenwood: swift is extremely slow apparently, but must be a breeze for iOs programmers
<apeiros> what's this "ruby" you speak of?
<sdegutis> atmosx: swift is slow? says who?
GriffinHeart has joined #ruby
lw has quit [Quit: s]
<atmosx> sdegutis: stackoverflow
dc has joined #ruby
<sdegutis> atmosx: link or it didnt happen
<atmosx> sdegutis: really?
yubrew has joined #ruby
shiggity__ has joined #ruby
<atmosx> sdegutis: hope didn't hurt your feelings ;-)
blackgoat has quit [Client Quit]
<sdegutis> atmosx: oh no im crushed
* sdegutis goes back to reading Make: Electronics
<atmosx> sdegutis: I feel you. You can still use objective-c.
fif has joined #ruby
<sdegutis> atmosx: nevarrr
<sdegutis> atmosx: c.f. https://github.com/sdegutis/phoenix
<Channel6> sweet Zombie Jesus Rails is amazing
<Channel6> why did I not get on this bandwagon earlier?
<sdegutis> Channel6: :(
<atmosx> sdegutis: interesting
<Channel6> sadface?
<atmosx> Channel6: good question. Try the Go bandwagon, or the Julia or the Rust one... they are leaving right now.
r0bby has quit [Remote host closed the connection]
<sdegutis> Go bandwagon is gone.
Arkaniad|Laptop has joined #ruby
ahofmann has quit [Quit: Computer has gone to sleep.]
<sdegutis> Julia on its way out, Rust is still there and going strong.
<havenwood> Nimrod!
<sdegutis> Meanwhile I'm jumping back on the Lua bandwagon pretty much permanently.
<atmosx> prolog!
<shevy> brainfuck!
r0bby has joined #ruby
GriffinHeart has quit [Ping timeout: 245 seconds]
<havenwood> Ruby is downright popular, our bandwagon became a metropolis.
lewix has joined #ruby
<sdegutis> Tried the Scheme bandwagon (in its modern incarnation as Clojure) and its pretty okay, but its dependence on (or "JS" "JVM") is just too much.
<havenwood> sdegutis: chicken or racket!
<havenwood> ?
<sdegutis> havenwood: Ruby is for rockstars, but I've settled down in life.
yubrew has quit [Ping timeout: 252 seconds]
maestrojed has quit [Quit: Computer has gone to sleep.]
<sdegutis> That said, I did just write a new project in Ruby the other day.
<ari-_-e> rust hasn't even stabilized yet, has it?
<atmosx> sdegutis: found a girlfriend?
<havenwood> ari-_-e: no
benzrf|offline is now known as benzrf
blackgoat has joined #ruby
<sdegutis> I'm very happy with the new tests I wrote, after scrapping my last test suite.
<havenwood> it appears that rust is going to land on being a programming language, but maybe a bit early to say
<ari-_-e> pretty crazy to even be talking about a "bandwagon" before the language stops changing on you without notice
blackgoat has quit [Client Quit]
<havenwood> ari-_-e: seems that's the space bandwagons thrive in
dEPy has quit [Read error: Connection reset by peer]
<Channel6> Well, I'm enjoying myself with Ruby
<Channel6> And Rails, for that matter.
<ari-_-e> perhaps, but I mean that it'd be crazy to really use it for anything yet
<sdegutis> Channel6: okay now you're just trolling
oo_ has joined #ruby
<havenwood> sdegutis: ;)
<ari-_-e> I guess some people are just crazy
<Channel6> I'm certifiable.
<tectonic> crazy to use what?
<atmosx> haha
<havenwood> Channel6: Certifiable monad?
blackgoat has joined #ruby
<ari-_-e> tectonic: any programming language that hasn't had a single stable release yet
Doppp has quit [Quit: leaving]
apeiros has quit [Remote host closed the connection]
<Channel6> not entirely certain what that is
<tectonic> ah ari-_-e
<tectonic> yes
apeiros has joined #ruby
Sonja has joined #ruby
zorak has quit [Ping timeout: 252 seconds]
EatMulti has joined #ruby
ddv has quit [Ping timeout: 245 seconds]
OrionKissinger has joined #ruby
ddv has joined #ruby
Doppp has joined #ruby
shiggity__ has quit [Quit: shiggity__]
gaboesquivel has joined #ruby
OrionKissinger has quit [Ping timeout: 264 seconds]
<atmosx> san antonio vs miami started
<atmosx> bbl
shiggity__ has joined #ruby
mary5030 has quit [Remote host closed the connection]
oo_ has quit [Remote host closed the connection]
moritzschaefer has joined #ruby
cashnguns has quit [Remote host closed the connection]
zorak has joined #ruby
mary5030 has joined #ruby
cashnguns has joined #ruby
Doppp has quit [Quit: leaving]
kalusn has joined #ruby
<shevy> Channel6 what are you coding?
moritzs has quit [Ping timeout: 260 seconds]
<Channel6> I'm still learning Rails via the Rails for Zombies
<sonofflynn> can someone tell me why this script wouldn't be working to parse XML? Script - http://pastebin.com/JLyGmd1i XML - http://pastebin.com/Ti6xL04f
adammokan has joined #ruby
adammokan has quit [Max SendQ exceeded]
<crome> define wouldnt work
sivoais has joined #ruby
<sonofflynn> it's not giving the expected results
adammokan has joined #ruby
<sonofflynn> So, it parses nmap (a port scanner's output)
<sonofflynn> basically, it is supposed to find webservers based on the xml output
<sonofflynn> so it looks for a host, grabs its IP address, then looks for open ports with "http" or "https" in the port's "name" field
<sonofflynn> and then records it all, as long as that port is open, and not closed
<sonofflynn> the test xml is just three computers, with web servers on 80, 443, and 8443
<sonofflynn> I've tried changing some of the port's attribute to make the port "closed", but it doesn't seem to work
kalusn has quit [Ping timeout: 276 seconds]
datafirm has quit [Ping timeout: 276 seconds]
<sonofflynn> and right now, it's completely missing some IPs, and ports
<ari-_-e> sonofflynn: what output are you getting, and what would you expect?
binaryhat has joined #ruby
stnly has joined #ruby
sivoais has quit [Ping timeout: 252 seconds]
LACP has joined #ruby
tectonic has quit []
<sonofflynn> right now, it's printing to the screen, that's how I'm trying to debug. It'll print a computers IP address and the port that has http or https in its name as long as it is open.
<sonofflynn> but it's missing some IPs and Ports
<ari-_-e> could you paste the output
<ari-_-e> ?
<sonofflynn> sure, just didn't want to flood the channel
<sonofflynn> one sec..
<ari-_-e> not in the channel...
<shiggity__> pastebin or something
<ari-_-e> use pastebin, like you did before
<sonofflynn> well, it's only one line
<sonofflynn> IP: Port: 443 and port is closed! and uses https://!
<sonofflynn> that's it
<ari-_-e> ok
<sonofflynn> so, it's clearly missing the IP, and only found one port, and it's printing the "closed" one
oo_ has joined #ruby
<sonofflynn> which 443 is open, not closed
<sonofflynn> so I'm not sure how/where this is going wrong
Vivekananda has quit [Quit: Ex-Chat]
vali has joined #ruby
<EatMulti> I'd just chuck in a ton of debug puts statements in
Vivekananda has joined #ruby
lethe has joined #ruby
<shiggity__> do it
<shiggity__> maximum verbosity
<shevy> it's the simplest way of testing!
<sonofflynn> true that
<shiggity__> word
shiggity__ is now known as shiggityjoe
<ari-_-e> sonofflynn: I'd also advise that you simplify this a bit - for example, the blocks of code starting at lines 60 and 68 seem to be almost identical
<EatMulti> was thinking about unit testing that... but nah. p and puts
<sonofflynn> true, they are very similar
sivoais has joined #ruby
<shiggityjoe> ah yes. looks like it’s same process just depends on whether http or https
<sonofflynn> this is more of a PoC, not necessarily the final cleaned up code
<sonofflynn> just trying to figure out how to get it working first
<ari-_-e> for me, this sort of cleanup sometimes makes causes or problems more obvious
<ari-_-e> that's why I suggest it at this stage
<ari-_-e> *causes of
<sonofflynn> ok, that's fair
bradhe has joined #ruby
<ari-_-e> or at least allows me to more easily comprehend what's happening
<ari-_-e> it'll also remove some of that nesting :)
<shiggityjoe> i knew your program looked familiar
<sonofflynn> yes
<sonofflynn> ha
<sonofflynn> So, the main reason, I'm not using the nmap parser as suggested
<sonofflynn> is because first, I want to learn how to do this
<shiggityjoe> sure
<sonofflynn> but second, I will also have to support another xml file, which doesn't have it's own gem
moritzschaefer has quit [Ping timeout: 276 seconds]
mercerist has quit [Quit: Computer has gone to sleep.]
<sonofflynn> so, I'm going to have to learn it at that point anyways, so just figured I might as well learn it right from the beginning
<shiggityjoe> hey man, write what you wanna write :)
<sonofflynn> I'm trying to teach myself ruby by porting my python program to ruby. It was going well, until I hit this xml parsing...
<sonofflynn> yup
semtex-h has quit []
<ari-_-e> sonofflynn: could I see the python program?
<sonofflynn> sure
<sonofflynn> one sec..
<shevy> sssz szshshShsh zszshs
bradhe has quit [Ping timeout: 240 seconds]
thomasxie has joined #ruby
<sonofflynn> that's the start of the xml parsing function, but that is also the entire script
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
thomasxie has quit [Read error: Connection reset by peer]
thomasxie has joined #ruby
EatMulti has quit [Quit: leaving]
benzrf is now known as benzrf|offline
thomasxie has quit [Remote host closed the connection]
<ari-_-e> sonofflynn: any reason you're using SAX in the ruby version?
binaryhat has quit [Quit: Leaving]
<sonofflynn> Because the XML files could potentially be massive, and didn't want to do DOM where it loads it completely in memory
<ari-_-e> hmm ok
<sonofflynn> it should be changed in python as well
vali has quit [Ping timeout: 240 seconds]
LACP has quit [Ping timeout: 240 seconds]
oo_ has quit [Remote host closed the connection]
sivoais has quit [Ping timeout: 240 seconds]
sivoais has joined #ruby
LACP has joined #ruby
<shevy> shshsssyessssss
io_syl has joined #ruby
io_syl has quit [Client Quit]
lewix has quit [Remote host closed the connection]
amclain has quit [Quit: Leaving]
Wolland has joined #ruby
vali has joined #ruby
<shevy> hmm
<shevy> what is the opposite of .reject!
<havenwood> shevy: a date
<shiggityjoe> select! ??
<shevy> hmm
<havenwood> shevy: i like #keep_if and #delete_if
<havenwood> shevy: as they modify the receiver without returning `nil` on no match
<shiggityjoe> isnt keep_if like an alias for select! ?
<shevy> huh
<havenwood> shiggityjoe: nope
oo_ has joined #ruby
yfeldblu_ has quit [Read error: Connection reset by peer]
<shiggityjoe> ok thought maybe it was
<havenwood> shiggityjoe: close, but different behavior when no match
<shiggityjoe> gotcha
yfeldblum has joined #ruby
yubrew has joined #ruby
<shevy> if I have something like an array:
fif has quit [Quit: Page closed]
lemur has joined #ruby
<shevy> array = ['/abc/def','/abc/df','/abc/ef']
brandonblack has quit [Ping timeout: 240 seconds]
<shevy> and now I have a variable that is so: foo = '*ef*'
<shevy> hmm
<shevy> lost my train of thought
<shiggityjoe> turning foo into regex?
<shevy> I would kinda like to do something like a Dir.glob, but against that array
OrionKissinger has joined #ruby
charliesome has joined #ruby
<shevy> so the first and last entry would match but not the middle one
<Wolland> do you want to support full regex?
<shevy> only the '*' character
<shevy> as in meaning "all before can be valid" and "all afterwards can be valid"
bmurt has quit []
<shevy> like *ef*
<Wolland> select_if can do that
<shiggityjoe> (.*)ef(.*)
<crome> are those some sort of ascii tits
<shiggityjoe> [.*]ef[.*]
<Wolland> with include?('ef')
yubrew has quit [Ping timeout: 240 seconds]
<shiggityjoe> member:identifier:wolland wouldn’t include? look for the array item equal to ‘ef’, not for a string including it?
<shiggityjoe> i thought there is a string include? and an array include?
<ari-_-e> shevy: File#fnmatch
OrionKissinger has quit [Ping timeout: 264 seconds]
<shevy> hmm
<ari-_-e> err, File.fnmatch
<shiggityjoe> if you iterate over the array and you can do include?, otherwise it will look for an exact matching array item if run on the array itself
<ari-_-e> or Pathname#fnmatch
lemur has quit [Ping timeout: 240 seconds]
tkuchiki has joined #ruby
<Wolland> shevy: array.keep_if{|item| item.include?('ef')}
<Wolland> will that work?
<Wolland> essentially *es*
<shiggityjoe> bueno
<shevy> Wolland hehe
<shevy> Wolland that's what I do right now; only problem is ... what to do if someone gives only one '*'
Photism has quit [Quit: Leaving]
<shiggityjoe> ends_with ?
<shiggityjoe> isn’t that a thing?
<Wolland> starts_with, ends_with
<Wolland> nm, that's rails
badhatter has joined #ruby
<Wolland> or use regex
bmurt has joined #ruby
badhatter has quit [Changing host]
badhatter has joined #ruby
robustus has quit [Ping timeout: 264 seconds]
benzrf|offline is now known as benzrf
scx has quit [Ping timeout: 245 seconds]
<ari-_-e> shevy: I think fnmatch would work, but it also supports a bunch of other stuff... is that a problem?
robustus has joined #ruby
<Wolland> shevy: array.select{ |i| i[/ef/] }
benlieb has quit [Quit: benlieb]
<Wolland> just derive at that regex from *ef vs *ef*, etc
SCommette has joined #ruby
benlieb has joined #ruby
<shevy> ari-_-e don't think it would be a problem, I really only need support for the abovementioned array check, like array = ['/abc/def','/abc/df','/abc/ef'] and input would be '*ef*'; support for '*ef' or 'ef*' additionally would be nice, but currently for my own use case I only need '*xyz*' support; I am using ruby to search for certain files, but I keep it all stored in a rather complicated array which can get
<shevy> modified by several different methods
<shevy> Wolland hmm
<shevy> let me think
<shevy> Wolland I would need more than one regex or?
bennylope has joined #ruby
drizz has quit [Remote host closed the connection]
<Wolland> starts with, ends with, and includes
<Wolland> I am guessing
<Wolland> ideal would be to take *ef and convert it into starts with ef regex
sidik has joined #ruby
<Wolland> basically sub ending * with $ for example
<Wolland> >> ["/abc/def", "/aef/df", "/abc/ef"] .select{ |i| i[/ef$/] }
<eval-in> Wolland => ["/abc/def", "/abc/ef"] (https://eval.in/159900)
unixpro1970 has joined #ruby
<Wolland> middle item not selected
<Wolland> >> ["/abc/def", "/aef/df", "/abc/ef"] .select{ |i| i[/ef/] }
<eval-in> Wolland => ["/abc/def", "/aef/df", "/abc/ef"] (https://eval.in/159901)
Hanmac1 has quit [Ping timeout: 276 seconds]
bennylope has quit [Client Quit]
<Wolland> >> ["/abc/def", "/aef/df", "/abc/ef"] .select{ |i| i[/^ef/] }
<eval-in> Wolland => [] (https://eval.in/159902)
railzFor_ has quit [Ping timeout: 260 seconds]
<Wolland> so these are your 3 variations
cashnguns has quit [Remote host closed the connection]
starfox_21 has quit [Quit: starfox_21]
benlieb has quit [Quit: benlieb]
CodeBunny has quit [Quit: CodeBunny needs a carrot. Be back later.]
havenwood has quit [Remote host closed the connection]
<Wolland> just come up with string then convert it to regex
sidik has quit [Ping timeout: 245 seconds]
SCommette has quit [Quit: SCommette]
<Wolland> >> ["/abc/def", "/aef/df", "/abc/ef"] .select{ |i| i[%r"ef"] }
<eval-in> Wolland => ["/abc/def", "/aef/df", "/abc/ef"] (https://eval.in/159903)
scx has joined #ruby
Doppp has joined #ruby
jack_rabbit has joined #ruby
<Wolland> all you need to do is "*ef*" > "ef", "ef*" > "^ef", "*ef" > "ef$"
Sonja has quit []
<benzrf> Wolland: why use %r there
<benzrf> why not //
unixpro1970 has quit [Ping timeout: 265 seconds]
<Wolland> I am guessing whatever that regex going to be, it's going to be string
<Wolland> not Regexp
<benzrf> >> "abcdefg"['cd']
<eval-in> benzrf => "cd" (https://eval.in/159904)
<benzrf> e
<benzrf> >> "abcdefg"['cdf']
<eval-in> benzrf => nil (https://eval.in/159905)
<benzrf> eenteresting
<benzrf> >> s = "abcdefg"; s['cd'].clear
<eval-in> benzrf => "" (https://eval.in/159906)
<benzrf> >> s = "abcdefg"; s['cd'].clear; s
<eval-in> benzrf => "abcdefg" (https://eval.in/159907)
<benzrf> pfft
andrewjanssen has joined #ruby
Arkaniad|Laptop has quit [Ping timeout: 260 seconds]
<shiggityjoe> where do you host your rails projects?
<Wolland> digitalocean here
<shiggityjoe> i have cheap shared hosting, but can never get rails going on it. Looking for maybe a new host for rails only
<Wolland> linode as well
<shiggityjoe> ic
<Wolland> linode is now cheaper than DO
adammokan has left #ruby [#ruby]
<Wolland> and they have loadbalancing
<shiggityjoe> yeah i’ve heard good things about linode..
Hanmac has joined #ruby
bennylope has joined #ruby
bennylope has quit [Max SendQ exceeded]
r0bby has quit [Ping timeout: 276 seconds]
bmurt has quit []
timonv has joined #ruby
gaboesquivel has quit [Remote host closed the connection]
<benzrf> shiggityjoe: have you tried hammering the rails in
bradhe has joined #ruby
jkline has joined #ruby
<benzrf> :^)
<shiggityjoe> lol
<benzrf> 4chan6u
newvegas has quit [Read error: Connection reset by peer]
<shiggityjoe> heroku?
<benzrf> shiggityjoe: heroku is pretty sweet
<benzrf> also, mega overpriced
<shiggityjoe> ah
hostess has quit [Quit: ZNC - http://znc.sourceforge.net]
<benzrf> shiggityjoe: but their free tier may be enough for you
<benzrf> and you could always switch ;)
hamakn_ has quit [Remote host closed the connection]
<lethe> heroku is terribly slow in east asia
timonv has quit [Ping timeout: 245 seconds]
The_NetZ_ has joined #ruby
The_NetZ has quit [Ping timeout: 240 seconds]
bradhe has quit [Ping timeout: 245 seconds]
Deele has quit [Ping timeout: 260 seconds]
hostess has joined #ruby
Neomex_ has quit [Read error: Connection reset by peer]
<shevy> because there are so many ninjas in east asia
sputnik13 has quit [Remote host closed the connection]
sdouglas has joined #ruby
<ari-_-e> sorta ironic given the Japanese-sounding name
Zenigor has joined #ruby
thrownaway has joined #ruby
northfurr has joined #ruby
andrewjanssen has quit [Quit: Leaving...]
sdouglas has quit [Ping timeout: 240 seconds]
andrewjanssen has joined #ruby
andrewjanssen has quit [Client Quit]
GriffinHeart has joined #ruby
yubrew has joined #ruby
yfeldblum has quit [Ping timeout: 252 seconds]
hamakn has joined #ruby
yfeldblum has joined #ruby
brandonblack has joined #ruby
papercode has quit [Quit: WeeChat 0.4.3]
yubrew has quit [Ping timeout: 240 seconds]
GriffinHeart has quit [Ping timeout: 260 seconds]
braincra- has joined #ruby
shiggityjoe has quit [Quit: shiggityjoe]
jkline has quit [Quit: jkline]
ixti has quit [Ping timeout: 260 seconds]
mr123 has quit [Quit: Page closed]
maximski has joined #ruby
braincrash has quit [Ping timeout: 252 seconds]
gaboesquivel has joined #ruby
virtualize has quit []
zorak has quit [Ping timeout: 276 seconds]
dayepa has joined #ruby
virtualize has joined #ruby
Asher has quit [Quit: Leaving.]
aantix has joined #ruby
radic has quit [Ping timeout: 240 seconds]
radic has joined #ruby
yarou has joined #ruby
OrionKissinger has joined #ruby
Zenigor has quit [Remote host closed the connection]
yfeldblum has quit [Remote host closed the connection]
yfeldblum has joined #ruby
kyb3r_ has quit [Read error: Connection reset by peer]
zorak has joined #ruby
SCommette has joined #ruby
jkline has joined #ruby
krz has joined #ruby
postmodern has joined #ruby
kyb3r_ has joined #ruby
maximski has quit []
toretore has quit [Quit: This computer has gone to sleep]
phoo1234567 has quit [Quit: Leaving]
eka has quit [Quit: My computer has gone to sleep. ZZZzzz…]
<benzrf> @hoogle ByteString -> String
<benzrf> oops
OrionKissinger has quit [Remote host closed the connection]
NukePuppy has joined #ruby
bradhe has joined #ruby
jkline has quit [Quit: jkline]
Vivekananda has quit [Ping timeout: 240 seconds]
NukePuppy has quit [Ping timeout: 240 seconds]
bradhe has quit [Ping timeout: 240 seconds]
aspires has quit []
Vivekananda has joined #ruby
bbbthunda_ has joined #ruby
Arkaniad|Laptop has joined #ruby
Arkaniad has joined #ruby
Arkaniad has quit [Read error: Connection reset by peer]
BBBThunda has quit [Ping timeout: 240 seconds]
gaboesquivel has quit [Remote host closed the connection]
hermanmunster has quit [Remote host closed the connection]
gaboesquivel has joined #ruby
Zamerick has quit [Ping timeout: 240 seconds]
hermanmunster has joined #ruby
krz has quit [Ping timeout: 245 seconds]
frem_ has joined #ruby
pietr0 has joined #ruby
pietr0 has quit [Client Quit]
larsam has quit [Ping timeout: 252 seconds]
SCommette has quit [Quit: SCommette]
gaboesquivel has quit [Ping timeout: 260 seconds]
yubrew has joined #ruby
sdouglas has joined #ruby
LnL has quit [Read error: Connection reset by peer]
LnL_ has joined #ruby
Vivekananda has quit [Ping timeout: 245 seconds]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
drizz has joined #ruby
scx_ has joined #ruby
lemur has joined #ruby
yubrew has quit [Ping timeout: 260 seconds]
sdouglas has quit [Ping timeout: 240 seconds]
Vivekananda has joined #ruby
scx has quit [Ping timeout: 260 seconds]
j75 has joined #ruby
braincra- has quit [Quit: bye bye]
lemur has quit [Ping timeout: 260 seconds]
mattmcclure has quit [Quit: Connection closed for inactivity]
dapz has joined #ruby
abstrakt has quit [Quit: Leaving]
braincrash has joined #ruby
phinfonet has quit []
Avahey_ has joined #ruby
trhodes_ has quit [Ping timeout: 264 seconds]
tectonic has joined #ruby
krz has joined #ruby
kitak has joined #ruby
trhodes_ has joined #ruby
hermanmunster has quit [Remote host closed the connection]
hermanmunster has joined #ruby
aspires has joined #ruby
stevesmename has quit [Ping timeout: 252 seconds]
recurrence has joined #ruby
hermanmunster has quit [Ping timeout: 245 seconds]
recurrence has left #ruby [#ruby]
tectonic has quit []
Alina-malina has quit [Ping timeout: 240 seconds]
banisterone has quit [Ping timeout: 265 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Alina-malina has joined #ruby
banisterone has joined #ruby
bradhe has joined #ruby
timonv has joined #ruby
bradhe has quit [Ping timeout: 245 seconds]
timonv has quit [Ping timeout: 252 seconds]
katmandoo has quit [Ping timeout: 240 seconds]
banisterone has quit [Ping timeout: 265 seconds]
banisterone has joined #ruby
kalusn has joined #ruby
unixpro1970 has joined #ruby
kalusn has quit [Ping timeout: 252 seconds]
amargherio has quit [Read error: Connection reset by peer]
unixpro1970 has left #ruby ["unixpro1970 has off IRC"]
yubrew has joined #ruby
GriffinHeart has joined #ruby
krz has quit [Remote host closed the connection]
JokerDoomWork has quit [Ping timeout: 260 seconds]
yubrew has quit [Ping timeout: 260 seconds]
jack_rabbit has quit [Ping timeout: 260 seconds]
GriffinHeart has quit [Ping timeout: 265 seconds]
JokerDoomWork has joined #ruby
oo_ has quit [Remote host closed the connection]
sdouglas has joined #ruby
starfox_21 has joined #ruby
aspires has quit []
dopie has joined #ruby
<dopie> hey guys
brunops has quit [Ping timeout: 245 seconds]
<dopie> im writing a help file for ruby for myself
oo_ has joined #ruby
<dopie> just a few basic questions
<dopie> using single quotes is good for when instead of double quotes?
lewix has joined #ruby
St_Marx has quit [Ping timeout: 264 seconds]
shiggityjoe has joined #ruby
steeve has joined #ruby
steeve has quit [Client Quit]
steeve has joined #ruby
St_Marx has joined #ruby
<dopie> Lewix, !!!
JokerDoomWork has quit [Ping timeout: 260 seconds]
jack_rabbit has joined #ruby
toastynerd has joined #ruby
anaeem1_ has joined #ruby
Burgestrand has joined #ruby
oo_ has quit [Remote host closed the connection]
<The_NetZ_> dopie: when you need to do #{expansion} :P
bmurt has joined #ruby
jeregrine has quit [Quit: Connection closed for inactivity]
<dopie> The_NetZ_, well i can do a #{expansion} in double quotes
<The_NetZ_> erm, backwards read your thing, sorry. I don't know if it works in single quotes, I think it doesnt.
toretore has joined #ruby
charliesome has joined #ruby
datafirm has joined #ruby
toastynerd has quit [Remote host closed the connection]
bmurt has quit [Ping timeout: 240 seconds]
sdouglas has quit [Remote host closed the connection]
sdouglas has joined #ruby
<lewix> hi dopie
mary5030 has quit [Remote host closed the connection]
drizz has quit [Remote host closed the connection]
Asher has joined #ruby
sdouglas has quit [Ping timeout: 240 seconds]
jackal__ has joined #ruby
drizz has joined #ruby
Doppp has quit [Quit: leaving]
GriffinHeart has joined #ruby
JasmeetQA has joined #ruby
frem_ has quit [Ping timeout: 265 seconds]
bradhe has joined #ruby
yarou has quit []
oo_ has joined #ruby
bradhe has quit [Ping timeout: 245 seconds]
bluOxigen has joined #ruby
iliketurtles has joined #ruby
shiggityjoe has quit [Quit: shiggityjoe]
lewix has quit [Quit: Leaving...]
tkuchiki has quit [Remote host closed the connection]
tkuchiki has joined #ruby
Burgestrand has quit [Quit: Burgestrand]
predator217 has quit [Ping timeout: 260 seconds]
predator117 has joined #ruby
kalusn has joined #ruby
x1337807x has joined #ruby
yubrew has joined #ruby
stevesmename has joined #ruby
Deele has joined #ruby
toastynerd has joined #ruby
kalusn has quit [Ping timeout: 265 seconds]
yubrew has quit [Ping timeout: 240 seconds]
shiggityjoe has joined #ruby
<pontiki> single-quoted strings do no expansion
banisterone has quit [Ping timeout: 265 seconds]
vinleod has joined #ruby
jackal__ has quit [Quit: Leaving]
maletor has joined #ruby
Channel6 has quit [Quit: Leaving]
narcan has joined #ruby
niftylettuce_ has joined #ruby
datafirm has quit [Quit: Computer has gone to sleep.]
aganov has joined #ruby
datafirm has joined #ruby
brunops has joined #ruby
sepp2k1 has quit [Read error: Connection reset by peer]
datafirm has quit [Ping timeout: 265 seconds]
toastynerd has quit [Remote host closed the connection]
Doppp has joined #ruby
mercwithamouth has joined #ruby
iliketurtles has quit [Quit: zzzzz…..]
spastorino has quit [Quit: Connection closed for inactivity]
<dopie> mcast.net) has joined #ruby
<dopie> * toastynerd (~toastyner@c-174-61-223-12.hsd1.wa.comcast.net)
jhulten has quit [Read error: Connection reset by peer]
sdouglas has joined #ruby
lxsameer has joined #ruby
jhulten has joined #ruby
chipotle has joined #ruby
CodeBunny has joined #ruby
toastynerd has joined #ruby
toastynerd has quit [Remote host closed the connection]
maletor has quit [Quit: Computer has gone to sleep.]
vee has quit [Ping timeout: 240 seconds]
toastynerd has joined #ruby
toastynerd has quit [Read error: Connection reset by peer]
momomomomo has joined #ruby
wallerdev has quit [Quit: wallerdev]
aspires has joined #ruby
shiggityjoe has quit [Quit: shiggityjoe]
bradhe has joined #ruby
frem_ has joined #ruby
holmser has joined #ruby
timonv has joined #ruby
hermanmunster has joined #ruby
IceDragon has quit [Ping timeout: 245 seconds]
hermanmu_ has joined #ruby
frem_ has quit [Ping timeout: 245 seconds]
bradhe has quit [Ping timeout: 265 seconds]
hermanmunster has quit [Ping timeout: 240 seconds]
toastyne_ has joined #ruby
timonv has quit [Ping timeout: 276 seconds]
brunops has quit [Ping timeout: 245 seconds]
Lucky_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
vee has joined #ruby
benzrf is now known as benzrf|offline
jprovazn has joined #ruby
absolutezeroff has quit [Remote host closed the connection]
toastyne_ has quit [Ping timeout: 245 seconds]
atraylen has joined #ruby
garndt has quit [Quit: Connection closed for inactivity]
anaeem1_ has quit [Ping timeout: 260 seconds]
_justin has joined #ruby
mary5030 has joined #ruby
railzForDaiz has joined #ruby
whyy has joined #ruby
whyy has quit [Read error: Connection reset by peer]
whyy has joined #ruby
diegoviola has joined #ruby
toastynerd has joined #ruby
GriffinHeart has quit [Remote host closed the connection]
yubrew has joined #ruby
GriffinHeart has joined #ruby
mary5030 has quit [Ping timeout: 245 seconds]
anaeem1 has joined #ruby
yubrew has quit [Ping timeout: 260 seconds]
toastynerd has quit [Remote host closed the connection]
GriffinHeart has quit [Ping timeout: 252 seconds]
iliketurtles has joined #ruby
maestrojed has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
akonny has joined #ruby
Burgestrand has joined #ruby
Xeago has joined #ruby
mrnugget has joined #ruby
krz has joined #ruby
toastynerd has joined #ruby
Xeago has quit [Remote host closed the connection]
mr_snowf1ake has quit [Ping timeout: 240 seconds]
Xeago has joined #ruby
jack_rabbit has quit [Quit: Leaving]
ra4king has quit [Ping timeout: 240 seconds]
railzForDaiz has quit [Ping timeout: 245 seconds]
Avahey_ has quit [Quit: Connection closed for inactivity]
railzForDaiz has joined #ruby
Xeago has quit [Ping timeout: 276 seconds]
aspires has quit []
sdouglas has quit [Remote host closed the connection]
toastynerd has quit [Remote host closed the connection]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dangerousdave has joined #ruby
sdouglas_ has joined #ruby
relix has joined #ruby
sdouglas_ has quit [Ping timeout: 276 seconds]
alem0lars has joined #ruby
ndrei has joined #ruby
LexicalScope has joined #ruby
Photism has joined #ruby
brandonblack has quit [Ping timeout: 265 seconds]
george2 has quit [Ping timeout: 245 seconds]
sinkensabe has joined #ruby
brandonblack has joined #ruby
frem_ has joined #ruby
Vivekananda has quit [Remote host closed the connection]
bigkevmcd has joined #ruby
blackgoat has quit [Quit: WeeChat 0.3.8]
frem_ has quit [Ping timeout: 240 seconds]
blackgoat has joined #ruby
LexicalScope has quit [Ping timeout: 252 seconds]
GriffinHeart has joined #ruby
alem0lars has quit [Quit: alem0lars]
ra4king has joined #ruby
bluOxigen has quit []
eagles0513875_ has joined #ruby
<eagles0513875_> hey all :)
bigkevmcd has quit [Ping timeout: 252 seconds]
<eagles0513875_> im looking at the rub on rails website and i am wondering how does ruby deal with website creation in terms of responsive design.
<mozzarella> #rubyonrails
bigkevmcd has joined #ruby
NukePuppy has joined #ruby
mrnugget has quit [Quit: mrnugget]
GriffinHeart has quit [Ping timeout: 260 seconds]
steeve has quit [Ping timeout: 252 seconds]
lethe has quit []
lethe has joined #ruby
charliesome has joined #ruby
<eagles0513875_> mozzarella whats the difference between ruby and rails?
lethe has quit [Client Quit]
lethe has joined #ruby
<ari-_-e> eagles0513875_: ruby is a programing language
<ari-_-e> rails is a web development framework written in ruby
<ari-_-e> this channel is about ruby
hamakn_ has joined #ruby
hamakn has quit [Read error: Connection reset by peer]
<eagles0513875_> ari-_-e: :D im interested in ruby for a project im working on
<eagles0513875_> my question now becomes does one compile the ruby application into a binary to run it
<ari-_-e> nope
<ari-_-e> ruby is an interpreted language
yubrew has joined #ruby
<eagles0513875_> ok
NukePuppy has quit [Ping timeout: 252 seconds]
<ari-_-e> I guess things like jruby do something that you could consider compiling
<ari-_-e> it's usually strictly interpreted though
<eagles0513875_> ok
ponga has joined #ruby
ponga has quit [Changing host]
ponga has joined #ruby
eagles0513875_ has quit [Quit: Page closed]
lethe has quit []
lethe has joined #ruby
yubrew has quit [Ping timeout: 252 seconds]
lethe is now known as nyamx2
Xeago has joined #ruby
<arrubin> Ruby is as compiled as Java in most cases.
<arrubin> There is just not a separate compilation step.
railzForDaiz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<arrubin> Different implementations and versions work slightly differently though.
aantix has quit [Quit: aantix]
why_away has joined #ruby
<arrubin> MRI 1.8 is pretty much interpreted.
<arrubin> 1.9 is compiled to bytecode and then run on an internal VM.
<arrubin> Rubinius does the same.
<arrubin> JRuby, as far as I understand, actually does run interpreted and then JIT compiles to JVM bytecode, which can then be JIT compiled to native code.
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<arrubin> I believe that Rubinius's VM can JIT to native code.
kalusn has joined #ruby
whyy has quit [Ping timeout: 260 seconds]
whyy_ has joined #ruby
<arrubin> And RubyMotion is compiled to native code.
steeve has joined #ruby
jhulten has quit [Remote host closed the connection]
why_away has quit [Ping timeout: 260 seconds]
kalusn has quit [Ping timeout: 260 seconds]
klaut has joined #ruby
ksinkar_ has quit [Quit: Konversation terminated!]
Xeago has quit [Ping timeout: 276 seconds]
duncannz has joined #ruby
jackneill has joined #ruby
akemrir has joined #ruby
zigomir has joined #ruby
DouweM has joined #ruby
iliketurtles has quit [Quit: zzzzz…..]
rghose1 has joined #ruby
claymore has joined #ruby
claymore has quit [Changing host]
claymore has joined #ruby
JensOfSweden has joined #ruby
<Burgestrand> dopie: your tab-character in front of each name
kilk_ has joined #ruby
<Burgestrand> dopie: it's considered the first character for capitalize
<dopie> Burgestrand, ha!
<dopie> ahhh ok
anarang has joined #ruby
JensOfSweden has left #ruby [#ruby]
JBreit has joined #ruby
skaflem has joined #ruby
lsmola_ has joined #ruby
hamakn has joined #ruby
brandonblack has quit [Ping timeout: 276 seconds]
hamakn_ has quit [Read error: Connection reset by peer]
ayaz has joined #ruby
<Hanmac> dopie: is the \t needed in the output?
<dopie> yeah
<dopie> i just moved it to the bottom
<dopie> puts "\t#{name1} #{health1} health"
noop has joined #ruby
hamakn has quit [Read error: Connection reset by peer]
arrubin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
hamakn has joined #ruby
<headius> no version of MRI does any JIT, so it's fair to say MRI is 100% interpreted
<Hanmac> headius: are you sure that the new one YARD that is used in ruby1.9+ isnt compiling to bytecode ?
<headius> compiling to bytecode doesn't mean you're not just interpreting the bytecode
bradhe has joined #ruby
<headius> interpreting means you have a piece of code that walks instructions of some kind and responds to them, rather than producing machine code for the CPU to handle
chipotle has quit [Quit: cya]
timonv has joined #ruby
<headius> YARV is an bytecode-based interpreted runtime, and it's unlikely they'll have a JIT any time soon
Spami has joined #ruby
Xeago has joined #ruby
Spami has quit [Read error: Connection reset by peer]
Spami has joined #ruby
bradhe has quit [Ping timeout: 240 seconds]
frem_ has joined #ruby
Hobogrammer has quit [Ping timeout: 240 seconds]
timonv has quit [Ping timeout: 252 seconds]
mupkoo has joined #ruby
dumdedum has joined #ruby
DouweM has quit [Ping timeout: 240 seconds]
frem_ has quit [Ping timeout: 252 seconds]
The_NetZ_ is now known as ntzrmtthihu777
ntzrmtthihu777 has quit [Changing host]
ntzrmtthihu777 has joined #ruby
GriffinHeart has joined #ruby
byteoverfl0w has joined #ruby
sinkensabe has quit [Remote host closed the connection]
sinkensabe has joined #ruby
charliesome has quit [Ping timeout: 276 seconds]
qba73 has joined #ruby
oo_ has quit [Remote host closed the connection]
oo_ has joined #ruby
yubrew has joined #ruby
iliketurtles has joined #ruby
dumdedum has quit [Ping timeout: 240 seconds]
chipotle has joined #ruby
renier has quit [Ping timeout: 252 seconds]
Eiam has quit [Ping timeout: 260 seconds]
sinkensabe has quit [Ping timeout: 240 seconds]
sinkensabe has joined #ruby
yubrew has quit [Ping timeout: 245 seconds]
ponga has quit []
renier has joined #ruby
pranny has joined #ruby
chipotle has quit [Quit: cya]
dapz has quit [Quit: Textual IRC Client: www.textualapp.com]
alem0lars has joined #ruby
TDJACR has quit [Ping timeout: 260 seconds]
Joulse has joined #ruby
maestrojed has quit [Quit: Computer has gone to sleep.]
alem0lars has quit [Client Quit]
alex88 has joined #ruby
lxsameer has quit [Ping timeout: 240 seconds]
dumdedum has joined #ruby
bluOxigen has joined #ruby
Hobogrammer has joined #ruby
Burgestrand has quit [Ping timeout: 245 seconds]
northfurr has quit [Quit: northfurr]
david__ has joined #ruby
david__ has quit [Max SendQ exceeded]
david__ has joined #ruby
mercwithamouth has quit [Ping timeout: 240 seconds]
varius has joined #ruby
isomorphismes has joined #ruby
steeve has quit [Ping timeout: 260 seconds]
Alina-malina has quit [Read error: Connection reset by peer]
<isomorphismes> I'm trying to do basically this: unless array.shift==nil { function(array.shift) }
<isomorphismes> I know that doesn't work because the unless is already shifting the array before the function shifts it
mikecmpbll has joined #ruby
<isomorphismes> Is there a way to do the assignment in the unless control statement? like unless a = array.shift == nil { function(a) }
steeve has joined #ruby
Alina-malina has joined #ruby
graspee has joined #ruby
<david__> resources for learning ruby??
railzForDaiz has joined #ruby
<isomorphismes> david__: I like the Ruby Koans
banisterone has joined #ruby
Alina-malina has quit [Read error: Connection reset by peer]
<Nilium_> I like sitting in a shell, staring into the black void of the console, occasionally typing in random experiments.
dels has joined #ruby
<isomorphismes> david__: You download a directory and edit each of the files in the directory. It's gamified
alem0lars has joined #ruby
apeiros has quit [Remote host closed the connection]
Alina-malina has joined #ruby
apeiros has joined #ruby
mikecmpbll has quit [Client Quit]
davedev24_ has quit [Remote host closed the connection]
claymore has quit [Ping timeout: 260 seconds]
davedev24_ has joined #ruby
<ari-_-e> isomorphismes: so you just want to check the first element?
<isomorphismes> ari-_-e: yes, I think so
<ari-_-e> then just check array[0]?
<isomorphismes> ariI actually thought of a fix: test for empty array instead of array.shift returning nil
<Nilium_> ary.shift.tap { |k| function(a) unless a.nil? }
klaut has quit [Remote host closed the connection]
<Nilium_> There's a fun way to write it so it's confusing
<isomorphismes> Nilium_: Is that supposed to be the confusing/fun way or you mean another one you didn't say yet?
jayne_ has joined #ruby
Dr3amc0d3r|away has quit [Ping timeout: 240 seconds]
AlexRussia has quit [Remote host closed the connection]
<Nilium_> There are plenty of ways to do what you're asking, assuming I understand the question
<Nilium_> I just don't see a reason to shorten it.
AlexRussia has joined #ruby
iliketurtles has quit [Quit: zzzzz…..]
<Nilium_> My cat is making squeaky noises while sleeping.
claymore has joined #ruby
<Hanmac> Nilium_: |k| should be replaced with |a| in your sample
<Nilium_> Ah, right, brainfart.
sk87 has joined #ruby
<Nilium_> Side-effect of 'k' being my go-to temporary.
jayne has quit [Read error: Connection reset by peer]
davedev24_ has quit [Ping timeout: 240 seconds]
mijicd has joined #ruby
jgrevich has joined #ruby
<isomorphismes> Nilium_: that was weird. The "tap" example seemed to eat two array elements at once.
<Nilium_> That is weird.
<isomorphismes> maybe typed something wrong. trying again..
whyy_ has quit [Remote host closed the connection]
<Nilium_> I wouldn't recommend using that method though.
cgj_ has joined #ruby
<isomorphismes> nvm
mateu has quit [Ping timeout: 240 seconds]
<isomorphismes> Nilium_: ok. why not?
<jgrevich> Souldn’t the channel title be updated for 1.9.3? (e.g. 545->547)
whyy has joined #ruby
<Nilium_> The sanest route is to just do a = ary.shift; function(a) unless a.nil?
<isomorphismes> Nilium_: is tap standard?
<Nilium_> Yes.
<isomorphismes> ok. I was trying to have unless work as a while loop.
<Nilium_> The likelihood that most people even know about it, though, is sort of low
mateu has joined #ruby
xiphias has quit [Ping timeout: 240 seconds]
<Nilium_> You mean `until COND ; things ; end`?
<isomorphismes> Exactly.
<Nilium_> So why not just write that?
<isomorphismes> unless ary.shift==nil { function(ary.shift) } uses up the front element
wookiehangover has quit [Ping timeout: 240 seconds]
<isomorphismes> in the conditional itself
xiphias has joined #ruby
rhys has quit [Ping timeout: 240 seconds]
<Nilium_> I'd say try not to get too fancy.
duncannz has quit [Ping timeout: 265 seconds]
akonny has quit [Quit: akonny]
aganov has quit [Ping timeout: 240 seconds]
cgj has quit [Ping timeout: 252 seconds]
<Nilium_> Future you will thank you (well, maybe whisper it, because future you is still going to curse past you and past you's ancestors for the code anyway)
<isomorphismes> unless Ary.shift.nil? { puts Ary.shift } #doesn't seem to loop
axilla has quit [Ping timeout: 252 seconds]
<apeiros> isomorphismes: any reason why you don't just use array.each do |item| func(item) ?
<isomorphismes> What's fancy about what I did?
mikecmpbll has joined #ruby
<Nilium_> Also, why the curly braces?
thrownaway has quit [Remote host closed the connection]
<apeiros> also do you really want to always skip one element?
<isomorphismes> I don't really speak Ruby.
drago777 has quit [Ping timeout: 240 seconds]
norm has quit [Ping timeout: 240 seconds]
<isomorphismes> apeiros: No I don't want to
thrownaway has joined #ruby
<isomorphismes> apeiros: ok that's a good idea
Doppp has quit [Quit: leaving]
<apeiros> isomorphismes: if you don't speak ruby, then you should ask how to solve a problem, not how to implement your solution
mgorbach has quit [Ping timeout: 240 seconds]
<isomorphismes> apeiros: let me try the array.each do |i| f(i) ..
<Nilium_> ary.each { |k| function(k) unless k.nil? }
whyy has quit [Ping timeout: 240 seconds]
ephemerian has joined #ruby
<isomorphismes> well I'm working on a langugae tutorial
<isomorphismes> so language details are what I'm really after
kies has quit [Read error: Connection reset by peer]
<Nilium_> Also bear in mind that {} is not a general scope thing
wookiehangover has joined #ruby
<isomorphismes> language mechanics
<isomorphismes> I'm not solving any real problems
rhys has joined #ruby
relix has quit [Ping timeout: 240 seconds]
gigetoo has quit [Ping timeout: 240 seconds]
<Nilium_> so whereas in C you'd have for(;;) {}, in Ruby you don't have that for basic loops.
<apeiros> tutorials which don't solve actual problems in their examples tend to suck
<apeiros> sorry if that's pretty blunt
Doppp has joined #ruby
davedev24_ has joined #ruby
Doppp has quit [Changing host]
Doppp has joined #ruby
<isomorphismes> apeiros: ruby koans is good
<Nilium_> Write a Lisp interpreter in Ruby.
<Nilium_> That'll be a fun exercise.
gigetoo has joined #ruby
<isomorphismes> I don't speak Lisp.
<isomorphismes> That sounds masochistic.
<apeiros> isomorphismes: anyway, even with that given, you do have an actual problem. an abstract problem is still a problem.
varius has quit [Ping timeout: 240 seconds]
psmolen has quit [Ping timeout: 240 seconds]
<Nilium_> Sounds like fun to me.
<Nilium_> Granted I'm also writing a virtual machine for fun, so…
psmolen has joined #ruby
_justin has quit [Quit: _justin]
bradhe has joined #ruby
<Nilium_> Different strokes.
<isomorphismes> It's probably fun for someone with the right knowledge base.
<apeiros> in your case, it sounds like "how do I iterate over an array", but I'm not sure because your suggested implementation of that problem is broken.
Doppp has quit [Client Quit]
drago777 has joined #ruby
<isomorphismes> ok
Dr3amc0d3r|away has joined #ruby
<isomorphismes> hold on let me play with your example apeiros
<isomorphismes> thanks both Nilium_ apeiros
mgorbach has joined #ruby
xiphias has quit [Ping timeout: 240 seconds]
<isomorphismes> so apeiros array.each do |i| f(i) # is the most idiomatic?
gogiel_ has joined #ruby
Photism has quit [Ping timeout: 240 seconds]
gogiel has quit [Ping timeout: 240 seconds]
xiphias has joined #ruby
kies has joined #ruby
bbbthunda_ has quit [Ping timeout: 260 seconds]
varius has joined #ruby
<graspee> seeking to be idiomatic has the potential to stifle innovation
relix has joined #ruby
ghr has quit []
jayne_ is now known as jayne
<isomorphismes> apeiros: The reason I was using array.shift is, I guess, because I only need to go through the aray once, so I don't mind (even it's good to) killing elements each time.
ghr has joined #ruby
marr has joined #ruby
shellox has joined #ruby
<shellox> hi
<isomorphismes> hi shellox
noop has quit [Ping timeout: 240 seconds]
cgj_ has quit [Quit: leaving]
bradhe has quit [Ping timeout: 265 seconds]
<isomorphismes> apeiros: So if I do array.each do { |i| i=peano(i) } it doesn't seem to actually ++ the elements of the array. This is a pass-by-value thing maybe?
noop has joined #ruby
<Hanmac> isomorphismes: you want to get a new array in return? use map
drager has quit [Ping timeout: 240 seconds]
steeve has quit [Remote host closed the connection]
<shellox> I've got this gemfile and installed the gems with bundler. After the installation i tried in irb require 'supply_drop'
<apeiros> isomorphismes: you ask about an aspect of your code but don't show the relevant code - how am I supposed to answer?
<Nilium_> graspee: I doubt basic idioms like looping over an array are in severe need of innovation
<shellox> but it returned an error and cannot load the file
<shellox> when i type gem list
drager has joined #ruby
hpoydar has joined #ruby
<shellox> i can't find the gem
<shellox> why is that?
<apeiros> isomorphismes: how about you show your actual code and desired result?
<isomorphismes> apeiros: what do you want to see? def peano(x) { x+1 }
<shellox> is it because the gem was installed from github
<apeiros> isomorphismes: x+1 does not modify x. and integers can't be modified anyway.
axilla_ has joined #ruby
xiphias has quit [Ping timeout: 240 seconds]
<apeiros> isomorphismes: variables have only one operation: assignment. everything else happens on the objects themselves.
<isomorphismes> apeiros: ary = [1,2,3]; def peano(x) { x+1 }; ary.each do { |i| i=peano(i) }
<apeiros> isomorphismes: assigning to i does not change the array
<apeiros> >> ary = [1,2,3]; def peano(x) x+1 end; ary.map { |i| peano(i) }
<eval-in> apeiros => [2, 3, 4] (https://eval.in/160014)
<isomorphismes> apeiros: eval-in oh awesome!
<Nilium_> isomorphismes: What are you trying to do specifically?
<Nilium_> i.e., not asking how to fix the code, but just describe the data and what you want to do with it.
<isomorphismes> Nilium_: I'm just working through this tutorial. It's the ruby koans about_scoring_project.rb.
<apeiros> isomorphismes: and you did it again - you didn't ask how to solve your problem. you wanted us to fix your suggested implementation.
<apeiros> you'll get bad answers that way.
<isomorphismes> apeiros: sorry I don't understand what you mean
r0bby has joined #ruby
<isomorphismes> apeiros: your answer made perfect sense
<Nilium_> As a general rule, when asking programming questions, figure out what the data is and what you want to do with the data without thinking too much in terms of code.
Takle has joined #ruby
whyy has joined #ruby
<isomorphismes> Nilium_: I'm sorry I don't understand what you mean by that.
<isomorphismes> I'm just trying to learn how the language works
why_away has joined #ruby
<isomorphismes> there is no problem to solve
mgorbach has quit [Ping timeout: 240 seconds]
<isomorphismes> these have been really helpful answers
<Nilium_> Just read the post.
<apeiros> isomorphismes: an abstract problem *still is a problem*
<isomorphismes> Nilium_: I did
axilla_ has quit [Ping timeout: 240 seconds]
XenoWolf has quit [Ping timeout: 240 seconds]
drago777 has quit [Ping timeout: 240 seconds]
renier has quit [Ping timeout: 240 seconds]
<Nilium_> You cannot have possible read both the question and answer in less than a minute
<Nilium_> *possibly
<apeiros> "I want to have an array with the result of a method applied to each element in an existing array" is an abstract problem
hpoydar has quit [Ping timeout: 265 seconds]
XenoWolf has joined #ruby
<apeiros> "I solve it by manually iterating and assigning stuff to variables" is a suggested implementation. and you asked about a part of that implementation "why doesn't assigning stuff to variables change my array".
axilla has joined #ruby
kies has quit [Remote host closed the connection]
mgorbach has joined #ruby
<apeiros> but in an idiomatic solution, that's not even part of the implementation.
<apeiros> see the example irc dialog in Nilium_'s link (first answer)
<isomorphismes> apeiros: What's the idiomatic solution?
<isomorphismes> first comment on second answer -- says these Q's are not necessarily bad. I don't feel I've received unhelpful answers, just the opposite
renier has joined #ruby
<apeiros> for the abstract problem I formulated? the map code I showed you above.
<isomorphismes> ok cool thanks
<Nilium_> As a suggestion, look at the Array class reference, the Hash class reference, and the Enumerable module reference
Takle has quit [Remote host closed the connection]
<isomorphismes> those are over my head
AndChat|102836 has joined #ruby
<Nilium_> They'll probably be easier to read than you think
<isomorphismes> I've tried to read them before
drago777 has joined #ruby
Kruppe has quit [Ping timeout: 240 seconds]
xiphias has joined #ruby
xiphias has joined #ruby
xiphias has quit [Changing host]
Spami has quit [Quit: This computer has gone to sleep]
Takle has joined #ruby
whyy has quit [Ping timeout: 276 seconds]
mercwithamouth has joined #ruby
yubrew has joined #ruby
kies has joined #ruby
banisterone has quit [Ping timeout: 260 seconds]
<isomorphismes> Nilium_: You're talking about ri Array #correct?
gigetoo has quit [Read error: Connection reset by peer]
Gadgetoid has quit [Ping timeout: 240 seconds]
<Nilium_> Well, not necessarily through ri (I've never used it), but that's the documentation
<Nilium_> Meant using something more like ruby-doc.org ⇒ http://www.ruby-doc.org/core-2.1.2/Array.html
Gadgetoid has joined #ruby
<Nilium_> For readability's sake.
dilated_dinosaur has joined #ruby
gigetoo has joined #ruby
<Nilium_> I also like that you can view the source code for stuff by clicking on it, but that's only useful when you've really gone insane.
xiphias has quit [Ping timeout: 240 seconds]
<isomorphismes> oh ok they're different
drago777 has quit [Ping timeout: 240 seconds]
ClarusCogitatio has quit [Ping timeout: 240 seconds]
nomadic has quit [Ping timeout: 240 seconds]
<apeiros> I nowadays usually just use ? and $ from within pry.
<isomorphismes> Nilium_: the web one is the one i've looked at before. ri is readable but very short. the web one is super long
spider-mario has joined #ruby
<isomorphismes> apeiros: oh cool
<apeiros> isomorphismes: the web one is exactly the one from ri
<Nilium_> ri only displays documentation for the specific thing you requested.
<apeiros> just differently formatted
yubrew has quit [Ping timeout: 260 seconds]
<Nilium_> So you won't get all the instance/class method docs in the same view.
Kruppe has joined #ruby
<isomorphismes> apeiros: sorry, I'm new -- ?Array; $Array; ?$Array don't pull it up in pry. What's the command exactly?
<apeiros> isomorphismes: for core classes, you need to install pry-doc
<apeiros> `? Array#concat` for example
Kruppe is now known as Guest80807
<apeiros> or `? Time.at`
<apeiros> .at is a class method, #concat an instance method
andrewlio has joined #ruby
<Nilium_> Oddly enough, that doesn't work in Pry for me.
<Nilium_> *pry
<Nilium_> I suspect pry's just confused as all hell.
nomadic has joined #ruby
Shidash has quit [Ping timeout: 265 seconds]
<apeiros> Nilium_: as said, install pry-doc
<isomorphismes> oh this is nice. So you cd Array; ls; ? Array#& or any of the methods listed in the ls
<Nilium_> I don't use it, so I'll pass
<apeiros> Nilium_: it can't display core docs otherwise because it doesn't have the source to it
<Nilium_> Dash is my documentation god
<apeiros> meh
<apeiros> switching apps for docs
mijicd has quit [Remote host closed the connection]
<apeiros> but to each its own, I guess
thoolihan has quit [Ping timeout: 240 seconds]
drago777 has joined #ruby
willgorman has quit [Ping timeout: 240 seconds]
yeticry has quit [Ping timeout: 240 seconds]
willgorman has joined #ruby
dideler|work has quit [Ping timeout: 240 seconds]
<Nilium_> I'm not writing code in pry, so I'm switching apps for something or another
dideler|work has joined #ruby
shtirlic has quit [Ping timeout: 240 seconds]
yeticry has joined #ruby
xiphias has joined #ruby
lxsameer has joined #ruby
rostam has quit [Read error: Connection reset by peer]
<isomorphismes> Nilium_: not sure I get what you mean by "ri only displays documentation for the specific thing you requested". So I requested ri Array #the stuff on the website IS about Array, no
railzForDaiz has quit [Ping timeout: 260 seconds]
zartoosh has joined #ruby
<isomorphismes> ?
shtirlic has joined #ruby
<isomorphismes> I don't know, I somehow thought there was a command-line access to all the smae information as this website.
thoolihan has joined #ruby
<isomorphismes> local, rather.
Xuerian has quit [Ping timeout: 240 seconds]
<Nilium_> It is the same documentation, it just doesn't display all of it at once.
ktun has joined #ruby
<Nilium_> If you specify a class name, it displays the class description. If you specify an instance method for a class, it displays the instance method description.
railzForDaiz has joined #ruby
ktun has quit [Client Quit]
PanPan has joined #ruby
ClarusCogitatio has joined #ruby
elaptics`away is now known as elaptics
Hanmac1 has joined #ruby
ReggieMan has joined #ruby
<isomorphismes> thanks everyone. thanks Nilium_ apeiros Hanmac
<isomorphismes> thanks ari-_-e
Xuerian has joined #ruby
Guest80807 has quit [Ping timeout: 240 seconds]
lxsameer has quit [Ping timeout: 260 seconds]
mercwithamouth has quit [Ping timeout: 245 seconds]
Wolland has quit []
Hanmac has quit [Ping timeout: 252 seconds]
<ReggieMan> Can anyone recommend JRuby over Rubinius or vice versa? Those two because they both have JIT compilers. I had no doubt about Python before I found out Python 3 doesn't have a JIT compiler.
Veidit has quit [Remote host closed the connection]
Veidit has joined #ruby
steeve has joined #ruby
timonv has joined #ruby
jcp has joined #ruby
Takle_ has joined #ruby
<headius> ReggieMan: I can, but I'm biased... JRuby (or really, JVM) is a far more mature and high-perfomance runtime
<ReggieMan> Hmm. I'll see if anyone else has anything to say.
Hanmac has joined #ruby
timonv has quit [Ping timeout: 240 seconds]
_justin has joined #ruby
xiphias has quit [Ping timeout: 240 seconds]
xiphias has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
xiphias has quit [Changing host]
xiphias has joined #ruby
chth0n has joined #ruby
Hanmac1 has quit [Ping timeout: 245 seconds]
ta has quit [Ping timeout: 240 seconds]
benlieb has joined #ruby
sawtooth has quit [Ping timeout: 240 seconds]
ta has joined #ruby
<ReggieMan> I plan on getting into Java one day, but I don't think that's a good reason to base my decision on. I plan on using it for Minecraft modding, anyway.
sawtooth has joined #ruby
Takle has quit [Ping timeout: 260 seconds]
jcp is now known as Guest9568
drago777 has joined #ruby
steeve has quit [Ping timeout: 260 seconds]
willgorman has quit [Ping timeout: 240 seconds]
Hobogrammer has quit [Ping timeout: 260 seconds]
<Nilium_> Wow, my cat is apparently so tired he didn't even bother moving from my desk to my chair.
<Nilium_> This is good. Means no crazy running around at 4am.
kalusn has joined #ruby
AndChat|102836 has quit [Read error: Connection reset by peer]
ziyadb has joined #ruby
willgorman has joined #ruby
marr has quit [Ping timeout: 260 seconds]
kalusn has quit [Ping timeout: 240 seconds]
david__ has quit [Quit: Leaving]
steeve has joined #ruby
andrewlio has quit [Quit: Leaving.]
xiphias has quit [Ping timeout: 240 seconds]
xiphias has joined #ruby
xiphias has quit [Changing host]
xiphias has joined #ruby
mercerist has joined #ruby
decoponio has joined #ruby
mupkoo has quit []
mercwithamouth has joined #ruby
Raboo_ has joined #ruby
axilla has quit [Ping timeout: 260 seconds]
jgrevich has quit [Quit: jgrevich]
nfk has joined #ruby
Raboo has quit [Ping timeout: 240 seconds]
Raboo_ is now known as Raboo
Guest9568 has quit [Ping timeout: 240 seconds]
xiphias has joined #ruby
xiphias has joined #ruby
xiphias has quit [Ping timeout: 240 seconds]
drago777 has quit [Ping timeout: 240 seconds]
gregf_ has quit [Ping timeout: 240 seconds]
chipotle has joined #ruby
gregf_ has joined #ruby
Doppp has joined #ruby
Slavox is now known as Slavox|AFK
axilla has joined #ruby
chipotle has quit [Client Quit]
momomomomo has quit [Quit: momomomomo]
Kruppe- has joined #ruby
bradhe has joined #ruby
drago777 has joined #ruby
akonny has joined #ruby
klaut has joined #ruby
chipotle has joined #ruby
shvelo has joined #ruby
chipotle has quit [Client Quit]
jhulten has joined #ruby
<atmosx> morning
obs has joined #ruby
AlSquire has joined #ruby
klaut has quit [Remote host closed the connection]
chipotle has joined #ruby
chipotle has quit [Client Quit]
wm3|away has joined #ruby
xiphias has quit [Ping timeout: 240 seconds]
willgorman has quit [Ping timeout: 240 seconds]
willgorman has joined #ruby
musl_ has quit [Ping timeout: 240 seconds]
bradhe has quit [Ping timeout: 260 seconds]
drago777 has quit [Ping timeout: 240 seconds]
chipotle has joined #ruby
chipotle has quit [Client Quit]
BizarreCake has joined #ruby
dc has quit [Remote host closed the connection]
jhulten has quit [Ping timeout: 260 seconds]
scx has joined #ruby
scx_ has quit [Ping timeout: 245 seconds]
DouweM has joined #ruby
dc has joined #ruby
<shvelo> Ahoy
<shvelo> what do we do with the drunken sailor early in the morning?
chipotle has joined #ruby
<ReggieMan> Come back to bed, Captain.
<atmosx> why all live in a yellow submarine
<atmosx> hahaha
emsilva has quit [Quit: Keep Walking (Computer Slept!)]
lkba has quit [Ping timeout: 260 seconds]
<Hanmac> shvelo: remove him from the pc so he does not to try to make rails apps
<shvelo> lol
railzForDaiz has quit [Ping timeout: 240 seconds]
akonny has quit [Quit: akonny]
emsilva has joined #ruby
malcolmva has quit [Ping timeout: 240 seconds]
drago777 has joined #ruby
Kruppe- has quit [Ping timeout: 240 seconds]
drago777 has quit [Ping timeout: 240 seconds]
willgorman has joined #ruby
willgorman has quit [Ping timeout: 240 seconds]
chipotle has quit [Client Quit]
shvelo has quit [Quit: Leaving]
yubrew has joined #ruby
chipotle has joined #ruby
xiphias has joined #ruby
chipotle has quit [Client Quit]
Azure_ has joined #ruby
starfox_21 has quit [Quit: starfox_21]
chipotle has joined #ruby
drago777 has joined #ruby
rotor has quit [Ping timeout: 240 seconds]
carraroj has joined #ruby
willgorman has quit [Ping timeout: 240 seconds]
jxf has quit [Ping timeout: 240 seconds]
benlieb has quit [Quit: benlieb]
Azure has quit [Ping timeout: 240 seconds]
malcolmva has joined #ruby
xiphias has quit [Ping timeout: 240 seconds]
yubrew has quit [Ping timeout: 260 seconds]
Takle_ has quit [Remote host closed the connection]
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
railzForDaiz has joined #ruby
Atttwww has quit [Ping timeout: 252 seconds]
rotor has joined #ruby
klaut has joined #ruby
duncannz has joined #ruby
chipotle has quit [Quit: cya]
newUser1234 has quit [Remote host closed the connection]
hermanmu_ has quit [Remote host closed the connection]
Kruppe has joined #ruby
willgorman has joined #ruby
chipotle has joined #ruby
hgl has quit [Ping timeout: 265 seconds]
drago777 has quit [Ping timeout: 240 seconds]
Nilium_ has quit [Remote host closed the connection]
Kruppe is now known as Guest90739
rdark has joined #ruby
keen________ has quit [Ping timeout: 240 seconds]
drago777 has joined #ruby
hgl has joined #ruby
mityaz has quit [Ping timeout: 252 seconds]
hgl has quit [Max SendQ exceeded]
willgorman has quit [Ping timeout: 240 seconds]
hgl has joined #ruby
chipotle has quit [Client Quit]
xiphias has joined #ruby
chipotle has joined #ruby
duncannz has quit [Quit: Leaving]
rotor has quit [Ping timeout: 240 seconds]
XenoWolf has quit [Ping timeout: 260 seconds]
rotor has joined #ruby
chipotle has quit [Client Quit]
willgorman has joined #ruby
charliesome has joined #ruby
Platini has quit [Ping timeout: 240 seconds]
pranny has quit [Quit: Leaving.]
moritzschaefer has joined #ruby
FIGO_ has joined #ruby
yacks has quit [Ping timeout: 245 seconds]
timonv has joined #ruby
xiphias has quit [Ping timeout: 240 seconds]
yacks has joined #ruby
hakunin_ has joined #ruby
musl_ has joined #ruby
FIGO_ is now known as Platini
niftylettuce_ has quit [Quit: Connection closed for inactivity]
blaxter has joined #ruby
XenoWolf has joined #ruby
oo__ has joined #ruby
sk87 has joined #ruby
rotor has quit [Ping timeout: 240 seconds]
Takle has joined #ruby
hamakn_ has joined #ruby
mehlah has quit [Quit: Leaving...]
keen________ has joined #ruby
mityaz has joined #ruby
willgorman has quit [*.net *.split]
PhilK has quit [*.net *.split]
Guest90739 has quit [*.net *.split]
hakunin has quit [*.net *.split]
dumdedum has quit [*.net *.split]
hamakn has quit [*.net *.split]
oo_ has quit [*.net *.split]
drago777 has quit [*.net *.split]
lxsameer has joined #ruby
timonv has quit [Remote host closed the connection]
timonv has joined #ruby
PhilK has joined #ruby
rghose1 has quit [Ping timeout: 240 seconds]
rghose1 has joined #ruby
gazz101_ has joined #ruby
gazz101_ has left #ruby [#ruby]
emsilva has quit [Quit: Keep Walking (Computer Slept!)]
ReggieMan has quit [Remote host closed the connection]
chipotle has joined #ruby
hermanmunster has joined #ruby
Guest42887 has quit [Quit: Guest42887]
drago777 has joined #ruby
chipotle has quit [Client Quit]
ndrei has quit [Ping timeout: 260 seconds]
chipotle has joined #ruby
rotor has joined #ruby
railzForDaiz has quit [Ping timeout: 276 seconds]
shvelo has joined #ruby
chipotle has quit [Client Quit]
chipotle has joined #ruby
near77 has joined #ruby
jcp has joined #ruby
willgorman has joined #ruby
pranny has joined #ruby
<shvelo> I don't like the hash syntax
jcp is now known as Guest41835
<Morrolan> That's unfortunate.
chipotle has quit [Client Quit]
hermanmunster has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
aganov has joined #ruby
hermanmunster has joined #ruby
shellox has left #ruby [#ruby]
ndrei has joined #ruby
<ari-_-e> shvelo: what about it?
<shvelo> =>
<shvelo> why not :
xiphias has joined #ruby
<ari-_-e> because perl
<ari-_-e> also, there's a new syntax which does use :
<ari-_-e> >> {a: 1, b: 2}
<eval-in> ari-_-e => {:a=>1, :b=>2} (https://eval.in/160072)
<shvelo> kool
<ari-_-e> it's nice if your keys are symbols
pranny has quit [Ping timeout: 260 seconds]
<Morrolan> And a syntax error otherwise. (:
JokerDoomWork has joined #ruby
Karunamon has quit [Ping timeout: 264 seconds]
<shvelo> btw Rspec is cool, any other testing frameworks I should try?
railzForDaiz has joined #ruby
GriffinHeart has quit [Remote host closed the connection]
hermanmunster has quit [Ping timeout: 252 seconds]
rghose1 has quit [Ping timeout: 260 seconds]
gbchaosmaster has quit [Ping timeout: 240 seconds]
Karunamon has joined #ruby
<shvelo> >> { :lel : "1", :kek : 3 }
<eval-in> shvelo => /tmp/execpad-1dc572ee1d86/source-1dc572ee1d86:2: syntax error, unexpected ':', expecting => ... (https://eval.in/160073)
yubrew has joined #ruby
ntzrmtthihu777 has quit [Quit: Leaving]
<shvelo> >> { lel : "1", kek : 3 }
<eval-in> shvelo => /tmp/execpad-3af65b2beb05/source-3af65b2beb05:2: syntax error, unexpected ':', expecting => ... (https://eval.in/160074)
<shvelo> >> { lel : "1", kek : "2" }
<eval-in> shvelo => /tmp/execpad-781e42b19c35/source-781e42b19c35:2: syntax error, unexpected ':', expecting => ... (https://eval.in/160075)
<shvelo> instructions unclear, dick stuck in toaster
doev has joined #ruby
rghose1 has joined #ruby
JokerDoomWork has quit [Ping timeout: 260 seconds]
mikepack has joined #ruby
railzForDaiz has quit [Ping timeout: 245 seconds]
<shvelo> >> require "rspec"
<eval-in> shvelo => (https://eval.in/160077)
banister has quit [Ping timeout: 265 seconds]
andrewlio has joined #ruby
yubrew has quit [Ping timeout: 260 seconds]
gazz101_ has joined #ruby
postmodern has quit [Quit: Leaving]
dangerou_ has joined #ruby
<ari-_-e> shvelo: apparently there can't be spaces before the colons
<ari-_-e> sigh
chth0n has quit [Remote host closed the connection]
railzForDaiz has joined #ruby
GriffinHeart has joined #ruby
<near77> hi
<near77> anyone knows the rail channel ?
aagdbl has joined #ruby
<shvelo> btw I didn't know about binding until yesterday
gazz101_ is now known as gazz102
<shvelo> >> binding
<ari-_-e> near77: #rubyonrails
<eval-in> shvelo => #<Binding:0x40bba590> (https://eval.in/160079)
<near77> thanks!
<shvelo> >> binding == binding
alem0lars has quit [Quit: Going AFK...]
<eval-in> shvelo => false (https://eval.in/160080)
mikepack has quit [Ping timeout: 252 seconds]
<ari-_-e> shvelo: one cool use of binding is in "binding.pry"
<shvelo> >> binding.eval("a=1"); a
<eval-in> shvelo => undefined local variable or method `a' for main:Object (NameError) ... (https://eval.in/160081)
<ari-_-e> you can put that anywhere and it will start pry when that line is executed
dangerousdave has quit [Ping timeout: 276 seconds]
kyb3r_ has quit [Quit: Leaving]
<shvelo> wow cool
blueOxigen has joined #ruby
lkba has joined #ruby
<shvelo> I use binding for a shitty template engine
PanPan has quit [Quit: ChatZilla 0.9.90.1 [Firefox 29.0.1/20140506152807]]
bluOxigen has quit [Ping timeout: 265 seconds]
zigomir_ has joined #ruby
Takle has quit [Remote host closed the connection]
railzForDaiz has quit [Ping timeout: 252 seconds]
Hanmac1 has joined #ruby
railzForDaiz has joined #ruby
alem0lars has joined #ruby
alem0lars has quit [Client Quit]
zigomir has quit [Ping timeout: 260 seconds]
mehlah has joined #ruby
Hanmac has quit [Ping timeout: 252 seconds]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
xiella has quit [Read error: No route to host]
Takle has joined #ruby
joelio has quit [Ping timeout: 252 seconds]
bhaak is now known as octe`
octe` is now known as bhaak
Joulse has quit [Quit: Joulse]
relix has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
qba73 has quit []
banister has joined #ruby
banister has quit [Max SendQ exceeded]
pranny has joined #ruby
pranny1 has joined #ruby
pranny has quit [Read error: Connection reset by peer]
sinkensabe has quit [Remote host closed the connection]
dseitz has quit [Quit: Textual IRC Client: www.textualapp.com]
sinkensabe has joined #ruby
bluOxigen has joined #ruby
bluOxigen has quit [Changing host]
bluOxigen has joined #ruby
banister has joined #ruby
senayar has joined #ruby
zarubin has joined #ruby
sinkensabe has quit [Ping timeout: 276 seconds]
blueOxigen has quit [Ping timeout: 260 seconds]
wm3|away has quit [Quit: Lost terminal]
steeve has quit [Remote host closed the connection]
steeve has joined #ruby
<ari-_-e> >> nil.to_a
<eval-in> ari-_-e => [] (https://eval.in/160082)
<ari-_-e> ^ wat
maximski has joined #ruby
steeve has quit [Ping timeout: 252 seconds]
kalusn has joined #ruby
<banister> nil.to_proc
<banister> >> nil.to_proc
<eval-in> banister => undefined method `to_proc' for nil:NilClass (NoMethodError) ... (https://eval.in/160083)
<Morrolan> NilClass' #to_something methods tend to return empty or valueless things. *shrug*
GriffinHeart has quit [Remote host closed the connection]
<Morrolan> Empty strings, arrays, hashes, zero
<ari-_-e> is there an actual use case for that?
<Morrolan> Haven't exactly found a use for it, tbh.
<banister> ari-_-e what did u expect taht to do bb
<ari-_-e> seems stupid to me
<Morrolan> I'd probably prefer an exception.
<ari-_-e> yeah
<ari-_-e> it doesn't make sense to convert nil to anything
<ari-_-e> it's just nil
bradhe has joined #ruby
<Morrolan> Reminds me of PHP's mentality - "the show must go on" ;)
dangerou_ has quit [Read error: Connection reset by peer]
<shevy> TIOBE says php is better than ruby
dangerousdave has joined #ruby
<shevy> lol
<Morrolan> Tiobe can say that, if they want. ;)
<shevy> the headline is hilarious
<shevy> "June Headline: Is Swift going to replace Objective-C?"
anaeem1 has quit [Quit: Leaving...]
<banister> ari-_-e it's useful sometimes
anaeem1_ has joined #ruby
_dels has joined #ruby
dels is now known as Guest68990
kalusn has quit [Ping timeout: 245 seconds]
Guest68990 has quit [Ping timeout: 265 seconds]
hermanmunster has joined #ruby
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
relix has joined #ruby
bradhe has quit [Ping timeout: 276 seconds]
bluOxigen has quit [Ping timeout: 245 seconds]
aagdbl has quit [Quit: This computer has gone to sleep]
relix has quit [Client Quit]
Hanmac has joined #ruby
Hanmac1 has quit [Ping timeout: 276 seconds]
alem0lars has joined #ruby
<atmosx> I've read a couple of weeks back that it's better to let the application come out with an error
<atmosx> than to use rescue Exception => e
<atmosx> is that so?
<atmosx> we should be using only expected exception e.g. Sequel::Error in my case?
<atmosx> but even that seems a little generric
shvelo has quit [Ping timeout: 260 seconds]
<katlogic> use rescue if you want to act upon it, not to ignore the error
jhulten has joined #ruby
yubrew has joined #ruby
aagdbl has joined #ruby
akonny has joined #ruby
why_away has quit [Remote host closed the connection]
whyy has joined #ruby
doev has quit [Quit: Verlassend]
GriffinHeart has joined #ruby
aagdbl has quit [Client Quit]
jhulten has quit [Ping timeout: 245 seconds]
sinkensabe has joined #ruby
yubrew has quit [Ping timeout: 260 seconds]
<apeiros> atmosx: if you blindly swallow exceptions you'll never (or just too late) notice that your program works incorrectly. and when you notice you'll have not much for diagnosis.
<apeiros> blindly swallowing exceptions == bad
<apeiros> and rescue Exception is a no-go because it also eats system level exceptions, like Interrupt (ctrl-c)
steeve has joined #ruby
<atmosx> I see
whyy has quit [Ping timeout: 245 seconds]
<atmosx> Nice so it's a good practice not to use it. Good, I'll remove them.
diegoviola has quit [Remote host closed the connection]
whyy has joined #ruby
Xeago has joined #ruby
phoo1234567 has joined #ruby
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
gazz102 has quit [Ping timeout: 246 seconds]
Xeago has quit [Ping timeout: 245 seconds]
<apeiros> note that you can e.g. globally rescue StandardError (plain rescue defaults to that), log the exception and shut down in a nicer fashion. that mostly makes sense if your users aren't developers.
aagdbl has joined #ruby
Xeago has joined #ruby
maximski has quit []
obs has quit [Quit: Saliendo]
mercwithamouth has quit [Ping timeout: 252 seconds]
morinap has joined #ruby
dc has quit [Remote host closed the connection]
kaspergrubbe has joined #ruby
workmad3 has joined #ruby
yfeldblum has quit [Ping timeout: 245 seconds]
dp__ has joined #ruby
maximski has joined #ruby
dp__ is now known as dp__io
dp__io has quit [Client Quit]
<gregf_> $r = qr/^0[1-68]([-. ]?[0-9]{2}){4}$/;print /$r/ ? "yep" : "nope" for qw/ 0502030506 05-02030506 05.02030506 05*02030506 /;
dp__io has joined #ruby
<gregf_> bah , sorry wrong chat :/
emsilva has joined #ruby
dp__io has quit [Client Quit]
Azure_ is now known as Azure
sk87 has joined #ruby
wald0 has joined #ruby
zigomir has joined #ruby
<shevy> eeks
<shevy> I wondered why ruby got so ugly all of a sudden
wald0 has quit [Client Quit]
workmad3 has quit [Quit: Lost terminal]
dEPy has joined #ruby
zigomir_ has quit [Ping timeout: 252 seconds]
sk87 has quit [Ping timeout: 276 seconds]
<gregf_> %w{ 0502030506 05-02030506 05.02030506 05*02030506}.each { |x| print x =~ /^0[1-68]([-. ]?[0-9]{2}){4}$/ ? "yep" : "nope"; } <== looks less uglier in ruby :/
sski has joined #ruby
alem0lars has quit [Quit: Going AFK...]
JasmeetQA has quit [Quit: Leaving.]
vifino has joined #ruby
emsilva has quit [Quit: Keep Walking (Computer Slept!)]
<shevy> nope
<shevy> looks awfully ugly still
Joulse has joined #ruby
JasmeetQA has joined #ruby
Burgestrand has joined #ruby
<railzForDaiz> hehe
phutchins has quit [Ping timeout: 252 seconds]
danshultz has joined #ruby
danshultz has quit [Read error: Connection reset by peer]
danshultz has joined #ruby
stevesmename has quit [Ping timeout: 265 seconds]
<shevy> has anyone of you compared lua with mruby effectively yet?
<shevy> as in, used both already seriously
bradhe has joined #ruby
varius has quit [Remote host closed the connection]
mengu has joined #ruby
why_away has joined #ruby
bradhe has quit [Ping timeout: 252 seconds]
whyy_ has joined #ruby
ktun has joined #ruby
tkuchiki has quit [Ping timeout: 245 seconds]
kitak has quit [Remote host closed the connection]
kitak has joined #ruby
danshult_ has joined #ruby
whyy has quit [Ping timeout: 260 seconds]
banister_ has joined #ruby
banister_ has quit [Max SendQ exceeded]
railzForDaiz has quit [Ping timeout: 240 seconds]
why_away has quit [Ping timeout: 260 seconds]
near77 has quit [Quit: Page closed]
banister_ has joined #ruby
banister has quit [Ping timeout: 265 seconds]
banister_ has quit [Max SendQ exceeded]
alem0lars has joined #ruby
banister has joined #ruby
yfeldblum has joined #ruby
railzForDaiz has joined #ruby
danshultz has quit [Ping timeout: 260 seconds]
artm has joined #ruby
eka has joined #ruby
danshult_ has quit [Remote host closed the connection]
doev has joined #ruby
danshultz has joined #ruby
yfeldblum has quit [Ping timeout: 245 seconds]
anaeem1_ has quit [Ping timeout: 276 seconds]
yubrew has joined #ruby
artm has quit [Client Quit]
jespada has joined #ruby
ndrei has quit [Ping timeout: 260 seconds]
anaeem1 has joined #ruby
Tricon has quit [Ping timeout: 260 seconds]
mityaz has quit [Ping timeout: 240 seconds]
danshultz has quit [Ping timeout: 276 seconds]
oo__ has quit [Remote host closed the connection]
maximski has quit []
yubrew has quit [Ping timeout: 265 seconds]
bluOxigen has joined #ruby
ndrei has joined #ruby
dEPy has quit [Read error: Connection reset by peer]
dEPy has joined #ruby
tkuchiki has joined #ruby
<shevy> it's +30°C here :(
railzForDaiz has quit [Ping timeout: 245 seconds]
<scx> 29 here :p
kalusn has joined #ruby
railzForDaiz has joined #ruby
karupa is now known as zz_karupa
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
JasmeetQA has quit [Read error: Connection reset by peer]
banister has joined #ruby
banister has quit [Client Quit]
akonny has quit [Quit: akonny]
doev has quit [Quit: Verlassend]
banister has joined #ruby
bluOxigen has quit [Ping timeout: 260 seconds]
gaboesquivel has joined #ruby
bluOxigen has joined #ruby
gaboesquivel has quit [Client Quit]
krz has quit [Quit: WeeChat 0.4.3]
<shevy> "mod_php solved this problem. PHP was a terrible language back then"
<shevy> the part headed "Library Dominance is Not a Historical Inevitability" is interesting
<shevy> though PHP of course is still an awful language haha
railzFor_ has joined #ruby
koell has joined #ruby
mark_locklear has joined #ruby
railzForDaiz has quit [Ping timeout: 265 seconds]
emsilva has joined #ruby
banister has quit [Ping timeout: 245 seconds]
banister_ has joined #ruby
mordof has quit [Disconnected by services]
mordof1 has joined #ruby
sumark has quit [Remote host closed the connection]
cocotton has joined #ruby
relix has joined #ruby
railzFor_ has quit [Ping timeout: 265 seconds]
sumark has joined #ruby
aagdbl has quit [Quit: This computer has gone to sleep]
danshultz has joined #ruby
garndt has joined #ruby
<sdegutis> Is there an excellent tutorial on making your own Gem (mainly the Gemspec) and testing it on a real project without pushing it up to ruby gems?
lewix has joined #ruby
AlexRussia has quit [Ping timeout: 245 seconds]
r0bby has quit [Excess Flood]
<Burgestrand> sdegutis: I'd use http://guides.rubygems.org/, together with Bundler to depend on the gem from a local path/or a github repository
anaeem1 has quit [Remote host closed the connection]
r0bby has joined #ruby
<sdegutis> Burgestrand: Ahh good idea, thanks.
moritzschaefer has quit [Ping timeout: 260 seconds]
<Burgestrand> sdegutis: http://bundler.io/v1.6/gemfile.html for info on bundler :)
<sdegutis> Burgestrand++
oorst has joined #ruby
<banister_> Burgestrand sup burgy
<banister_> Burgestrand ltns
<Burgestrand> banister_: indeed :)
jhass|off is now known as jhass
anaeem1 has joined #ruby
<banister_> Burgestrand still doing ruby/rails or moved on to something cooler already? :P
<Burgestrand> banister_: working at the same place, doing ruby/rails ;)
<Burgestrand> banister_: http://elabs.se/
<Burgestrand> banister_: usually don't IRC much any more, only gaming, not much coding in my spare time
alexju has joined #ruby
<Burgestrand> banister_: how's you? pry has certainly caught on ;)
cocotton_ has joined #ruby
<banister_> Burgestrand working for a ruby/rails shop too, it's ok…but rails work is pretty uninspiring
<banister_> Burgestrand doing much ios?
yosafbridge has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
<Burgestrand> banister_: naw, not so much, only sometimes
<Burgestrand> banister_: some rubymotion in my spare time, but… not much coding in the spare time
<banister_> Burgestrand why? is the passion going out? or is your woman taking up all your free time? (as in my case..)
chipotle has joined #ruby
<Burgestrand> banister_: naw, most of the time I just… yeah the woman, and gaming, and just doing other stuff!
AlexRussia has joined #ruby
_dels has quit [Quit: Leaving.]
<banister_> Burgestrand cool! are you following the oculus rift developments? :)
<Burgestrand> banister_: a little! tried the rift at DreamHack here in winter, and it's cool, can't wait for it to come out
alexju has quit [Ping timeout: 240 seconds]
<Burgestrand> banister_: the feeling of spaghetti legs after using it definitely sold it
<banister_> Burgestrand did you preorder the dk2 or anything like that?
cocotton has quit [Ping timeout: 265 seconds]
pranny1 has quit [Quit: Leaving.]
<Burgestrand> banister_: no development kit for me, 3D development is not for me
<Burgestrand> banister_: I want the final thing with some games, and I'll lock myself in my apartment for a few days
carraroj has quit [Ping timeout: 252 seconds]
<Burgestrand> banister_: you do any development on things like that?
<Burgestrand> banister_: maybe even with ruby? hehe
cocotton_ has quit [Quit: Leaving...]
benzrf|offline is now known as benzrf
ec has quit [Disconnected by services]
yosafbridge has joined #ruby
cocotton has joined #ruby
qwyeth has quit [Quit: Leaving]
<banister_> Burgestrand hmm, i want to do a bit of dev with it, but more, there's a lot of content already out there for the rift, i'd like to juts play with that. THere's also some very interesting stuff that aren't quite games, they're like recreations of scenes from movies, some one recently did the bus stop scene from my neighbor totoro, and the boiler scene from spirited away. Also, there's a few vids taken with 3d cameras around japan that are
<banister_> meant to be pretty incredible with the rift
<banister_> Burgestrand i'll probably play a bit with ue4
chipotle has quit [Client Quit]
<Burgestrand> banister_: aw yeah, exploring movies would be cool
<Burgestrand> banister_: I tried some development using a leap motion and unity, but it was a bit too much… naw, I'd make 2D games if anything
<banister_> Burgestrand i mean https://www.youtube.com/watch?v=XyYy-q6Bprk#t=92
<banister_> Burgestrand too much? you mean learning curve is too steep?
<Burgestrand> banister_: dunno, just doesn't feel like my thing
mikesplain has joined #ruby
lewix has quit [Ping timeout: 252 seconds]
<banister_> Burgestrand i think u have to go in there with a project in mind
benzrf is now known as benzrf|offline
<banister_> otherwise you could get bogged down with all the crap
<banister_> Burgestrand what's the leap motion like bw?
<banister_> btw*
<Burgestrand> hehe, yeah, probably, I've dabbled in some 2D game development with a goal in mind, but it's just too much fun fiddling around rather than finishing, as always :P
bluOxigen has quit []
lewix has joined #ruby
lewix has joined #ruby
<Burgestrand> banister_: it's cool! they recently released an update that addresses my only concerns with it (sometimes losing track of fingers, light sensitivity) that I have not tried
<Burgestrand> banister_: but… you kind of miss the feedback physical objects give; having an arbitrary cube in the air is tricky for UX
koell has left #ruby ["So say we all!"]
JokerDoom has joined #ruby
<Burgestrand> banister_: now my eyes are set on the Myo armband, I'm more interested in doing cool stuff with e.g. iphone apps
<banister_> Burgestrand what's the myo armband
<Burgestrand> banister_: https://www.thalmic.com/en/myo/
bmurt has joined #ruby
yfeldblum has joined #ruby
<Burgestrand> banister_: gesture control armband
ItSANgo has quit [Quit: Leaving...]
danshultz has quit [Ping timeout: 265 seconds]
mikesplain has quit [Ping timeout: 265 seconds]
sk87 has joined #ruby
mikecmpbll has quit [Quit: ciao.]
<shevy> sdegutis don't worry really, just push to rubygems.org and call it a beta gem
northfurr has joined #ruby
northfurr has quit [Client Quit]
shvelo has joined #ruby
<sdegutis> lol
sambao21 has joined #ruby
snath has quit [Ping timeout: 260 seconds]
yfeldblum has quit [Ping timeout: 276 seconds]
yubrew has joined #ruby
banister_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
shwouchk has left #ruby ["ERC Version 5.3 (IRC client for Emacs)"]
anaeem1 has quit [Remote host closed the connection]
dc has joined #ruby
pontiki has quit [Quit: Lost terminal]
maximski has joined #ruby
yubrew has quit [Ping timeout: 245 seconds]
danshultz has joined #ruby
<sdegutis> Okay, before I push this gem, it's time to settle on a decent gem name.
<sdegutis> (project name)
OrionKissinger has joined #ruby
<bmurt> depends on what it does
<sdegutis> It was inspired by fuckingshellscripts.org.
ixti has joined #ruby
obs has joined #ruby
strax has joined #ruby
<sdegutis> The description of my project is "Minimalist EC2 management & deployment tool"
<sdegutis> The current name is kinda dumb.
<bmurt> which is?
<sdegutis> Oh! I know! How about "Dragon" ?
<sdegutis> The current name is "billow"
<sdegutis> (found it in the thesaurus for "cloud")
<bmurt> how does dragon relate?
<sdegutis> It doesn't, but it's way cool.
ItSANgo has joined #ruby
<bmurt> "stationary"
<sdegutis> I am bad at naming things.
<bmurt> plays on the word deployment
zarubin has quit [Read error: Connection reset by peer]
<sdegutis> Hmm.
_dels has joined #ruby
zarubin has joined #ruby
_dels is now known as dels
<bmurt> emdt
zarubin has quit [Read error: Connection reset by peer]
<bmurt> abbreviations
oorst has quit [Quit: oorst]
zarubin has joined #ruby
<bmurt> emdtk
alem0lars has quit [Quit: Going AFK...]
<bmurt> ec2 management & deployment toolkit
chipotle has joined #ruby
dc has quit [Remote host closed the connection]
predator117 has quit [Ping timeout: 276 seconds]
boris has joined #ruby
jhulten has joined #ruby
maximski has quit []
chipotle has quit [Client Quit]
sdouglas has joined #ruby
<shevy> sdegutis oh man
<shevy> sdegutis you already now face the biggest problem ruby hackers face
<shevy> sdegutis giving things proper names
<bmurt> heh, just mash keys and go with it
<sdegutis> My wife suggested "Web Ignite"
<shevy> that's how we end up with things like god, unicorn and more crap like that
vpretzel has joined #ruby
chipotle has joined #ruby
<bmurt> seems to be how most shit is named
<shevy> sdegutis well that is too long
<bmurt> 'cancan'
<bmurt> how does cancan relate to authorization?!
<shevy> dunno
<shevy> how does python relate to programming
<shevy> it's a god damn animal!
<bmurt> animals program though
<shevy> I know, I've seen the cats hackers
dc has joined #ruby
<sdegutis> To be fair, all of my new non-Ruby projects are just named after mythological creatures and such, like Phoenix and Zephyros (window managers), Bahamut (music player), Leviathan and Chaos (text editors)
mityaz has joined #ruby
chipotle has quit [Client Quit]
<sdegutis> So anything slightly-relevant is a step up for me.
<bmurt> isn't bahamut an irc service?
<sdegutis> Probably.
<bmurt> it was, i dont know if its still active
mityaz has quit [Client Quit]
chipotle has joined #ruby
Takle has quit [Remote host closed the connection]
<sdegutis> It's also my obscure OS X music player that ~20 people like.
<bmurt> ahh, its an ircd
rghose1 has left #ruby [#ruby]
mityaz has joined #ruby
<shevy> omg
dc_ has joined #ruby
<shevy> people suck at naming things
<sdegutis> At least I had a professional icon made for mine.
jhulten has quit [Ping timeout: 260 seconds]
dc has quit [Read error: Connection reset by peer]
<shevy> hehe
<sdegutis> Oh! How about "Ignition"?
chipotle has quit [Client Quit]
alexju has joined #ruby
<shevy> call it Elvis
<sdegutis> (for my ec2 manager/deployer gem"
dblessing has joined #ruby
<shevy> for Elvis Presley
<sdegutis> Crap, wrong end-delimiter.
sdouglas has quit [Ping timeout: 240 seconds]
<bmurt> deployee
qwyeth has joined #ruby
<bmurt> like employee, but it actually works and for cheaper
chipotle has joined #ruby
<bmurt> "no obamacare needed for this gem!"
<sdegutis> :D
<sdegutis> Keepers.
predator117 has joined #ruby
sdrew has joined #ruby
kpshek has joined #ruby
<sdegutis> Okay, it's gonna be named "Deployee" and the description will be "No ObamaCare needed for this gem!" and the summary will be "Like Employee, but it actually works and for cheaper."
chipotle has quit [Client Quit]
<bmurt> i like it
<bmurt> :D
<sdegutis> I'll tell everyone to blame Brendan Murtagh for it.
<sdegutis> s.author = "Brendan Murtagh"
katmandoo has joined #ruby
OrionKissinger has quit [Remote host closed the connection]
chipotle has joined #ruby
<bmurt> that's fine. i'll finally be popular
<bmurt> :_
<sdegutis> :D
<bmurt> :)
Guest25852 has joined #ruby
Mongey is now known as zeel2
jcarouth has joined #ruby
chipotle has quit [Client Quit]
<shevy> this is a wonderful example why the names for gems will continue to be awful
zeel2 is now known as zeel_cola
akonny has joined #ruby
r0bby has quit [Excess Flood]
echevemaster has joined #ruby
chipotle has joined #ruby
<sdegutis> Actually I won't choose that name.
<bmurt> :*(
<sdegutis> We have too many funny names, this one should be serious.
* bmurt hunts down sdegutis's address and buys a sharp knife
<bmurt> i put lots of effort into deployee
<sdegutis> bmurt: Oh thanks, we've needed some.. can you make it a cheese knife?
Maple__ has quit [Quit: bbl]
r0bby has joined #ruby
<sdegutis> PM me for directions
dangerousdave has quit [Read error: Connection reset by peer]
<bmurt> i prefer a butter knife
sdrew has quit [Client Quit]
dangerou_ has joined #ruby
<sdegutis> bmurt: our cheese knife is the dullest one, we could use a new one
bluOxigen has joined #ruby
maximski has joined #ruby
chipotle has quit [Client Quit]
<bmurt> once you make it big with deployee, you can buy you're own
<bmurt> :D
<shevy> let's consider the simplest choice
<shevy> class Foobar
<shevy> the project could be called foobar
<shevy> well that was an example
chipotle has joined #ruby
mengu has quit [Remote host closed the connection]
<shevy> you don't have to take it literally
lxsameer has quit [Quit: Leaving]
<shevy> omg
<sdegutis> shevy: the main module name is Billow
<shevy> FoobarLotto::Drawing.draw # => [23, 22, 3, 7, 16]
<sdegutis> shevy: which is what I want to replace
katmandoo has quit [Ping timeout: 260 seconds]
creativeembassy has joined #ruby
<sdegutis> No gems are named "fragglerock" ???
chipotle has quit [Client Quit]
<bmurt> i think he should replace it with deployee
<bmurt> :D
akonny has quit [Quit: akonny]
<shevy> look at all those insults!
mikesplain has joined #ruby
creativeembassy has quit [Client Quit]
<bmurt> shevy: shit should be pulled from RG
zarubin has quit [Remote host closed the connection]
<shevy> just gem install fuck and you are done
zarubin has joined #ruby
chipotle has joined #ruby
Maple__ has joined #ruby
danshultz has quit [Read error: Connection reset by peer]
<bmurt> at least fuck has methods
mengu has joined #ruby
<bmurt> shit just has a version lib
<shevy> "Girlfriend is an installable, upgradable and removeable girlfriend"
<sdegutis> This is insane.
<shevy> lol
<sdegutis> So many joke libs.
<sdegutis> At least mine was useful.
Takle has joined #ruby
<shevy> haha
<bmurt> heh
<sdegutis> (Since lost the source)
<bmurt> look at https://rubygems.org/gems/happygirl 's dependency
<sdegutis> But it worked like: "foo".omnom == "fo"
chipotle has quit [Client Quit]
<bmurt> hoe >= 1.3.0
<sdegutis> And "foo.omnomnom == "f"
<shevy> no wait
<shevy> hoe is actually a real gem
danshultz has joined #ruby
<bmurt> its just a funny combo
<shevy> https://rubygems.org/gems/hoe more than 2.5 million downloads
<bmurt> happygirl + hoe
naw has joined #ruby
<shevy> someone has dirty thoughts here
<bmurt> i wish happygirl required dildo v0.0.1
<shevy> "Opinionated script execution framework"
Joulse has quit [Quit: Joulse]
<sdegutis> Found it: https://rubygems.org/gems/cd
<sdegutis> configuration + deployment
<shevy> please sdegutis
<shevy> for the sake of future generation
<shevy> give it a proper name
<bmurt> like deployee
<sdegutis> Yes, this is my goal.
<bmurt> :D
robertodecurnex has joined #ruby
SCommette has joined #ruby
<shevy> I think I know bmurt's goal
<sdegutis> "code" is short for "COnfiguration + DEployment"
<sdegutis> ok "code" it is
<bmurt> the problem w/ deployee is that it gives the impression its not just for aws/ec2
<sdegutis> Oh yeah, this has that same problem.
<sdegutis> relevant subjects = deployment, configuration, management, EC2
<sdegutis> "codemaec" ?
GriffinHeart has quit [Remote host closed the connection]
<sdegutis> Or I could just do freakingshellscripts.org to connote fuckingshellscripts.org
sski has quit [Remote host closed the connection]
<bmurt> fss_emdtk
<bmurt> :D
<bmurt> really keep it unknown
sski has joined #ruby
<sdegutis> LOL
pushpak has joined #ruby
jerius has joined #ruby
maximski has quit []
andrewjanssen has joined #ruby
zeel_cola is now known as Mongey
oo_ has joined #ruby
katmandoo has joined #ruby
oo_ has quit [Remote host closed the connection]
workmad3 has joined #ruby
<sdegutis> Because it really makes it that easy.
oo_ has joined #ruby
railzForDaiz has joined #ruby
<sdegutis> Or "abra"
Joulse has joined #ruby
aagdbl has joined #ruby
<shevy> ohhhh a magic wong
cocotton_ has joined #ruby
<sdegutis> Yeah that's not a good association.
sski has quit [Ping timeout: 252 seconds]
<sdegutis> Remembered.
<shevy> haha
sailias has joined #ruby
<shevy> I always hatter hairy potsmoker
<shevy> erm
<shevy> *hated
<atmosx> who's hat?
<atmosx> that
<sdegutis> shevy: you had one job
banister has joined #ruby
<shevy> I was dragged to even watch him in movie
banister has quit [Client Quit]
<shevy> I fell asleep during part II
mary5030 has joined #ruby
mary5030 has quit [Remote host closed the connection]
bradhe has joined #ruby
<sdegutis> Yeah I liked Narnia better.
havenwood has joined #ruby
mary5030 has joined #ruby
kitak has quit [Remote host closed the connection]
dangerou_ has quit [Read error: Connection reset by peer]
dangerousdave has joined #ruby
<sdegutis> Oh how about "autocloud"?
kitak has joined #ruby
doodlehaus has joined #ruby
cocotton has quit [Ping timeout: 276 seconds]
<sdegutis> Meh not super happy with it.
xaxisx has joined #ruby
Ankhers has joined #ruby
railzForDaiz has quit [Ping timeout: 252 seconds]
tkuchiki has quit [Read error: Connection reset by peer]
Azulinho has joined #ruby
silkfox has joined #ruby
tkuchiki has joined #ruby
bradhe has quit [Ping timeout: 265 seconds]
<shevy> no
<shevy> tell you what
<shevy> let your wife give it a name
danshultz has quit [Ping timeout: 265 seconds]
danshultz has joined #ruby
sski has joined #ruby
<sdegutis> Man, if only "noctilucent" wasn't hard to spell.
davedev24_ has quit [Remote host closed the connection]
davedev24_ has joined #ruby
<bmurt> i'd take a break from the name game
<bmurt> let your head clear
<bmurt> the come back with some more shitty suggestions
<bmurt> :D
BizarreCake has quit [Read error: Connection reset by peer]
<bmurt> deployee will still be around
paulfm has joined #ruby
<bmurt> ;)
newUser1234 has joined #ruby
railzForDaiz has joined #ruby
timonv has quit [Remote host closed the connection]
<sdegutis> heh
<sdegutis> It may just stay "billow"
phutchins has joined #ruby
<bmurt> no because i didn't think of that
doev has joined #ruby
<sdegutis> ok
<lagweezle> "What was this naming game for?
yfeldblum has joined #ruby
<lagweezle> noctilucent, btw, is delicious sounding.
maximski has joined #ruby
mupkoo has joined #ruby
silkfox has quit [Ping timeout: 260 seconds]
<shevy> how about
<shevy> noctillow
<shevy> or bilucent
<shevy> hahaha
kevind has joined #ruby
<sdegutis> noctilucent is latin for night shine or something
<shevy> or deployeecent
<lagweezle> noctillow makes me think 'nocturnal emissions' .. I'm guessing between 'nocturnal' and 'pillow' ...
<shevy> what?
<shevy> nocturnal taking a piss?!?!
<sdegutis> never mind
<shevy> lol
davedev24_ has quit [Ping timeout: 260 seconds]
<shevy> once you found a name
<shevy> will you tell us sdegutis?
codabrink has joined #ruby
mercwithamouth has joined #ruby
<sdegutis> shevy: sure why not
<sdegutis> It's this project btw: https://github.com/sdegutis/billow
<sdegutis> The readme is slightly out of date.
<sdegutis> But not by anything significant.
<sdegutis> CloudHQ
<sdegutis> That's the name.
yfeldblum has quit [Ping timeout: 252 seconds]
gensgad has quit [Ping timeout: 260 seconds]
yubrew has joined #ruby
bluOxigen has quit [Ping timeout: 276 seconds]
sinkensabe has quit [Remote host closed the connection]
sinkensabe has joined #ruby
sinkensabe has quit [Remote host closed the connection]
dc_ has quit [Remote host closed the connection]
predator117 has quit [Ping timeout: 245 seconds]
<sdegutis> Although I'd rather it be called FogHQ, but I don't know if I can get away with that legally.
iamvery has joined #ruby
sinkensabe has joined #ruby
<shevy> bmurt
<bmurt> yo
<shevy> look at this
<shevy> you should have been more insistent with getting him to name it deployee
<shevy> now it's too late :(
* sdegutis waits...
<sdegutis> shevy: oh thought you had some link or something relevant
<shevy> people will come and ask him
<shevy> "Hey, how can I connect my iPhone to your CloudHQ app?"
JokerDoomWork has joined #ruby
<bmurt> sdegutis: i reject your claim to name it cloudhq. i suggest deployee
<shevy> \o/
<shevy> the more often the word gets repeated, the better it sticks
<bmurt> guaranteed to get you laid by ruby nerds since june 9th, 2014
<shevy> omg
<bmurt> true
<shevy> ruby nerds
<bmurt> so i think im going to do some deployeeing today of new VMs
Guest25852 has quit []
<bmurt> our network engineer is getting ready to deployee a new router
luksaur has joined #ruby
<atmosx> bmurt: and you are going to delpoy a vm for a router?
marr123 has joined #ruby
akonny has joined #ruby
<bmurt> yep. using this new gem called deployee
<bmurt> once sdegutis renames it
<bmurt> :D
yubrew has quit [Ping timeout: 252 seconds]
<sdegutis> "de" = un, "plicare" = to fold, "deploy" = unfold; "employ" = enfold, or fold-in, since "en" = in; "employee" = one who folds in, deployee = "one who folds"
davedev24_ has joined #ruby
mikecmpbll has joined #ruby
silkfox has joined #ruby
_justin has quit [Quit: _justin]
<sdegutis> "displicare" (deploy) can also mean "explain", not just "unfold", so deployee = "one who explains"
<sdegutis> I can dig that.
devdazed has quit [Quit: Bye]
<atmosx> sdegutis: what are you doing to these people?
<bmurt> aka, "one who folds a bunch of shit and ships it to aws"
<bmurt> deployee
<atmosx> I'm so tired of writing begin/rescue/ennd and if/else clauses
sinkensabe has quit [Ping timeout: 276 seconds]
<sdegutis> atmosx: then stop
<atmosx> sdegutis: no, I wanna make it perfect
<sdegutis> atmosx: that doesn't make it better
<atmosx> no more errors in my code.
<sdegutis> I only used begin/rescue/end once I think.
<atmosx> sdegutis: it really does.
<sdegutis> Okay, deployee may not be a bad idea.
Zenigor has joined #ruby
predator117 has joined #ruby
JokerDoomWork has quit [Quit: Leaving]
<atmosx> sdegutis: neither exception handling
marr123 is now known as marr
diegoviola has joined #ruby
<sdegutis> Keeper.
xaxisx has quit [Quit: xaxisx]
mercerist has quit [Quit: Computer has gone to sleep.]
byteoverfl0w has quit [Quit: Leaving... have a good one...]
mercwithamouth has quit [Ping timeout: 265 seconds]
railzFor_ has joined #ruby
Takle has quit [Remote host closed the connection]
devdazed has joined #ruby
djcp has joined #ruby
<sdegutis> Oh come on Firefox, at least render /something/ on travis-ci.org
<railzFor_> is it possible to create a hash with default keys ? looking liek this Hash.new(:task, :date, :author) and later on add the corresponding values later ?
railzForDaiz has quit [Ping timeout: 276 seconds]
TDJACR has joined #ruby
<aagdbl> railzFor_, what should be the default values for the keys?
akonny has quit [Quit: akonny]
<jhass> railzFor_: yes: Hash.new {|h, k| h[k] = default }
pushpak has quit [Quit: Linkinus - http://linkinus.com]
horsecowdog has joined #ruby
Xeago has quit [Remote host closed the connection]
<Mon_Ouie> It's not possible (I mean you can explicitly create a hash that maps each key to nil of course)
<railzFor_> aagdbl want them to be nil for now
Xeago has joined #ruby
sinkensabe has joined #ruby
<aagdbl> railzFor_, i don't understand. hashes don't need to have a fixed set of keys.
<railzFor_> basically line.chomp.split(/,/)
<railzFor_> add to hash
qwyeth has quit [Ping timeout: 276 seconds]
djcp has left #ruby [#ruby]
<railzFor_> then i wanna put it into array
<aagdbl> yes, you can add any key value pair into a hash
<railzFor_> so i can easily sort the data by date, name, subject
<aagdbl> put what into an array?
SCommette has quit [Quit: SCommette]
stevesmename has joined #ruby
mattstratton has joined #ruby
<railzFor_> This is the text,2014-06-08 19:00:13 +0200,2014-06-08 19:00:24 +0200,4,yello
<railzFor_> Thirsty little hippos,2014-06-08 19:01:13 +0200,2014-06-08 19:06:26 +0200,1,green
<jhass> lines << Hash[[:date, :name, :subject].zip(line.chomp.split(','))] ?
<railzFor_> read each of those lines and add into hash and into single array
sdouglas has joined #ruby
auxbuss has joined #ruby
maximski has quit []
<railzFor_> jhass i think that could be it
<jhass> just .map if your input is enumerable
mercwithamouth has joined #ruby
<railzFor_> alright
<railzFor_> thanks
Xeago has quit [Ping timeout: 265 seconds]
Xeago has joined #ruby
mercerist has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
dangerou_ has joined #ruby
diegoviola has quit [Quit: WeeChat 0.4.3]
sdouglas has quit [Ping timeout: 240 seconds]
danshultz has quit [Ping timeout: 260 seconds]
auxbuss has quit [Quit: I'm gone.]
whyy_ has quit [Remote host closed the connection]
maximski has joined #ruby
jottr has joined #ruby
whyy has joined #ruby
forcefsck has joined #ruby
horsecowdog has quit []
Takle has joined #ruby
amargherio has joined #ruby
tiguser has joined #ruby
Azulinho has quit [Ping timeout: 245 seconds]
qwyeth has joined #ruby
trhodes_ has quit [Ping timeout: 264 seconds]
whyy has quit [Ping timeout: 260 seconds]
xaxisx has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
yubrew has joined #ruby
Vivekananda has joined #ruby
NukePuppy has joined #ruby
xaxisx has quit [Client Quit]
Zamerick has joined #ruby
hpoydar has joined #ruby
jarray52 has joined #ruby
Asher has quit [Quit: Leaving.]
trhodes_ has joined #ruby
andrewjanssen has quit [Quit: Leaving...]
tiguser has quit [Ping timeout: 245 seconds]
dc has joined #ruby
lewix has quit [Ping timeout: 265 seconds]
lewix has joined #ruby
mengu has quit []
tiguser has joined #ruby
kilk_ has quit [Quit: Leaving]
ffranz has joined #ruby
andrewjanssen has joined #ruby
kalusn has quit []
lemur has joined #ruby
hpoydar has quit [Ping timeout: 245 seconds]
i_s has joined #ruby
i_s has quit [Remote host closed the connection]
sepp2k has joined #ruby
andrewjanssen has quit [Client Quit]
i_s has joined #ruby
hpoydar has joined #ruby
bradhe has joined #ruby
OrionKissinger has joined #ruby
krz has joined #ruby
thesheff17 has quit [Remote host closed the connection]
iamvery has quit [Remote host closed the connection]
iamvery has joined #ruby
Azulinho has joined #ruby
Spami has joined #ruby
<sdegutis> Oh for crap's sake Travis, what the heck.
andrewjanssen has joined #ruby
iamvery_ has joined #ruby
aagdbl has quit [Quit: This computer has gone to sleep]
<railzFor_> jhass fuck yeah :D :)
bradhe has quit [Ping timeout: 276 seconds]
lkba has quit [Ping timeout: 260 seconds]
newvegas has joined #ruby
treehug88 has joined #ruby
nanoyak has quit [Quit: Computer has gone to sleep.]
thesheff17 has joined #ruby
iamvery has quit [Ping timeout: 260 seconds]
SCommette has joined #ruby
RaCx has joined #ruby
RaCx has quit [Read error: Connection reset by peer]
enebo has joined #ruby
aagdbl has joined #ruby
timonv has joined #ruby
RaCx has joined #ruby
kman has quit [Remote host closed the connection]
yfeldblum has joined #ruby
ldnunes has joined #ruby
Hanmac1 has joined #ruby
Zenigor has quit [Remote host closed the connection]
Hanmac has quit [Ping timeout: 240 seconds]
eka has quit [Quit: Textual IRC Client: www.textualapp.com]
yfeldblum has quit [Ping timeout: 240 seconds]
OrionKissinger has quit [Remote host closed the connection]
<sdegutis> Is it possible to make Ruby not assume ARGV is a bunch of filenames to be loaded?
aganov has quit [Quit: Leaving]
eka has joined #ruby
tiguser has quit [Ping timeout: 240 seconds]
echevemaster has quit [Remote host closed the connection]
thumpba has quit [Remote host closed the connection]
thumpba has joined #ruby
tiguser has joined #ruby
Xeago has quit [Remote host closed the connection]
iamvery_ has quit [Remote host closed the connection]
<Hanmac1> sdegutis: yes
echevemaster has joined #ruby
auxbuss has joined #ruby
Xeago has joined #ruby
Kricir has joined #ruby
<sdegutis> Yay.
mikepack has joined #ruby
iamvery has joined #ruby
lmickh has joined #ruby
GodPuppet has quit [Ping timeout: 240 seconds]
Xeago has quit [Ping timeout: 240 seconds]
Zenigor has joined #ruby
<Mon_Ouie> Use $stdin.gets, not just gets
benzrf|offline is now known as benzrf
tiguser has quit [Ping timeout: 252 seconds]
Blaguvest has joined #ruby
cocotton_ has quit [Remote host closed the connection]
GriffinHeart has joined #ruby
geggam has joined #ruby
geggam has quit [Client Quit]
cocotton has joined #ruby
diegoviola has joined #ruby
toastynerd has joined #ruby
aagdbl has quit [Quit: Leaving]
cocotton has quit [Remote host closed the connection]
tiguser has joined #ruby
GodPuppet has joined #ruby
pasties has quit [Read error: Connection reset by peer]
Xeago has joined #ruby
<sdegutis> I should figure out a better way to register commands besides using subclasses.
jerius has quit [Read error: Connection reset by peer]
<sdegutis> I mean, subclasses are cool and all, but this probably isn't how they're meant to be usd.
jerius has joined #ruby
cocotton has joined #ruby
brunops has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
dangerou_ has quit [Read error: Connection reset by peer]
dangerousdave has joined #ruby
<sdegutis> I wouldn't mind just calling a method and passing it a hash of details and a lambda, but that would probably feel a bit uglier.
sdrew has joined #ruby
<sdegutis> Anyway, it's the right way to go.
auxbuss has quit [Quit: I'm gone.]
pasties has joined #ruby
OrionKissinger has joined #ruby
naw has quit [Read error: Connection reset by peer]
iamvery has quit [Remote host closed the connection]
RaCx has joined #ruby
RaCx has quit [Client Quit]
ascarter has joined #ruby
naw has joined #ruby
RaCx has joined #ruby
<benzrf> sdegutis: y not make a class for commands
geggam has joined #ruby
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<benzrf> Command.new property: wut, cool_option: neat_value do |arg1, arg2, sweet|
<benzrf> # some shit
<benzrf> end
__class__ has quit [Read error: Connection reset by peer]
relix has joined #ruby
ascarter has quit [Client Quit]
maestrojed has joined #ruby
relix has quit [Client Quit]
jhulten has joined #ruby
ascarter has joined #ruby
ascarter has quit [Remote host closed the connection]
GodPuppet has quit [Remote host closed the connection]
snath has joined #ruby
ascarter has joined #ruby
<sdegutis> benzrf: Yeah that sounds more Ruby-esque.. I was thinking too much in Clojure
<benzrf> sdegutis: ;)
<benzrf> sdegutis: step back and think:
<benzrf> - what kind of objects am i working with
<benzrf> one kind of object youre working with is a command
<benzrf> viz, class command
niharvey is now known as niharvey|call
<sdegutis> benzrf: But all I really want to do is register a function and a name (which I could probably derive from the function).
<benzrf> sdegutis: orly
Hanmac has joined #ruby
<benzrf> in that case just use a method call taking a block :u
<benzrf> sdegutis: wait, is this for cmdline stuff
<benzrf> if so http://whatisthor.com/
iamvery has joined #ruby
lolmaus has joined #ruby
tiguser has quit [Ping timeout: 276 seconds]
RaCx has quit [Remote host closed the connection]
RaCx has joined #ruby
Hanmac1 has quit [Ping timeout: 260 seconds]
<sdegutis> :)
toastynerd has quit [Remote host closed the connection]
jhulten has quit [Ping timeout: 260 seconds]
<sdegutis> Although, if I change this, one of the things I lose is the ability to use :subject in RSpec.
<sdegutis> Which is really convenient.
mupkoo has quit [Remote host closed the connection]
i_s has quit [Remote host closed the connection]
relix has joined #ruby
kaspergrubbe has quit []
nyamx2 has quit [Remote host closed the connection]
maximski has quit [Ping timeout: 245 seconds]
brunops has quit [Changing host]
brunops has joined #ruby
brunops is now known as nibbless
tiguser has joined #ruby
datafirm has joined #ruby
steeve has quit [Remote host closed the connection]
nibbless is now known as brunops
__class__ has joined #ruby
steeve has joined #ruby
ruralhack has joined #ruby
<sdegutis> Just found my favorite new way to list things in the terminal: https://github.com/sdegutis/management/blob/master/lib/management/commands/list_servers.rb
Robbo` has joined #ruby
Hobogrammer has joined #ruby
steeve has quit [Remote host closed the connection]
steeve has joined #ruby
jprovazn is now known as jprovazn_afk
dEPy has quit [Quit: Computer has gone to sleep.]
kirun has joined #ruby
qwyeth has quit [Ping timeout: 245 seconds]
qwyeth has joined #ruby
scx_ has joined #ruby
scx has quit [Ping timeout: 260 seconds]
tiguser has quit [Ping timeout: 276 seconds]
bradhe has joined #ruby
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
<sdegutis> Aha! Management::Command.register("list-servers") do |env_name = nil| ... end
hpoydar has quit [Remote host closed the connection]
RaCx has quit [Quit: Computer has gone to sleep.]
timonv has quit [Remote host closed the connection]
hpoydar has joined #ruby
b1205 has joined #ruby
iamvery has left #ruby ["Leaving..."]
thumpba has quit [Ping timeout: 276 seconds]
markuman has joined #ruby
baroquebobcat has joined #ruby
<markuman> is there a way to get the list of all seed numbers when doing? r=Random.new(0)
<shevy> dont think so
<shevy> well there is #seed on http://www.ruby-doc.org/core-2.1.2/Random.html
scx_ has quit [Ping timeout: 245 seconds]
bradhe has quit [Ping timeout: 252 seconds]
alem0lars has joined #ruby
tiguser has joined #ruby
rippa has joined #ruby
zz_jrhorn424 is now known as jrhorn424
alem0lars has quit [Client Quit]
workmad3 has quit [Quit: Lost terminal]
baroquebobcat has quit [Client Quit]
jrhorn424 is now known as zz_jrhorn424
workmad3 has joined #ruby
zz_jrhorn424 is now known as jrhorn424
Royalb15 has quit [Quit: Leaving]
hpoydar has quit [Read error: Connection reset by peer]
thumpba has joined #ruby
Bira has joined #ruby
stantona has joined #ruby
phansch has joined #ruby
<sdegutis> Gyahh, implicit blocks create procs, not lambdas, which don't tell me which args are truly required.
stantona has quit [Read error: Connection reset by peer]
stantona has joined #ruby
Hanmac has quit [Ping timeout: 240 seconds]
marco82 has joined #ruby
mikesplain has quit [Ping timeout: 245 seconds]
tiguser has quit [Ping timeout: 260 seconds]
Hanmac has joined #ruby
baroquebobcat has joined #ruby
tiguser has joined #ruby
sk87 has joined #ruby
Zamerick has quit [Ping timeout: 245 seconds]
sambao21 has quit [Quit: Computer has gone to sleep.]
chrisja has joined #ruby
marco82 has left #ruby ["Sto andando via"]
luisjose has joined #ruby
sdouglas has joined #ruby
sambao21 has joined #ruby
sputnik13 has joined #ruby
<luisjose> Hello, is there a way to listen to keyboard events on a daemon running on background, or even launched on another console and listen to keyboard on another console
mikesplain has joined #ruby
hakunin_ is now known as hakunin
jarray52 has left #ruby [#ruby]
maletor has joined #ruby
baroquebobcat has quit [Client Quit]
<jhass> not sure, I think I'd investigate reading /dev/input directly first
b00stfr3ak has joined #ruby
<jhass> probably more of a #linux question I guess
baroquebobcat has joined #ruby
ruralhack has quit [Ping timeout: 260 seconds]
OrionKissinger has quit []
markuman has left #ruby ["WeeChat 0.4.3"]
IceDragon has joined #ruby
toastynerd has joined #ruby
shvelo has quit [Quit: Leaving]
<Mon_Ouie> You don't even know that he's using linux yet though
shiggity_ has quit [Quit: Leaving]
<hoelzro> once a job is backgrounded, I believe it loses control of the tty
sinkensabe has quit [Remote host closed the connection]
<hoelzro> that's getting into process group/session land
arrubin has joined #ruby
mary5030_ has joined #ruby
<hoelzro> you *might* be able to listen to another terminal's input by finding out its tty name
<hoelzro> and opening that file
maletor has quit [Ping timeout: 260 seconds]
baroquebobcat has quit [Client Quit]
<jhass> luisjose: what's the goal of doing that anyway? keylogger?
<Hanmac> jhass: he might be a agent from the NSA ;P
<jhass> duh, I'd expected them to not get the best man, but that low?
<jhass> ;P
Guest41835 is now known as Kruppe
scx has joined #ruby
<sdegutis> Is there a way to make blocks passed to methods actually be lambdas without explicitly passing lambdas?
<toretore> elaborate
mary5030 has quit [Ping timeout: 276 seconds]
hpoydar has joined #ruby
<workmad3> sdegutis: not without rewriting the method
mijicd has joined #ruby
<jhass> what feature of a lambda do you need anyway?
<sdegutis> required args
mary5030 has joined #ruby
apipkin has joined #ruby
ruralhack has joined #ruby
<toretore> that's a bit backwards
<apipkin> is there a specific channel for haml, or is this a good place?
<sdegutis> apipkin: LOL
<sdegutis> apipkin: you had me for a second
<sdegutis> toretore: oh?
<toretore> it's your method that decides the arguments
<toretore> not the block/lambda
_justin has joined #ruby
<sdegutis> toretore: right on
<sdegutis> toretore: I'll probably just use def then.
<sdegutis> Not sure how to test this function without namespacing it though.
scx has quit [Ping timeout: 245 seconds]
<jhass> sdegutis: as toretore said you shouldn't need that enforcement. If you think you really do the simplest thing is to check .arity by hand
<apipkin> sdegutis: huh? :-/
mary5030_ has quit [Ping timeout: 240 seconds]
<sdegutis> apipkin: LOL the whole andy kaufman style is a great touch
<toretore> apipkin: did you try #haml ?
obs has quit [Remote host closed the connection]
<sdegutis> apipkin: oh wait I misread you as sayign "html"
<Hanmac> jhass all other best man dont want to do the job because they have "moral" ;P
benzrf is now known as benzrf|offline
<apipkin> toretore: i didn’t see many people in there :) This may be more ruby based anyways…
<jhass> I think everybody has moral. Some people just don't notice they do until it's too late
<toretore> apipkin: you won't know until you try to ask them
<apipkin> toretore: roger that
baroquebobcat has joined #ruby
<toretore> that is the rule: try the right channel first, then try another one if you don't get a reply
timonv has joined #ruby
<workmad3> apipkin: also, #rubyonrails could be a good place to ask
ayaz has quit [Quit: Textual IRC Client: www.textualapp.com]
<toretore> god damn heat, i don't understand what people like about it
<apipkin> workmad3: that makes sense too, thanks!
troyready has joined #ruby
sinkensabe has joined #ruby
<jhass> toretore: I think they actually like the sun and not the heat. Wrong associations and all that
<toretore> apipkin: to be clear: your question is probably quite relevant to this channel, but it's more relevant to #haml :)
<Dekade> can you assign a new value to a hash key like x['y'] += z ?
<toretore> yes
<jhass> exactly like that
Lucky_ has joined #ruby
<Dekade> hmm, alright I figured. dont know why I keep messing up.
<Hanmac> Dekade: if the Hash supports it with a default value yes
scx has joined #ruby
<toretore> oh
<jhass> I think new value implies that it exists before
<toretore> yes
havenwood has quit [Remote host closed the connection]
<apipkin> Is there an alternative to each on a hash so that I only get the “loop” once on any key of the hash?
bmurt has quit []
<jhass> apipkin: .each_key
sski has quit [Remote host closed the connection]
noop has quit [Ping timeout: 265 seconds]
diegoviola has quit [Quit: WeeChat 0.4.3]
<toretore> jhass: people are always like "oh summer is the best" but it's like 30C and you sweat like a pig
alem0lars has joined #ruby
sski has joined #ruby
<jhass> doesn't defeat my point
SCommette has quit [Quit: SCommette]
<jhass> it's the sun light that makes you happy, people just associate the feeling the the omnipresent heat during the times you get a lot
hamakn_ has quit [Remote host closed the connection]
<jhass> *to the
<sdegutis> Oooh, I remember the other reason I used inheritance for commands... so they could inherit methods. Oops.
Mon_Ouie has quit [Ping timeout: 240 seconds]
Hanmac1 has joined #ruby
<Hanmac1> toretore: you need to think it from another direction ... you are sitting in a sauna ... and you dont need to pay for that
CodeBunny has quit [Ping timeout: 240 seconds]
<toretore> but i don't like saunas :(
hamakn has joined #ruby
sski has quit [Ping timeout: 240 seconds]
Hanmac has quit [Ping timeout: 252 seconds]
LnL_ is now known as LnL
<jhass> that's okay, at least you don't have to pay for it, remember?
subraminion has joined #ruby
<Hanmac1> jhass: psst don't let the capitalist hear that!
cocotton has quit [Remote host closed the connection]
vee has quit [Read error: Connection reset by peer]
<luisjose> jhass: is an app that listen to a barcode scanner, I want to run it on background, actually it runs on startup and take control of the tty so i can't login while is running unless i do it by ssh, and if i need to restart the app, i need to reboot
<luisjose> hoelzro: its actually Linux
<luisjose> jhass: but the barcode scanner acts as a keyboard
<jhass> I'd definitely pursue directly opening the input device node then
chrisja has quit [Quit: leaving]
<hoelzro> luisjose: what I described should work on Linux
SCommette has joined #ruby
ruralhack has quit [Ping timeout: 265 seconds]
juco has joined #ruby
hpoydar has quit [Remote host closed the connection]
<hoelzro> and in light of what you've described, I agree with jhass
<luisjose> yeah thats what im looking for, but i don't know how to open the keyboard device directly
IceDragon has quit [Ping timeout: 265 seconds]
<luisjose> thats what im trying to find out
IceDragon has joined #ruby
<jhass> File.open("/dev/input/right_thing_here") though that might be a bit raw and direct, depending on what the scanner sends
wallerdev has joined #ruby
hamakn has quit [Ping timeout: 276 seconds]
hpoydar has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
<hoelzro> you may have to turn off buffering as well
mikepack has quit [Remote host closed the connection]
acmehandle has joined #ruby
sinkensabe has quit [Remote host closed the connection]
acmehandle has quit [Client Quit]
sinkensabe has joined #ruby
acmehandle_ has joined #ruby
poguez_ has joined #ruby
_justin has quit [Quit: _justin]
<acmehandle_> Hi, does ruby have the same concept of namespace like perl and python? Or is ruby's concept of namespace like java?
<jhass> hm, neither I'd say
ephemerian has quit [Quit: Leaving.]
steeve has quit [Ping timeout: 252 seconds]
<acmehandle_> Ok, so does ruby handle its memory like python? Meaning in python everything links back to a 'table' of values
akonny has joined #ruby
<jhass> rubys namespaces are modules (of which classes are a subclass of), the filename/path where those a defined doesn't relate beyond conventions
<workmad3> acmehandle_: http://patshaughnessy.net/ruby-under-a-microscope may be of interest to you
el_diablo has joined #ruby
<acmehandle_> Yes, interesting. Thank you.
<acmehandle_> Oh, I have to buy the book?
steeve has joined #ruby
whyy has joined #ruby
<acmehandle_> No I'm not going to do that. I've bought hundreds of books and spent thousands of dollars on books over the years.
<hoelzro> I would say the organization of object members is an implementation detail
sailias1 has joined #ruby
sailias has quit [Read error: Connection reset by peer]
<workmad3> acmehandle_: well, you don't *have* to buy the book... I'm suggesting that, considering the types of questions you're asking that the book would be likely highly interesting to you
<hoelzro> you *could* implement them as a dictionary, but if you were clever, you could probably implement them with packed memory
JasmeetQA has joined #ruby
cocotton has joined #ruby
sinkensabe has quit [Ping timeout: 265 seconds]
baroquebobcat has quit [Quit: baroquebobcat]
bradhe has joined #ruby
railzFor_ has quit [Ping timeout: 252 seconds]
Rahul_Roy has joined #ruby
<acmehandle_> Thats a lot to chew on right there.
benzrf|offline is now known as benzrf
Wolland has joined #ruby
<acmehandle_> Thank you for that. That gives me something to think about.
railzForDaiz has joined #ruby
bluOxigen has joined #ruby
Joulse has quit [Quit: Joulse]
Gil_ has joined #ruby
hamakn has joined #ruby
<acmehandle_> But everything is not 'an object' in ruby like other languages are so fond of saying nowadays.
<acmehandle_> It seems
whyy has quit [Ping timeout: 240 seconds]
<hoelzro> acmehandle_: what do you mean?
<jhass> what's not an object in ruby that should be?
<workmad3> jhass: blocks are quantum-objects :) and the code itself isn't really an object...
<jhass> "..that should be"
Gil_ has quit [Remote host closed the connection]
<acmehandle_> I dont know. Honestly I'm just trying to make the bridge between python and ruby and then just wrap my mind around ruby as it is on its own. Unfortunately saying that a language is 'not object oriented' is used disparagingly nowadays which I think is silly.
<workmad3> jhass: ah... so you've never written lisp then? :)
<jhass> and I pretty much can get an object representation of a block
<jhass> hm, no
<acmehandle_> Never written lisp.
jpstokes has joined #ruby
<hoelzro> I think you could argue that individual variables in Ruby are not objects
<jpstokes> Hey I'm trying to figure out why when I run my tests it basically skips everything: https://gist.github.com/jpstokes/7887ef50ef0132875325
aantix has joined #ruby
<workmad3> jhass: lispers would say that the code itself should be part of the data... or in ruby terms, the code should be an object (and I think rubinius exposes a huge amount of that as objects you can manipulate and inspect at runtime)
<sdegutis> Hmm, this code is getting weird.
Asher has joined #ruby
bradhe has quit [Ping timeout: 265 seconds]
<jhass> acmehandle_: you might approach this from the wrong side, recognizing concepts you already know from other languages while learning a new one and then skipping ahead is good, but don't try to learn it by listing all concepts you know and trying to map them to the new language
<acmehandle_> for example, in python types are objects. A string would have its own set of functions available to manipulate the string.
<workmad3> acmehandle_: I'm not aware of people saying ruby isn't object-oriented... I'm aware of people saying *python* isn't object-oriented, and with a variety of, IMO, good reasons (starting with the complete lack of an implicit 'self' or 'this' concept inside methods)
<acmehandle_> I agree jhass, I am trying to tread carefully here.
<sdegutis> module Foo; extend self; def bar; 3; end; end; Foo.bar == 3
<jhass> jpstokes: because there's `skip` in every test?
<workmad3> acmehandle_: also, things like 'len(foo)' is not what people would typically class as OO
<sdegutis> I like this style, but it's hard to integrate with other Ruby code, which expects classes and instances.
<jpstokes> oh duh!
kpshek has quit []
<jpstokes> jhass: overlooked that! thx for pointing that out
nemesit|znc has joined #ruby
brandonblack has joined #ruby
djbkd has joined #ruby
jhulten has joined #ruby
<acmehandle_> Yeah, I dont know why anyone would consider len(dis) as a class.
dawkirst has joined #ruby
<acmehandle_> thats just a function.
<workmad3> acmehandle_: isn't that how python handles a lot of 'basic' functions though? :)
<acmehandle_> But what about types? Like strings, arrays. How many basic types does ruby have?
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mikepack has joined #ruby
yfeldblum has joined #ruby
<workmad3> acmehandle_: ruby doesn't have 'types'... it has classes
<acmehandle_> Right, fucntions
nanoyak has joined #ruby
<workmad3> acmehandle_: and classes are themselves objects, which you can call methods on...
<acmehandle_> But something like a = string ?
_justin has joined #ruby
<workmad3> a = String
<workmad3> >> a = String
<eval-in> workmad3 => String (https://eval.in/160165)
<acmehandle_> Or a = "String" ?
<jhass> >> a = String; b = a.new; b.size
<eval-in> jhass => 0 (https://eval.in/160166)
<workmad3> acmehandle_: a = "String" would create an instance of String with the contents "String"
dangerousdave has quit [Read error: Connection reset by peer]
dangerou_ has joined #ruby
<workmad3> >> a = "String"; a.class
<eval-in> workmad3 => String (https://eval.in/160167)
<acmehandle_> so is a = String legal? Or should it be only a = "String" ?
Sc0rp10n has quit [Remote host closed the connection]
banister has joined #ruby
anarang has quit [Quit: Leaving]
<jhass> we just showed you that it's legal
<workmad3> acmehandle_: both
<acmehandle_> Just wanted to confirm I didnt miss something.
<jhass> String is just a constant pointing to a instance of Class
<workmad3> acmehandle_: a = String; <-- that assigns the class String to the variable a, a = "String" <-- that assigns an instance of String to the variable a
mikesplain has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<workmad3> acmehandle_: >> sends some ruby code to eval-in, which runs it and gives you back the result ;)
Spami has quit [Quit: This computer has gone to sleep]
<workmad3> acmehandle_: so when we do '>> a = String' and eval-in comes back without errors, it's showing legal, working code ;)
IceDragon has quit [Ping timeout: 252 seconds]
IceDragon has joined #ruby
niharvey|call is now known as niharvey
<acmehandle_> eval-in: a = "String"
yfeldblum has quit [Ping timeout: 265 seconds]
aspires has joined #ruby
<acmehandle_> Not sure what that meant. Ok. Thank you. This is something to chew on.
subraminion has quit [Ping timeout: 260 seconds]
<apipkin> (bare with my n00bness here :) ) I have nested hashes like https://gist.github.com/apipkin/601cbaa9654d9f6a849e where the inner hash for each is the same structure. I want to get the inner hash of any of the element so I can iterate over the inner to build out the UI. In javascript I would do it like http://jsbin.com/pibeyofe/2/edit
redondos has quit [Excess Flood]
mikesplain has joined #ruby
redondos has joined #ruby
redondos has joined #ruby
redondos has quit [Changing host]
freerobby has joined #ruby
<workmad3> >> a = "string"
<eval-in> workmad3 => "string" (https://eval.in/160168)
danshultz has joined #ruby
<workmad3> acmehandle_: ^^ like that, use >> not 'eval-in:'
<workmad3> >> 1..10.to_a
<eval-in> workmad3 => undefined method `to_a' for 10:Fixnum (NoMethodError) ... (https://eval.in/160170)
<workmad3> >> (1..10).to_a
<eval-in> workmad3 => [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] (https://eval.in/160171)
mityaz has quit [Remote host closed the connection]
<acmehandle_> >> a = AcmeClassName
<eval-in> acmehandle_ => uninitialized constant AcmeClassName (NameError) ... (https://eval.in/160172)
benzrf is now known as benzrf|offline
<acmehandle_> >> a = "AcmeString"
<eval-in> acmehandle_ => "AcmeString" (https://eval.in/160173)
<jhass> apipkin: hash.each do |key, inner_hash| inner_hash.each do |inner_key, value|
<acmehandle_> >> a = AcmeClassName;
<eval-in> acmehandle_ => uninitialized constant AcmeClassName (NameError) ... (https://eval.in/160174)
hpoydar has quit [Remote host closed the connection]
<jhass> apipkin: make sure to choose better names thant hash, key, inner_hash, inner_key and value
<acmehandle_> >> a => AcmeClassName;
<eval-in> acmehandle_ => /tmp/execpad-7d05e4f05d2e/source-7d05e4f05d2e:2: syntax error, unexpected =>, expecting keyword_end ... (https://eval.in/160175)
mikecmpbll has quit [Ping timeout: 240 seconds]
<acmehandle_> >> a => AcmeClassName
<eval-in> acmehandle_ => /tmp/execpad-cd518c8e1160/source-cd518c8e1160:2: syntax error, unexpected =>, expecting keyword_end ... (https://eval.in/160176)
treehug8_ has joined #ruby
alex88 has quit [Quit: Leaving...]
<workmad3> acmehandle_: it would help if you used valid classes and ruby syntax ;)
<jhass> acmehandle_: please use irb or yet better pry for testing stuff, eval-in is only for demonstration purposes
weems has quit [Read error: Connection reset by peer]
<acmehandle_> Got it. Ok thanks
hpoydar has joined #ruby
weems has joined #ruby
jobewan has joined #ruby
<apipkin> jhass: and that would only do one of the outter hashes?
mijicd has quit [Remote host closed the connection]
<jhass> apipkin: no that would iterate through all hashes
andrewlio has quit [Quit: Leaving.]
treehug88 has quit [Ping timeout: 240 seconds]
<jhass> you can as well skip the second each and use inner_hash[key]
Gil_ has joined #ruby
JBreit has left #ruby ["Leaving"]
Hanmac1 has quit [Ping timeout: 260 seconds]
djbkd has quit [Remote host closed the connection]
<apipkin> jhass: yeah i’m just wanting one of the inner hashes. It doesn’t matter which one, but the keys aren’t constant so that’s where I’m getting stuck
Hobogrammer has quit [Ping timeout: 245 seconds]
troyready has quit [Quit: Leaving]
binaryhat has joined #ruby
<jhass> well then just pick the first one: hash.values.first
djbkd has joined #ruby
<jhass> or for a random one hash.values.sample
phansch has quit [Quit: WeeChat 0.4.3]
hpoydar has quit [Remote host closed the connection]
<apipkin> ah! I hadn’t seen those options yet :)
Xeago has quit [Read error: Connection reset by peer]
nanoyak has quit [Quit: Computer has gone to sleep.]
Xeago has joined #ruby
<apipkin> jhass: that’s perfect :) thank you so much!
saarinen has joined #ruby
saarinen has quit [Client Quit]
deric_skibotn has joined #ruby
hpoydar has joined #ruby
hpoydar has quit [Remote host closed the connection]
hpoydar has joined #ruby
djbkd has quit [Remote host closed the connection]
momomomomo has joined #ruby
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
klaut has quit [Remote host closed the connection]
Eiam has joined #ruby
saarinen has joined #ruby
chipotle has joined #ruby
JasmeetQA has quit [Read error: Connection reset by peer]
alem0lars has quit [Quit: Going AFK...]
djbkd has joined #ruby
djbkd has quit [Remote host closed the connection]
wallerdev has quit [Quit: wallerdev]
dilated_dinosaur has quit [Ping timeout: 260 seconds]
andrewjanssen has quit [Quit: Leaving...]
<cocotton> With the optparse lib, is there a way to specify we are waiting for a string with spaces in it, so users would not have a add quotes when using the flag?
Hanmac has joined #ruby
mduk has joined #ruby
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
<xybre> "waiting"?
iliketurtles has joined #ruby
timonv has quit [Remote host closed the connection]
djbkd has joined #ruby
andrewjanssen has joined #ruby
sdouglas has quit [Remote host closed the connection]
djbkd has quit [Remote host closed the connection]
<cocotton> just a way of saying that when you call the script with the flag -x, this last one should receive "a string with spaces in it", so that it just doesn't take the first word as input
Hobogrammer has joined #ruby
<mduk> hi, i'm pretty new to ruby so please forgive my ignorance, but i'm running into a little difficulty with Thor and manipulating an argument to my command. eg: def mycommand( myparam ). what I want to do is myparam.downcase! but it's moaning that myparam is "frozen". what does that mean and how do i reheat it? thanks! :)
blizzow has joined #ruby
<blizzow> Anyone here have suggestions on updating ruby definitions once ruby-build and rbenv have been installed via apt-get on an ubuntu system?
<xybre> ccooke: Oh, like the "--" a lot of commands have?
lkba has joined #ruby
<ccooke> xybre: too many cs :-)
DouweM has quit [Ping timeout: 245 seconds]
<jhass> mduk: frozen means that you can't modify the object anymore, just do the non-mutating version: myparam = myparam.downcase
binaryhat has quit [Quit: Leaving]
silkfox has quit [Ping timeout: 260 seconds]
ndrei has quit [Ping timeout: 276 seconds]
<mduk> jhass, ok will do. so thor arguments are just plain'old immutable. wasn't sure if i was missing something dumb. thanks! :)
<cocotton> xybre: I guess this could be it! Really new to the ruby world. What I'd like to do is to pass in a date like ruby myScript.rb -d 2014-06-09 12:56:00.000
<xybre> Oh, sorry, cocotton :D
hpoydar has quit [Remote host closed the connection]
<apeiros> cocotton: quote your argument
<xybre> ccooke: Yep I blured the two together :D
<cocotton> apeiros: Is there a way not to be force to quote the argument? Feels a bit dirty to me
<cocotton> xybre: haha np!
<apeiros> cocotton: that's more related to how shells and shell arguments work than ruby
<xybre> cocotton: You can jsut grab the next 2 or more args after that, but you'd do it manually, I don't think optparse supports it.
<apeiros> cocotton: it's the proper way. or provide the date without a space (e.g. iso8601 style with a T)
<apeiros> xybre: ew
<apeiros> violate expectations by working differently than all other shell tools?
<xybre> cocotton: The "splitting" of the arguments and parsing of them is handled by the shell so Ruby never gets the raw string (I just had to check).
<cocotton> apeiros: oh ok ok nice, thx :)
hpoydar has joined #ruby
<apeiros> seriously, if anything is dirty - and not just a bit - then it's custom arg handling.
danshultz has quit [Ping timeout: 260 seconds]
<cocotton> apeiros: with quotes it's going to be then ;)
djbkd has joined #ruby
i_s has joined #ruby
<xybre> apeiros: Like I said above I was expecting "--" to end the sequence of normal stuff. -d taking two args does seem strange. Typically you'd put a comma between them.
chipotle has quit [Quit: cya]
<xybre> (or in quotes, of course)
benzrf|offline is now known as benzrf
<apeiros> xybre: if it was considered 2 arguments, yes. but in this case, it's supposed to be one
TheCuban has joined #ruby
frem_ has joined #ruby
<apeiros> xybre: alternative to , is multiple flags, like with ruby's -I or -r
djbkd has quit [Remote host closed the connection]
cocotton has quit [Remote host closed the connection]
zigomir has quit [Remote host closed the connection]
danijoo has joined #ruby
gruz0[russia] has joined #ruby
<xybre> apeiros: Yeah I sorta glossed over the actual use case, that was my bad. I was imagining a different one when I made my suggestion.
sambao21 has joined #ruby
sambao21 has quit [Client Quit]
tkuchiki has quit [Remote host closed the connection]
b1205 has quit [Ping timeout: 260 seconds]
silkfox has joined #ruby
wallerdev has joined #ruby
dilated_dinosaur has joined #ruby
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
<xybre> Tangentially I found an interesting commandline interface DSL https://github.com/docopt/docopt.rb
luisjose has quit [Quit: Leaving...]
Zamerick has joined #ruby
<banister> DSL ka dyan!
heftig has quit [Quit: Quitting]
workmad3 has quit [Quit: Lost terminal]
heftig has joined #ruby
havenwood has joined #ruby
GriffinHeart has quit [Remote host closed the connection]
<Hanmac> ping havenwood ;P are you feeling like in Episode 42 where the alien does burn everyone too because of the outdoor temperature? ;P
oo_ has quit [Remote host closed the connection]
silkfox has quit [Ping timeout: 252 seconds]
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
nyamx2 has joined #ruby
forcefsck has quit [Ping timeout: 240 seconds]
<havenwood> maybe
jkline has joined #ruby
jkline has quit [Client Quit]
sputnik13 has joined #ruby
<sdegutis> Hmm, turns out I actually want instances and inheritance, so that state will be reset with each new instance, and inherited methods will have the new state.
<sdegutis> Weird.
starfox_21 has joined #ruby
<sdegutis> Hoorah for mutable state.
sambao21 has joined #ruby
nyamx2 has quit [Ping timeout: 265 seconds]
b1205 has joined #ruby
rdark has quit [Quit: leaving]
michaelchum has joined #ruby
goleldar has joined #ruby
tessi_zz is now known as tessi
baroquebobcat has joined #ruby
dangerou_ has quit [Read error: Connection reset by peer]
nanoyak has joined #ruby
lkba has quit [Ping timeout: 245 seconds]
yfeldblum has joined #ruby
dangerousdave has joined #ruby
goleldar has quit [Client Quit]
yfeldblu_ has joined #ruby
<sdegutis> Ahh, I can pass the helper (of a new instance) to the lambda.
bmurt has joined #ruby
gregf has quit [Quit: WeeChat 0.4.3]
ixti has quit [Quit: WeeChat 0.4.3]
m8 has joined #ruby
yfeldblum has quit [Ping timeout: 276 seconds]
yfeldblu_ has quit [Ping timeout: 240 seconds]
dels has quit [Quit: Leaving.]
wald0 has joined #ruby
morinap has quit [Quit: late]
<sdegutis> Phew!
<havenwood> stabby stab stab ->{}
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
<shevy> <-{}
<shevy> counter-stab
_justin has quit [Quit: _justin]
djbkd has joined #ruby
sputnik13 has joined #ruby
sputnik13 has quit [Max SendQ exceeded]
jhulten has quit [Remote host closed the connection]
sputnik13 has joined #ruby
morinap has joined #ruby
pietr0 has joined #ruby
postmodern has joined #ruby
silkfox has joined #ruby
krz has quit [Quit: WeeChat 0.4.3]
zigomir has joined #ruby
mityaz has joined #ruby
gregf has joined #ruby
sdouglas has joined #ruby
RaCx has joined #ruby
dawkirst has quit [Remote host closed the connection]
happytux has joined #ruby
<happytux> hi
gattuso has quit [Ping timeout: 260 seconds]
<happytux> I got a Rake related question, although I find it very ruby.
<happytux> system('build/vendor/node_modules/bin/bower', 'install',
<happytux> '--config.strict_ssl=false'
<happytux> ) or exit!(1)
<happytux> OK, so I want to add '--config.strict_ssl=false' to the args list only, when a variable is true.
reset has joined #ruby
<happytux> I could use a condition with slightly different invocations, but this will duplicate the code.
<happytux> I want to have only one invocation.
<jhass> build an array and splat it to the method
Hanmac has quit [Ping timeout: 252 seconds]
<happytux> jhass: it is not possible without an array?
Arkaniad|Laptop has quit [Remote host closed the connection]
<jhass> command = ['build/vendor/node_modules/bin/bower', 'install']; command << '--config.strict_ssl=false' if condition; system(*command)
dc has quit [Ping timeout: 240 seconds]
spastorino has joined #ruby
<shevy> my brain is not quite working
mrnugget has joined #ruby
<shevy> when it comes to the ruby readline module, how can I respond to tab-press events only IF the user has a leading proper word correct? for instance
<shevy> I have a dictionary for english and I wish to allow this:
<shevy> trans fo<PRESS_TAB_HERE>
<happytux> jhass: Can I also write this?
<happytux> command = ['build/vendor/node_modules/bin/bower', 'install']
<happytux> command << '--config.strict_ssl=false' if ENV.CI
<happytux> system(*command)
* happytux thinks that three lines are still OK to be pasted directly in IRC
<jhass> happytux: of course! never use ; in your code, that's just for brevity here
gattuso has joined #ruby
Arkaniad has joined #ruby
mordof has joined #ruby
<happytux> jhass: ah, ok! thank you very much
<mordof> I'm trying to convert a Date to a DateTime in Ruby - under rails i would use Date.current.in_time_zone, but Ruby doesn't have this method. is there a different way to go about doing that in Ruby?
hpoydar has quit [Remote host closed the connection]
<mordof> Note: I need the time zone awareness
<jhass> isn't there to_datetime?
<mordof> there's a to_time
<mordof> which isn't time zone aware
<mordof> puts it to the wrong zone
<benzrf> the world sucks
<benzrf> timezones suck
ndrei has joined #ruby
<mordof> yes.. yes they do
<benzrf> lets make a new world where we dont need em
<jhass> >> require 'date'; Date.today.to_datetime
<eval-in> jhass => #<DateTime: 2014-06-09T00:00:00+00:00 ((2456818j,0s,0n),+0s,2299161j)> (https://eval.in/160191)
Shidash has joined #ruby
<mordof> hmm
BizarreCake has joined #ruby
wald0 has quit [Quit: Lost terminal]
* mordof goes to check that
reset has quit [Ping timeout: 260 seconds]
<benzrf> lets make a planet with 256-day years and 32-day months
<benzrf> and no leap nonsense
wald0 has joined #ruby
<jhass> benzrf: you could just switch our calendar system to base 12
hpoydar has joined #ruby
sungai_keruh has joined #ruby
TheCuban has left #ruby [#ruby]
<brandonblack> I've never understood why so many people struggly with time zones
<brandonblack> its really pretty simple
luisjose has joined #ruby
<brandonblack> utc always on the back end, deal with tz on in the UI/application layer
Hanmac has joined #ruby
<brandonblack> DateTime.parse(utc) in ruby
<brandonblack> and Date.new(utc) in javascript
<mordof> brandonblack: first time working with time zones in a larger application.. and this is a situation where the database was storing dates, not datetimes
<brandonblack> never store a localized time
<mordof> brandonblack: so the conversion broke some logic on date where clauses
<happytux> jhass: I try to grasp what your code does. So the '<<' in [...]command <<[...] is a STDOUT operator like in C(++)?
<brandonblack> mordof: gotcha.
newUser1234 has quit [Remote host closed the connection]
<jhass> happytux: << is the ruby operator for "appending"
<mordof> brandonblack: to fix the from - to, i'm just doing (date + 1).to_datetime - 1
sdouglas has quit [Remote host closed the connection]
<mordof> then the <= will work
strax has quit [Quit: Connection closed for inactivity]
<jhass> "foo" << "bar" #=> "foobar"; [:a] << :b #=> [:a, :b] etc
mikepack has quit [Remote host closed the connection]
boris has quit [Ping timeout: 245 seconds]
<jhass> happytux: like all ruby operators it's actually a method you can look up in the docs
robert__ has joined #ruby
<benzrf> >> class Fixnum; def << other; "#{self}#{other}".to_i; end; end; 3 <<
<eval-in> benzrf => /tmp/execpad-b4d57dcb6310/source-b4d57dcb6310:3: syntax error, unexpected keyword_rescue ... (https://eval.in/160192)
<benzrf> >> class Fixnum; def << other; "#{self}#{other}".to_i; end; end; 3 << 4
<eval-in> benzrf => 34 (https://eval.in/160193)
<eam> cardinal rule for any object oriented language: overload << and >> in some new and confusing way
<benzrf> >> class Fixnum; def << other; "#{self}#{other}".to_i; end; end; 55 << 23 << 98
<eval-in> benzrf => 552398 (https://eval.in/160194)
<benzrf> :^)
robert_ has quit [Disconnected by services]
boris has joined #ruby
hpoydar has quit [Ping timeout: 276 seconds]
<Hanmac> eam you know what Fixnum already use << for bitshift?
<happytux> jhass: and one can put the condition part to the end instead to the beginning of the body of an if condition?
<happytux> jhass: I find this intuitive, didn't know this is possible in ruby
<jhass> yes, it's called modifer-if
alexju has quit [Remote host closed the connection]
Azulinho has quit [Ping timeout: 245 seconds]
ghr has quit [Ping timeout: 276 seconds]
andrewlio has joined #ruby
djbkd has quit [Remote host closed the connection]
<benzrf> Hanmac: yes
newUser1234 has joined #ruby
<Hanmac> ups i messaged to the wrong guy ;P
<mordof> jhass: problem with to_datetime: i need to shift the date forward 1 day, then bring it back 1 second
<mordof> where as a -1 on to_datetime takes it back a day (same as date)
<jhass> so what exactly is the issue with to_time?
<mordof> it doesn't use the correct time zone
<mordof> it reads the system clock
ari-_-e has quit [Quit: Leaving]
mrnugget has quit [Quit: mrnugget]
bmurt has quit []
<mordof> i need it in UTC
<jhass> what's the "correct timezone"?
newUser1_ has joined #ruby
<jhass> >> (Date.today+1).to_time.utc-1
<eval-in> jhass => undefined method `today' for Date:Class (NoMethodError) ... (https://eval.in/160195)
<slash_nick> hehe
<jhass> >> require 'date'; (Date.today+1).to_time.utc-1
<eval-in> jhass => 2014-06-09 21:59:59 UTC (https://eval.in/160196)
<mordof> doing that grabs the to_time first, then converts it to UTC
* mordof tries it the other way around
<jhass> oh well
<jhass> >> require 'date'; (Time.now.utc.to_date+1).to_time-1
<eval-in> jhass => 2014-06-09 23:59:59 +0200 (https://eval.in/160197)
AlSquire has quit [Quit: This computer has gone to sleep]
<jhass> hm, not utc again
<jhass> I guess I'd go for Time.at
<mordof> i already have a date
andrewjanssen has quit [Quit: Leaving...]
klaut has joined #ruby
newUser1234 has quit [Ping timeout: 252 seconds]
jrhorn424 is now known as zz_jrhorn424
x1337807x has joined #ruby
mehlah has quit [Quit: Leaving...]
onewheelskyward has left #ruby ["Textual IRC Client: www.textualapp.com"]
<mordof> >> require 'date'; Time.find_zone("UTC").parse((Date.current + 1).to_s) - 1
<eval-in> mordof => undefined method `find_zone' for Time:Class (NoMethodError) ... (https://eval.in/160198)
<mordof> why is find_zone not available here?
<mordof> there's too many versions of datetime/time/date garbage, lol
<mordof> i never know what's available
<jhass> >> require 'date; date = Date.today; Time.new(date.year, date.month, date.day, 23, 59, 59, 0)
<eval-in> jhass => /tmp/execpad-cecbf2dab8ab/source-cecbf2dab8ab:2: unterminated string meets end of file ... (https://eval.in/160199)
<jhass> heh
<jhass> >> require 'date'; date = Date.today; Time.new(date.year, date.month, date.day, 23, 59, 59, 0)
<eval-in> jhass => 2014-06-09 23:59:59 +0000 (https://eval.in/160200)
_dels has joined #ruby
_dels is now known as dels
hpoydar has joined #ruby
<mordof> i guess that's what I'm doing, lol
* mordof tries it
papercode has joined #ruby
<mordof> jhass: that last paramter is seconds, correct?
<jhass> no, timezone
<mordof> ok
<mordof> i put it as 59 and it just worked, so i guess it ignored my invalid timezone offset, heh
nicksloan has left #ruby ["["Textual IRC Client: www.textualapp.com"]"]
Kricir has quit [Remote host closed the connection]
jxf has joined #ruby
mikecmpbll has joined #ruby
bmurt has joined #ruby
robert__ has quit [Ping timeout: 265 seconds]
djbkd has joined #ruby
cocotton has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bmurt has quit [Client Quit]
bradhe has joined #ruby
dawkirst has joined #ruby
akemrir has quit [Quit: WeeChat 0.4.3]
alexju has joined #ruby
krz has joined #ruby
andrewjanssen has joined #ruby
railzForDaiz has quit [Ping timeout: 245 seconds]
SilverKey has joined #ruby
cocotton has quit [Ping timeout: 260 seconds]
krz has quit [Client Quit]
<sdegutis> Heck yeah! Totally just passed a lambda around and suddenly my Ruby code looks insanely cleaner!
bradhe has quit [Ping timeout: 276 seconds]
dawkirst_ has joined #ruby
RandyT has joined #ruby
mattmcclure has joined #ruby
<csmrfx> woopla
robertodecurnex has quit [Ping timeout: 276 seconds]
RyanV has joined #ruby
whyy has joined #ruby
dawkirst has quit [Ping timeout: 240 seconds]
alem0lars has joined #ruby
mehlah has joined #ruby
mikepack has joined #ruby
noop has joined #ruby
mehlah has quit [Client Quit]
iliketurtles has quit [Quit: Textual IRC Client: www.textualapp.com]
ruralhack has joined #ruby
dawkirst_ has quit [Ping timeout: 260 seconds]
luisjose has quit [Quit: Leaving...]
reset has joined #ruby
whyy has quit [Ping timeout: 240 seconds]
reset has quit [Client Quit]
jottr has quit [Ping timeout: 240 seconds]
tyfighter has joined #ruby
mikepack has quit [Ping timeout: 240 seconds]
auxbuss has joined #ruby
<shevy> are procs making the ruby code better?
crazymykl has quit [Remote host closed the connection]
maroloccio has joined #ruby
gbchaosmaster has joined #ruby
b1205 has quit [Ping timeout: 245 seconds]
auxbuss has quit [Client Quit]
CodeBunny has joined #ruby
ruby659 has joined #ruby
<ruby659> hi all
<ruby659> I have this problem when i tryed to execute compass watch with susy
<ruby659> Unable to activate susy-2.1.2, because sass-3.2.19 conflicts with sass
ambient has joined #ruby
<jhass> do you have a Gemfile?
<happytux> jhass: wrong first argument
x1337807x has joined #ruby
<ruby659> if i desactivate sass-3.x compass not work
<happytux> jhass: command << '--config.strict_ssl=false' if ENV['CI'] == 'true'
<ruby659> and susy need a compass > 3.0
<happytux> jhass: I guess << will prepend?
mehlah has joined #ruby
<jhass> no, it appends
<ruby659> if i desactivate sass-2.x compass not work
benzrf is now known as benzrf|offline
ryanleesipes has joined #ruby
steeve has quit []
x1337807x has quit [Client Quit]
<shevy> *deactivate
havenwood has quit [Remote host closed the connection]
<ruby659> thx
b1205 has joined #ruby
<ruby659> someone had an idea ?
<jhass> ruby659: you could use compass latest beta http://rubygems.org/gems/compass/versions/1.0.0.alpha.19
<sdegutis> "void value expression" what the hell ruby?
<ruby659> oky, i will try thx
Bouncer0 has joined #ruby
mityaz has quit [Quit: See ya!]
B1n4r10 has joined #ruby
skaflem has quit [Quit: Leaving]
klaut has quit []
alvaro_o has joined #ruby
CodeBunny has quit [Read error: Connection reset by peer]
<ruby659> hum i have this error
Xeago has quit [Remote host closed the connection]
dawkirst has joined #ruby
crazymykl has joined #ruby
<jhass> looks like you're missing ruby-dev or whatever the package is on your system
lkba has joined #ruby
<ruby659> oky
<shevy> ruby659 you must run debian-based system; the debian developers often remove stuff to make you unhappy
<ruby659> i use ruby 1.9 with gem
<sdegutis> Wooow, this is batnutsinsane.
<ruby659> i'm noob with ruby
<ruby659> i only use for compass sass and susy
<sdegutis> If you use the ->{} lambda syntax, you can't pass implicit "do end" blocks to methods within it.
<shevy> ruby659 you are also a noob on debian; read here http://blogs.law.harvard.edu/hoanga/2006/10/27/fixing-mkmf-load-error-ruby-in-ubuntu/
<shevy> sdegutis really?
<sdegutis> apparently
<shevy> I'd never find out anyway, I hate the stabby proc too much to use it
<ruby659> It's ok that works
<ruby659> thanks guyz
<sdegutis> wow Ruby, you're kind of a stupid language
<happytux> jhass: command = ['build/vendor/node_modules/bin/bower', 'install']; command << '--config.strict_ssl=false' if ENV['CI'] == 'true'; system(command) or exit!(1)
<jhass> sdegutis: got a minimal example that reproduces?
<shevy> the ruby parser is a tricky beast
<happytux> jhass: wrong first argument
<sdegutis> jhass: sec
<jhass> happytux: scroll back and look what I wrote
ruby659 has quit [Quit: Page closed]
<jhass> you're missing something
<Hanmac> isnt stabby lambdas created to you can type less, and then you want to use do ... end?
Notte has joined #ruby
bwilson has joined #ruby
benzrf|offline is now known as benzrf
Bosox20051 has joined #ruby
jerius_ has joined #ruby
treehug8_ has quit []
<sdegutis> Oops, never mind.
<sdegutis> It only happens when you pass the ->()do..end to a method as the last arg.
BizarreCake has quit [Quit: Leaving]
<sdegutis> ... without parens
<sdegutis> Lame.
<jhass> no, perfectly sensible, the original distinction between { } and do end for blocks is the precedence
jerius has quit [Ping timeout: 260 seconds]
<jhass> foo bar { } vs. foo bar do end
<jhass> first passed the block to bar, second to foo
<happytux> jhass: I can't scroll back, my IRC client screwed it :(
<jhass> happytux: you're missing the splat part, it's system(*command)
<sdegutis> This is dumb.
Tricon has joined #ruby
ambient has quit [Quit: Page closed]
AlexRussia has quit [Excess Flood]
Blaguvest has quit [Read error: Connection reset by peer]
jottr has joined #ruby
nhhagen has joined #ruby
nhhagen has quit [Remote host closed the connection]
AlexRussia has joined #ruby
dawkirst has quit [Ping timeout: 245 seconds]
<sdegutis> man, cleaning my code up is making such a mess of my code
pushpak has joined #ruby
GriffinHeart has joined #ruby
B1n4r10 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jottr has quit [Ping timeout: 245 seconds]
newUser1_ has quit [Read error: Connection reset by peer]
carraroj has joined #ruby
stantona has quit [Remote host closed the connection]
newUser1234 has joined #ruby
AlexRussia has quit [Client Quit]
troyready has joined #ruby
naw has quit [Remote host closed the connection]
nhhagen has joined #ruby
naw has joined #ruby
<shevy> lol
<shevy> you are funny sdegutis
alem0lars has quit [Quit: alem0lars]
<shevy> but you may end up like me
GriffinHeart has quit [Ping timeout: 245 seconds]
<shevy> and never use -> again
<sdegutis> i am already using "def cmd.run()" instead
mania has joined #ruby
<Hanmac> i always know that this stabby lambdas are backstabbing me one day ;P
<shevy> you seem to like ()
<jhass> ew, empty parens in a method def
<shevy> Hanmac do you use -> ?
nhhagen has quit [Client Quit]
<Hanmac> shevy: nope, i call them brutus lambdas ;P
moritzschaefer has joined #ruby
<sdegutis> I wish Ruby did more lexical scoping and less dynamic scoping.
alem0lars has joined #ruby
<Hanmac> because of the backstabbing ... and the syntax "->()" already looks like backstabbing ...
reset has joined #ruby
<shevy> you make it sound as if you could have the same feature support in both situations sdegutis
<shevy> Hanmac yeah it's an operator for thieves and assassins
<shevy> in other words, honourless low-life scum
shadoi has joined #ruby
gtc has quit [Remote host closed the connection]
<Hanmac> shevy depends in some Fantasy books of Terry Pratchett assassins have a high moral code compared to simple killers ... like they dont kill someone if they not get paid for that
<shevy> Terry Pratchett is a pirate.
<crome> yarrrr
<mania> Guys, quick question: Will "select * from Table where col1 = 'desiredvalue' order by RAND() limit 1" become "Table.first(col1: 'desiredvalue').order(Sequel.lit('RAND()'))" in Sequel? I know that using RAND() isn't recommended. But this is a very small table with < 50 rows
andrewjanssen has quit [Quit: Leaving...]
iamvery has joined #ruby
AlexRussia has joined #ruby
Photism has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
testcore has joined #ruby
RyanV has quit [Quit: Computer has gone to sleep.]
<jhass> mania: easy enough to try out, isn't it?
<mania> I was interested in whether I'm understanding it correctly. I'm new to Sequel .. so still not confident
gtc has joined #ruby
<mania> Even if it works, I won't know if this is the right way to do this :)
beef-wellington has joined #ruby
dawkirst has joined #ruby
nanoyak has quit [Quit: Computer has gone to sleep.]
jimbauds has quit [Ping timeout: 252 seconds]
<jhass> not sure if you need the Sequel.lit in the order clause, but looks fine to me
silkfox has quit [Read error: Connection reset by peer]
<mania> ok. thank you!
<sdegutis> Indecision paralysis.
bradhe has joined #ruby
djbkd has quit [Remote host closed the connection]
blizzow has quit [Ping timeout: 260 seconds]
Xeago has joined #ruby
dpp has joined #ruby
akonny has quit [Quit: akonny]
Gil_ has quit [Remote host closed the connection]
shvelo has joined #ruby
revoohc has joined #ruby
b1205 has quit [Ping timeout: 260 seconds]
jezen has joined #ruby
<shvelo> hi shevy
sambao21 has quit [Quit: Computer has gone to sleep.]
<shevy> hey shvelo
<shvelo> >>binding.eval "binding.eval\" puts 'inception' \""
<eval-in> shvelo => inception ... (https://eval.in/160225)
<shvelo> what's up shevy
vpretzel has quit [Quit: Adios!]
bradhe has quit [Ping timeout: 260 seconds]
<shevy> shvelo not much, not doing much coding; the little I do mostly is to continue porting old code
<shevy> like all my ruby-gnome collection, about 400 files
jezen has quit [Client Quit]
<shvelo> cool
<shvelo> I was writing a stupid template engine
<shvelo> it's good for learning
<shvelo> :D
mikesplain has quit [Ping timeout: 265 seconds]
mania has quit [Quit: Page closed]
JBreit has joined #ruby
sambao21 has joined #ruby
ta has quit [Ping timeout: 265 seconds]
RaCx has joined #ruby
mikesplain has joined #ruby
doev has quit [Quit: Verlassend]
boris has quit [Remote host closed the connection]
linojon has joined #ruby
Notte_ has joined #ruby
terrell_t has joined #ruby
ta has joined #ruby
cocotton has joined #ruby
jxf has quit [Ping timeout: 240 seconds]
Shidash has quit [Quit: Leaving.]
luksaur has quit [Ping timeout: 265 seconds]
x1337807x has joined #ruby
Notte has quit [Ping timeout: 260 seconds]
pushpak has quit [Quit: Linkinus - http://linkinus.com]
terrell_t has quit [Remote host closed the connection]
yfeldblum has joined #ruby
Mon_Ouie has joined #ruby
terrellt has quit [Ping timeout: 240 seconds]
Xeago has quit [Read error: Connection reset by peer]
dawkirst has quit [Quit: Leaving...]
<sdegutis> current status: writing clojure-like code in ruby
failshell has joined #ruby
robertodecurnex has joined #ruby
thrownaway has quit [Ping timeout: 240 seconds]
mark_locklear has quit [Ping timeout: 265 seconds]
shvelo has quit [Ping timeout: 276 seconds]
jezen has joined #ruby
zonetti has quit [Ping timeout: 252 seconds]
carraroj has quit [Quit: Konversation terminated!]
mikepack has joined #ruby
Xeago has joined #ruby
<jezen> I’m trying to run `rake db:reset` from a .rb file. I’m already doing `require "rake"; load "Rakefile"; Rake::Task[:db:reset].invoke`, but predictably, Ruby is confused by the colon in the symbol. How can I work around this?
andrewjanssen has joined #ruby
ffranz has quit [Ping timeout: 252 seconds]
JBreit has left #ruby ["Leaving"]
<jhass> pass a string
mark_locklear has joined #ruby
<jhass> but for reference you'd be able to write :'db:reset'
stantona has joined #ruby
toastynerd has quit [Remote host closed the connection]
zonetti has joined #ruby
<sdegutis> ruby does not make it easy to test my code
FifthWall has quit [Ping timeout: 252 seconds]
<jezen> jhass: Thanks!
alem0lars has quit [Ping timeout: 265 seconds]
blizzow has joined #ruby
mikepack has quit [Ping timeout: 260 seconds]
andrewhl has joined #ruby
acmehandle_ has quit [Ping timeout: 252 seconds]
alem0lars has joined #ruby
benzrf is now known as benzrf|offline
i_s has quit [Read error: Connection reset by peer]
terrellt has joined #ruby
i_s has joined #ruby
professor_soap has joined #ruby
<professor_soap> hello :)
shtirlic has quit [Ping timeout: 240 seconds]
FifthWall has joined #ruby
professor_soap has left #ruby [#ruby]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
shtirlic has joined #ruby
Davey has quit [Max SendQ exceeded]
Sawbones has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
wald0 has quit [Quit: Lost terminal]
b1205 has joined #ruby
Gil_ has joined #ruby
Davey has joined #ruby
jezen has quit []
Martxel has joined #ruby
mikepack has joined #ruby
Rahul_Roy has quit [Quit: Connection closed for inactivity]
horrror has joined #ruby
ffranz has joined #ruby
newUser1_ has joined #ruby
nemesit|znc has quit [Ping timeout: 260 seconds]
<horrror> i'm trying to user paperclip-ffmpeg to convert mp4 to wav with 16k rate . i'm kinda stuck. https://gist.github.com/anonymous/08ba56f529311c56a25e
<horrror> how to fill parameters here?
newUser__ has joined #ruby
nemesit|znc has joined #ruby
newUser1234 has quit [Ping timeout: 240 seconds]
Asher has quit [Quit: Leaving.]
DanishMan has joined #ruby
Xeago has quit [Read error: Connection reset by peer]
newUser1_ has quit [Ping timeout: 240 seconds]
<atmosx> horrror: try #rubyonrails
jerius_ has quit []
treehug88 has joined #ruby
frem_ has quit [Ping timeout: 260 seconds]
zz_jrhorn424 is now known as jrhorn424
sdouglas has joined #ruby
hpoydar has quit [Remote host closed the connection]
andrewhl has quit [Quit: andrewhl]
guyz has quit [Quit: quit]
ruralhack has quit [Ping timeout: 260 seconds]
el_diablo has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
Bosox20051 has quit [Read error: Connection reset by peer]
ruralhack has joined #ruby
rm_ has quit []
pontiki has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
aspires has quit []
jerius has joined #ruby
sdouglas has quit [Remote host closed the connection]
sambao21 has joined #ruby
cearls has joined #ruby
sungai_keruh has quit [Quit: Leaving]
SCommette has quit [Quit: SCommette]
relix has joined #ruby
benzrf|offline is now known as benzrf
Nilium has joined #ruby
RaCx has joined #ruby
gruz0[russia] has quit [Quit: This computer has gone to sleep]
Burgestrand_ has joined #ruby
djbkd has joined #ruby
benzrf is now known as benzrf|offline
horrror has quit [Quit: horrror]
ascarter has joined #ruby
TheComrade has joined #ruby
moritzschaefer has quit [Ping timeout: 276 seconds]
<TheComrade> Strange days. I have a conditional like: if !(File.exists f && File.size(f) == ...). f does not exist, but the short circuiting isn't ... short circuiting, and I get an exception thrown on File.size (file does not exist). Can someone explain this behavior?
shvelo has joined #ruby
horrror has joined #ruby
horrror has quit [Client Quit]
bradhe has joined #ruby
<hoelzro> are you sure it's not parsing as File.exists(f && File.size(f))?
<hoelzro> try File.exists(f) rather than File.exists f
BizarreCake has joined #ruby
mikecmpbll has quit [Quit: i've nodded off.]
Ankhers has quit [Ping timeout: 264 seconds]
<jhass> TheComrade: also unless you got an elsif use unless over if !(..)
robert_ has joined #ruby
<TheComrade> jhass, yeah, will do, just for debugging purposes... I have added a variety of parentheses with no joy yet.
djbkd has quit [Remote host closed the connection]
<jhass> unless File.exists?(filename) && File.size(filename) == size
<TheComrade> It looks like I can use size? to simplify the conditional but I want to know what's going on anyway...
stantona_ has joined #ruby
robert_ has quit [Max SendQ exceeded]
robert_ has joined #ruby
<TheComrade> hoelzro: I got a paren combo that avoids the exception, so I guess that was it. Thanks!
Burgestrand_ has quit [Quit: Burgestrand_]
decoponio has quit [Quit: Leaving...]
bradhe has quit [Ping timeout: 260 seconds]
mikecmpbll has joined #ruby
stantona has quit [Ping timeout: 260 seconds]
toastynerd has joined #ruby
frem_ has joined #ruby
maximski has joined #ruby
Azulinho has joined #ruby
xaxisx has joined #ruby
codecop has joined #ruby
djbkd has joined #ruby
soulcake has quit [Read error: Connection reset by peer]
dc has joined #ruby
klaut has joined #ruby
soulcake has joined #ruby
redondo has quit [Ping timeout: 276 seconds]
jackneill has quit [Read error: Connection reset by peer]
frem_ has quit [Ping timeout: 260 seconds]
danijoo has quit [Read error: Connection reset by peer]
hpoydar has joined #ruby
alem0lars has quit [Quit: alem0lars]
danijoo has joined #ruby
shadoi has quit [Quit: Leaving.]
Bouncer0 has quit [Quit: Wychodzi]
Bouncer0 has joined #ruby
RaCx_ has joined #ruby
RaCx has quit [Ping timeout: 260 seconds]
RaCx_ is now known as RaCx
moritzschaefer has joined #ruby
gattuso has quit [Quit: YUK]
jheg has joined #ruby
Burgestrand_ has joined #ruby
aspires has joined #ruby
treehug88 has quit []
timmow has quit [Ping timeout: 260 seconds]
akonny has joined #ruby
jxf has joined #ruby
wallerdev has quit [Quit: wallerdev]
oo_ has joined #ruby
wjimenez52711 has joined #ruby
phutchins has quit [Ping timeout: 276 seconds]
nanoyak has joined #ruby
timmow has joined #ruby
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
gattuso has joined #ruby
yfeldblum has quit [Remote host closed the connection]
RaCx has quit [Quit: Computer has gone to sleep.]
nanoyak has quit [Read error: Connection reset by peer]
sambao21 has quit [Quit: Computer has gone to sleep.]
RaCx has joined #ruby
nanoyak has joined #ruby
Mattx has joined #ruby
<Mattx> Hi
<Mattx> is there a built in function to replace a char in a certain position in a string?
<Mon_Ouie> string[pos] = 'c'
<Mattx> something like: (a[2] = "#"; a)
<Mattx> Mon_Ouie, I want to use the result in the same line
sambao21 has joined #ruby
noop has quit [Ping timeout: 276 seconds]
<Mon_Ouie> Your own example fits in one line
yfeldblum has joined #ruby
taybin has joined #ruby
<Mon_Ouie> (I know what you mean, I just think it's pointless… you can use tap if you really want)
<Mattx> I know, but I'm asking in case a built in function such as .replace or something exist
ruralhack has quit [Quit: Leaving]
oo_ has quit [Ping timeout: 260 seconds]
<Mattx> (you really don't want to use <a[2] = "#"; a> in any real code, it sucks
oo_ has joined #ruby
justin_pdx has joined #ruby
shvelo has quit [Ping timeout: 252 seconds]
<Mon_Ouie> There's nothing wrong with having a program that's more than one line
jimbow has joined #ruby
<justin_pdx> Hi folks. I'm seeing code that begins with an equals sign, like =begin followed by =end on a later line - what does this mean?
<Mon_Ouie> justin_pdx: It's a comment
maximski has quit []
<Mon_Ouie> Notice it has to be at the beginning of the line, you can't indent '=begin' or '=end'
<lemur> Anyone know of a way to require different gems dependent on the ruby version?
<justin_pdx> Thank you, Mon_Ouie.
<banister> Mon_Ouie 'alutte svp
<Mon_Ouie> gem 'name', (RUBY_VERSION >= '2.0' ? '~> 1.0' : '~> 2.0')
<Mon_Ouie> And then just require
<Mon_Ouie> (The problem is you can't do something like that in a gempsec if that's what you mean)
shadoi has joined #ruby
Kricir has joined #ruby
Bouncer0 has quit [Quit: Wychodzi]
oo_ has quit [Ping timeout: 240 seconds]
elaptics is now known as elaptics`away
frem_ has joined #ruby
justin_pdx has quit [Quit: justin_pdx]
SCommette has joined #ruby
Notte_ has quit [Remote host closed the connection]
stef1a has joined #ruby
<stef1a> how do i open a file, iterate over each line, and perform a regex sub on matching lines? with what i currently have ( http://pastie.org/pastes/9274849/text ), the output file is the same name as the original, but the contents are empty
treehug88 has joined #ruby
<happytux> jhass: Why do I have to use a '*' in `system(*command)` ? Some kind of reference/pointer?
terrellt has quit [Remote host closed the connection]
mikesplain has quit [Ping timeout: 276 seconds]
terrellt has joined #ruby
<jhass> happytux: it's a splat, it takes an array and passes its elements as individual arguments
oo_ has joined #ruby
mikesplain has joined #ruby
djbkd has quit [Remote host closed the connection]
jimbow has quit [Quit: jimbow]
djbkd has joined #ruby
terrell_t has joined #ruby
DouweM has joined #ruby
momomomomo has quit [Read error: Connection reset by peer]
jprovazn_afk is now known as jprovazn
momomomomo has joined #ruby
<Mon_Ouie> stef1a: Modifying a file in-place like that is not so easy because the cursor is moved as you're reading and as you're writing. Really the simplest way is to write to a temporary file and then rename the temporary file to the input.
terrellt has quit [Read error: Connection reset by peer]
<Mon_Ouie> (in your case you may be able to get away without it because your output is always going to be smaller than your input… but I wouldn't bother)
<sdegutis> trying to use ruby without using classes is a recipe for disaster :(
sdegutis has left #ruby [#ruby]
newUser__ has quit [Remote host closed the connection]
oo__ has joined #ruby
<toretore> stef1a: you can read one line at a time from the input file and write one line at a time to the output file
digifiv5e has joined #ruby
oo_ has quit [Ping timeout: 276 seconds]
digifiv5e is now known as Guest47880
sinkensabe has joined #ruby
<jheg> what is the purpose of .collect if .map does the same thing?
<toretore> it's an alias
<toretore> its purpose is the same
GriffinHeart has joined #ruby
stantona_ has quit [Remote host closed the connection]
<jheg> yeah but whats the point if they do the same thing?
Hanmac1 has joined #ruby
<jheg> which came first?
stantona has joined #ruby
<toretore> what is the purpose of map if collect does the same thing?
<toretore> does it matter?
<DouweM> jheg: "the point" is that these are both common names for the same practice, so we have both names so people can use whichever they prefer
<jheg> yep
<toretore> no, it doesn't
<happytux> jhass: so if I don't use the splat 'operator', the array would be passed to first argument and then the method will fail
<happytux> ah
oo_ has joined #ruby
<Mon_Ouie> It's not like one really came first, they came from different languages. map from functional programming languages, collect from Smalltalk.
<DouweM> jheg: "which cames first" matters very little. the only thing that *may* matter is which is more popular/common in open source Ruby code. In that case, probably #map
<jheg> toretore: I'm just trying to understand the language
stantona has quit [Read error: No route to host]
Hanmac has quit [Ping timeout: 240 seconds]
shadoi has quit [Ping timeout: 265 seconds]
<stef1a> Mon_Ouie: toretore: ah, beautiful. thank!
SCommette has quit [Quit: SCommette]
<stef1a> thanks! *
stantona has joined #ruby
<toretore> jheg: and that is what you shall understand: it doesn't matter
oo__ has quit [Ping timeout: 265 seconds]
_JokerDoom has joined #ruby
GriffinHeart has quit [Ping timeout: 245 seconds]
<jheg> toretore: thanks i'll try not to worry about it
cocotton has quit [Ping timeout: 260 seconds]
<toretore> worry bad, silent mind good
<DouweM> jheg: it's definitely useful to know which is more popular, but there's no "original" one, really
morinap has quit [Remote host closed the connection]
morinap has joined #ruby
oo__ has joined #ruby
JokerDoom has quit [Ping timeout: 265 seconds]
Kricir has quit [Remote host closed the connection]
oo_ has quit [Ping timeout: 260 seconds]
baroquebobcat has quit [Ping timeout: 260 seconds]
Takle has quit [Remote host closed the connection]
<jheg> DouweM: thanks
jezen has joined #ruby
jottr has joined #ruby
Notte has joined #ruby
<jezen> I’m trying to insert NULL into a postgres date field. How can I create NULL with Ruby?
<DouweM> nil
Xeago has joined #ruby
x1337807x has joined #ruby
Kricir has joined #ruby
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Boohbah has joined #ruby
<jezen> I’m not sure that’ll work in my case; I’m programmatically building insert queries
<jezen> so each value is wrapped in single quotes
ELLIOTTCABLE has joined #ruby
<Boohbah> hello, what is best gem for parsing atom feeds?
treehug8_ has joined #ruby
<jezen> and I think `nil` when wrapped in single quotes is interpreted as an empty string
<jhass> jezen: ew, just let the pg gem do the escaping
<DouweM> anything within single quotes is a string. you can't put nil in single quotes. and yeah, use actual parameterized queries
<DouweM> don't try to roll your own
<jezen> ok, thanks
morinap has quit [Ping timeout: 260 seconds]
timgauthier has joined #ruby
oo__ has quit [Ping timeout: 260 seconds]
treehug__ has joined #ruby
Takle has joined #ruby
treehug88 has quit [Ping timeout: 245 seconds]
Xeago_ has joined #ruby
sinkensabe has quit [Remote host closed the connection]
sinkensabe has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
bradhe has joined #ruby
<Mattx> so guys does anybody know if a function for inline string replacement exist?
benzrf|offline is now known as benzrf
terrell_t has quit [Remote host closed the connection]
Zamerick has quit [Remote host closed the connection]
<hoelzro> Mattx: inline string replacement?
Xeago has quit [Ping timeout: 276 seconds]
<jhass> Mattx: .replace ?
<DouweM> .gsub
Zenigor has quit [Remote host closed the connection]
<Mattx> text = "foobar"; i = 2; -> text[i] = "#"; text
<Mattx> this ^
BizarreCake has quit [Quit: Leaving]
<DouweM> well there you have it
sinkensabe has quit [Read error: Connection reset by peer]
treehug8_ has quit [Ping timeout: 276 seconds]
sinkensabe has joined #ruby
<Mattx> I can't concatenate other functions after it, I was looking for something more like this: text.repl(i, "#").whateverhere
terrellt has joined #ruby
<jhass> text.tap {|s| s[i] = '#' }
treehug__ has quit [Ping timeout: 240 seconds]
oo_ has joined #ruby
<DouweM> >> "abc".[]=(1, "x").reverse
<eval-in> DouweM => "x" (https://eval.in/160240)
<DouweM> eh
andrewlio has quit [Remote host closed the connection]
wallerdev has joined #ruby
<Mon_Ouie> setters (foo= methods) always return the rhs
<Mattx> isn't it weird that this function does not exist? there are like 10 ways to achieve this, but nothing like .repl :P
<DouweM> Mon_Ouie: I know that's the case in general, hoped it'd behave more method-y here
<DouweM> Mon_Ouie: but alas :)
<Mattx> ok, I'm writing my own...
<jhass> Mattx: if you provide the larger context we may be able to come up with a different solution
<DouweM> Does anyone else thing #gsub is a pretty terrible method name
<DouweM> What's wrong with #replace
Dreamer3 has joined #ruby
<jhass> it's taken
<wallerdev> lol
bradhe has quit [Ping timeout: 260 seconds]
<DouweM> and thus shows my ignorance
<DouweM> all right
<wallerdev> they should gsub replace with gsub
<Dreamer3> does rdoc document all constants? evey those i just reference in passing?
mark_locklear has quit [Ping timeout: 240 seconds]
<Dreamer3> Library.test causes a file to be generated for Library, is that a way to turn that off or tweak it?
qwyeth has quit [Quit: Leaving]
mehlah has quit [Ping timeout: 240 seconds]
<jhass> DouweM: also it's basically a specialization of .sub
<DouweM> still, I'd prefer replace for gsub and [something else] for replace. replacing X by Y is far more common than replacing the entire string
jtiggo has joined #ruby
<Mon_Ouie> It's because #replace is not a string-specific operation
<DouweM> jhass: right. lots of languages have a specific g flag, that makes sense. #sub is not that bad, but gsub just looks weird
<wallerdev> i like the name gsub
<Mon_Ouie> It behaves the same way as Hash#replace and Array#replace
Gil_ has quit [Remote host closed the connection]
<DouweM> Mon_Ouie: yeah I know
<wallerdev> the triick is to say it as one syllable
<lemur> As do I, you do enough Unix scripting and it makes lots of sense.
<DouweM> wallerdev: I've come to like it, but from the onset it's weird
oo_ has quit [Ping timeout: 240 seconds]
sambao21 has joined #ruby
mehlah has joined #ruby
exgf has joined #ruby
shinobi_one has joined #ruby
newUser1234 has joined #ruby
Dreamer3 has quit [Ping timeout: 265 seconds]
xaxisx has quit [Quit: xaxisx]
<stef1a> so what do i do if i want to iterate over the lines in a file multiple times and perform multiple substitutions? should i just store the entire file (not very large) in a string and iterate over that repeatedly, performing the necessary substitutions? that seems like it would be easier
Burgestrand_ has quit [Quit: Burgestrand_]
<jhass> just do the substitutions in one loop?
<Mon_Ouie> You can very easily write line by line in a temporary file
<stef1a> but the latter substitutions rely on the former
aspires has quit []
sdouglas has joined #ruby
<jhass> so?
<stef1a> so how can i do all of them at once
Bira has quit [Remote host closed the connection]
SilverKey has quit [Quit: Halted.]
xaxisx has joined #ruby
<lemur> regex capture groups, learn them
<jhass> each_line do |line| line.gsub(...); line.gsub(...); ... end
jrhorn424 is now known as zz_jrhorn424
<jhass> er, gsub!
<stef1a> oh... duh...
paulfm has quit []
jprovazn has quit [Quit: Odcházím]
ascarter has joined #ruby
<stef1a> thanks jhass
oo_ has joined #ruby
<lemur> line.gsub().gsub()
<lemur> chain
cvitullo has joined #ruby
cvitullo has quit [Remote host closed the connection]
<lemur> or make sure to learn regex more in depth and get rid of multiple method calls.
akonny has quit [Quit: akonny]
Xeago_ has quit [Remote host closed the connection]
SilverKey has joined #ruby
SilverKey has quit [Max SendQ exceeded]
<lemur> >> 'string'.gsub('s','').gsub('t','')
<eval-in> lemur => "ring" (https://eval.in/160241)
Xeago has joined #ruby
<Mon_Ouie> .delete('st')
robertodecurnex has quit [Remote host closed the connection]
Xeago has quit [Read error: Connection reset by peer]
akonny has joined #ruby
<lemur> I'm aware, basic example
akonny has quit [Remote host closed the connection]
<lemur> chaining
<lemur> besides, those will return the same string if you just gsub
Xeago has joined #ruby
ndrei has quit [Ping timeout: 245 seconds]
frem_ has quit [Ping timeout: 260 seconds]
ctp_ has quit [Ping timeout: 260 seconds]
<Mon_Ouie> jhass: Mentioned he meant gsub!
sambao21 has quit [Quit: Computer has gone to sleep.]
<lemur> ah
ryanleesipes has quit [Quit: Leaving]
maletor has joined #ruby
<lemur> just saying, each_line { |line| line.gsub.gsub }
oo__ has joined #ruby
ryanleesipes has joined #ruby
<lemur> chain instead of that odd semicolon bit
oo_ has quit [Ping timeout: 260 seconds]
<jhass> that semicolon is just #ruby IRC for "press enter"
<Mon_Ouie> Those are new lines in reality. If the regexps/replacement strings end up taking a lot of space that looks less weird than chaining.
aspires has joined #ruby
emsilva has quit [Quit: Keep Walking (Computer Slept!)]
<stef1a> okay... how would i remove all lines before a particular regex match?
sdouglas has quit [Remote host closed the connection]
<jhass> hmmm. flip-flop? :P
<Mon_Ouie> If you need to do things like this writing everything line by line may not be the right solution
sdouglas has joined #ruby
jhulten has joined #ruby
<Mon_Ouie> You may want to just process the whole file and then write the new version
taybin has quit [Quit: This computer has gone to sleep]
freerobby has quit [Quit: Leaving.]
frem_ has joined #ruby
<stef1a> Mon_Ouie: how would i do that, and why would i want to?
mikesplain has quit [Ping timeout: 260 seconds]
Burgestrand_ has joined #ruby
xaxisx has left #ruby [#ruby]
<jheg> is there a short way of creating an array of numbers like there is for words with %w(an array of words)?
freerobby has joined #ruby
oo__ has quit [Ping timeout: 276 seconds]
<stef1a> there's just one thing i need to remove before a certain line in each file, and the rest of the matches can just be done line by line
sdouglas has quit [Remote host closed the connection]
<DouweM> jheg: no built in way, but you can of course .map(&:to_i)
treehug88 has joined #ruby
<Morrolan> jheg: How would you shorten [1, 2, 3]? The sole advantage of %w is that you needn't type quotes.
SCommette has joined #ruby
b1205 has quit [Ping timeout: 245 seconds]
<DouweM> also, what morrolan says. there's really no need for that in the case of numbers
<DouweM> .map(&:to_i), while working, is much longer than those couple of commas
b1205 has joined #ruby
<Mon_Ouie> Oh, then you can probably just skip lines until you find the match that says you have to start processing
<jhass> jheg: if they're sequences make sure to keep Range in mind
happytux has quit [Quit: ChatZilla 0.9.90.1-rdmsoft [XULRunner 22.0/20130619132145]]
<stef1a> Mon_Ouie: oh. what's the optimal way to do that?
<Mon_Ouie> loop until input.gets matches your regexp
<jheg> Morrolan: good point :)
<jheg> jhass: what does that mean?
sambao21 has joined #ruby
<Mon_Ouie> (then continue with each_line as before)
<jhass> >> (1..4).to_a
<eval-in> jhass => [1, 2, 3, 4] (https://eval.in/160244)
<jhass> >> (1..6).step(2).to_a
<eval-in> jhass => [1, 3, 5] (https://eval.in/160245)
oo__ has joined #ruby
sdouglas has joined #ruby
codecop has quit [Remote host closed the connection]
<jhass> you may even be able to omit the to_a
moritzschaefer has quit [Ping timeout: 265 seconds]
mercwithamouth has quit [Ping timeout: 276 seconds]
<jheg> is to_a to array?
<jhass> yes
<jheg> cool thanks
failshell has quit []
luisjose has joined #ruby
kirun has quit [Quit: Client exiting]
nyamx2 has joined #ruby
<jheg> with the vast amount of methods do you often find yourself writing your own methods to only discover later down the line that it already existed?
Dreamer3 has joined #ruby
<Dreamer3> does rdoc document all constants? evey those i just reference in passing?
<Dreamer3> Library.test causes a file to be generated for Library, is that a way to turn that off or tweak it?
rezzack has joined #ruby
NukePuppy has quit [Ping timeout: 240 seconds]
oo__ has quit [Ping timeout: 260 seconds]
<DouweM> jheg: always google or search the docs before writing something you're sure someone else has ran into before
lemur has quit [Remote host closed the connection]
Zenigor has joined #ruby
dEPy has joined #ruby
<benzrf> my brain is full of haskell
<benzrf> yall should go fill up ur brains with haskell
<DouweM> benzrf: heresy!
<DouweM> benzrf: also, yo
sdouglas has quit [Remote host closed the connection]
<benzrf> y-yo
ldnunes has quit [Quit: Leaving]
<jheg> DouweM: sure will
nyamx2 has quit [Ping timeout: 240 seconds]
Sawbones has quit [Remote host closed the connection]
RaCx has quit [Quit: Computer has gone to sleep.]
jxf has quit [Quit: Leaving]
mordof has quit [Ping timeout: 245 seconds]
RaCx has joined #ruby
RaCx has quit [Client Quit]
mordof_work has joined #ruby
b1205 has quit [Ping timeout: 265 seconds]
iamvery has left #ruby ["Leaving..."]
Atttwww has joined #ruby
<RubyPanther> my brain is full of interfaces, and data relationships
dEPy has quit [Quit: Lingo - http://www.lingoirc.com]
jaimef has quit [Excess Flood]
sdouglas has joined #ruby
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
RaCx has joined #ruby
revoohc has quit [Quit: revoohc]
<shevy> in other words - a mess
Zenigor has quit [Remote host closed the connection]
amargherio has quit [Remote host closed the connection]
Zenigor has joined #ruby
jezen has quit [Remote host closed the connection]
aantix has quit [Quit: aantix]
b1205 has joined #ruby
jhass is now known as jhass|off
Deele has quit [Ping timeout: 260 seconds]
sailias1 has quit [Quit: Leaving.]
mattstratton has quit [Quit: Textual IRC Client: www.textualapp.com]
kitak has quit [Remote host closed the connection]
kitak has joined #ruby
danshultz has joined #ruby
<RubyPanther> shevy: I prefer the term entrenched legacy functionality to "mess"
stef1a has quit [Ping timeout: 252 seconds]
bluOxigen has quit [Ping timeout: 276 seconds]
Burgestrand_ has quit [Quit: Burgestrand_]
sdouglas has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
Vivekananda has quit [Read error: Connection reset by peer]
tyfighter has quit [Quit: tyfighter]
danshultz has quit [Remote host closed the connection]
jezen has joined #ruby
moritzschaefer has joined #ruby
danshultz has joined #ruby
aarkerio has joined #ruby
Gil_ has joined #ruby
oo_ has joined #ruby
terrell_t has joined #ruby
<aarkerio> hi! I see this code:
<aarkerio> region = user.region & region.children
<aarkerio> I guess both are methods (.region and .children)
<aarkerio> but what "&" means here
sambao21 has quit [Quit: Computer has gone to sleep.]
<wallerdev> bitwise and
<wallerdev> used for bitmasking
<wallerdev> looks like its being used wrong though lol
jaimef has joined #ruby
sdouglas has joined #ruby
<shevy> that depends on what these methods return
<shevy> if both are arrays it could be like
<shevy> >> %w( abc ) & %w( def abc )
<eval-in> shevy => ["abc"] (https://eval.in/160256)
<wallerdev> ah yeah that could make more sense
Gil_ has quit [Ping timeout: 240 seconds]
oo_ has quit [Ping timeout: 245 seconds]
terrellt has quit [Ping timeout: 260 seconds]
<shevy> though I go with wallerdev, I think the author was most likely drunk
kitak has quit [Ping timeout: 264 seconds]
aantix has joined #ruby
<shevy> what the ... are children doing in the user's region...
danshultz has quit [Ping timeout: 260 seconds]
<wallerdev> lol
treehug8_ has joined #ruby
Kricir has quit [Remote host closed the connection]
<aarkerio> ok, I know what search now
Notte has quit []
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<aarkerio> thank you guys!
aantix has quit [Client Quit]
newUser1234 has quit [Remote host closed the connection]
kitak has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
oo_ has joined #ruby
doodlehaus has quit [Remote host closed the connection]
treehug88 has quit [Ping timeout: 245 seconds]
sdouglas has quit [Remote host closed the connection]
aantix has joined #ruby
oo_ has quit [Read error: Connection reset by peer]
oo_ has joined #ruby
moritzschaefer has quit [Ping timeout: 260 seconds]
bradhe has joined #ruby
byteoverfl0w has joined #ruby
aantix has quit [Ping timeout: 260 seconds]
terrell_t has quit [Remote host closed the connection]
x1337807x has joined #ruby
<RubyPanther> >> class Foo < Array; def & rval; ['der'] end end ; Foo.new([1,2]) & Foo.new([:buckle,:shoe])
<eval-in> RubyPanther => ["der"] (https://eval.in/160258)
RaCx_ has joined #ruby
jezen has quit [Remote host closed the connection]
terrellt has joined #ruby
sdouglas has joined #ruby
lewix has quit [Ping timeout: 240 seconds]
<RubyPanther> and worse, it could be a monkey
oo_ has quit [Ping timeout: 276 seconds]
Steve21 has joined #ruby
chipotle has joined #ruby
oo_ has joined #ruby
bradhe has quit [Ping timeout: 276 seconds]
RaCx has quit [Ping timeout: 265 seconds]
RaCx_ is now known as RaCx
stef1a has joined #ruby
shenk has joined #ruby
andrewjanssen has quit [Quit: Leaving...]
terrellt has quit [Read error: Connection reset by peer]
terrellt has joined #ruby
sambao21 has joined #ruby
oo_ has quit [Ping timeout: 260 seconds]
kyb3r_ has joined #ruby
saarinen has quit [Quit: saarinen]
aarkerio has quit [Quit: Verlassend]
Darryl has quit [Quit: Connection closed for inactivity]
DanishMan has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
sambao21 has quit [Client Quit]
shenk` has joined #ruby
stef1a has quit [Quit: leaving]
ktun has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
naturehack has joined #ruby
Zenigor has quit [Remote host closed the connection]
pontiki has quit [Quit: "Poets have been mysteriously silent on the subject of cheese." -- G.K.Chesterson]
ryanleesipes has quit [Remote host closed the connection]
<naturehack> where did twitter come from?
<naturehack> could it be #freenode?
<naturehack> everyone needs objects 140 words.
<naturehack> html5 says hello ruby.
<naturehack> you embedded now.
<naturehack> ruby on rails, what the heck is that?
<naturehack> its the physics of ruby that makes it beauty.
<naturehack> coding making happening. the same happening 10,000 years from now.
<naturehack> the physics of inheritance never change, we are transcending brains, today, yesterday, and tomorrow.
<naturehack> git above language. wait, git out of here, was that from ruby too?
sinkensabe has quit [Remote host closed the connection]
jailbot has joined #ruby
<benzrf> naturehack: what
freerobby has quit [Quit: Leaving.]
<benzrf> naturehack: is this some kind of time cube nonsense
sinkensabe has joined #ruby
<jailbot> anyone have experience with paperclip for rails?
Xeago has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
<jailbot> so this comes up whenever I run rails g
nanoyak has quit [Quit: Computer has gone to sleep.]
Azulinho has quit [Ping timeout: 245 seconds]
blizzow has quit [Ping timeout: 252 seconds]
jheg has quit [Quit: jheg]
RaCx has joined #ruby
bwilson has quit [Quit: bwilson]
katmandoo has quit [Ping timeout: 265 seconds]
naturehack is now known as ruralhack
oo_ has joined #ruby
sinkensabe has quit [Ping timeout: 252 seconds]
<jailbot> got et
ruralhack has quit [Changing host]
ruralhack has joined #ruby
dpp has quit [Ping timeout: 260 seconds]
flagg0204 has joined #ruby
jerius has quit [Ping timeout: 260 seconds]
nitr has joined #ruby
Xeago has quit [Ping timeout: 276 seconds]
maroloccio has quit [Quit: WeeChat 0.4.3]
beef-wellington has quit [Ping timeout: 265 seconds]
bwilson has joined #ruby
dblessing has quit [Quit: dblessing]
nanoyak has joined #ruby
j_mcnally has joined #ruby
sambao21 has joined #ruby
<Nilium> Huh, apparently named arguments must have a symbol as the name
<Nilium> e.g., foo(**{1 => 2}) is invalid.
<Nilium> Didn't know that 'til now.
charliesome has joined #ruby
oo_ has quit [Ping timeout: 260 seconds]
nanoyak has quit [Client Quit]
Kricir has joined #ruby
stantona has quit [Remote host closed the connection]
oorst has joined #ruby
mary5030_ has joined #ruby
mary5030 has quit [Ping timeout: 240 seconds]
brandonblack has quit [Quit: Lost terminal]
nanoyak has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
sdrew has quit [Quit: *poof*]
alexju has quit [Remote host closed the connection]
oo_ has joined #ruby
<ericwood> makes sense to me
<ericwood> has to correspond to a variable!
enebo has quit [Quit: enebo]
nitr has quit []
claymore has quit [Quit: night]
Kricir has quit [Ping timeout: 276 seconds]
freezey has joined #ruby
geggam has quit [Quit: commute]
Martxel has quit [Ping timeout: 276 seconds]
nevans has quit [Quit: good bye]
djbkd has quit [Remote host closed the connection]
oo_ has quit [Ping timeout: 260 seconds]
djbkd has joined #ruby
spider-mario has quit [Read error: Connection reset by peer]
<shevy> naturehack you are on drugs right
riotjone_ has joined #ruby
dels has left #ruby [#ruby]
Olipro has quit [*.net *.split]
<jailbot> always
<jailbot> drugs rule fuck school
m8 has quit [Quit: Sto andando via]
x1337807x has quit [Ping timeout: 252 seconds]
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
riotjones has quit [Ping timeout: 245 seconds]
oo_ has joined #ruby
sputnik13 has joined #ruby
<jailbot> what the hell is going on there
sdouglas has quit [Remote host closed the connection]
blizzow has joined #ruby
<ruralhack> me and matz's beauty of ruby's late binding of inheritance. > http://i.imgur.com/IwUCbN8.png
djbkd has quit [Ping timeout: 240 seconds]
JokesOnYou77 has joined #ruby
GriffinHeart has joined #ruby
x1337807x has joined #ruby
jheg has joined #ruby
<ruralhack> moving life cpu <alphabetic technology> binary cells
RaCx has joined #ruby
<JokesOnYou77> Hi all. I'm trying to make a file post using multipart-post and I'm getting a routing error: /http.rb:879:in `initialize': getaddrinfo: Name or service not known (SocketError) I'm pretty sure this is a result of my inexperience with uri and how to structure the parameters but nothing I try is working
jottr_ has joined #ruby
terrellt has quit [Remote host closed the connection]
<shevy> ruralhack why should anyone click on that considering that you are not using ruby?
stantona has joined #ruby
sdouglas_ has joined #ruby
weems has quit [Read error: Connection reset by peer]
weems has joined #ruby
oo_ has quit [Ping timeout: 276 seconds]
mary5030_ has quit [Ping timeout: 252 seconds]
<ruralhack> electro/|\agnetic Evolution? http://i.imgur.com/Wvf3kah.jpg
mijicd has joined #ruby
lemur has joined #ruby
GriffinHeart has quit [Ping timeout: 265 seconds]
<ruralhack> i think with objects transcending my body like ruby demands. women who know ruby know easily how to keep their baby's music instead of notation.
jottr has quit [Ping timeout: 260 seconds]
<Boohbah> bot alert
<ruralhack> postpartum depression history
terrellt has joined #ruby
<ruralhack> women get him, he forgot the shifts ruby presents. we felt them as children.
<ruralhack> matz did something beautiful and no one knows.
<shevy> ruralhack you are so lame
hpoydar has quit [Remote host closed the connection]
BlakeRG has joined #ruby
combusean has joined #ruby
combusean has quit [Remote host closed the connection]
combusean has joined #ruby
combusean has quit [Remote host closed the connection]
oorst has quit [Quit: oorst]
Olipro has joined #ruby
jobewan has quit [Quit: Leaving]
<ericwood> what is happening
lemur has quit [Ping timeout: 260 seconds]
havenwood has joined #ruby
terrellt has quit [Ping timeout: 245 seconds]
Gil_ has joined #ruby
katmandoo has joined #ruby
<ruralhack> use of language not transcending your body will get you put in an asylum soon shenk. I'm not worthy of presenting to the only community worthy of changing the world yet, the ruby community, please don't burn me at the stake.
Hanmac1 has quit [Ping timeout: 252 seconds]
treehug8_ has quit []
chipotle has quit [Quit: cya]
linuxnewb2 has joined #ruby
<shevy> ruralhack you don't deserve a good death anyway
newUser1234 has joined #ruby
bradhe has joined #ruby
oo_ has joined #ruby
<ruralhack> #DufusHunter an algorithm scraping the internet exposing DarkAgers for the children by the language they use. you will be listed in a database until you prove you think from the TechAge of two classes of time. until then you are las vegas shooter.
Bira has joined #ruby
<xybre> Markov chains are fun, eh?
<wallerdev> what is going on
<ruralhack> kik
<ruralhack> lol
terrellt has joined #ruby
<ruralhack> i'm leaving before i get burned at the stake by a man before i can present to the woman of ruby. love you friend!
BlakeRG has quit []
ruralhack has left #ruby ["Leaving"]
tyfighter has joined #ruby
Gil_ has quit [Ping timeout: 260 seconds]
RaCx has quit [Quit: Computer has gone to sleep.]
<xybre> wat
ruralhack has joined #ruby
northfurr has joined #ruby
byteoverfl0w has quit [Quit: Leaving... have a good one...]
<ruralhack> i forgot the missing link electro/|\echanically: http://i.imgur.com/Wvf3kah.jpg
sambao21 has quit [Quit: Computer has gone to sleep.]
<ruralhack> bye now
Hanmac has joined #ruby
ruralhack has left #ruby ["Leaving"]
northfurr has quit [Client Quit]
mercerist has quit [Quit: Computer has gone to sleep.]
oo_ has quit [Ping timeout: 276 seconds]
bradhe has quit [Ping timeout: 276 seconds]
tyfighter has quit [Ping timeout: 260 seconds]
olivier_bK has joined #ruby
mary5030 has joined #ruby
linojon has quit [Quit: linojon]
newUser1234 has quit [Ping timeout: 260 seconds]
baroquebobcat has joined #ruby
thesheff17 has quit [Quit: Leaving]
thesheff17 has joined #ruby
saarinen has joined #ruby
northfurr has joined #ruby
northfurr has quit [Client Quit]
Bira has quit [Remote host closed the connection]
djbkd has joined #ruby
hermanmunster has quit [Remote host closed the connection]
<JokesOnYou77> I'm trying to make a file post using multipart-post and I'm getting a routing error: /http.rb:879:in `initialize': getaddrinfo: Name or service not known (SocketError) I'm pretty sure this is a result of my inexperience with uri and how to structure the parameters but nothing I try is working
hermanmunster has joined #ruby
_djbkd has joined #ruby
jespada has quit [Quit: Leaving]
freerobby has joined #ruby
djbkd has quit [Remote host closed the connection]
lmickh has quit [Remote host closed the connection]
jxf has joined #ruby
ixti has joined #ruby
hermanmunster has quit [Ping timeout: 265 seconds]
jailbot has quit [Remote host closed the connection]
klaut has quit [Remote host closed the connection]
hpoydar has joined #ruby
centrx has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sdouglas_ has quit [Remote host closed the connection]
nfk has quit [Quit: yawn]
sdouglas has joined #ruby
combusean has joined #ruby
<timgauthier> woah so much typing!
freezey has quit [Remote host closed the connection]
<Nilium> Sometimes I can't tell if people working on MRI intentionally write the ugliest C known to man or if they're just stuck in academic-code-is-crap land and don't know how to get out.
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
tyfighter has joined #ruby
<Nilium> Though apparently terrifying code is a Japanese thing, so that might be it.
<timgauthier> mri?
<combusean> matz's ruby interpreter
<timgauthier> ah is it in C?
<Nilium> Yes.
<Nilium> Yes.
FDj has joined #ruby
b1205 has quit [Ping timeout: 245 seconds]
Steve21 has quit [Quit: Steve21]
<Nilium> Not sure how much of MRI remains in YARV, though, so I just refer to pre- and post-YARV-MRI as MRI.
benlieb has joined #ruby
<Nilium> Either way, a lot of the code comes across as almost nightmarish
Kricir has joined #ruby
sdouglas has quit [Ping timeout: 240 seconds]
sdouglas has joined #ruby
jottr_ has quit [Ping timeout: 252 seconds]
dopie has quit [Quit: Leaving]
dangerousdave has quit [Ping timeout: 265 seconds]
aantix has joined #ruby
andrewjanssen has joined #ruby
tyfighter has quit [Ping timeout: 276 seconds]
predator217 has joined #ruby
<centrx> Nilium, How so?
clov3r has joined #ruby
<Nilium> Best example I can think of is probably ruby.h -- everything is abbreviated, there's little in the way of documentation, and trying to find anything in it is kind of a huge pain in the ass.
<Nilium> It's just ugly code.
b1205 has joined #ruby
zigomir has quit [Remote host closed the connection]
MrDoctor has joined #ruby
<Nilium> A lot of stuff also comes across as fairly macro-heavy, but I'm not sure how consistent that is.
predator117 has quit [Ping timeout: 252 seconds]
<MrDoctor> I wish to share a @var in two different methods defined in a controller
<MrDoctor> How can I achieve that
ahofmann has joined #ruby
<MrDoctor> I tried before_filter to define a @var for both methods
<MrDoctor> But the value of @var is different in the scope of both methods
<combusean> MrDoctor: i would try #rubyonrails
<Nilium> I think you need to ask in a Rails room
<MrDoctor> Okay combusean, Nilium
<MrDoctor> Thanks
<centrx> Interesting
charliesome has joined #ruby
SCommette has quit [Quit: SCommette]
saarinen has quit [Quit: saarinen]
tessi is now known as tessi_zz
mary5030 has quit [Remote host closed the connection]
onewheelskyward has joined #ruby
Mattx has quit [Ping timeout: 276 seconds]
SCommette has joined #ruby
seitensei has joined #ruby
baroquebobcat has quit [Ping timeout: 245 seconds]
toastynerd has quit [Remote host closed the connection]
jheg has quit [Quit: jheg]
mikecmpbll has quit [Quit: ciao.]
kitak has quit [Remote host closed the connection]
blinkdesign has joined #ruby
mary5030 has joined #ruby
kitak has joined #ruby
mary5030_ has joined #ruby
kevind has quit [Quit: kevind]
andrewjanssen has quit [Quit: Leaving...]
Tricon has quit [Quit: Linkinus - http://linkinus.com]
blizzow has quit [Ping timeout: 240 seconds]
vifino has quit [Quit: Ze Cat now leaves...]
sdouglas has quit [Remote host closed the connection]
SCommette has quit [Quit: SCommette]
Avahey_ has joined #ruby
mary5030 has quit [Ping timeout: 252 seconds]
bradhe has joined #ruby
CodeBunny has joined #ruby
Mattx has joined #ruby
Arkaniad has quit [Ping timeout: 276 seconds]
snath has quit [Ping timeout: 260 seconds]
blinkdesign has quit [Remote host closed the connection]
jottr_ has joined #ruby
Gil_ has joined #ruby
bradhe has quit [Ping timeout: 265 seconds]
andrewjanssen has joined #ruby
george2 has joined #ruby
michaelchum has quit [Quit: Connection closed for inactivity]
KLVTZ has joined #ruby
x1337807x has joined #ruby
Vivekananda has joined #ruby
ixti has quit [Quit: WeeChat 0.4.3]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
hermanmunster has joined #ruby
Gil_ has quit [Ping timeout: 252 seconds]
axilla has quit [Ping timeout: 260 seconds]
jottr_ has quit [Ping timeout: 265 seconds]
rhys has quit [Read error: Connection reset by peer]
MrDoctor_ has joined #ruby
rhys has joined #ruby
Wolland has quit [Remote host closed the connection]
combusean has quit [Quit: Leaving.]
narcan has quit [Quit: -[AppDelegate installMalware]: unrecognized selector sent to instance 0x156109c0]
Wolland has joined #ruby
MrDoctor has quit [Ping timeout: 240 seconds]
sdouglas_ has joined #ruby
Sawbones has joined #ruby
narcan has joined #ruby
ffranz has quit [Quit: Leaving]
blizzow has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Arkaniad has joined #ruby
Wolland has quit [Ping timeout: 276 seconds]
<JokesOnYou77> I'm trying to make a file post using multipart-post and I'm getting a routing error: /http.rb:879:in `initialize': getaddrinfo: Name or service not known (SocketError) I'm pretty sure this is a result of my inexperience with uri and how to structure the parameters but nothing I try is working
axilla has joined #ruby
nisstyre has quit [Quit: WeeChat 0.4.3]
frem_ has quit [Ping timeout: 245 seconds]
Lwhite has joined #ruby
nisstyre has joined #ruby
sdouglas_ has quit [Remote host closed the connection]
sdouglas has joined #ruby
HashNuke has joined #ruby
sdouglas has quit [Read error: Connection reset by peer]
sdouglas has joined #ruby
axilla has quit [Ping timeout: 252 seconds]
andrewjanssen has quit [Quit: Leaving...]
Sawbones has quit [Remote host closed the connection]
Sawbones has joined #ruby
andrewjanssen has joined #ruby
lazyguru has quit [Ping timeout: 252 seconds]
ponga has joined #ruby
Bira_ has joined #ruby
lazyguru has joined #ruby
x1337807x has joined #ruby
narcan has quit [Quit: -[AppDelegate installMalware]: unrecognized selector sent to instance 0x156109c0]
Sawbones has quit [Ping timeout: 260 seconds]
sepp2k1 has joined #ruby
binaryhat has joined #ruby
sepp2k has quit [Ping timeout: 245 seconds]