havenwood changed the topic of #ruby to: Rules & more: http://ruby-community.com || Ruby 2.2.3; 2.1.7; 2.0.0-p647: https://ruby-lang.org || Paste >3 lines of text on https://gist.github.com || log @ http://irclog.whitequark.org/ruby/
mg^ has joined #ruby
northfurr has joined #ruby
ziprar has joined #ruby
willharrison has quit [Ping timeout: 268 seconds]
cwong_on_irc has quit [Quit: Leaving.]
m3_del has quit [Ping timeout: 265 seconds]
nateberkopec has quit [Ping timeout: 255 seconds]
ruurd has quit [Quit: ZZZzzz…]
s00pcan has quit [Ping timeout: 250 seconds]
riotjone_ has joined #ruby
zipace has quit [Ping timeout: 265 seconds]
devoldmx has joined #ruby
s00pcan has joined #ruby
Alina-malina has quit [Ping timeout: 246 seconds]
jackjackdripper has quit [Ping timeout: 240 seconds]
Aswebb_ has quit [Remote host closed the connection]
tkuchiki has joined #ruby
bruno- has quit [Ping timeout: 255 seconds]
benlovell has joined #ruby
benlovel1 has joined #ruby
solocshaw has quit [Ping timeout: 240 seconds]
BSaboia has quit [Ping timeout: 246 seconds]
Aderium has quit [Quit: Textual IRC Client: www.textualapp.com]
solocshaw has joined #ruby
jackjackdripper has joined #ruby
riotjone_ has quit [Ping timeout: 264 seconds]
jackjackdripper has quit [Client Quit]
RegulationD has joined #ruby
jackjackdripper has joined #ruby
roger_rabbit has joined #ruby
amclain_ has joined #ruby
h99h9h88 has joined #ruby
benlovel1 has quit [Ping timeout: 250 seconds]
benlovell has quit [Ping timeout: 250 seconds]
amclain has quit [Read error: Connection reset by peer]
amclain__ has joined #ruby
tkuchiki has quit [Remote host closed the connection]
shock_one has joined #ruby
ivanskie has joined #ruby
l_tonz has quit [Remote host closed the connection]
chipotle has joined #ruby
h99h9h88 has quit [Ping timeout: 240 seconds]
amclain_ has quit [Ping timeout: 265 seconds]
gregoriokusowski has joined #ruby
Fire-Dragon-DoL has quit []
h99h9h88 has joined #ruby
jackjackdripper has quit [Quit: Leaving.]
bender_unit has joined #ruby
bender_unit has quit [Client Quit]
arthurix_ has joined #ruby
h99h9h88 has quit [Remote host closed the connection]
NeverDie has quit [Quit: http://radiux.io/ -> Manhattan Project]
nfk has quit [Read error: Connection reset by peer]
shock_one has quit [Ping timeout: 268 seconds]
nateberkopec has joined #ruby
bricker has quit [Quit: leaving]
arthurix has quit [Ping timeout: 265 seconds]
jgt2 has joined #ruby
pontiki has joined #ruby
cdg has quit [Remote host closed the connection]
northfurr has quit [Quit: northfurr]
NeverDie has joined #ruby
cdg has joined #ruby
h99h9h88_ has joined #ruby
NeverDie has quit [Client Quit]
jgt1 has quit [Ping timeout: 250 seconds]
nateberkopec has quit [Ping timeout: 252 seconds]
ja has quit [Changing host]
ja has joined #ruby
niftylettuce has joined #ruby
linduxed has quit [Ping timeout: 260 seconds]
h99h9h88_ has quit [Remote host closed the connection]
h99h9h88 has joined #ruby
ziprar has quit [Ping timeout: 244 seconds]
ekinmur has joined #ruby
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
cdg has quit [Ping timeout: 240 seconds]
tjohnson has joined #ruby
h99h9h88 has quit [Ping timeout: 255 seconds]
n008f4g_ has quit [Ping timeout: 256 seconds]
EllisTAA has joined #ruby
sepp2k1 has quit [Read error: Connection reset by peer]
SCHAAP137 has quit [Quit: Leaving]
`derpy has quit [Read error: Connection reset by peer]
gambl0re has quit [Ping timeout: 260 seconds]
eminencehc has quit [Remote host closed the connection]
`derpy has joined #ruby
_aeris_ has quit [Ping timeout: 256 seconds]
Fridtjof has quit [Ping timeout: 250 seconds]
northfurr has joined #ruby
adaedra has quit [Ping timeout: 250 seconds]
snockerton has quit [Quit: Leaving.]
NeverDie has joined #ruby
northfurr has quit [Client Quit]
Biohazard has quit [Ping timeout: 250 seconds]
bewie has quit [Ping timeout: 250 seconds]
jgt2 has quit [Ping timeout: 250 seconds]
hxegon has joined #ruby
ecksit has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bewie has joined #ruby
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
mikecmpbll has quit [Quit: i've nodded off.]
adaedra has joined #ruby
Igorshp has quit [Remote host closed the connection]
northfurr has joined #ruby
nateberkopec has joined #ruby
NeverDie has quit [Client Quit]
djbkd has quit [Remote host closed the connection]
prasselpikachu has joined #ruby
Biohazard has joined #ruby
_aeris_ has joined #ruby
bnagy_ is now known as bnagy
Fire-Dragon-DoL has joined #ruby
sanjayu has quit [Ping timeout: 268 seconds]
hxegon_ has joined #ruby
bffff_ has quit [Quit: Connection closed for inactivity]
nateberkopec has quit [Ping timeout: 268 seconds]
rrichardsr3 has joined #ruby
hxegon has quit [Ping timeout: 252 seconds]
maxz has quit [Ping timeout: 244 seconds]
devoldmx has quit [Remote host closed the connection]
<shevy> $1 is magical
tkuchiki has joined #ruby
ss_much has quit [Quit: Connection closed for inactivity]
jay_ has joined #ruby
<pontiki> is it?
aspiers has joined #ruby
<shevy> yeah! it can mysteriously appear and disappear
maletor has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
blackmesa has quit [Quit: WeeChat 1.3]
<Ox0dea> >> [defined?($1), ''[/()/], defined?($1), ''[//], defined?($1)] # pontiki
<ruboto> Ox0dea # => [nil, "", "global-variable", "", nil] (https://eval.in/458137)
workmad3 has joined #ruby
jay_ has quit [Client Quit]
chipotle has quit [Ping timeout: 240 seconds]
<Ox0dea> I believe that's what shevy meant.
EllisTAA has quit [Quit: EllisTAA]
gambl0re has joined #ruby
<pontiki> ah
tkuchiki has quit [Ping timeout: 268 seconds]
linduxed has joined #ruby
<pontiki> that ought to be so for all the grouping variables, no?
<Ox0dea> Quite a substantial number of ostensibly global variables are really "virtual" or "scope-local" variables, but matz had already run out of sigils with which to prefix them by that time.
<Ox0dea> pontiki: Sure, $~ and everything derived thereof fit into ^.
<pontiki> could have gone for the RCS one
<pontiki> $(@)
<pontiki> :D
workmad3 has quit [Ping timeout: 264 seconds]
<Ox0dea> %1 wouldn't be so bad.
* pontiki nods
tkuchiki has joined #ruby
tkuchiki has quit [Remote host closed the connection]
djbkd has joined #ruby
<pontiki> i never really gave it all that much thought; it works rather like perl does
failshell has joined #ruby
djbkd has quit [Remote host closed the connection]
tedstriker has joined #ruby
juanca_ has joined #ruby
djbkd has joined #ruby
<havenwood> shevy: ruby -e "# frozen_string_literal: true
<havenwood> p 'forest'.frozen?"
<havenwood> #=> true
gambl0re has quit []
nateberkopec has joined #ruby
symm- has quit [Ping timeout: 268 seconds]
failshell has quit [Remote host closed the connection]
craysiii has joined #ruby
bruno- has joined #ruby
twohlix has quit [Quit: justQU.IT]
scpike has quit [Remote host closed the connection]
diegoaguilar has quit [Remote host closed the connection]
weemsledeux has joined #ruby
ec\ has quit [Quit: Lost terminal]
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
nateberkopec has quit [Ping timeout: 240 seconds]
wldcordeiro has joined #ruby
diegoaguilar has joined #ruby
bruno- has quit [Ping timeout: 260 seconds]
<havenwood> shevy: If you invoke the Hundred Years Winter in Ruby 2.3 the Strings will freeze. Make haste children and beavers!
l_tonz has joined #ruby
l_tonz has quit [Client Quit]
* baweaver scampers off
l_tonz has joined #ruby
d34th4ck3r has joined #ruby
tolo123 has joined #ruby
<shevy> lol
<shevy> yeah that dam freezing
nofxx has joined #ruby
nofxx has joined #ruby
gregoriokusowski has quit [Quit: gregoriokusowski]
Xiti has quit [Quit: Xiti]
<pontiki> oh, well played :)
Fire-Dragon-DoL has quit []
tolo123 has left #ruby [#ruby]
<Ox0dea> > Now is the winter of our discontent, made glorious summer by this Object#thaw, and all the mutation that low'r'd upon our codebases.
Xiti has joined #ruby
<pontiki> :D
<havenwood> "Didn’t I tell you," answered Mr. Beaver, "that she'd made it always winter and never Christmas? Didn’t I tell you? Well, just come and see!" ~ Ruby 2.3, coming this Christmas!
shock_one has joined #ruby
leafybasil has quit [Remote host closed the connection]
ivanskie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
shock_one has quit [Ping timeout: 244 seconds]
x07C8 has joined #ruby
<Ox0dea> >> h = {}; h[a = [1]] = 1; h[a.tap(&:pop)] = 2; h
<ruboto> Ox0dea # => {[]=>1, []=>2} (https://eval.in/458142)
treehug88 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
KensoDev has quit []
<Ox0dea> Also `h[[]]` is 2 there, and I don't know precisely why.
x07C8 has left #ruby ["ERC (IRC client for Emacs 24.5.1)"]
pontiki has quit [Ping timeout: 246 seconds]
nateberkopec has joined #ruby
ec\ has joined #ruby
wildlander has joined #ruby
wildlander has quit [Max SendQ exceeded]
l_tonz has quit [Remote host closed the connection]
wildlander has joined #ruby
l_tonz has joined #ruby
pontiki has joined #ruby
<havenwood> Ox0dea: wat...? oh dear.
jdawgaz has joined #ruby
houhoulis has joined #ruby
chipotle has joined #ruby
nateberkopec has quit [Ping timeout: 272 seconds]
<baweaver> >> h = {}; h[a = [1]] = 1; h[a.tap(&:pop)] = 2; h.keys.map(&:object_id)
<ruboto> baweaver # => [551935980, 551935980] (https://eval.in/458144)
pontiki has quit [Client Quit]
<baweaver> huh
<baweaver> well dang
<baweaver> you win
Aswebb_ has joined #ruby
<havenwood> and `h.keys.map(&:hash).inject :== #=> true` as well as `h.keys.inject :eql? #=> true`
marr has quit [Ping timeout: 250 seconds]
<havenwood> I guess they weren't upon insertion.
<havenwood> Eek.
`tim` has joined #ruby
bruce_lee2 has joined #ruby
chipotle has quit [Ping timeout: 244 seconds]
Aswebb_ has quit [Ping timeout: 250 seconds]
alexdunne has joined #ruby
cmoneylu_ has joined #ruby
cmoneylu_ is now known as cmoney
maletor has joined #ruby
bruce_lee has quit [Ping timeout: 246 seconds]
bruce_lee2 has quit [Changing host]
bruce_lee2 has joined #ruby
bruce_lee2 is now known as bruce_lee
ecksit has joined #ruby
northfurr has quit [Quit: northfurr]
minimalism has joined #ruby
alexdunne has quit [Ping timeout: 240 seconds]
tkuchiki has joined #ruby
northfurr has joined #ruby
Emmanuel_Chanel has quit [Quit: Leaving]
l_tonz has quit [Quit: Leaving...]
Emmanuel_Chanel has joined #ruby
towski_ has quit [Remote host closed the connection]
l_tonz has joined #ruby
agent_white has joined #ruby
<agent_white> Evenin'
nateberkopec has joined #ruby
cpup- has joined #ruby
Motoservo has quit [Quit: Shhh. I'm trying to get some sleep here.]
saddad has joined #ruby
ecksit has quit [Quit: Textual IRC Client: www.textualapp.com]
northfurr has quit [Quit: northfurr]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
northfurr has joined #ruby
nateberkopec has quit [Ping timeout: 252 seconds]
<Ox0dea> havenwood: That `{a: 1, a: 2}` warns and `{[] => 1, [] => 2}` doesn't might be of some pertinence.
Pupeno has joined #ruby
M-mistake1 has quit [Remote host closed the connection]
M-Kodo1 has quit [Remote host closed the connection]
Jardayn has quit [Read error: Connection reset by peer]
Motoservo has joined #ruby
cjheath has joined #ruby
<cjheath> Hey ho all. Any other gem authors wondering how they can avoid/minimise the occurrence of “WARN: Unresolved specs during Gem::Specification.reset” warnings?
cpup- is now known as cpup
andersoldahl has joined #ruby
Motoservo has quit [Client Quit]
northfurr has quit [Quit: northfurr]
benlovel1 has joined #ruby
benlovell has joined #ruby
<Ox0dea> cjheath: Do some housekeeping.
northfurr has joined #ruby
Pupeno has quit [Ping timeout: 244 seconds]
maletor has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<cjheath> I’ve done gem cleanup, biundle updates on all projects that have installed gems, gem cleanup again, and I’m still gettng errors on json
<cjheath> 0x0dea: Also this is not about me, it’s about users of my gems. This seems to be new behaviour and its most unfriendly to end-users
inteq has joined #ruby
<cjheath> So I’m just trying to understand what causes it (duplicate versions obviously, but what else?) and how it can be avoided or minimised
benlovel1 has quit [Ping timeout: 240 seconds]
benlovell has quit [Ping timeout: 240 seconds]
dfockler has joined #ruby
Xiti has quit [Quit: Xiti]
<cpup> Are Arrays optimized for space when sparse?
pleiosaur has quit [Remote host closed the connection]
Xiti has joined #ruby
<cjheath> cpup: I believe the answer is no.
alexdunne has joined #ruby
<Ox0dea> Indeed not.
csaunders has quit [Quit: later tater]
IrishGringo has joined #ruby
Xiti has quit [Client Quit]
<Ox0dea> >> require 'objspace'; [ObjectSpace.memsize_of(a = []), a[42] = nil, ObjectSpace.memsize_of(a)] # cpup
<ruboto> Ox0dea # => [20, nil, 252] (https://eval.in/458145)
SebastianThorn has quit [Ping timeout: 255 seconds]
bruno- has joined #ruby
SebastianThorn has joined #ruby
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
failshell has joined #ruby
<cpup> Would ~20 ~400 element arrays be very bad?
M-Kodo has joined #ruby
<Ox0dea> >> Time.now.year # cpup
<ruboto> Ox0dea # => 2015 (https://eval.in/458146)
<pwnd_nsfw> lol
<pwnd_nsfw> cpup, maybe in like... the 70-80s
<pwnd_nsfw> MAYBE
<cpup> hehe
<cpup> Ok, I'll stop worrying about that then.
alexdunne has quit [Ping timeout: 260 seconds]
diegoaguilar has quit [Quit: Leaving]
nateberkopec has joined #ruby
eminencehc has joined #ruby
cmoney has quit [Remote host closed the connection]
hxegon has joined #ruby
bruno- has quit [Ping timeout: 240 seconds]
scoot_ has quit []
rshetty has joined #ruby
failshell has quit [Ping timeout: 272 seconds]
<Ox0dea> cjheath: http://git.io/vW9Er
hxegon_ has quit [Ping timeout: 265 seconds]
<Ox0dea> Just duplicates, it seems.
M-mistake has joined #ruby
M-prosodyContext has joined #ruby
`tim` has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
rshetty_ has joined #ruby
nateberkopec has quit [Ping timeout: 264 seconds]
Bloomer has joined #ruby
craysiii has quit [Remote host closed the connection]
<cjheath> The dups are different versions, matched by a Gemspec/Gemfile requirement. So for example I have various projects that installed 1.8,1 and 1.8.2 of json. But the program I’m running can work with either (it has json (>= 1.7.7, ~> 1.7))
fowl has left #ruby [#ruby]
<cjheath> Hmmm, I guess that means there’s no match to the ~>1.7, bit either matches >= 1.7.7
h99h9h88 has joined #ruby
Lucky__ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
moeabdol1 has joined #ruby
<cjheath> factory_girl_rails has this requirement, for example.
rshetty has quit [Ping timeout: 256 seconds]
hxegon_ has joined #ruby
<cjheath> I notice that some gems now include Gemfile.lock - is that a good or bad practise?
jord has quit [Quit: Connection closed for inactivity]
hxegon has quit [Ping timeout: 256 seconds]
Lucky__ has joined #ruby
moeabdol has quit [Ping timeout: 244 seconds]
shock_one has joined #ruby
jgt2 has joined #ruby
Xiti has joined #ruby
stardiviner has joined #ruby
arescorpio has joined #ruby
leafybasil has joined #ruby
ivanskie has joined #ruby
hxegon_ has quit [Quit: leaving]
Bloomer has quit [Ping timeout: 268 seconds]
sunya7a has joined #ruby
dmitch has quit [Read error: Connection reset by peer]
mois3x has quit [Quit: mois3x]
shock_one has quit [Ping timeout: 240 seconds]
IrishGringo has quit [Remote host closed the connection]
_aeris_ has quit [Remote host closed the connection]
rideh has quit [Ping timeout: 260 seconds]
jgt2 has quit [Ping timeout: 244 seconds]
_aeris_ has joined #ruby
mois3x has joined #ruby
d34th4ck3r has quit [Quit: zzz]
northfurr has quit [Quit: northfurr]
rideh has joined #ruby
northfurr has joined #ruby
leafybasil has quit [Ping timeout: 256 seconds]
govg has joined #ruby
brendan- has joined #ruby
northfurr has quit [Client Quit]
nateberkopec has joined #ruby
cmoney has joined #ruby
zenguy_pc has quit [Read error: Connection reset by peer]
zenguy_pc has joined #ruby
andersoldahl has quit [Quit: My Mac has gone to sleep.]
dasher00 has quit [Ping timeout: 272 seconds]
pdoherty has quit [Ping timeout: 265 seconds]
zenguy_pc has quit [Read error: Connection reset by peer]
favadi has joined #ruby
nateberkopec has quit [Ping timeout: 256 seconds]
dasher00 has joined #ruby
TheNet has quit [Quit: Leaving...]
nsuke has quit [Remote host closed the connection]
<Ox0dea> cjheath: You don't necessarily control when Gem::Specification.reset gets invoked, so you can't run the "offending" portion of your code is a warning suppression block.
<Ox0dea> It seems the only way to silence it would be to redefine Kernel#warn, or (slightly less invasively) prepend a Module with its own definition to Object.
hmsimha_ has joined #ruby
musou has quit [Quit: Connection closed for inactivity]
<cjheath> Can;t really do that, since it’s an executable called by rbenv, and the warn has happened before the program starts
ruby-lang251 has joined #ruby
<Ox0dea> cjheath: There's always BEGIN{}.
<ruby-lang251> Hey I'm just learning read/write techniques and am having trouble reading and verifying data exists on a file. can someone help?
<cjheath> Still not sure that’d get called, since rbenv runs a stub before loading the target program
eminencehc has quit [Remote host closed the connection]
northfurr has joined #ruby
dikaio has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
workmad3 has joined #ruby
TheHodge has quit [Quit: Connection closed for inactivity]
pdoherty has joined #ruby
<Ox0dea> cjheath: Then it's completely out of your control, no?
<cjheath> Unless I can fix the Gemfile/gemspec/whatever is causing the mismatch
<cjheath> which I possibly can
<cjheath> Actually the error probably occurs when the actual program calls require, rather than earlier
<cjheath> as I said however, I’m trying to undersrtand best practise on how to avoid warnings
<cjheath> like, some gems include Gemfile.lock - does this matter or have any effect?
aspiers has quit [Ping timeout: 265 seconds]
<ruby-lang251> any help on this?
crime has quit [Quit: Connection closed for inactivity]
workmad3 has quit [Ping timeout: 246 seconds]
<cjheath> ruby-lang251: looking now
<cjheath> Hint1: Don’t use hardware tabs
<cjheath> Hint2: if you do use hardware tabs, set ytour eitor to epand then to 8-spaces
northfurr has quit [Quit: northfurr]
<cjheath> Hint3: See hint1 :)
zenguy_pc has joined #ruby
dikaio has joined #ruby
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
charliesome has joined #ruby
nateberkopec has joined #ruby
<cjheath> ruby-lang251: Assuming you’re having troubl around line 120-128, you should use a block to File.open (you never close the file)
<ruby-lang251> so my spacing on my .txt file is throwing the check off?
csaunders has joined #ruby
<cjheath> no, that was just general advice :)
ausec has joined #ruby
djbkd has quit [Quit: My people need me...]
ausec has quit [Remote host closed the connection]
<cjheath> I like hadware tabs, but the Ruby community hates them because people stopped always expanding them to 8-spaces, so code always looks different from one screen to anotger
Oatmeal has quit [Ping timeout: 240 seconds]
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
hiyosi has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<cjheath> the code *indent* and the use of tabs are entirely separate things, but Textmate and other editors forgot that
<ruby-lang251> i thought the while !file.eof? results in it closing itself?
jgpawletko has quit [Quit: jgpawletko]
Oatmeal has joined #ruby
<cjheath> Nope. Just breaks the loop when you reach the end
<cjheath> then the ariable goes out of scope, but nothig closes the file (at leats not until gc)
ausec has joined #ruby
nateberkopec has quit [Ping timeout: 256 seconds]
Bloomer has joined #ruby
<cjheath> You can also just do File.readlines(“account.txt”).each… as long as the file isn't gigabytes :)
<cjheath> It looks to me line check_account will actually work though.
<cjheath> for some definition of “work”
<cjheath> what problem are you seeing
`tim` has joined #ruby
willardg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
charliesome has quit [Ping timeout: 240 seconds]
weemsledeux has joined #ruby
absolutejam has quit [Ping timeout: 244 seconds]
solocshaw has quit [Ping timeout: 246 seconds]
charliesome has joined #ruby
malconis has joined #ruby
absolutejam has joined #ruby
niemcu has joined #ruby
malconis has quit [Client Quit]
tedstriker has quit [Quit: Anti-Fraping status set.]
<ruby-lang251> so im saving my account/password on the same line to a txt doc and passing both arguments into this method...where am i wrong here?
<ruby-lang251> sry indention
bruno- has joined #ruby
bollullera has left #ruby [#ruby]
Bloomer has quit [Ping timeout: 240 seconds]
<cjheath> that code has the wrong number of end’s. Have you even run it?
<cjheath> Oh wait now.
<cjheath> you close the file and return 0 at the end of processing the first line
<cjheath> the file.close and return 0 should be after the end that closes the while loop
cyanide7 has joined #ruby
<Ox0dea> ruby-lang251: Have you come to Ruby from C?
<ruby-lang251> no first language
northfurr has joined #ruby
<ruby-lang251> cjheath: thanks. something so obvious i completely looked over. :/
<cjheath> It’s really not looking like Ruby though as 0x0dea points out
bruno- has quit [Ping timeout: 250 seconds]
<cjheath> hang five, I’ll show you a better way
<ruby-lang251> oh well ive tinkered with html and css a bit but ive not done anything object oriented
nateberkopec has joined #ruby
centrx has quit [Quit: "You cannot fix a machine by just power-cycling it with no understanding of what is going wrong."]
<cjheath> ruby-lang251: Assuming that you must return 0 or 1 (which isn’t Ruby style!): https://gist.github.com/cjheath/7b03bec49ed51b637551
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<cjheath> should return true or nil, and the call should be just “if check_cccount(…)” with no “== 1” on it
northfurr has quit [Client Quit]
Feyn has joined #ruby
yfeldblum has quit [Ping timeout: 240 seconds]
RegulationD has quit [Ping timeout: 260 seconds]
<cjheath> How’s the weather in Wichita anyhow?
jdawgaz has joined #ruby
nateberkopec has quit [Ping timeout: 264 seconds]
<Ox0dea> cjheath: File.open('account.txt').find { |line| line[acct] && line[pass] }
<Ox0dea> But pretend you didn't see that.
<cjheath> 0x0dea: That doesn’t close the file.
zenguy_pc has quit [Read error: Connection reset by peer]
<Ox0dea> I'll phone the authorities.
<cjheath> the idea wasn’t golf anyhow :)
zenguy_pc has joined #ruby
<Ox0dea> String#[String] should be more popular.
<cjheath> :)
darkf has joined #ruby
Aswebb_ has joined #ruby
zenguy_pc has quit [Read error: Connection reset by peer]
zenguy_pc has joined #ruby
jdawgaz has quit [Client Quit]
shortdudey123 has quit [Remote host closed the connection]
Bloomer has joined #ruby
tjohnson has quit [Quit: Connection closed for inactivity]
<ruby-lang251> cjheath, Ox0dea: thanks
<Ox0dea> ruby-lang251: Do you mind my asking whence you're learning Ruby?
<ruby-lang251> must admit Ox0deas notation looks more enticing
<Ox0dea> <3
<Ox0dea> Ruby is for lovers.
<ruby-lang251> lol
<ruby-lang251> im using multiple sources
<ruby-lang251> but rubymonk.com
duckpuppy has joined #ruby
<ruby-lang251> + google
<ruby-lang251> + this chat
<ruby-lang251> + just tinkering around with things
<cjheath> ruby-lang251: Just remember that File.open only closes the file if you pass a block
<ruby-lang251> i shall
Aswebb_ has quit [Ping timeout: 240 seconds]
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
jdawgaz has joined #ruby
gambl0re has joined #ruby
dopieee has joined #ruby
<Ox0dea> ruby-lang251: Well, but, for instance, how did you come to associate 0 with falsehood?
<Ox0dea> Explicitly comparing with 0 isn't even all that conventional in C.
tvw has quit [Ping timeout: 256 seconds]
<ruby-lang251> well 0 just means none existent to me
<cjheath> or with 1. Especially with 1, in fact
<cjheath> Not in Ruby
<cjheath> “0” is truthy in Ruby
<ruby-lang251> why?
<Ox0dea> Because that's how it should be.
<ruby-lang251> whats false?
<ruby-lang251> -1?
<Ox0dea> Yikes. :P
<cjheath> false and nil, and nothing else
<Ox0dea> And may sanity ever prevail.
<cjheath> if snity prevailed, we wouldn;t have both being falsy :)
<ruby-lang251> got it.
<Ox0dea> cjheath: Hm? It's good to distinguish being nonexistence and falsehood.
<Ox0dea> s/being/between/
<cjheath> truthiness should be false and true and nothing else
<Ox0dea> I take your point, but `nil` being truthy would be so weird.
<cjheath> nothing but true should be truthy
<Ox0dea> I disagree emphatically.
<cjheath> but here I’m starting to sound like a typed-language afionado, when in reality I’m no-where near so bigoted
<cjheath> just pointing out that both Ruby and C are odd in different ways
<ruby-lang251> i just got ruby logic pwned truthy?
<cjheath> 0x0dea: If you want three-valued logic, Ruby’s is not the right one to choose.
<cjheath> but it works well enough, fo all that
shortdudey123 has joined #ruby
cmoney has quit [Remote host closed the connection]
craysiii has joined #ruby
nateberkopec has joined #ruby
<Ox0dea> ruby-lang251: Any Ruby value may participate in a boolean context.
<Ox0dea> Where you would explicitly say `true`, you can actually say anything other than `false` or `nil` and the same branch will be taken.
<Ox0dea> >> 42 if :symbols_are_truthy
<ruboto> Ox0dea # => 42 (https://eval.in/458158)
d34th4ck3r has joined #ruby
cmoney has joined #ruby
<cjheath> >> “Hello rubot”
<ruboto> cjheath # => undefined local variable or method `rubot”' for main:Object (NameError) ...check link for more (https://eval.in/458159)
_blizzy_ has joined #ruby
<cjheath> heh. smart quotes
nateberkopec has quit [Ping timeout: 240 seconds]
NeverDie has joined #ruby
h99h9h88 has quit [Remote host closed the connection]
wildlander has quit [Quit: Saliendo]
benlovel1 has joined #ruby
benlovell has joined #ruby
rshetty_ has quit [Remote host closed the connection]
<baweaver> You can even do this!
<baweaver> >> "Hi!" if 0x0dea
<ruboto> baweaver # => "Hi!" (https://eval.in/458160)
<baweaver> Ox0dea would approve
benlovel1 has quit [Ping timeout: 255 seconds]
benlovell has quit [Ping timeout: 255 seconds]
yfeldblum has joined #ruby
Pupeno has joined #ruby
yfeldblum has quit [Remote host closed the connection]
slackbotgz has joined #ruby
yfeldblum has joined #ruby
d34th4ck3r has quit [Quit: zzz]
nateberkopec has joined #ruby
rrichardsr3 has quit [Quit: He who dares .... wins.]
houhoulis has quit [Remote host closed the connection]
Pupeno has quit [Ping timeout: 246 seconds]
swgillespie has joined #ruby
<Ox0dea> >> Would baweaver approve? if 1 == 1i
<ruboto> Ox0dea # => nil (https://eval.in/458161)
<Lilian> Is using backtics encouraged over using %x{} ?
<baweaver> well that answers that
<Lilian> I thought %x{} looked nicer, but rubocop got mad at me about it
unreal_ has joined #ruby
<baweaver> To quote a very wise man on the subject
<baweaver> They're not really rules, they're more of guidelines really
nateberkopec has quit [Ping timeout: 240 seconds]
<Lilian> yeah definitely, if they were rules I wouldn't be able to use %x{}
* baweaver isn't apologizing for quoting Captain Barbosa
<Lilian> but I guess I'm trying to "properly" learn so my code doesn't look shit
<Ox0dea> Lilian: Shit in RuboCop's cereal and use `%x foo `.
<Ox0dea> Yes, space as the delimiter.
rshetty has joined #ruby
<Lilian> lmao
<Lilian> okay sure
dikaio has quit [Quit: ........]
`tim` has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<baweaver> acknowledge that guidelines are only there to keep certain juniors on teams from arguing for hours on pointless nonsense.
unreal has quit [Ping timeout: 240 seconds]
<Lilian> ha, fair enough
<baweaver> instead of things that actually matter like efficiency and architecture
towski_ has joined #ruby
cmoney has quit [Remote host closed the connection]
<Ox0dea> I found some bikesheds on sale: http://idiosyncratic-ruby.com/15-207-ways-to-rome.html
<baweaver> of course they do
gener1c_ has joined #ruby
alexdunne has joined #ruby
<Lilian> of course there's an idiosyncratic-ruby.com
l_tonz has quit [Remote host closed the connection]
failshell has joined #ruby
blur3d has joined #ruby
gener1c has quit [Ping timeout: 264 seconds]
failshell has quit [Remote host closed the connection]
bigmac__ has joined #ruby
alexdunne has quit [Ping timeout: 240 seconds]
braincra- has quit [Quit: bye bye]
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
djbkd has joined #ruby
niemcu has quit [Ping timeout: 264 seconds]
l_tonz has joined #ruby
RegulationD has joined #ruby
braincrash has joined #ruby
pdoherty has quit [Ping timeout: 246 seconds]
snockerton has joined #ruby
snockerton has quit [Client Quit]
nateberkopec has joined #ruby
sanjayu has joined #ruby
l_tonz has quit [Ping timeout: 250 seconds]
RegulationD has quit [Ping timeout: 260 seconds]
l_tonz has joined #ruby
freerobby has joined #ruby
failshell has joined #ruby
gamov has joined #ruby
jgt2 has joined #ruby
shock_one has joined #ruby
nateberkopec has quit [Ping timeout: 246 seconds]
failshell has quit [Remote host closed the connection]
kp666 has quit [Remote host closed the connection]
cyanide7 has quit [Remote host closed the connection]
bigmac__ has quit [Quit: Leaving]
blue_deref has joined #ruby
chipotle has joined #ruby
_blizzy_ has quit [Ping timeout: 264 seconds]
shock_one has quit [Ping timeout: 255 seconds]
jgt2 has quit [Ping timeout: 260 seconds]
failshell has joined #ruby
gix has quit [Ping timeout: 240 seconds]
slackbotgz has quit [Remote host closed the connection]
failshell has quit [Remote host closed the connection]
<gambl0re> hi guys
gix has joined #ruby
workmad3 has joined #ruby
<cjheath> hi
foooobear has joined #ruby
<gambl0re> i have a question
<Ox0dea> That's a statement.
<gambl0re> ?
Motoservo has joined #ruby
kp666 has joined #ruby
bruno- has joined #ruby
eminencehc has joined #ruby
failshell has joined #ruby
eminencehc has quit [Remote host closed the connection]
<Ox0dea> > to be honest, i dont feel comfortable asking questions in here anymore
<al2o3-cr> Does Ruby have any packet manipulation gems similar to scapy except packetfu?
failshell has quit [Remote host closed the connection]
workmad3 has quit [Ping timeout: 272 seconds]
<Ox0dea> al2o3-cr: How've you found PacketFu to be deficient?
govg has quit [Ping timeout: 250 seconds]
nateberkopec has joined #ruby
<al2o3-cr> Ox0dea: I haven't, just wondering as the metasploit framework doesn't seem to use packetfu any more
diegoaguilar has joined #ruby
Oog has joined #ruby
<al2o3-cr> so wondering what they were using insted
benlovel1 has joined #ruby
benlovell has joined #ruby
<al2o3-cr> *instead
ibouvousaime has quit [Ping timeout: 265 seconds]
bruno- has quit [Ping timeout: 264 seconds]
NeverDie has quit [Read error: Connection reset by peer]
NeverDie_ has joined #ruby
pdoherty has joined #ruby
<Ox0dea> al2o3-cr: What does "doesn't seem to use" mean?
<al2o3-cr> Ox0dea: My mistake they do use packetfu
<al2o3-cr> They was using Racket
NeverDie_ has quit [Max SendQ exceeded]
<cjheath> There must be better languages than Ruby for packet dis/assemby
NeverDie has joined #ruby
nateberkopec has quit [Ping timeout: 268 seconds]
benlovel1 has quit [Ping timeout: 250 seconds]
benlovell has quit [Ping timeout: 250 seconds]
<Ox0dea> cjheath: What makes you say so?
arescorpio has quit [Quit: Leaving.]
<Ox0dea> Ruby's string manipulation facilities are arguably second-to-none.
VeryBewitching has quit [Quit: Konversation terminated!]
<havenwood> cjheath: Which language would be better? Why?
<cjheath> doesn;t really have good structures for manipulating bits-n-bytes
<Ox0dea> Wat.
<cjheath> I don’t mean it has none, just not great
<Ox0dea> cjheath: Integer#[] is bit access.
<cjheath> pack/unpack is a bit clunky if you ask me
<cjheath> I know, I’ve done it too, it was painful
Oog has quit []
Renich has quit [Quit: leaving]
juanca_ has quit []
<Ox0dea> I'm not sure I see how Ruby is at fault.
m3_del has joined #ruby
<cjheath> How many languages have you worked in, professionally, 0x0dea?
chipotle has quit [Quit: cheerio]
failshell has joined #ruby
<havenwood> cjheath: You've made the claim. What's the better language and why?
* cjheath is rubyist since 2002, programmer since 1974
<cjheath> have worked in quite a few languags
<gambl0re> 1974?...
<Ox0dea> I'll round down and say five, but I fail to see the relevance.
<cjheath> since I was 14
<cjheath> currently55
<Ox0dea> My apologies; I was not aware we had a bad-ass over here.
<cjheath> and still coding every day
<gambl0re> are you professional programmer or just hobby?
<cjheath> don’t get me wrong, I love Ruby and all… but… horses for courses
<Ox0dea> cjheath: Which horse, then?
<cjheath> co-founder of Infinuendo.
<havenwood> cjheath: Foxes.
<cjheath> :)
<cjheath> maintainer of treetop
c9s has joined #ruby
c9s has left #ruby [#ruby]
<cjheath> just outside the top 10 in gem downloads
<gambl0re> what is infinuendo
<cjheath> new company - heard of this thing called DNS? It helps you find a web server goven a name :)
<gambl0re> cool man...maybe you can help me with my question
failshell has quit [Remote host closed the connection]
<cjheath> given that I’m currently procrastinating anyway :)
dopieee has quit [Quit: Leaving]
dopie has joined #ruby
willardg has joined #ruby
bnizzle1 has joined #ruby
dfockler has quit [Ping timeout: 246 seconds]
bnizzle has quit [Ping timeout: 268 seconds]
opensource_ninja has quit [Quit: opensource_ninja]
nateberkopec has joined #ruby
slawrence00 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
RobertBirnie has joined #ruby
lkba has quit [Remote host closed the connection]
leafybasil has joined #ruby
nateberkopec has quit [Ping timeout: 246 seconds]
yardenbar has quit [Ping timeout: 246 seconds]
snockerton has joined #ruby
daffy_duck_2 has joined #ruby
Aswebb_ has joined #ruby
leafybasil has quit [Ping timeout: 240 seconds]
daffy_duck has quit [Ping timeout: 260 seconds]
devoldmx has joined #ruby
terminalrecluse has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Aswebb_ has quit [Ping timeout: 250 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
RobertBirnie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
d34th4ck3r has joined #ruby
foooobear has quit [Quit: (null)]
<gambl0re> thanks cjheath
nemo_ has joined #ruby
RegulationD has joined #ruby
blur3d has quit [Ping timeout: 240 seconds]
<baweaver> you should probably just ask your question on channel
<cjheath> asked, answered, s/he has something to play with
<baweaver> if you're ok with it, fine
dcarmich has joined #ruby
jenrzzz has joined #ruby
<baweaver> but gambl0re tends to avoid asking in channel for some reason and never gives a straight answer to it
willardg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
craysiii has quit [Remote host closed the connection]
<cjheath> Well, given that about the moment that gambl0re appeared, 0x0dea mentioned that he doesn;t like to ask questions here, I can understand it
<Radar> Ox0dea: was quoting gambl0re from a few days ago
<cjheath> Oh
<cjheath> sorry, I don’t hang out here normally
<cjheath> just came to try to get an answer on best practise to avoid some new bundler/rubygems dramas
philoserf has joined #ruby
<cjheath> Hi Ryan
RegulationD has quit [Ping timeout: 246 seconds]
<Radar> Hi.
<Radar> Doesn't look like you asked your question yet.
<cjheath> an hour back
<Radar> missed it between all the rambling
<cjheath> But again, since I didn’t really get an answer, I’ve been having trouble (and users of mygems too) with WARN: Unresolved specs during Gem::Specification.reset
nateberkopec has joined #ruby
<baweaver> can't say I've seen it before, I'd have to do some research on it to know :/
<cjheath> because of gem dependency specifications havig ambiguous matches
trautwein has joined #ruby
shock_one has joined #ruby
<cjheath> currently with json; several projcts sharing the same gemset in rbenv, and ven after bundle update everywhere I have two 1.7.x versionf oe json
roxtrongo has joined #ruby
<cjheath> QN: Is it “correc t practise” for a gem to ship a Gemfile.lock, and does that get used while loading gems?
<cjheath> I see a fair few gems that do
<cjheath> I thought that only the dependencies in <foo>.gemspec got used
shinnya has quit [Ping timeout: 252 seconds]
freerobby has quit [Quit: Leaving.]
al2o3-cr has quit [Ping timeout: 264 seconds]
<cjheath> The default behaviour of “bundle gem my_new_gem” is to include all files that are checked in to git
<cjheath> Radar: any thoughts?
nateberkopec has quit [Ping timeout: 244 seconds]
<Radar> I've seen the warning around the place but I don't know what usually fixes it.
<Radar> I thought `gem cleanup` does that, but I am not 100% certain.
<Radar> Would be great if we had a reproducible test case.
poguez_ has quit [Quit: Connection closed for inactivity]
devoldmx has quit [Remote host closed the connection]
<cjheath> I’ve done all thej bundle updates and gem cleanups, and still have two 1.7.x json’s
shock_one has quit [Ping timeout: 260 seconds]
tmtwd has joined #ruby
h99h9h88 has joined #ruby
<Radar> steps to reproduce please
<cjheath> thing is, my bundle and their deps install two specific versions
<cjheath> Hmm. Maybe I can do that :)
favadi has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<cjheath> Might take a bit of extraction though… there;s a Rails app in tere
Bloomer has quit [Ping timeout: 240 seconds]
skinux has quit [Quit: Leaving]
Jello_Raptor has quit [Quit: ZNC - http://znc.in]
<Radar> start up a VPS box somewhere and see if you can reproduce? That'd be a good start.
Jello_Raptor has joined #ruby
ausec has quit [Quit: ZNC 1.6.1 - http://znc.in]
<cjheath> “gem install sdoc” adds this dep: add_runtime_dependency("json", "~> 1.7", ">= 1.7.7”). My gem’s Gemfile.lock requests 1.8.3
<cjheath> factory_girl_rails also requests ~>1.7, >= 1.7.1
<Radar> That shouldn't be happening if it's got a ~> 1.7 in there. It should be anything from the 1.7.x range.
saddad has quit [Ping timeout: 240 seconds]
<Radar> Well, anything from that range that is >= 1.7.7
tlarevo has joined #ruby
<cjheath> curious: “gem "json" cannot be uninstalled because it is a default gem”
<cjheath> the default version is 1.8.1, but these gens have ~>1.7
bweston92 has quit [Ping timeout: 260 seconds]
<cjheath> activesupport 4.2.4 wants 1.7
bruno- has joined #ruby
<cjheath> if it’s now a default gem, perhaps the dependencies should be removed
<Radar> It's not default on all Ruby versions.
<Radar> If it's default, it's a recent version.
benlieb has joined #ruby
m3_del has quit [Remote host closed the connection]
krz has joined #ruby
m3_del has joined #ruby
<cjheath> Hand-editing to remove the dep from all installed gemspecs fixed the issue this time around...
al2o3-cr has joined #ruby
amclain__ has quit [Quit: Leaving]
<cjheath> but it seems like a thing that’s going to bite in more and more ways
<cjheath> and I’ll have to go pristine again anyhow
helpa has quit [Remote host closed the connection]
govg has joined #ruby
helpa has joined #ruby
tubuliferous_ has quit [Ping timeout: 260 seconds]
bruno- has quit [Ping timeout: 272 seconds]
m3_del has quit [Ping timeout: 255 seconds]
choke has joined #ruby
htmldrum has quit [Ping timeout: 255 seconds]
<ruby-lang251> is this proper syntax?
<ruby-lang251> File.open("demondeep/#{username}.txt", "r") {|data| stats << data}
charliesome has joined #ruby
nateberkopec has joined #ruby
<cjheath> data is thej handle to the opened file,
<cjheath> you don’t need , “r” - that’s default
ibouvousaime has joined #ruby
<cjheath> so no, almost certainly not correct (syntax is fine, just the logic isnt!)
<ruby-lang251> this should push the |data| into a stats.array right?
tlarevo has left #ruby [#ruby]
snockerton has quit [Quit: Leaving.]
<cjheath> IDK what stats was before, but if it was an array before, then afterwards, it’ll have one more element, which is a closed handle to a file - almost certainly not useful
<ruby-lang251> hmm
<cjheath> did you want to append the contents of the file as a new final element for the array
<cjheath> ?
<cjheath> that would be stats << data.read
<ruby-lang251> ahh
<cjheath> or did you want to concatenate each line of the file as separate elements to stats?
<cjheath> that would be stats.concat data.readlines or something like that
freerobby has joined #ruby
<bnagy> either way don't use File#open
avahey has quit [Quit: Connection closed for inactivity]
<bnagy> File#read or File#each
shinenelson has joined #ruby
nateberkopec has quit [Ping timeout: 246 seconds]
spacemud has quit [Ping timeout: 250 seconds]
<cjheath> He didnt use File#open, he used File.open - differet thing
<bnagy> my bad, it's foreach (bizarrely)
favadi has joined #ruby
freerobby1 has joined #ruby
<cjheath> also it depends if s/he wants lines, or just the whole file
freerobby has quit [Read error: Connection reset by peer]
<bnagy> yeah I meant ::
<bnagy> but either way, open is still "wrong"
<cjheath> :)
spacemud has joined #ruby
<cjheath> Depends, open is good if you need to rewind for example
freerobby1 has quit [Read error: Connection reset by peer]
<bnagy> yes, it's good if you're doing something completely different to the two situations I was commenting on
freerobby has joined #ruby
<bnagy> attaboy
<cjheath> :)
bryanray has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
htmldrum has joined #ruby
yfeldblum has quit [Ping timeout: 246 seconds]
freerobby has quit [Ping timeout: 260 seconds]
speakingcode has quit [Ping timeout: 268 seconds]
philoserf has quit [Quit: philoserf]
mois3x has quit [Quit: mois3x]
agent_white has quit [Read error: Connection reset by peer]
wprice has quit [Read error: Connection reset by peer]
wprice has joined #ruby
lxsameer has joined #ruby
bryanray has joined #ruby
pdoherty has quit [Ping timeout: 260 seconds]
agent_white has joined #ruby
odigity has quit [Ping timeout: 265 seconds]
nateberkopec has joined #ruby
Log1x has quit [Remote host closed the connection]
sameerynho has joined #ruby
devoldmx has joined #ruby
Mia has joined #ruby
djbkd has quit [Remote host closed the connection]
alexdunne has joined #ruby
mcoder has joined #ruby
<mcoder> Anyone here choose Redis for a project as a versatile datastore vs rolling your own service in Ruby and exposing via HTTP, etc.? Any wins doing this you can elaborate on?
odigity has joined #ruby
lxsameer has quit [Ping timeout: 260 seconds]
<baweaver> the two aren't comparable
<baweaver> you're talking about different things
<baweaver> one is a language, one is a database
arup_r has joined #ruby
ivanskie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<baweaver> ruby can USE redis
<baweaver> or it could use any other number of databases
Ropeney has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
cgfbee has quit [Remote host closed the connection]
astrobunny has joined #ruby
<baweaver> what are you trying to make?
Log1x has joined #ruby
<mcoder> Yes I understand, what I mean is that in a SOA architecture you can implement data service that is called by other services. The data service can do many of the same things Redis can do and then some.
Axy has joined #ruby
<baweaver> I'm not sure you do
nateberkopec has quit [Ping timeout: 265 seconds]
Mia has quit [Ping timeout: 244 seconds]
<baweaver> A service still has a data source
<baweaver> which could be Redis, MySQL, or who knows what else
<mcoder> The immediate need is for realtime stats and distributed caching.
alexdunne has quit [Ping timeout: 246 seconds]
<mcoder> In this case it would be in-memory vs outsource it to a datastore like Redis
<baweaver> I will warn you that Ruby isn't well suited to either streams or realtime
<baweaver> redis is in memory
riotjones has joined #ruby
<baweaver> You'd be looking at an in-memory DB like Redis or Memcached
<baweaver> or a messaging system like RabbitMQ or Kafka for bussing data to something like Logstash or Splunk
djbkd has joined #ruby
<baweaver> If the words "realtime" or "streaming" are used, Ruby is a very bad option
<baweaver> That'd be more the land of something like Scala, Elixir, or NodeJS
<Nilium> Well I just ordered 150 github stickers. This is going to be fun.
<baweaver> Node would be your most common usecase for small to midscale distributed systems and streaming.
<baweaver> Scala tends to take the more advanced ground with frameworks like Spark attached to Kafka and Cassandra clusters for truly massive sets.
<Nilium> I'd use Go for that, but that's more from a maintaining-node-is-hell standpoint
<baweaver> I don't know Go well enough to really recommend it to anyone
cgfbee has joined #ruby
<baweaver> can't say I have the time to get acquainted quite yet either :P
<Radar> I heard Elixir is good too.
<baweaver> but long story short: do more reading on this, it sounds like you're stringing buzzwords together
<Nilium> I recommended it hard enough that it's now one of our primary languages at work
ibouvousaime has quit [Ping timeout: 240 seconds]
<baweaver> Radar: mentioned it
<Radar> dang.
<Nilium> Elixir is on the list of things I want to learn.
RegulationD has joined #ruby
<Radar> Nilium: I'd recommend Programming Elixir by PragProg. Great book.
<Nilium> The trouble with Elixir, and Erlang, is that I always feel like anything I'd use them for is way too big for me to just start building
<Radar> I blew through most of it in a weekend.
<Radar> :D
riotjones has quit [Ping timeout: 252 seconds]
<Radar> More that it was easy to read and well written than my general badassness
<mcoder> baweaver, thanks for trying to help but I may have been misleading here... I am actually using Scala, not Ruby. I'm asking here and other channels to get real-world feedback from those that added Redis their stack to learn how it helped them when implementing similar functionality in their language of choice is rather easy for certain common cases (counters, analytics, distributed cache).
tubuliferous_ has joined #ruby
<baweaver> Check Ruby, Python, and Perl off the list
<baweaver> as I mentioned earlier, anything involving realtime or streaming don't work well in any of those languages
shock_one has joined #ruby
astrobunny has quit [Remote host closed the connection]
<ICantCook> You want to look into nodejs for this
workmad3 has joined #ruby
<Nilium> The most I ever had to do with Go was build stuff to process about 5 billion "events" per day, which is not really that much in practice.
<baweaver> also already mentioned
<mcoder> Scala/Java are just fine for these cases.
<Nilium> Would be a fun project to re-do that in Elixir, but nobody would let me ever deploy it at work
<baweaver> our scale would kill a ruby machine :/
haraoka has joined #ruby
<baweaver> They are
<baweaver> which is why I mentioned Scala above
* havenwood deploys Elixir at work
<baweaver> I just have a seething hatred of Java
moeabdol1 has quit [Quit: WeeChat 1.3]
<Nilium> Most things would kill Ruby unless you had a bunch of servers and a load balancer
yfeldblum has joined #ruby
kerunaru has joined #ruby
RegulationD has quit [Ping timeout: 255 seconds]
jgt2 has joined #ruby
Motoservo has quit [Quit: Over & out.]
<baweaver> we had one guy that killed some larger compute machines on AWS with Scala
<baweaver> managed to in-memory 20GB to Spark
<Nilium> You could certainly get the GC to do that
<Nilium> Scala makes a lot of tiny allocations if you're not careful
<havenwood> mcoder: What is it you're trying to do?
<baweaver> mentioned he might want to lower the batch size, he said he already had
<baweaver> the original was terrabytes
<Nilium> Jeez
<baweaver> scale here gets insane fast
<baweaver> Nilium: do you have a Playstation?
<Nilium> I've got a PS3 and a PS4, though they admittedly don't get much use lately.
workmad3 has quit [Ping timeout: 265 seconds]
<baweaver> you know all the movements you go through, game data, friends, and all that?
<Nilium> More or less.
<baweaver> it gets big fast :P
<Nilium> Sounds like you kind of do stuff similar to what I do for phones.
tkuchiki has quit [Remote host closed the connection]
<baweaver> I just deploy them new servers to break
<Nilium> Except with phones it's thankfully short bursts of use
chrissonar has joined #ruby
nateberkopec has joined #ruby
<mcoder> immediate use would be distributed cache that a few other services would need access to. Also some counters/analytics shortly after. I can do these rather easily and quickly in Scala, which is how I lean as I don't want to add anything to the stack unless it really brings something to the table. I can see how Redis could be a superior option for truly large data sets (JVM isn't ideal over 10GB generally). I'm trying to find any other benefi
<baweaver> It's like a pez dispenser. They click a button and server!
<Nilium> Although you should see what happens when someone sends out a push notification and you can watch a wave of people pick up their phones and open an app as it hits them
jgt2 has quit [Ping timeout: 240 seconds]
<baweaver> mcoder: define what needs to be in live memory
<baweaver> everything else goes to Cassandra, HDFS, or another similar large store
<Nilium> Closest we have to button→server here is probably our Mesos/Marathon stuff.
<Nilium> Which is more button→thing-running-on-server
<Nilium> Assuming there are resources
fedexo has joined #ruby
<baweaver> Have I ever told you I'm officially a badass developer?
hmsimha_ has quit [Ping timeout: 265 seconds]
<baweaver> Like I have it on my resume
<Nilium> Do you have clones, though?
<baweaver> except it's an acronym
<baweaver> Build and Deployment Automation Support System
<Nilium> Clever.
<baweaver> clones in what context?
<Nilium> I have "english major" on mine. I have no idea how I have a job.
<cjheath> BadAssWeaver?
h99h9h88 has quit [Read error: Connection timed out]
<baweaver> Brandon A, but I don't correct people often ;)
<Nilium> Clones as in the kind that you meet and a revolver materializes in one of your hands and you have to shoot the other one because they're evil.
<Nilium> Standard law of doppelgangers.
<baweaver> You've been reading Fractal Prince haven't you?
<Nilium> Never heard of it, actually.
h99h9h88 has joined #ruby
<baweaver> Quantum Thief is the first book in that one
<baweaver> covers that idea in an amusing way.
nateberkopec has quit [Ping timeout: 252 seconds]
<Nilium> Worth reading?
<baweaver> Eh, wasn't my thing
<baweaver> ymmb
<baweaver> ymmv
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Nilium> Hm, may as well give it a shot. Books are cheap.
<Nilium> Part of why I have a mostly unused PS3 and PS4.
kies^ has joined #ruby
tkuchiki has joined #ruby
george2 has left #ruby [#ruby]
skade has joined #ruby
djbkd_ has joined #ruby
rbowlby has quit [Remote host closed the connection]
<baweaver> On my list of must read: Lies of Locke Lamora, Name of the Wind, Blood Song, Mistborn, Wheel of Time
<baweaver> Wheel of time alone will keep you busy for a loooooong time
bruno- has joined #ruby
bryanray has quit [Ping timeout: 260 seconds]
h99h9h88 has quit [Remote host closed the connection]
sdothum has joined #ruby
h99h9h88 has joined #ruby
djbkd_ has quit [Ping timeout: 244 seconds]
bruno- has quit [Ping timeout: 240 seconds]
_michael has joined #ruby
djbkd has quit []
h99h9h88 has quit [Ping timeout: 244 seconds]
aganov has joined #ruby
<shevy> you are such a busy beaver
<shevy> wheel of time makes me sad, the author died right? and a good friend also died perhaps 1 month lateron or so, he read every novel
failshell has joined #ruby
dhjondoh has joined #ruby
<baweaver> Brandon Sanderson picked up the series and finished it
lxsameer_ has joined #ruby
<baweaver> same author that wrote Mistborn
tvw has joined #ruby
Xeago has joined #ruby
skade has quit [Read error: No route to host]
skade has joined #ruby
sameerynho has quit [Ping timeout: 265 seconds]
nateberkopec has joined #ruby
<Nilium> Wheel of Time is on the list of things I might eventually read but might die in the process because that's not insignificant
timonv has joined #ruby
<shevy> hah
<baweaver> 14 books averaging over 800 pages a pop
<baweaver> took me two months
<Nilium> And I'm the sort of person who reads Cryptonomicon and goes "that was long"
ElSif has joined #ruby
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
failshell has quit [Remote host closed the connection]
<Nilium> And then Quicksilver and I think The Confusion. Don't think I read System of the World because I got fed up with it...
<Nilium> I don't really like Neal Stephenson anymore. That kind of sucks.
_blizzy_ has joined #ruby
shock_one has quit [Remote host closed the connection]
tagrudev has joined #ruby
riotjones has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
nateberkopec has quit [Ping timeout: 252 seconds]
claw has quit [Ping timeout: 260 seconds]
claw has joined #ruby
Pupp3tm4st3r has joined #ruby
Macaveli has joined #ruby
Eiam has quit [Read error: Connection reset by peer]
Axy is now known as Mia
craysiii has joined #ruby
C0r3 has joined #ruby
<C0r3> shevy: Hey!
Aswebb_ has joined #ruby
Icey has quit [Ping timeout: 255 seconds]
tlarevo has joined #ruby
shock_one has joined #ruby
_blizzy_ has quit [Ping timeout: 240 seconds]
haxrbyte_ has quit [Read error: Connection reset by peer]
timonv has quit [Ping timeout: 250 seconds]
haxrbyte has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
norc has joined #ruby
tubuliferous_ has quit [Ping timeout: 256 seconds]
<norc> How does Ruby decide whether to look up "foo" in methods or instance variables?
tlarevo has joined #ruby
<Xeago> norc: instance variables start with @
<baweaver> attr_* define methods
<baweaver> which are effectively getters and setters
<norc> Sorry I meant local variable. :)
towski_ has quit [Remote host closed the connection]
Aswebb_ has quit [Ping timeout: 250 seconds]
<baweaver> I want to say it starts looking local and then scopes out
Pisuke has joined #ruby
agent_white has quit [Read error: Connection reset by peer]
Xeago has quit []
<baweaver> anyways, bed for me. 'night
tlarevo has quit [Read error: Connection reset by peer]
baweaver has quit [Remote host closed the connection]
<norc> >> a = 0; def a; 1; end; a
<ruboto> norc # => 0 (https://eval.in/458223)
<norc> I would naively expect Ruby to call the method a.
tlarevo has joined #ruby
Icey has joined #ruby
l_tonz has quit [Remote host closed the connection]
MyMind has quit [Ping timeout: 252 seconds]
tlarevo has quit [Read error: No route to host]
tlarevo has joined #ruby
_michael has quit [Quit: leaving]
tvw has quit []
Bloomer has joined #ruby
alexdunne has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
benlieb has quit [Quit: benlieb]
tlarevo has joined #ruby
towski_ has joined #ruby
mcoder has quit [Quit: HydraIRC -> http://www.hydrairc.com <- Would you like to know more?]
nateberkopec has joined #ruby
yardenbar has joined #ruby
<norc> >> a = 0; foo = proc { a += 1 }; def bar; foo.call; end; bar()
<ruboto> norc # => undefined local variable or method `foo' for main:Object (NameError) ...check link for more (https://eval.in/458224)
<norc> Blah. Why
tlarevo has quit [Read error: Connection reset by peer]
<norc> And ruboto behaves differently than my Ruby here mmm.
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
tlarevo has joined #ruby
kerunaru has joined #ruby
alexdunne has quit [Ping timeout: 250 seconds]
tlarevo_ has joined #ruby
_michael has joined #ruby
skade has quit [Read error: No route to host]
haxrbyte has quit [Remote host closed the connection]
nateberkopec has quit [Ping timeout: 240 seconds]
kies^ has quit [Ping timeout: 260 seconds]
arup_r has quit [Quit: Leaving]
agent_white has joined #ruby
rshetty has quit [Remote host closed the connection]
tlarevo_ has quit [Read error: Connection reset by peer]
Coldblackice has quit [Ping timeout: 240 seconds]
tlarevo has quit [Ping timeout: 255 seconds]
BSaboia has joined #ruby
ych has joined #ruby
ych is now known as Guest84541
tlarevo has joined #ruby
wprice has quit [Quit: wprice]
RegulationD has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
dcarmich has quit [Ping timeout: 268 seconds]
<djellemah> norc: foo is outside of the scope of method bar.
bigkevmcd has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<norc> djellemah: Except the error message says its defined for main:Object, which is where I defined the local variable foo in the first place
bigkevmcd has joined #ruby
RegulationD has quit [Ping timeout: 250 seconds]
tlarevo has quit [Read error: Connection reset by peer]
<norc> Err it says its not defined there. ;-)
tlarevo has joined #ruby
<djellemah> >> a = 0; @foo = proc { a += 1 }; def bar; @foo.call; end; bar()
<ruboto> djellemah # => 1 (https://eval.in/458225)
benlieb has joined #ruby
weemsledeux has joined #ruby
towski_ has quit [Remote host closed the connection]
keen_________ has joined #ruby
<norc> >> foo = proc {}
<ruboto> norc # => #<Proc:0x411fc5e8@/tmp/execpad-b55baf4e9f4e/source-b55baf4e9f4e:2> (https://eval.in/458226)
<norc> Is this not a local variable of main:Object?
dEPy has joined #ruby
keen________ has quit [Ping timeout: 255 seconds]
_michael has quit [Ping timeout: 260 seconds]
akkad has quit [Quit: Emacs must have died]
<dEPy> Is theree any quick metaprogramming trick I can use to see which objects (Classes) are calling which objects (Classes)? So when I run rspec for one example I will see something like: Task sent 'register' to User
emilkarl has joined #ruby
<djellemah> object instances don't have local variables. Methods and bindings do. But methods aren't closures.
<dEPy> So... I guess that's a no?
nateberkopec has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<dEPy> I just want to find our in my Rails app what relies on what. Cause I have a bunch of code that needs cleaning up. :/
dhjondoh has quit [Quit: dhjondoh]
<dEPy> I guess I could look at my tests where I have a lot of setup code also. But I still think there's a better way to do this. Is it?
tak1n has joined #ruby
<djellemah> dEPy: maybe something like rcov would help.
matcouto has joined #ruby
matcouto has joined #ruby
<norc> djellemah: Then who owns that local variable "foo" ?
<norc> djellemah: Or is that the realm of main magic?
fedexo has quit [Ping timeout: 240 seconds]
<dEPy> Well rcov can certainly help me find dead code but not code with too many dependencies
<djellemah> norc: afaik, irb/pry keeps a binding for you that contains the local variables you've defined.
<djellemah> dEPy: or a callgraph from ruby-prof
nateberkopec has quit [Ping timeout: 260 seconds]
<djellemah> dEPy: There's also http://ruby-doc.org/core-2.2.3/TracePoint.html , I've never used it though.
karapetyan has joined #ruby
bruno- has joined #ruby
skade has joined #ruby
BSaboia has quit [Ping timeout: 265 seconds]
napcae has quit [Remote host closed the connection]
benlieb has quit [Quit: benlieb]
dikaio has joined #ruby
wprice has joined #ruby
emilkarl has quit [Quit: emilkarl]
failshell has joined #ruby
bruno- has quit [Ping timeout: 240 seconds]
tubuliferous_ has joined #ruby
failshell has quit [Remote host closed the connection]
chihhsin has quit [Quit: Lost terminal]
subscope has joined #ruby
moeabdol has joined #ruby
<agent_white> Is there an 'elegant' way to convert a 2d array to string? So far I'm just doing...
<agent_white> >> [["foo"]][0][0]
<ruboto> agent_white # => "foo" (https://eval.in/458230)
Feyn has quit [Quit: Leaving]
blackmesa has joined #ruby
<dEPy> agent_white: do you need to combine more strings or is that it?
SylarRuby has joined #ruby
<agent_white> dEPy: That's it! Guess it seems to be the only option.
Or1on has quit [Quit: gone]
<dEPy> I guess. You can complicate things like: [['omg'
<dEPy> oops
<dEPy> [['omg']].first.first or .flatten.first
dhjondoh has joined #ruby
<dEPy> but probably no point
nateberkopec has joined #ruby
solars has joined #ruby
<agent_white> Regex just returns a result in a 2d array instead of a single string.
<agent_white> Yeah exactly.
<agent_white> Oh well, no worries! Just was checking to see.
<dEPy> I guess the best thing you can do is wrap it in a method named something like 'unwrap_from_array' or 'string_from_array'
<dEPy> so if you use it at other places it's more descriptive
<dEPy> If that's the only place you use it then i would just leave it like that
<djellemah> >> "some string"[/(\w+).*/,1]
<ruboto> djellemah # => "some" (https://eval.in/458236)
jamesaxl|2 has joined #ruby
<dEPy> I think that's even more cryptic :)
htmldrum has quit [Ping timeout: 246 seconds]
_aeris_ has quit [Ping timeout: 256 seconds]
htmldrum has joined #ruby
<djellemah> Yup, there's no accounting for taste ;-)
nemo_ has quit [Remote host closed the connection]
<ruby-lang251> 8 hours of coding done.
BSaboia has joined #ruby
gamov has quit [Quit: gamov]
jamesaxl has quit [Ping timeout: 246 seconds]
skade has quit [Quit: Computer has gone to sleep.]
ledestin has quit [Remote host closed the connection]
nateberkopec has quit [Ping timeout: 272 seconds]
_aeris_ has joined #ruby
rshetty has joined #ruby
ledestin has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
quazimodo has quit [Ping timeout: 260 seconds]
tlarevo has joined #ruby
astrobunny has joined #ruby
dEPy has quit [Ping timeout: 268 seconds]
duckpuppy has quit [Ping timeout: 244 seconds]
diegoaguilar has quit [Remote host closed the connection]
C0r3 has quit [Quit: leaving]
DoubleMalt has joined #ruby
rshetty has quit [Remote host closed the connection]
rshetty has joined #ruby
HayesHimself has joined #ruby
tmtwd has quit [Ping timeout: 252 seconds]
alexdunne has joined #ruby
pledgeshield has joined #ruby
workmad3 has joined #ruby
calleerlandsson has joined #ruby
d34th4ck3r has quit [Quit: zzz]
rshetty has quit [Ping timeout: 260 seconds]
nfk|laptop has joined #ruby
rbowlby has joined #ruby
d34th4ck3r has joined #ruby
pledgeshield has left #ruby [#ruby]
platzhirsch has joined #ruby
codecop has joined #ruby
alexdunne has quit [Ping timeout: 260 seconds]
Gnomethrower has joined #ruby
nateberkopec has joined #ruby
workmad3 has quit [Ping timeout: 246 seconds]
roxtrongo has quit [Remote host closed the connection]
dionysus69 has joined #ruby
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
workmad3 has joined #ruby
ruby-lang251 has quit [Quit: Page closed]
TomyWork has joined #ruby
SCHAAP137 has joined #ruby
aspiers has joined #ruby
nateberkopec has quit [Ping timeout: 255 seconds]
rshetty has joined #ruby
roxtrongo has joined #ruby
CloCkWeRX has quit [Quit: Leaving.]
CloCkWeRX1 has joined #ruby
workmad3 has quit [Ping timeout: 250 seconds]
RegulationD has joined #ruby
beast has joined #ruby
leafybasil has joined #ruby
Luna_Moonfang has quit [Quit: WeeChat 1.3]
vigintas has joined #ruby
Luna_Moonfang has joined #ruby
charliesome has joined #ruby
jgt2 has joined #ruby
tvw has joined #ruby
tak1n has quit [Ping timeout: 246 seconds]
blaxter has joined #ruby
leafybasil has quit [Ping timeout: 264 seconds]
RegulationD has quit [Ping timeout: 255 seconds]
charliesome has quit [Client Quit]
benlovel1 has joined #ruby
benlovell has joined #ruby
tlarevo_ has joined #ruby
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
nemo_ has joined #ruby
jgt2 has quit [Ping timeout: 260 seconds]
tlarevo has quit [Read error: Connection reset by peer]
<djellemah> Periodically I find a use for an xpath-style object-tree-querying gem. Which I haven't found yet. So far I've looked at Representable, Parslet::Transform, alf and rom but none of them really do what I'm looking for. Any other suggestions?
stan has joined #ruby
ta has quit [Remote host closed the connection]
ta has joined #ruby
<ddv> djellemah: You can't use Nokogiri?
skade has joined #ruby
Aswebb_ has joined #ruby
<apeiros> as far as I understood, they want to query object structures, not xml. but with a mechanism like xpath.
<djellemah> ddv: First I'd have to convert the object graph to xml. Which is overkill.
rshetty has quit [Remote host closed the connection]
<ddv> oh
nateberkopec has joined #ruby
<norc> Is there some way to get an (incomplete) parse tree representation of ruby code that *fails* to parse, to understand how Ruby tries to understand a piece of code?
<norc> Ripper seems to only work on code that successfully parses
Ox0dea has quit [Ping timeout: 264 seconds]
andikr has joined #ruby
dc has joined #ruby
tak1n has joined #ruby
Pupeno has joined #ruby
Pupeno has joined #ruby
Luna_Moonfang has quit [Quit: changing terminal]
Luna_Moonfang has joined #ruby
nateberkopec has quit [Ping timeout: 244 seconds]
govg has quit [Ping timeout: 255 seconds]
tkuchiki_ has joined #ruby
tkuchiki has quit [Read error: Connection reset by peer]
shock_one has quit [Remote host closed the connection]
failshell has joined #ruby
alexdunne has joined #ruby
joonty has joined #ruby
Bloomer has quit [Remote host closed the connection]
CloCkWeRX1 has left #ruby [#ruby]
rshetty has joined #ruby
failshell has quit [Ping timeout: 255 seconds]
sl33k has joined #ruby
tlarevo_ has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
davedev2_ has quit [Remote host closed the connection]
d34th4ck3r has quit [Quit: zzz]
ruurd has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
shredding has joined #ruby
senayar has joined #ruby
sl33k has quit [Client Quit]
cjheath has quit [Ping timeout: 250 seconds]
howdoi has joined #ruby
devoldmx has quit [Remote host closed the connection]
darkf has quit [Ping timeout: 264 seconds]
cjheath has joined #ruby
postmodern has quit [Quit: Leaving]
nateberkopec has joined #ruby
ibouvousaime has joined #ruby
kimegede has joined #ruby
devoldmx has joined #ruby
Bloomer has joined #ruby
Juanchito has joined #ruby
dikaio has quit [Quit: ........]
Alina-malina has joined #ruby
nateberkopec has quit [Ping timeout: 260 seconds]
Pumukel has joined #ruby
Peg-leg has joined #ruby
big|bad|wolf has joined #ruby
timonv has joined #ruby
Pumukel has quit [Excess Flood]
workmad3 has joined #ruby
Pumukel has joined #ruby
darkf has joined #ruby
G has quit [Remote host closed the connection]
chihhsin has joined #ruby
ruurd has quit [Quit: ZZZzzz…]
G has joined #ruby
SylarRuby has quit []
mikecmpbll has joined #ruby
Archyme_ has quit [Quit: Leaving]
workmad3 has quit [Ping timeout: 260 seconds]
Cyther has quit [Quit: Leaving]
pepperbreath has quit [Quit: Leaving.]
darkf_ has joined #ruby
duncannz has joined #ruby
marr has joined #ruby
devoldmx_ has joined #ruby
TheHodge has joined #ruby
duncannz has quit [Max SendQ exceeded]
Peg-leg has quit [Read error: Connection reset by peer]
darkf has quit [Ping timeout: 246 seconds]
Peg-leg has joined #ruby
Peg-leg has quit [Read error: Connection reset by peer]
duncannz has joined #ruby
Peg-leg has joined #ruby
darkf_ is now known as dkar
dkar is now known as darkf
Stoge88 has joined #ruby
Stoge88 has quit [Client Quit]
infernix has quit [Ping timeout: 240 seconds]
bweston92 has joined #ruby
devoldmx has quit [Ping timeout: 265 seconds]
nateberkopec has joined #ruby
infernix has joined #ruby
workmad3 has joined #ruby
aspiers has quit [Ping timeout: 268 seconds]
chthon has joined #ruby
nateberkopec has quit [Ping timeout: 255 seconds]
RegulationD has joined #ruby
devoldmx has joined #ruby
devoldmx_ has quit [Read error: Connection reset by peer]
workmad3 has quit [Ping timeout: 260 seconds]
haxrbyte has joined #ruby
lkba has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
shock_one has joined #ruby
pepperbreath has joined #ruby
haxrbyte_ has joined #ruby
tlarevo has joined #ruby
benlovel1 has quit [Quit: Lost terminal]
benlovell has quit [Quit: Lost terminal]
RegulationD has quit [Ping timeout: 244 seconds]
infernix has quit [Ping timeout: 256 seconds]
tomaz_b has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
haxrbyte has quit [Ping timeout: 264 seconds]
lxsameer_ has quit [Ping timeout: 250 seconds]
shock_one has quit []
tlarevo_ has joined #ruby
lxsameer_ has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
jgt2 has joined #ruby
tlarevo_ has quit [Read error: Connection reset by peer]
devoldmx has quit [Ping timeout: 260 seconds]
devoldmx_ has joined #ruby
tvw has quit [Ping timeout: 250 seconds]
tlarevo has joined #ruby
htmldrum has quit [Ping timeout: 264 seconds]
devoldmx_ has quit [Remote host closed the connection]
tlarevo has quit [Read error: Connection reset by peer]
d34th4ck3r has joined #ruby
devoldmx has joined #ruby
tlarevo has joined #ruby
Hounddog has joined #ruby
haxrbyte_ has quit [Ping timeout: 250 seconds]
last_staff has joined #ruby
nateberkopec has joined #ruby
bruno- has joined #ruby
devoldmx has quit [Ping timeout: 240 seconds]
govg has joined #ruby
big|bad|wolf has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sameerynho has joined #ruby
spider-mario has joined #ruby
EmeraldExplorer has quit [Quit: Connection closed for inactivity]
Neniah has joined #ruby
big|bad|wolf has joined #ruby
Hounddog has quit [Ping timeout: 252 seconds]
rbowlby has quit [Remote host closed the connection]
lxsameer_ has quit [Ping timeout: 272 seconds]
nateberkopec has quit [Ping timeout: 250 seconds]
bruno- has quit [Ping timeout: 246 seconds]
Hounddog has joined #ruby
Neniah has quit [Remote host closed the connection]
bruno- has joined #ruby
elaptics`away is now known as elaptics
Peg-leg has quit [Read error: Connection reset by peer]
Peg-leg has joined #ruby
Peg-leg has quit [Read error: Connection reset by peer]
Peg-leg has joined #ruby
jgt2 has quit [Ping timeout: 272 seconds]
infernix has joined #ruby
jordanloky has joined #ruby
darkf has quit [Ping timeout: 250 seconds]
tubuliferous_ has quit [Ping timeout: 256 seconds]
karapetyan has quit [Remote host closed the connection]
A124 has quit [Read error: No route to host]
karapetyan has joined #ruby
bonemind has joined #ruby
dc has quit [Remote host closed the connection]
d34th4ck3r has quit [Quit: zzz]
A124 has joined #ruby
Pupp3tm4st3r has quit [Ping timeout: 240 seconds]
haxrbyte has joined #ruby
haxrbyte has quit [Read error: Connection reset by peer]
agit0 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
haxrbyte has joined #ruby
haxrbyte has quit [Read error: Connection reset by peer]
duckpuppy has joined #ruby
haxrbyte has joined #ruby
dmolina has joined #ruby
nateberkopec has joined #ruby
Pupp3tm4st3r has joined #ruby
rodfersou has joined #ruby
nofxx has quit [Ping timeout: 256 seconds]
blue_deref has quit [Quit: bbn]
duckpuppy has quit [Ping timeout: 240 seconds]
darkf has joined #ruby
haxrbyte_ has joined #ruby
teclator has joined #ruby
haxrbyte has quit [Read error: Connection reset by peer]
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
nateberkopec has quit [Ping timeout: 252 seconds]
big|bad|wolf has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
workmad3 has joined #ruby
haraoka has quit [Remote host closed the connection]
duncannz has quit [Remote host closed the connection]
leafybasil has joined #ruby
leafybasil has quit [Remote host closed the connection]
stamina has joined #ruby
akem has joined #ruby
leafybasil has joined #ruby
jamesaxl|2 has quit [Ping timeout: 246 seconds]
astrobunny has quit [Remote host closed the connection]
karapetyan has quit [Remote host closed the connection]
charliesome has joined #ruby
karapetyan has joined #ruby
big|bad|wolf has joined #ruby
gregoriokusowski has joined #ruby
kp666_ has joined #ruby
kp666_ has quit [Max SendQ exceeded]
big|bad|wolf has quit [Max SendQ exceeded]
kp666_ has joined #ruby
kp666_ has quit [Max SendQ exceeded]
pandaant_ has joined #ruby
kp666_ has joined #ruby
kp666_ has quit [Read error: Connection reset by peer]
karapetyan has quit [Ping timeout: 252 seconds]
kp666_ has joined #ruby
kp666_ has quit [Max SendQ exceeded]
kp666_ has joined #ruby
kp666_ has quit [Max SendQ exceeded]
kp666_ has joined #ruby
kp666_ has quit [Max SendQ exceeded]
kp666 has quit [K-Lined]
niemcu has joined #ruby
dhjondoh has quit [Quit: dhjondoh]
Jackneill has joined #ruby
DaniG2k has joined #ruby
jgt2 has joined #ruby
matcouto has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
nateberkopec has joined #ruby
JammyHammy has quit [Read error: Connection reset by peer]
stamina has quit [Quit: WeeChat 1.3]
charliesome has joined #ruby
User458764 has quit [Ping timeout: 260 seconds]
lkba_ has joined #ruby
RegulationD has joined #ruby
Rickmasta has joined #ruby
User458764 has joined #ruby
nateberkopec has quit [Ping timeout: 250 seconds]
lkba has quit [Ping timeout: 240 seconds]
stamina has joined #ruby
vigintas has quit [Ping timeout: 250 seconds]
RegulationD has quit [Ping timeout: 240 seconds]
txdv_ has joined #ruby
txdv has quit [Ping timeout: 244 seconds]
TPBallbag has joined #ruby
ICantCook has quit [Ping timeout: 240 seconds]
ICantCook has joined #ruby
Guest84541 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Bloomer has quit [Remote host closed the connection]
ych has joined #ruby
ych is now known as Guest76581
UtkarshRay has joined #ruby
Macaveli has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rshetty has quit [Remote host closed the connection]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
akem has quit [Quit: Bye]
ziprar has joined #ruby
benlovell has joined #ruby
JammyHammy has joined #ruby
rshetty has joined #ruby
ldnunes has joined #ruby
rshetty has quit [Remote host closed the connection]
charliesome has joined #ruby
Igorshp has joined #ruby
nateberkopec has joined #ruby
vigintas has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
favadi has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tlarevo has joined #ruby
failshell has joined #ruby
gregf_ has quit [Quit: Lost terminal]
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
rshetty has joined #ruby
nateberkopec has quit [Ping timeout: 272 seconds]
krz has quit [Ping timeout: 272 seconds]
<darix> norc: ruby_parser also exists
<darix> but in doubt paste the code to gist.github.com and maybe we can tell you
<darix> probably something with optional () which would make it parse
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
codecop has quit [Remote host closed the connection]
failshell has quit [Ping timeout: 264 seconds]
<norc> darix: Oh Im just trying to understand how Ruby attemps (and fails) to parse this snippet I found here yesterday; def f(n) end; p f 1, f 1
bruno- has quit [Read error: Connection reset by peer]
tlarevo has quit [Read error: Connection reset by peer]
<darix> norc: add ()
<darix> either to the f() or p() call
Igorshp has quit [Remote host closed the connection]
<norc> darix: That is the thing. Adding it to the p() call is not enough.
but3k4 has joined #ruby
<darix> f 1, f 1 could mean
<darix> f(1,f(1)) or f(1), f(1)
niemcu has quit [Ping timeout: 255 seconds]
subscope has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tlarevo has joined #ruby
<norc> darix: I cannot find any combination of paranthesis that reproduces that error message.
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<norc> As I said, Im really trying to figure out what Ruby assumes if you leave them out, because I cannot reproduce it.
govg has quit [Ping timeout: 256 seconds]
<darix> norc: well if you add the () it is not ambiguous anymore
<yorickpeterse> IIRC it's parsed as:
<yorickpeterse> def f(n); end; p(f.1, f)
<yorickpeterse> err
<yorickpeterse> def f(n); end; p(f.1, f(1))
<darix> norc: similar problems can happen with:
<yorickpeterse> though I'm pretty sure it's a syntax error
<darix> f 1 { ... }
<norc> Okay, lets reduce this for simplicity sake to: [p(1), p 1]
<norc> SyntaxError: (irb):28: syntax error, unexpected tINTEGER, expecting keyword_do or '{' or '('
bruno- has joined #ruby
<darix> sometimes you have to tell the parser a little hint if {} is a hash or a block
<workmad3> norc: `def f(n) end; p f(1, f) 1` gives you that error
<norc> Except there are no curly brackets
<djellemah> [f 1] also give the error.
dhjondoh has joined #ruby
dhjondoh has quit [Client Quit]
<norc> workmad3: Ruby expects end-of-input rather than do, { or ( though.
rshetty has quit [Remote host closed the connection]
<workmad3> norc: or simplified to f(1, f) 1
<darix> crowd sourced test case reduction
<norc> Or is that irrelevant?
rshetty has joined #ruby
y0da has joined #ruby
cjheath has quit [Quit: cjheath]
<norc> workmad3: Ohh damn I get it now.
but3k4 has quit [Read error: Connection reset by peer]
<agent_white> p f 1, f 1. print func arg, arg func
tlarevo has quit [Read error: Connection reset by peer]
<norc> Isnt there a difference between those two tho? http://pastie.org/10513262
symm- has joined #ruby
tlarevo has joined #ruby
<darix> norc: does it really matter if the solution is "make the code less ambiguous"?
<workmad3> norc: a slight one, yes... `f(1, f) 1` removes one bit of ambiguity leaving fewer options on the exact syntax error
<darix> even if you could fix the parser to handle the case. just for the readability i would add the ()
<norc> darix: This is not my code, and this is just purely educational about the parser here. :)
rshetty has quit [Remote host closed the connection]
weihan_ has joined #ruby
<agent_white> norc: `def f(n) end; p f 1, f; 1` vs `def f(n) end; p f 1, f; 1
allcentury has joined #ruby
<agent_white> erm
cjheath has joined #ruby
<norc> (Over the past few weeks I noticed much how time it saves me to carefully read parser errors. Understanding what the error means, rather than just looking at the line and trying out things until the code works again)
Oatmeal has quit [Read error: Connection reset by peer]
<agent_white> `p f 1, f 1` vs `p f 1, f; 1`
nateberkopec has joined #ruby
rshetty has joined #ruby
haxrbyte_ has quit [Ping timeout: 272 seconds]
gregf_ has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
Igorshp has joined #ruby
<norc> workmad3: I think Im slowly getting it. It chokes on: p(something) tINTEGER
skade has quit [Quit: Computer has gone to sleep.]
<workmad3> norc: it also chokes on f(1, f 1) btw
Oatmeal has joined #ruby
nateberkopec has quit [Ping timeout: 250 seconds]
rshetty has quit [Ping timeout: 265 seconds]
s00pcan has quit [Ping timeout: 268 seconds]
<workmad3> norc: personally, I find it's easier to be liberal with use of parens rather than try to figure out exactly what the parser might see in some esoteric circumstance... even if I can get it to parse, there's likely to be enough ambiguity that I'd have trouble figuring out if it was correct anyway so I'd prefer a couple of extra chars that meant I could read my own code ;)
syath has joined #ruby
<agent_white> ^
DaniG2k has left #ruby [#ruby]
<agent_white> workmad3: You and me both brotha. Rubyists for parens! :D
<norc> workmad3: Absolutely. It was never my goal to leave out parens. :)
<workmad3> agent_white: definitely! no parens for parameterless methods, and rarely parens on class macros... otherwise parens everywhere!
<norc> Bought Ruby under a Microscope the other day, and the book starts off with the tokenizer and parser - so here I am, trying to figure things out one bit at a time.
<workmad3> agent_white: `super` vs `super()` can still cause me to spend some extra time figuring out code though :)
tlarevo has quit [Read error: Connection reset by peer]
kimegede has quit [Quit: Leaving...]
tlarevo has joined #ruby
karapetyan has joined #ruby
kimegede has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
Rollabunna has joined #ruby
<agent_white> workmad3: Haha same here! I'll add parens to methods without params more as 'notes' to myself to "be mindful" around the method. :P
tlarevo has joined #ruby
<norc> Im actually wondering whether my reduced example of [p(1), p 1] # => actually is not ambiguity, but a demonstration that Ruby does not condone leaving out parens (it actually tells me that it expected () {} or do end after the second p)
<norc> workmad3: What difference?
solocshaw has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
<workmad3> norc: between `super` and `super()`?
<norc> Yeah
<workmad3> norc: `super` calls the supermethod with the original arguments (possibly modified), `super()` calls the supermethod with no arguments
karapetyan has quit [Ping timeout: 264 seconds]
tlarevo has joined #ruby
zenguy_pc has quit [Read error: Connection reset by peer]
<norc> Ok that is a subtle but disgusting difference I was not aware of....
zenguy_pc has joined #ruby
<workmad3> norc: haha :) yup
yeticry_ has quit [Read error: Connection reset by peer]
<djellemah> This kind of inconsistency-that-still-makes-sense is what drives pythonistas up the wall about ruby.
<norc> But yeah, Im beginning to wonder whether strictly adding parens around every method call might be a good idea again...
tkuchiki_ has quit [Remote host closed the connection]
favadi has joined #ruby
dhjondoh has joined #ruby
dhjondoh has quit [Client Quit]
nateberkopec has joined #ruby
RegulationD has joined #ruby
but3k4 has joined #ruby
y0da has quit [Read error: Connection reset by peer]
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
nateberkopec has quit [Ping timeout: 246 seconds]
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
RegulationD has quit [Ping timeout: 264 seconds]
cornerma1 has joined #ruby
agit0 has joined #ruby
<agent_white> djellemah: Haha so true. But they'll never get me to quit bitching about their whitespace.
blackmesa has quit [Ping timeout: 246 seconds]
but3k4 has quit [Ping timeout: 268 seconds]
cornerman has quit [Read error: Connection reset by peer]
cornerma1 is now known as cornerman
rshetty has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
govg has joined #ruby
tlarevo has joined #ruby
<norc> agent_white: I once heard that carriage return is considered a whitespace for Python indentation...
but3k4 has joined #ruby
tlarevo has quit [Remote host closed the connection]
<apeiros> norc: on that note, super() still passes on a block passed to the original method. you need super(&nil) to suppress that.
sankaber has joined #ruby
rshetty_ has joined #ruby
_blizzy_ has joined #ruby
<workmad3> agent_white: tbh, the couple of times I've used python, the whitespace didn't really bother me in practice (I thought it would before hand)... what really bothered me was the weirdness of python objects (always needing an explicit `this` argument for 'methods'), and with what I was doing needing a lot of regexp, the python regexp support made me want to cry with how verbose and crappy it was
<agent_white> norc: Python had me at ending blocks that way... too scary for me. I like defined beginning/ends to things :P
<norc> apeiros: Im guessing beyond historical reasons and "because matz said so" this is just the way it is?
<apeiros> norc: I have no insight into the ideas behind this design :-/
<agent_white> workmad3: Haha oh god yes. 'this' bothered me to no end. Wasn't sure if I was writing JS or python.
<apeiros> I guess the idea was that it's "convenient". personally I think it's more than offset by the confusion it causes.
iceden has quit [Ping timeout: 260 seconds]
<norc> agent_white: 'this' is actually not that bad if you ignore any prior C++ experience, or assume it to be like "self" in Ruby or something along these lines.
solocshaw has quit [Ping timeout: 240 seconds]
rshetty has quit [Ping timeout: 250 seconds]
<norc> The day I understood JavaScript prototypes and method invocation was the day I stopped having headaches when writing JS code. ;-)
<agent_white> norc: Welp. That explains the sour taste it puts on my tongue then ;P
dhjondoh has joined #ruby
dhjondoh has quit [Client Quit]
<workmad3> norc: I still get the occasional headache when I switch between JS and ruby, and forget that something like a `.each` method in JS typically takes a function signature of `function(index, object)` rather than `function(object, index)` and will set `this` to the current object too
subscope has joined #ruby
blackmesa has joined #ruby
<norc> workmad3: Heh. The biggest trap people fall into is when they try to iterate over objects in the first place in JS. It usually never ends well. ;-)
yeticry has joined #ruby
<workmad3> norc: that's a .each on an array, not iterating over object parameters :P
Guest76581 has quit [Quit: Textual IRC Client: www.textualapp.com]
favadi has quit [Quit: Textual IRC Client: www.textualapp.com]
nateberkopec has joined #ruby
stamina has quit [Quit: WeeChat 1.3]
skade has joined #ruby
s00pcan has joined #ruby
<norc> workmad3: Ive seen enough people using for(element in ary) just to discover erroneous behavior because of the two big traps. ;-)
<norc> And after a year you then have a select list with an order that sometimes changes, and always seem to have that "null" as first attribute, which the "senior javascript developer" just cannot explain, because it is a "complex matter".
tlarevo has joined #ruby
symm- has quit [Ping timeout: 260 seconds]
rshetty_ has quit [Read error: Connection reset by peer]
rshetty has joined #ruby
hiyosi has joined #ruby
s00pcan has quit [Ping timeout: 265 seconds]
dionysus69 has quit [Ping timeout: 256 seconds]
s00pcan has joined #ruby
dc has joined #ruby
stamina has joined #ruby
krisquigley has quit []
dc has quit [Ping timeout: 256 seconds]
ruurd has joined #ruby
pandaant_ has quit [Quit: Lost terminal]
duckpuppy has joined #ruby
xaa has joined #ruby
napcae has joined #ruby
<xaa> hi, I am wondering if rubygems is included with ruby > 2.1.5? Because if I rn $apt-cache policy rubygems I have no candiate version. On another server I have ruby1.93 and the candidate is rubygems1.8.24. thank you
Gu_______ has joined #ruby
duckpuppy has quit [Ping timeout: 240 seconds]
<xaa> sorry if this is a dumb question.. I am playing with linux since few months only
Pupp3tm4st3r has quit [Remote host closed the connection]
millerti has joined #ruby
bMalum has joined #ruby
govg has quit [Ping timeout: 252 seconds]
wprice has quit [Quit: wprice]
kimegede has quit [Quit: Linkinus - http://linkinus.com]
kimegede has joined #ruby
JammyHammy has quit [Read error: Connection reset by peer]
SylarRuby has joined #ruby
Icey has quit [Quit: Leaving]
Mon_Ouie has joined #ruby
Icey has joined #ruby
tlarevo has left #ruby [#ruby]
jgt2 has quit [Ping timeout: 255 seconds]
wprice has joined #ruby
pard has joined #ruby
<pard> greetin's
sdothum has joined #ruby
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l(5) { 12 }
<ruboto> pard # => 12 (https://eval.in/458428)
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l (5) { 12 }
<ruboto> pard # => 12 (https://eval.in/458429)
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l 5 { 12 }
<ruboto> pard # => /tmp/execpad-0011f485f473/source-0011f485f473:2: syntax error, unexpected '{', expecting keyword_end ...check link for more (https://eval.in/458430)
<pard> why?
<apeiros> because {} block precedence associates it with 5
<apeiros> l(5 { 12 })
Pupp3tm4st3r has joined #ruby
<pard> thanks, but why won't it do this with (5) in 2?
<pard> thanks, but why won't it do this with (5) in #2?
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l (5) { 12 }
<ruboto> pard # => 12 (https://eval.in/458431)
<apeiros> because () delimit method arguments.
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l (5, 5) { 12 }
<ruboto> pard # => /tmp/execpad-3d76b0f71a13/source-3d76b0f71a13:2: syntax error, unexpected ',', expecting ')' ...check link for more (https://eval.in/458432)
rshetty_ has joined #ruby
zapata has quit [Quit: WeeChat 1.3]
<apeiros> edge case of when and when not () are interpreted as part of the method call or as an expression of its own.
<apeiros> I'd prefer if it was required to not have a space after the method name.
rshetty has quit [Read error: Connection reset by peer]
<pard> apeiros, thanks a lot; isn't it a small quirk ?
<apeiros> define "small quirk"
Igorshp has quit [Remote host closed the connection]
<pard> i mean, the ' ' before '(' is meant to make it be treated as an arg, not an arg list; but in this case, it actually won't
sanjayu has quit [Quit: Leaving]
Igorshp has joined #ruby
<norc> >> (5, 5)
<ruboto> norc # => /tmp/execpad-76cf34c74748/source-76cf34c74748:2: syntax error, unexpected ',', expecting ')' ...check link for more (https://eval.in/458433)
<norc> Its just that
<norc> The space does exactly that pard. It makes Ruby tread it as an expression
<pard> norc, no ; in #2, it does not
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l (5) { 12 }
<ruboto> pard # => 12 (https://eval.in/458434)
prestorium has joined #ruby
<pard> norc, the ' ' in this case does nothing
dhjondoh has joined #ruby
<pard> the (5) is taken as an arg list
<apeiros> as said, edge cases. more reason to use a good code style.
<pard> i guess it can be eliminated; i wonder it has not been yet
<norc> pard: The space makes ruby tread (5) as an expression still.
<norc> >> (5)
<ruboto> norc # => 5 (https://eval.in/458440)
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l (5, 5)
<ruboto> pard # => /tmp/execpad-c9cbaf580b06/source-c9cbaf580b06:2: syntax error, unexpected ',', expecting ')' ...check link for more (https://eval.in/458441)
rshetty_ has quit [Ping timeout: 265 seconds]
<apeiros> norc: no. if it would, the block would be associated with (5).
<norc> >> p((5,5))
<ruboto> norc # => /tmp/execpad-03e45cb84e76/source-03e45cb84e76:2: syntax error, unexpected ',', expecting ')' ...check link for more (https://eval.in/458442)
<norc> That isa the same thing.
<norc> apeiros: mmm
<apeiros> or at least that's how I understand what's going on. I might be off. I try not to use ambiguous syntax and hence rarely run into such stuff :)
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l (5, 5) { 12 }
<ruboto> pard # => /tmp/execpad-db7917337518/source-db7917337518:2: syntax error, unexpected ',', expecting ')' ...check link for more (https://eval.in/458443)
<apeiros> pard: yes. we've seen it. no need to spam it.
<pard> sorry
<norc> But yeah. All of this shows that trying to leave out parens for method calls is a bad idea.
millerti has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
synthroid has joined #ruby
<norc> Or inserting spaces in front of them.
<pard> apeiros, it did not appear in my client; apologies
<pard> the reason i call it a quirk is that, l (5) {12} takes (5) as an arg list, but l (5, 5) won't
<apeiros> it's inconsistent, yes.
<pard> :\
<apeiros> but I think verbose ruby warns you about spaces between method-name and (
inteq has quit [Remote host closed the connection]
Igorshp has quit [Remote host closed the connection]
<pard> verbose ruby?
<apeiros> -v
<pard> thanks
<apeiros> or $VERBOSE=true
<pard> thanks a lot :)
RegulationD has joined #ruby
<pard> apeiros, could i ask for a technicl advice?
<norc> >> 1 =~//
<ruboto> norc # => nil (https://eval.in/458444)
benlovell has quit [Ping timeout: 272 seconds]
<norc> Why does this work? What is this good for?
<apeiros> why should it not work?
Igorshp has joined #ruby
<norc> >> 1 =~ /./
<ruboto> norc # => nil (https://eval.in/458447)
ekinmur has joined #ruby
<norc> apeiros: It seemingly does not match anything.
<apeiros> not just seemingly. it does not match anything.
<norc> Then why allow it in the first place
<apeiros> for the same reason as == is allowed on all objects.
benlovell has joined #ruby
<apeiros> Fixnum#=~ is not defined, so 1 =~ uses Object#=~. and that defaults to always return nil.
Macaveli has joined #ruby
<pard> apeiros, how you actually used any of the parser nstruments availabl for ruby? if yes, has their output been ntelligible?
<apeiros> it allows you to use =~ with *any* object, without first testing whether it is implemented.
<pard> *have
karapetyan has joined #ruby
<apeiros> pard: short answer is no, I haven't.
<pard> sorry
andersoldahl has joined #ruby
RegulationD has quit [Ping timeout: 255 seconds]
<norc> apeiros: I dont know. I mean I can see how =~ #=> nil would be useful for NilClass, but extending it to Object seems a little drastic.
<pard> i was just wondering if there is any acceptabl reason none of them uses a clean representatio of the AST
<norc> But I dont want to judge.
rikkipitt has joined #ruby
benlovell has quit [Ping timeout: 264 seconds]
<apeiros> norc: as said, same reason as for ==
<pard> can && also be oevrloadde like any other op ?
<apeiros> you expect to be able to do `a == b` without thinking about what `a` is.
<apeiros> pard: no. && is not a method call and hence can't be redefined.
<Mon_Ouie> pard: No, because it's not a method (it does not evaluate the rhs if the lhs is false)
<pard> thanks
yeticry has quit [Ping timeout: 265 seconds]
devoldmx has joined #ruby
<norc> apeiros: Testing whether two objects are equal without knowing what they are is a senseful thing. Testing whether any object (String, a Socket or an AbstractInterfaceThingy) matches a string pattern is not.
<norc> But maybe thats just me.
<apeiros> norc: "a string pattern" - who says =~ is limited to that?
<apeiros> irc_user =~ host_mask # where host_mask.class # => HostMask
<norc> apeiros: Oh. I guess the important bit here is in the docs. "meaningful pattern-match semantics."
<norc> Sorry.
<norc> It was just set in my mind that this always means regular expressions.
<apeiros> one problem with == and =~ is that they're not commutative. a == b != b == a.
<pard> >> 12 > 5 > 12
<apeiros> (they can be - if the operands are implemented that way, but they not necessarily are)
<ruboto> pard # => undefined method `>' for true:TrueClass (NoMethodError) ...check link for more (https://eval.in/458449)
<apeiros> pard: ruby does not expand 12 > 5 > 12 to 12 > 5 && 5 > 12 for you.
sepp2k has joined #ruby
<pard> :\
<norc> apeiros: 1 == 2 == 3 is a syntax error to begin with though, no?
<apeiros> so you do (12 > 5) > 12 (execution order), and since 12 > 5 evaluates to true, you do `true > 12`
<apeiros> norc: no. you're chaining methods.
<apeiros> 1 + 2 + 3 # not a syntax error either. chaining methods
<Mon_Ouie> >> 1 == 2 == 3
<ruboto> Mon_Ouie # => /tmp/execpad-491708012d5b/source-491708012d5b:2: syntax error, unexpected == ...check link for more (https://eval.in/458450)
<Mon_Ouie> ^ it is, for some reason
<apeiros> 1.==(2).==(3)
<norc> apeiros: I mean I get what you mean by chaining (its commonly done in C++ operator overloading for >> and <<)
<apeiros> Mon_Ouie: OO
devoldmx has quit [Ping timeout: 272 seconds]
<pard> >:'\
<apeiros> that. is. weird.
<pard> quirk
<apeiros> special cased in the parser then I guess?
<apeiros> >> (1 == 2) == 3
<ruboto> apeiros # => false (https://eval.in/458451)
<apeiros> tbh, with the complexity of ruby's parser I could fully imagine that this is unintentional.
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l(if 5 then 5 else 12 end)
<ruboto> pard # => nil (https://eval.in/458452)
jgt2 has joined #ruby
<pard> >> def l(*_l, &_L ) if _L then 12 end end; l(if 5 then break end)
<ruboto> pard # => /tmp/execpad-0dc94c6a2a08/source-0dc94c6a2a08:2: void value expression (https://eval.in/458453)
<apeiros> pard: what's up with your weird argument names? _l, _L?
<pard> sorry
TPBallbag has quit []
<norc> apeiros: I have a feeling we have an obfuscated code contest candidate here. :-)
<Mon_Ouie> I believe it is because in parse.y tEQ (the token for ==) is marked as "nonassoc". Since it has no associativity rule, the parser could not decide whether a == b == c is (a == b) == c or a == (b == c) and thus it is not allowed.
<norc> The way he has been looking for the weirdest ways to break the ruby parser
<apeiros> pard: "sorry" is unnecessary and not actually an answer :-p
mwlang has joined #ruby
<apeiros> norc: may well just be exploring the limits of ruby. that makes sense to me. gives you a frame of reference.
<Mon_Ouie> (<=>, ==, !=, =~ and !~ are some of the operators that have no associativity rules)
<pard> i thought they might be undistinguishabl from 1 , that's why i perepend them with _
<apeiros> Mon_Ouie: intriguing. not what I'd have expected.
mwlang has quit [Client Quit]
<norc> apeiros: absolutely, I have been doing similar things recently. :)
<norc> Was not trying to be judgemental.
bruno- has quit [Ping timeout: 244 seconds]
<apeiros> if they have <=> and == without associativity, I don't get why >=, >, <, <= have one
<Mon_Ouie> For some reason they explicitly make > and < associative from left to right though
ledestin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<pard> i feel it's an unnecessary thing that merely compicates the parser code
decoponio has joined #ruby
bruno- has joined #ruby
<pard> why don't they just do an RD parser rather than using a '93 crank?
GnuYawk has quit [Ping timeout: 240 seconds]
<apeiros> pard: go ahead and implement an RD parser?
<pard> i mean, look they way llvm's cpp parser compres to gcc's minefield
<Mon_Ouie> Because they wrote it before 93 and no one wants to rewrite it? :p
freerobby has joined #ruby
<pard> *the
brendan- has quit [Ping timeout: 265 seconds]
<apeiros> compare it to the '93 crank and see whether it's better and covers all, if it does, make a pull request?
<pard> :)
<pard> i actually am
<pard> that is why i have joind this channel
<apeiros> pard: then I guess you should ask on the ruby-core ML which parser behaviors are intentional and which aren't.
<agent_white> Maybe they're following bitwise operator precedence in C?
<apeiros> because I doubt anybody but parser implementors/maintainers know.
<pard> thanks :)
blackmesa has quit [Ping timeout: 240 seconds]
<pard> is there a channel for it ? or only the ML ?
s00pcan has quit [Ping timeout: 260 seconds]
dfinninger has joined #ruby
<apeiros> there is #ruby-core. but not sure how active it is.
<apeiros> ML is probably the better place for such things.
<pard> thanks a lot
s00pcan has joined #ruby
<agent_white> Mon_Ouie: Same with associativity... all operators are left to right unless they're assignment, ternary, or increment/casting.
<pard> >> - 5 ** -5
<ruboto> pard # => (-1/3125) (https://eval.in/458464)
<agent_white> (in C)... so I'm assuming it's following the same rules.
<Mon_Ouie> 'int a = 3 == 4 == 5;' is not a syntax error according to GCC though
mwlang has joined #ruby
<pard> does '-' have higher precedenc than '**'?
Igorshp has quit [Remote host closed the connection]
<pard> (the uanry- i mean)
duckpuppy has joined #ruby
dionysus69 has joined #ruby
Igorshp has joined #ruby
DEac- has quit [Quit: leaving]
<agent_white> Mon_Ouie: a = ((3 ==4) == 5) ?
<Mon_Ouie> If I'm reading this correctly, unary minus binds less tightly than '**' (which itself binds less tightly than unary plus)
roxtrongo has quit [Remote host closed the connection]
<pard> >> - 5 ** -12
<ruboto> pard # => (-1/244140625) (https://eval.in/458473)
DEac- has joined #ruby
<pard> thanks
<pard> thanks a lot Mon_Ouie
benlovell has joined #ruby
treehug88 has joined #ruby
BSaboia has quit [Read error: Connection reset by peer]
BSaboia has joined #ruby
* pard feels like an obsessed nitpicker
last_staff has quit [Quit: last_staff]
<xaa> which version of sass should be installed to use on debian with ruby-compass 0.12.2, please ?
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
duckpuppy has quit [Ping timeout: 272 seconds]
Igorshp has quit [Ping timeout: 256 seconds]
beast has quit [Quit: Leaving]
Mon_Ouie has quit [Ping timeout: 252 seconds]
Jackneill has quit [Ping timeout: 250 seconds]
ekinmur has joined #ruby
<pard> thanks for all the help
ekinmur has quit [Client Quit]
benlovell has quit [Ping timeout: 264 seconds]
<pard> apeiros, thanks a lot
mag42c has joined #ruby
pard has left #ruby ["Leaving"]
dhjondoh has quit [Quit: dhjondoh]
JDiPierro has joined #ruby
roxtrongo has joined #ruby
rshetty has joined #ruby
`tim` has joined #ruby
ElFerna has joined #ruby
e1senhorn has joined #ruby
ekinmur has joined #ruby
<mwlang> How do I get a Ruby class instance itself to return a scalar value? For example: https://gist.github.com/mwlang/1e7f0fe26aaba826c562
e1senhorn has left #ruby [#ruby]
sgambino has joined #ruby
<apeiros> mwlang: that concept does not exist in ruby.
elaptics is now known as elaptics`away
pu22l3r_ has quit [Remote host closed the connection]
pu22l3r has joined #ruby
roxtrongo has quit [Remote host closed the connection]
andersoldahl has quit [Quit: Goodbye everyone.]
<agent_white> Mon_Ouie: Sounds right... assignments in C are expressions. Not in Ruby it seems.
<agent_white> Woops. That was late, he's long gone. :P
roxtrongo has joined #ruby
dhjondoh has joined #ruby
RobertBirnie has joined #ruby
<mwlang> apeiros: what about inheriting from say Float class or something along those lines…provide an initialization with different parameters?
dhjondoh has quit [Client Quit]
<apeiros> mwlang: google for coerce & ruby
<apeiros> that might have some ideas on how you can create a new numeric type
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
tkuchiki has joined #ruby
K1MOS has joined #ruby
RobertBirnie has quit [Client Quit]
gambl0re has quit [Ping timeout: 255 seconds]
roxtrongo has quit [Remote host closed the connection]
koos303 has joined #ruby
<mwlang> apeiros: there we go! exactly what I was looking for, but couldn’t quite find the words/concept to call it out.
sameerynho has quit [Quit: Leaving]
sankaber has quit [Remote host closed the connection]
ekinmur has joined #ruby
ekinmur has quit [Client Quit]
Macaveli has quit [Quit: Textual IRC Client: www.textualapp.com]
sankaber has joined #ruby
tkuchiki has quit [Ping timeout: 246 seconds]
Jardayn has joined #ruby
benlovell has joined #ruby
ekinmur has joined #ruby
RegulationD has joined #ruby
Gu_______ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
niemcu has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
synthroid has quit [Remote host closed the connection]
seitensei has joined #ruby
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
failshell has joined #ruby
RegulationD has quit [Ping timeout: 252 seconds]
roxtrongo has joined #ruby
quaj has joined #ruby
freerobby has quit [Quit: Leaving.]
karapetyan has quit [Ping timeout: 240 seconds]
tkuchiki has joined #ruby
blaxter has quit [Quit: foo]
synthroid has joined #ruby
benlovell has quit [Ping timeout: 252 seconds]
Fire-Dragon-DoL has joined #ruby
Aswebb_ has quit [Remote host closed the connection]
everbot has quit [Ping timeout: 240 seconds]
nsuke has joined #ruby
sl33k_ has joined #ruby
sl33k_ has quit [Client Quit]
rshetty has quit [Ping timeout: 255 seconds]
rbennacer has joined #ruby
panzi has joined #ruby
<panzi> anyone knows how to draw an image on top of another image in rmagick? (adding a logo to a corner of another image)
<panzi> I can't find a simple draw_image method!
jdawgaz has joined #ruby
pandaant has quit [Remote host closed the connection]
blackmesa has joined #ruby
dopamean_ has quit [Ping timeout: 240 seconds]
roxtrongo has quit [Remote host closed the connection]
andikr has quit [Remote host closed the connection]
Igorshp has joined #ruby
Voker57 has joined #ruby
<panzi> ah, its composite
panzi has quit [Quit: ChatZilla 0.9.92 [Firefox 41.0.2/20151014143721]]
blackmesa has quit [Ping timeout: 252 seconds]
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
failshell has quit []
jdawgaz has joined #ruby
umgrosscol has joined #ruby
Fire-Dragon-DoL has quit [Remote host closed the connection]
freerobby has joined #ruby
s00pcan has quit [Remote host closed the connection]
s00pcan has joined #ruby
jxl180 has joined #ruby
tomaz_b has quit [Ping timeout: 265 seconds]
quaj has quit [Ping timeout: 250 seconds]
jgpawletko has joined #ruby
haxrbyte has joined #ruby
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
shlomo has joined #ruby
malconis has joined #ruby
krz has joined #ruby
Igorshp has quit [Remote host closed the connection]
benlovell has joined #ruby
Guest53 has joined #ruby
malconis has quit [Remote host closed the connection]
zapata has joined #ruby
malconis has joined #ruby
BSaboia has quit [Ping timeout: 246 seconds]
Gnomethrower is now known as Dogethrower
Dogethrower is now known as Gnomethrower
Igorshp has joined #ruby
blaxter has joined #ruby
sunya7a has quit [Quit: leaving]
krz has quit [Ping timeout: 250 seconds]
sunya7a has joined #ruby
benlovell has quit [Ping timeout: 244 seconds]
sunya7a has quit [Client Quit]
dopie has quit [Ping timeout: 252 seconds]
duckpuppy has joined #ruby
musou has joined #ruby
sunya7a has joined #ruby
blaxter has quit [Ping timeout: 244 seconds]
ekinmur has joined #ruby
ESpiney has joined #ruby
Guest53 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
quaj has joined #ruby
duckpuppy has quit [Ping timeout: 240 seconds]
lele has quit [Ping timeout: 240 seconds]
dopamean_ has joined #ruby
ElFerna has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Gnomethrower is now known as dogethrower
dogethrower has left #ruby ["Textual IRC Client: www.textualapp.com"]
Guest53 has joined #ruby
Mon_Ouie has joined #ruby
ElFerna has joined #ruby
blackmesa has joined #ruby
lele has joined #ruby
blackoperat has joined #ruby
inteq has joined #ruby
SylarRuby has quit [Remote host closed the connection]
sunya7a has quit [Quit: leaving]
rwilcox has joined #ruby
sunya7a has joined #ruby
* adaedra waves
* ruurd waves back
dhjondoh has joined #ruby
dorei has joined #ruby
haxrbyte_ has joined #ruby
Puck6633 has quit [Read error: Connection reset by peer]
Guest53 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Puck6633 has joined #ruby
blackmesa has quit [Ping timeout: 265 seconds]
Aswebb_ has joined #ruby
Guest53 has joined #ruby
ruurd has quit [Quit: ZZZzzz…]
ruurd has joined #ruby
arup_r has joined #ruby
mrhmouse has joined #ruby
SylarRuby has joined #ruby
duckpuppy has joined #ruby
haxrbyte has quit [Ping timeout: 244 seconds]
The_Phoenix has joined #ruby
K1MOS has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
The_Phoenix has quit [Max SendQ exceeded]
jobewan has joined #ruby
RegulationD has joined #ruby
axl_ has joined #ruby
The_Phoenix has joined #ruby
kfrz has joined #ruby
benlovell has joined #ruby
SylarRuby has quit [Ping timeout: 256 seconds]
roxtrongo has joined #ruby
duckpuppy has quit [Ping timeout: 268 seconds]
Guest53 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
RegulationD has quit [Ping timeout: 240 seconds]
Igorshp has quit [Remote host closed the connection]
Fire-Dragon-DoL has joined #ruby
teclator has quit [Ping timeout: 250 seconds]
benlovell has quit [Ping timeout: 240 seconds]
devoldmx has joined #ruby
cyle has joined #ruby
rshetty has joined #ruby
teclator has joined #ruby
startupality has joined #ruby
Igorshp has joined #ruby
dhjondoh has quit [Quit: dhjondoh]
pdoherty has joined #ruby
bronson has quit [Ping timeout: 246 seconds]
nemo_ has quit [Remote host closed the connection]
Guest53 has joined #ruby
lkba_ has quit [Ping timeout: 265 seconds]
devoldmx has quit [Ping timeout: 244 seconds]
niemcu has quit [Ping timeout: 264 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rikkipitt has quit [Quit: Leaving...]
banister has quit [Quit: Textual IRC Client: www.textualapp.com]
lxsameer has joined #ruby
dnomyar has joined #ruby
SylarRuby has joined #ruby
polishdub has joined #ruby
Oatmeal has quit [Quit: TTFNs!]
blackoperat has quit [Quit: Textual IRC Client: www.textualapp.com]
rippa has joined #ruby
blackoperat has joined #ruby
DrCode has joined #ruby
northfurr has joined #ruby
SylarRuby has quit [Ping timeout: 264 seconds]
djbkd has joined #ruby
dfinninger has quit [Remote host closed the connection]
arthurix has joined #ruby
elusiveother has joined #ruby
Igorshp has quit [Remote host closed the connection]
eminencehc has joined #ruby
Igorshp has joined #ruby
rodfersou is now known as rodfersou|lunch
arthurix_ has quit [Ping timeout: 260 seconds]
p0wn3d__ has joined #ruby
stardiviner has quit [Quit: Code, Sex, Just fucking world.]
moty66 has quit [Ping timeout: 265 seconds]
Igorshp has quit [Ping timeout: 246 seconds]
TPBallbag has joined #ruby
bruno- has quit [Ping timeout: 240 seconds]
eminencehc has quit [Remote host closed the connection]
pandaant has joined #ruby
tagrudev has quit [Remote host closed the connection]
nateberkopec has quit [Quit: Leaving...]
skade has quit [Quit: Computer has gone to sleep.]
aganov has quit [Remote host closed the connection]
ruurd has quit [Quit: ZZZzzz…]
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Fire-Dra_ has joined #ruby
blackoperat has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
benlovell has joined #ruby
kimegede has quit [Quit: Linkinus - http://linkinus.com]
cdg has joined #ruby
I has joined #ruby
I is now known as Guest70277
blackoperat has joined #ruby
SylarRuby has joined #ruby
cdg has quit [Remote host closed the connection]
banister has joined #ruby
cdg has joined #ruby
bmurt has joined #ruby
seitensei has quit [Remote host closed the connection]
Fire-Dragon-DoL has quit [Ping timeout: 256 seconds]
bmurt has quit [Client Quit]
Guest70277 has quit [Client Quit]
niemcu has joined #ruby
blackoperat has quit [Client Quit]
SylarRuby has quit [Ping timeout: 272 seconds]
davedev2_ has joined #ruby
slawrence00 has joined #ruby
Rickmasta has joined #ruby
mary5030 has joined #ruby
blackoperat has joined #ruby
benlovell has quit [Ping timeout: 250 seconds]
bmurt has joined #ruby
paulcsmith has joined #ruby
paulcsmith has quit [Remote host closed the connection]
kobain has joined #ruby
mary5030 has quit [Remote host closed the connection]
cyle has quit [Ping timeout: 272 seconds]
mary5030 has joined #ruby
mary5030 has quit [Remote host closed the connection]
allcentury has quit [Ping timeout: 260 seconds]
mary5030 has joined #ruby
<chris2> umm
<chris2> i have code that works with ruby script < file
<chris2> but not with cat file | ruby script
<chris2> and it uses STDIN.scanf...
SylarRuby has joined #ruby
pard has joined #ruby
ruurd has joined #ruby
pard has quit [Client Quit]
blackoperat has quit [Ping timeout: 246 seconds]
Rinzlit_ has joined #ruby
dfinninger has joined #ruby
<chris2> when reading from a pipe it only catches the first match for every line
<chris2> guh
bronson has joined #ruby
eminencehc has joined #ruby
<mrhmouse> Can you paste a gist for the code, or narrow it down to a simple example?
Fire-Dra_ has quit []
<chris2> no, scanf.rb is just broken
Igorshp has joined #ruby
<chris2> seek(start_position + matched_so_far, IO::SEEK_SET)
<chris2> rescue Errno::ESPIPE
Fire-Dragon-DoL has joined #ruby
<chris2> end
bruno- has joined #ruby
pard has joined #ruby
<pard> greetin's
Rinzlit has quit [Ping timeout: 255 seconds]
symbol has joined #ruby
freerobby has quit [Quit: Leaving.]
SylarRuby has quit [Ping timeout: 252 seconds]
<pard> >> print {5=>12}
<ruboto> pard # => /tmp/execpad-d843635bac98/source-d843635bac98:2: syntax error, unexpected =>, expecting '}' ...check link for more (https://eval.in/458550)
tkuchiki has quit [Remote host closed the connection]
Wompy has joined #ruby
cdg has quit [Ping timeout: 264 seconds]
<dorei> >> print(5=>12)
<ruboto> dorei # => {5=>12}nil (https://eval.in/458553)
txtsd has left #ruby ["WeeChat 1.3"]
<pard> dorei , thanks
<dorei> >> print({5 => 12})
<ruboto> dorei # => {5=>12}nil (https://eval.in/458554)
<dorei> but you can ommit the { }
<pard> dorei , thanks
kies^ has joined #ruby
<pard> >> a = 5 => 12
<ruboto> pard # => /tmp/execpad-8bd2c9844d05/source-8bd2c9844d05:2: syntax error, unexpected =>, expecting keyword_end ...check link for more (https://eval.in/458555)
<adaedra> print { } is interpreted as a block, not a hash
HayesHimself has quit [Quit: Textual IRC Client: www.textualapp.com]
<apeiros> ?experiment pard
<ruboto> pard, Please use your local irb or pry (see ?pry) to experiment, ruboto's eval functionality is for demonstration purposes only.
cdg has joined #ruby
bmurt_ has joined #ruby
<pard> ruboto, sorry
<apeiros> alternatively, ask actual questions instead of just throwing out syntax errors
<gregf_> ?justabot
<ruboto> I'm just a bot. You don't need to address me.
<pard> apeiros, thanks
chrissonar has quit [Remote host closed the connection]
<pard> excuse me ?
<gregf_> ?justabot pard ;)
<ruboto> pard, I'm just a bot. You don't need to address me.
timonv has quit [Quit: WeeChat 1.3]
maletor has joined #ruby
SylarRuby has joined #ruby
brendan- has joined #ruby
<pard> i thought i'm dumb; but i never thought myself be _that_ stupid; i apologise
<gregf_> pard: ruboto is only a bot . anyways, no need to apologize ;)
<apeiros> gregf_: I think the apologies are deeply ingrained in pard. told them twice already :)
<gregf_> heh
jgt2 has quit [Read error: Connection reset by peer]
bmurt has quit [Ping timeout: 260 seconds]
<pard> making mistakes makes me embarassed
<apeiros> pard: *shrug*, everybody makes mistakes. it's ok.
dikaio has joined #ruby
<apeiros> that is - as long as you learn from them :)
<adaedra> if you don't make mistakes, you're not trying high enough.
<adaedra> hard*
RegulationD has joined #ruby
<gregf_> well, if you feel embarassed about learning something whilst making mistakes you wont learn anythig. that said, pry/irb wont make you feel stupid ;)
jgt2 has joined #ruby
<apeiros> adaedra: you forget the obvious alternative: or you're perfect :D
HayesHimself has joined #ruby
tkuchiki has joined #ruby
<adaedra> apeiros: I've yet to find anyone that fits in this description.
<apeiros> pard: while I generally advise for pry/irb - since you're looking for parser oddities, those tools won't cut it. they can alter how parsing happens. use ruby executable directly. e.g. with `ruby -e` or with plain `ruby` + ctrl-D
bmurt has joined #ruby
naftilos76 has joined #ruby
tkuchiki has quit [Remote host closed the connection]
<apeiros> adaedra: damn.
<adaedra> Also, perfection must be soooo boring.
<pard> even though i take great effort not to; i guess iim under some kind of Dunning–Kruger effect
moty66 has joined #ruby
SylarRuby has quit [Ping timeout: 260 seconds]
bmurt_ has quit [Ping timeout: 260 seconds]
mrhmouse has left #ruby ["WeeChat 1.3"]
codecop has joined #ruby
brendan- has quit [Ping timeout: 264 seconds]
<pard> apeiros, no :) i was actually trying to know what should i wrap a hash in , as i could not get to print it with mere {'s
norc has quit [Ping timeout: 246 seconds]
<apeiros> ok
<apeiros> parens. it's always parens.
<pard> thank you
<apeiros> print {} is interpreted as block to print. and plain `5 => 12` within that is not valid (as you've seen from your `a = 5 => 12`
rshetty has quit [Ping timeout: 250 seconds]
bruno- has quit [Ping timeout: 250 seconds]
Macaveli has joined #ruby
<pard> yes; i guess i have much practice before me before my mind becomes as flexible as ruby is
<gregf_> pard: out of curiosity, is ruby the first language you;re learning?
SylarRuby has joined #ruby
towski_ has joined #ruby
wldcordeiro has quit [Ping timeout: 265 seconds]
<pard> gregf_, in a sense yes; i've been doing SysC and VHDL for quite some time,but i have been told they are not much of a prog lang in common sense actually
allcentury has joined #ruby
dfinninger has quit [Remote host closed the connection]
benlovell has joined #ruby
<canton7> the mindset is quite different :P
<pard> yes :\
<gregf_> pard: er, ok. never heard much of that. sorry. no. is 'C' the base language in them?
* pard embitters
<canton7> they're hardware description langauges. they describe hardware, which is operating entirely in parallel, rather than sequential software
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<kfrz> Where can I find some benchmarks on raw speed js vs ruby
howdoi has quit [Quit: Connection closed for inactivity]
SylarRuby has quit [Ping timeout: 252 seconds]
<havenwood> kfrz: Speed doing what?
HayesHimself has quit [Quit: Textual IRC Client: www.textualapp.com]
<kfrz> sorry, I mean, general benchmarks for general algorithms
<kfrz> if it exists
<havenwood> kfrz: There are many, many benchmarks of various things.
<kfrz> That
<pard> gregf_, if their output has an actualisation , then their run and make it ; if it does not then it's an err; much of the otherwise valid code in them is consider'd erroneous only because it doesn't have a real-world equivalent
freerobby has joined #ruby
<pard> *they
<kfrz> Fair, fair
jgt2 has quit [Quit: WeeChat 1.2]
<kfrz> I'm just learning so curious
Wompy has quit [Quit: Leaving...]
towski_ has quit [Remote host closed the connection]
freerobby has quit [Client Quit]
<gregf_> pard: VHDL does look like a prog language. its got keywords, constructs etc etc. tho' no braces.. ;)
Guest53 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
skade has joined #ruby
<gregf_> anyways, good luck
<gregf_> with ruby i meant :)
<pard> thanks :)
SylarRuby has joined #ruby
skweek has quit [Ping timeout: 272 seconds]
brendan- has joined #ruby
<pard> is there any style guide for ruby out there ?
rshetty has joined #ruby
<havenwood> kfrz: If you're looking for speed with something Ruby-like try Crystal. You'll see it performs quite well on those benchmarks. http://crystal-lang.org
<havenwood> pard: Yeah, there are a few.
kerunaru has joined #ruby
<pard> i would be very thankful in case sb knows of one; it would also be great if i could also be guided to some sort of comprehnive chaethseet
mollusk_ has quit [Ping timeout: 250 seconds]
<pard> thanks , could i ask you where it is ?
ziprar has quit [Changing host]
ziprar has joined #ruby
<canton7> gregf, it looks like a programming langauge, but if you go into it with the sequential mindset you'll get very messed up :P
<havenwood> ?quickref pard
troulouliou_div2 has joined #ruby
<pard> thanks a lot
l_tonz has joined #ruby
<pard> canton7, well-said :)
SylarRuby has quit [Ping timeout: 260 seconds]
brendan- has quit [Client Quit]
elusiveother has quit [Quit: must go]
Lucky__ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
skade has quit [Ping timeout: 246 seconds]
diegoaguilar has joined #ruby
ivanskie has joined #ruby
willardg has joined #ruby
l_tonz has quit [Remote host closed the connection]
krz has joined #ruby
weihan_ has quit [Ping timeout: 255 seconds]
ivanskie has quit [Client Quit]
Guest53 has joined #ruby
skade has joined #ruby
ivanskie has joined #ruby
jessemcgilallen has joined #ruby
SylarRuby has joined #ruby
tlarevo has joined #ruby
Voker57 has quit [Read error: Connection reset by peer]
Mon_Ouie has quit [Ping timeout: 244 seconds]
willardg has quit [Client Quit]
duckpuppy has joined #ruby
dc has joined #ruby
ruurd has quit [Quit: ZZZzzz…]
wldcordeiro has joined #ruby
jessemcgilallen has quit [Client Quit]
SylarRuby has quit [Ping timeout: 250 seconds]
cyle has joined #ruby
ElFerna has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
umgrosscol has quit [Remote host closed the connection]
duckpuppy has quit [Ping timeout: 246 seconds]
dc has quit [Ping timeout: 255 seconds]
Motoservo has joined #ruby
eminencehc has quit [Remote host closed the connection]
lkba has joined #ruby
ruurd has joined #ruby
dionysus69 has quit [Ping timeout: 250 seconds]
`tim` has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
mattwashere has joined #ruby
pard has quit [Quit: Leaving]
_blizzy_ has quit [Ping timeout: 240 seconds]
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
troyready has joined #ruby
<kfrz> havenwood: very interesting.... I like Ruby over JS because of the community, open-nature of everything and multiple paths to success
yardenbar has quit [Ping timeout: 268 seconds]
<kfrz> so these ruby sub-languages are very very interesting to dig through
tak1n has quit [Remote host closed the connection]
purplexed^ has joined #ruby
polishdub has quit [Quit: Leaving]
brendan- has joined #ruby
_blizzy_ has joined #ruby
karapetyan has joined #ruby
wldcordeiro has quit [Quit: WeeChat 1.3]
wldcordeiro has joined #ruby
<purplexed^> Hi all. I'm trying to figure out how to run Dir.mkdir_p '/usr/share/<somedirectory> with Rubymine. I can see I don't have the necessary priviledges. I've tried to google for a solution, but I havent found anything I can use. Should I be running Rubymine with some other credentials, other then the one I am logged in with. Just like I would need to do if I ran the program on a machine ? ... and can someone perhaps help me find out how to do that
`tim` has joined #ruby
<adaedra> wut
<adaedra> do you mean in your ruby script executed by rubymine?
<adaedra> /usr/share is usally owned by root, so you need to be root to write in it
karapetyan has quit [Remote host closed the connection]
<adaedra> (but don't run RubyMine as root as a workaround, plese)
<adaedra> please*
mrtomme has quit [Ping timeout: 260 seconds]
solars has quit [Ping timeout: 268 seconds]
<purplexed^> No, I don't plan on doing that :)
bricker has joined #ruby
karapetyan has joined #ruby
mrtomme has joined #ruby
karapetyan has quit [Remote host closed the connection]
blackmesa has joined #ruby
amclain has joined #ruby
karapetyan has joined #ruby
<purplexed^> so, let's say I have one ruby program, that will generate some directory for use in another ruby program. Where is a good place to store that then ?
arthurix_ has joined #ruby
aspiers has joined #ruby
<adaedra> depends.
<adaedra> you may want to give more information.
towski_ has joined #ruby
lapide_viridi has joined #ruby
NeverDie has quit [Quit: http://radiux.io/ -> Manhattan Project]
baroquebobcat has joined #ruby
shinenelson has quit [Quit: Connection closed for inactivity]
rbowlby has joined #ruby
lkba has quit [Remote host closed the connection]
<purplexed^> I have an application 'Agent' and another application 'Scheduler'. The Agent will receieve files, that the 'Scheduler' will then load as configuration. So it's a suite of applications
<purplexed^> what could a good structure look like ?
[Butch] has joined #ruby
<adaedra> You could run them both from a directory that will be the directory where they save things
duckpuppy has joined #ruby
<adaedra> How long is this data supposed to stay?
chthon has quit [Ping timeout: 244 seconds]
<purplexed^> so I could have say: /projectFolder/Agent, /projectFolder/Scheduler/, /projectFolder/configurations
arthurix has quit [Ping timeout: 250 seconds]
<purplexed^> indefinitely
The_Phoenix has quit [Quit: Leaving.]
Asher1 has joined #ruby
bmurt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
lkba has joined #ruby
<purplexed^> I'm very bad at linux still, so excuse my ignorance :)
<adaedra> So yeah, let them have a common working directory, maybe configured in a config file or a cli switch
kerunaru has joined #ruby
<adaedra> or by running them from this directory
Asher has quit [Read error: No route to host]
Asher1 is now known as Asher
_blizzy_ has quit [Ping timeout: 268 seconds]
chthon has joined #ruby
<purplexed^> so, /projectFolder/Agent.rb, projectFolder/Scheduler.rb .. and otherwise the structure above ?
<adaedra> you can also create a folder in your system at a fixed location with correct rights (to be done before manually) if you want
roxtrongo has quit [Remote host closed the connection]
Voker57 has joined #ruby
<adaedra> usually, data directories are in /var i think
<purplexed^> okay, lemme just read up on /var thanks
baroquebobcat has quit [Quit: baroquebobcat]
dionysus69 has joined #ruby
<purplexed^> oh, that's a great resource, cheers
baweaver has joined #ruby
terlar has quit [Ping timeout: 255 seconds]
<purplexed^> I guess it's really a temp location I need, and I want the scheduler to pick it up, and take it to it's own location
<purplexed^> so I'll try and find something suitable for that
<purplexed^> it's a zip file you see
<adaedra> If it's temporary and does not need to stick across reboots, /tmp is the place
rodfersou|lunch is now known as rodfersou
<adaedra> also, /tmp is usually writable by anyone, so no need to bother about permissions
<purplexed^> it looks like tmp is a bit unstable... so let's say i receive a file, put it in temp, it could potentially be deleted before the scheduler gets it. Eventhough the scheduler is triggered right away.. it's a small window though :)
<purplexed^> maybe it's fine for now
Bloomer has joined #ruby
startupality has quit [Quit: startupality]
<purplexed^> I can always fix it later
The_Phoenix has joined #ruby
willardg has joined #ruby
<purplexed^> thanks alot
northfurr has quit [Quit: northfurr]
Eiam has joined #ruby
The_Phoenix has quit [Client Quit]
dionysus69 has quit [Remote host closed the connection]
eminencehc has joined #ruby
dfockler has joined #ruby
dionysus69 has joined #ruby
mary5030 has quit [Remote host closed the connection]
ruurd has quit [Quit: ZZZzzz…]
Pupp3tm4st3r has quit [Remote host closed the connection]
mary5030 has joined #ruby
eminencehc has quit [Remote host closed the connection]
bruno- has joined #ruby
<purplexed^> Another quick question. If I have 'Agent' running and 'Scheduler' running. And I want 'Agent' to trigger some operation like 'update_configuration' in the 'Scheduler' application. Is "pipes" the normal way to do that.. it seems there are pipes and sockets
roxtrongo has joined #ruby
axisys has quit [Remote host closed the connection]
<apeiros> purplexed^: within the same process?
symbol has quit [Quit: WeeChat 1.1]
<purplexed^> no, it's two separate processes
trautwein has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
chipotle has joined #ruby
<apeiros> I think pipes are only useful if you fork. not sure though.
<purplexed^> okay, well, i have a few sources to read about it :)
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
ruurd has joined #ruby
NeverDie has joined #ruby
bruno- has quit [Ping timeout: 250 seconds]
sharkman has joined #ruby
<sharkman> test
<purplexed^> pong
sdothum has joined #ruby
<mg^> Assertion failed
ivanskie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<sharkman> lol
blackoperat has joined #ruby
`based_pdev` has quit [Read error: Connection reset by peer]
tlarevo has quit [Remote host closed the connection]
maletor has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
<apeiros> sharkman: you know, something like "hello everybody" is much less annoying than "test".
<purplexed^> adaedra: works great with /tmp :)
<sharkman> k sorry
<adaedra> apeiros: named pipes!
SCHAAP137 has quit [Remote host closed the connection]
<adaedra> purplexed^, too
<purplexed^> named pipes... noted.
TomyWork has quit [Ping timeout: 260 seconds]
nertzy has joined #ruby
devoldmx has joined #ruby
aspiers has quit [Ping timeout: 264 seconds]
eminencehc has joined #ruby
based_pdev has joined #ruby
ivanskie has joined #ruby
rshetty has quit [Ping timeout: 240 seconds]
beauby has joined #ruby
lapide_viridi has quit [Quit: Leaving]
purplexed^ is now known as purplexed-
ruurd has quit [Quit: ZZZzzz…]
arthurix has joined #ruby
devoldmx has quit [Ping timeout: 264 seconds]
shinnya has joined #ruby
Macaveli has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
roxtrongo has quit [Remote host closed the connection]
baweaver has quit [Remote host closed the connection]
Macaveli has joined #ruby
to_json has joined #ruby
CorySimmons has joined #ruby
arthurix_ has quit [Ping timeout: 272 seconds]
purplexed- has left #ruby [#ruby]
willardg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
akkad has joined #ruby
rshetty has joined #ruby
Aswebb_ has quit []
baweaver has joined #ruby
maletor has joined #ruby
Macaveli has quit [Client Quit]
snockerton has joined #ruby
baweaver has quit [Remote host closed the connection]
bruno- has joined #ruby
purplexed-^ has joined #ruby
tlarevo has joined #ruby
marr has quit [Ping timeout: 268 seconds]
flak has joined #ruby
lkba_ has joined #ruby
skweek has joined #ruby
purplexed-^ has quit [Client Quit]
purplexed-^ has joined #ruby
marr has joined #ruby
roxtrongo has joined #ruby
rippa has quit [Ping timeout: 255 seconds]
lkba has quit [Ping timeout: 246 seconds]
poguez_ has joined #ruby
chipotle has quit [Quit: cheerio]
tjohnson has joined #ruby
Soda has joined #ruby
marr has quit [Killed (sinisalo.freenode.net (Nickname regained by services))]
freerobby has joined #ruby
freerobby has quit [Client Quit]
marr has joined #ruby
purplexed-^ has quit [Client Quit]
purplexed-^ has joined #ruby
maxz has joined #ruby
arthurix has quit [Read error: Connection reset by peer]
arthurix has joined #ruby
purplexed-^ has quit [Client Quit]
purplexed- has joined #ruby
willardg has joined #ruby
freerobby has joined #ruby
fbidu has joined #ruby
chipotle has joined #ruby
failshell has joined #ruby
purplexed- has quit [Changing host]
purplexed- has joined #ruby
ibouvousaime_ has joined #ruby
ibouvousaime has quit [Ping timeout: 240 seconds]
bricker has quit [Quit: leaving]
ibouvousaime_ has quit [Max SendQ exceeded]
purplexed- has quit [Client Quit]
purplexed- has joined #ruby
purplexed- has quit [Changing host]
purplexed- has joined #ruby
ibouvousaime_ has joined #ruby
towski_ has quit [Remote host closed the connection]
chipotle has quit [Client Quit]
subscope has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
bruno-_ has joined #ruby
joonty has quit [Quit: joonty]
The_Phoenix has joined #ruby
The_Phoenix has quit [Client Quit]
polishdub has joined #ruby
kp666 has joined #ruby
_djbkd has joined #ruby
dfinninger has joined #ruby
bruno- has quit [Ping timeout: 255 seconds]
shlomo has quit [Quit: WeeChat 1.3]
northfurr has joined #ruby
Icey has quit [Ping timeout: 244 seconds]
Icey has joined #ruby
rakm has joined #ruby
benlovell has quit [Ping timeout: 250 seconds]
nertzy has quit [Quit: This computer has gone to sleep]
senayar has quit []
pandaant has quit [Quit: Lost terminal]
bricker has joined #ruby
bonemind has quit [Quit: WeeChat 1.0]
SCHAAP137 has joined #ruby
blackoperat has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
symm- has joined #ruby
baweaver has joined #ruby
towski_ has joined #ruby
shinenelson has joined #ruby
nemo_ has joined #ruby
Guest53 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
chipotle has joined #ruby
nemo_ has quit [Read error: Connection reset by peer]
agit0 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
teclator_ has joined #ruby
RegulationD has quit [Remote host closed the connection]
krz has quit [Quit: WeeChat 1.2]
teclator has quit [Read error: Connection reset by peer]
agit0 has joined #ruby
agit0 has quit [Client Quit]
TPBallbag has quit [Remote host closed the connection]
nemo_ has joined #ruby
Peg-leg has quit [Quit: Leaving.]
RegulationD has joined #ruby
Klumben has quit [Ping timeout: 246 seconds]
johnhamelink has quit [Ping timeout: 240 seconds]
Pupp3tm4st3r has joined #ruby
blackoperat has joined #ruby
blue_deref has joined #ruby
Junaos_ has quit [Ping timeout: 250 seconds]
DoubleMalt has quit [Remote host closed the connection]
towski_ has quit [Remote host closed the connection]
shredding has quit [Ping timeout: 240 seconds]
Junaos has joined #ruby
to_json has quit [Quit: Leaving.]
Klumben has joined #ruby
johnhamelink has joined #ruby
devoldmx has joined #ruby
CorySimmons has quit [Quit: Bye!]
iateadonut has quit [Quit: Leaving.]
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
RegulationD has quit [Ping timeout: 260 seconds]
iateadonut has joined #ruby
postmodern has joined #ruby
axl__ has joined #ruby
dnomyar has quit [Ping timeout: 240 seconds]
axl_ has quit [Ping timeout: 268 seconds]
axl__ is now known as axl_
skade has quit [Ping timeout: 256 seconds]
Pupp3tm4st3r has quit [Remote host closed the connection]
marr has quit []
NeverDie_ has joined #ruby
leafybas_ has joined #ruby
leafybas_ has quit [Remote host closed the connection]
to_json has joined #ruby
to_json has joined #ruby
leafybas_ has joined #ruby
NeverDie_ has quit [Max SendQ exceeded]
NeverDie has quit [Ping timeout: 272 seconds]
alexdunne has quit [Ping timeout: 255 seconds]
Pumukel has quit [Ping timeout: 246 seconds]
darkf has quit [Quit: Leaving]
leafybasil has quit [Ping timeout: 268 seconds]
NeverDie has joined #ruby
stan has quit [Ping timeout: 255 seconds]
kobain has quit [Ping timeout: 252 seconds]
leafybas_ has quit [Ping timeout: 264 seconds]
h99h9h88 has joined #ruby
mikecmpbll has quit [Quit: i've nodded off.]
beauby has quit [Ping timeout: 264 seconds]
hiyosi has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
kobain has joined #ruby
_djbkd has quit [Quit: My people need me...]
NeverDie has quit [Max SendQ exceeded]
choke has quit [Quit: Textual IRC Client: www.textualapp.com]
h99h9h88 has quit [Ping timeout: 250 seconds]
NeverDie has joined #ruby
failshell has quit [Remote host closed the connection]
err_ok has quit [Ping timeout: 256 seconds]
kobain has quit [Max SendQ exceeded]
failshell has joined #ruby
Oatmeal has joined #ruby
skweek has quit [Ping timeout: 246 seconds]
Contigi777 has quit [Ping timeout: 256 seconds]
err_ok has joined #ruby
marr has joined #ruby
akem has joined #ruby
failshell has quit [Remote host closed the connection]
failshell has joined #ruby
blackmesa has quit [Ping timeout: 268 seconds]
kerunaru has joined #ruby
yardenbar has joined #ruby
shadoi has joined #ruby
beauby has joined #ruby
sankaber has quit [Remote host closed the connection]
failshell has quit [Client Quit]
sankaber has joined #ruby
UtkarshRay has quit [Quit: Leaving]
pocketprotector- has joined #ruby
RegulationD has joined #ruby
podman has joined #ruby
nateberkopec has joined #ruby
beauby has quit [Ping timeout: 250 seconds]
_aeris_ has quit [Remote host closed the connection]
_aeris_ has joined #ruby
aclearman037 has joined #ruby
aclearman037 has quit [Client Quit]
karapetyan has quit [Remote host closed the connection]
FernandoBasso has joined #ruby
duckpupp1 has joined #ruby
karapetyan has joined #ruby
cyle has quit [Ping timeout: 265 seconds]
ElFerna has joined #ruby
baweaver has quit [Remote host closed the connection]
seitensei has joined #ruby
n008f4g_ has joined #ruby
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
duckpuppy has quit [Ping timeout: 240 seconds]
Hounddog has quit [Remote host closed the connection]
eminencehc has quit [Remote host closed the connection]
karapetyan has quit [Ping timeout: 265 seconds]
mattwashere has quit [Remote host closed the connection]
beauby has joined #ruby
dmolina has quit [Quit: Leaving.]
leafybasil has joined #ruby
troulouliou_div2 has quit [Read error: Connection reset by peer]
nertzy has joined #ruby
roxtrongo has quit [Remote host closed the connection]
dnomyar has joined #ruby
niemcu has quit [Ping timeout: 260 seconds]
SenpaiSilver has quit [Quit: Leaving]
K1MOS has joined #ruby
yfeldblum has quit [Ping timeout: 240 seconds]
mikecmpbll has joined #ruby
_blizzy_ has joined #ruby
leafybasil has quit [Remote host closed the connection]
_djbkd has joined #ruby
towski_ has joined #ruby
Bloomer has quit [Remote host closed the connection]
Y_Ichiro has quit [Remote host closed the connection]
Y_Ichiro has joined #ruby
Y_Ichiro has quit [Changing host]
Y_Ichiro has joined #ruby
Guest53 has joined #ruby
Bloomer has joined #ruby
konr has joined #ruby
Cyther has joined #ruby
ahegyi has joined #ruby
chipotle has quit [Quit: cheerio]
baweaver has joined #ruby
LoganG has quit [Quit: robots are cool]
SenpaiSilver has joined #ruby
LoganG has joined #ruby
jxl180 has quit [Quit: ChatZilla 0.9.92 [Firefox 41.0.2/20151015125802]]
dionysus69 has quit [Remote host closed the connection]
roxtrongo has joined #ruby
Igorshp has quit [Remote host closed the connection]
Macaveli has joined #ruby
Macaveli has quit [Max SendQ exceeded]
leafybasil has joined #ruby
Macaveli has joined #ruby
druonysus has joined #ruby
skade has joined #ruby
ruurd has joined #ruby
Igorshp has joined #ruby
eminencehc has joined #ruby
Igorshp has quit [Remote host closed the connection]
wlch has joined #ruby
arup_r has quit [Ping timeout: 272 seconds]
blackmesa has joined #ruby
roxtrongo has quit [Remote host closed the connection]
chthon has quit [Ping timeout: 244 seconds]
rgb-one has joined #ruby
<rgb-one> Hello
<rgb-one> Can the key of a hash be referenced like this hashname.key
<rgb-one> ?
<rgb-one> that will return the value I would think
arup_r has joined #ruby
<rgb-one> do I have to do hashname[:key]?
Channel6 has joined #ruby
arooni has joined #ruby
arooni has quit [Max SendQ exceeded]
arooni has joined #ruby
nertzy has quit [Quit: This computer has gone to sleep]
platzhirsch has left #ruby [#ruby]
TPBallbag has joined #ruby
Icey has quit [Quit: Leaving]
<adaedra> A hash has multiple keys
<adaedra> What do you want to do, get key(s) for a given value?
<rgb-one> adaedra: Can have multipe keys
Icey has joined #ruby
<rgb-one> adaedra: I am just wondering about syntax
<adaedra> To get what, the keys of a hash?
<rgb-one> is hash_name.key the same as hash[:key]?
alexdunne has joined #ruby
<adaedra> No
<rgb-one> adaedra: That will return the value assigned to the key
cdg has quit [Remote host closed the connection]
<adaedra> &ri Hash#key
<adaedra> This is not javascript, doing .xxx is not the same as [:xxx]
Ox0dea has joined #ruby
Pupeno has quit [Remote host closed the connection]
<adaedra> .key is calling the method #key on the hash (and is an error, as it expects an argument)
<Ox0dea> rgb-one: What you (think you) want is an OpenStruct.
<Ox0dea> >> require 'ostruct'; foo = OpenStruct.new(bar: 42); [foo.bar, foo[:bar], foo['bar']]
<ruboto> Ox0dea # => [42, 42, 42] (https://eval.in/458683)
TPBallbag has quit [Client Quit]
<Ox0dea> rgb-one: Please be advised that programming != typing.
<rgb-one> Ox0dea: Yea, important thing to note.
<rgb-one> Ox0dea: So OpenStruct is similar to stucts in C right?
<adaedra> No
<adaedra> That would be Struct
quaj has quit [Ping timeout: 244 seconds]
alexdunne has quit [Ping timeout: 240 seconds]
<rgb-one> adaedra: What does OpenStruct do?
<adaedra> OpenStruct is closer to JS objects, I think (if we try not to be too picky)
<Ox0dea> rgb-one: OpenStruct takes a Hash and gives you too many accessors into it.
mordocai has joined #ruby
<Ox0dea> `bar: 42` is actually a Hash in the example I provided.
<eam> they're both kinda the same yeah?
ht__ has joined #ruby
<adaedra> eam: which ones?
startupality has joined #ruby
<eam> all of the above, conceptually
<eam> accessing a set of value by names
treehug88 has quit [Quit: Textual IRC Client: www.textualapp.com]
<rgb-one> Ox0dea: So it allows for accessing a value in multiple ways?
<Ox0dea> >> require 'ostruct'; foo = OpenStruct.new(bar: 42); [foo.bar, foo[:bar], foo['bar']] # rgb-one
<ruboto> Ox0dea # => [42, 42, 42] (https://eval.in/458684)
daffy_duck_2 has quit [Quit: Leaving]
fbidu has quit [Ping timeout: 250 seconds]
<Ox0dea> >> require 'ostruct'; obj = OpenStruct.new; obj.prop = :val; obj['prop']
<ruboto> Ox0dea # => :val (https://eval.in/458685)
<Ox0dea> They are indeed extremely similar to JavaScript Objects.
h99h9h88 has joined #ruby
h99h9h88 has quit [Remote host closed the connection]
dc has joined #ruby
<rgb-one> Ox0dea: It allows for writing to and reading from values in a hash. Being that you mentioned accessors, I figure that it allows for read write operations of values to the keys of a hash. Is that the case?
h99h9h88 has joined #ruby
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
<rgb-one> reading from keys in a hash*
CanTonic has joined #ruby
<adaedra> rgb-one: yes, it wraps the hash and add new ways to read an write data in it.
PaulCapestany has quit [Quit: .]
<rgb-one> adaedra: I see.
<adaedra> But they in fact have very little added value compared to a traditional hash.
ruurd has quit [Quit: ZZZzzz…]
<Ox0dea> >> require 'ostruct'; s = OpenStruct.new foo: 1; s.bar = 2; s.instance_variable_get :@table # rgb-one
<ruboto> Ox0dea # => {:foo=>1, :bar=>2} (https://eval.in/458689)
baweaver has quit [Remote host closed the connection]
h99h9h88 has quit [Remote host closed the connection]
<Ox0dea> Your computational resources are better spent elsewhere, in my opinion.
PaulCapestany has joined #ruby
h99h9h88 has joined #ruby
to_json has quit [Quit: Leaving.]
tmtwd has joined #ruby
ruby-lang242 has joined #ruby
_djbkd has quit [Quit: My people need me...]
ivanskie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ruby-lang242 has quit [Client Quit]
FernandoBasso has quit [Quit: Leaving]
Knifelessness has joined #ruby
willardg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ht__ has quit [Quit: Konversation terminated!]
kerunaru has joined #ruby
ht__ has joined #ruby
synthroid has quit [Remote host closed the connection]
fbidu has joined #ruby
<rgb-one> Im using OptionParser in this application. At the bottom I attempt to use the hash_name.key syntax however it doesn't work.
<rgb-one> I understand that I can't reference a value of a key that way
h99h9h88 has quit [Ping timeout: 265 seconds]
<rgb-one> And in order to use such a syntax, OpenStruct is required
<adaedra> what is wrong with hash[key] ?
seitensei has quit [Remote host closed the connection]
<Ox0dea> It's too obviously correct.
_djbkd has joined #ruby
<dorei> hash.key is less chars than hash[key] :p
<Ox0dea> *fewer
<dorei> fewer :)
eminencehc has quit [Remote host closed the connection]
to_json has joined #ruby
to_json has joined #ruby
kadoppe has quit [Ping timeout: 268 seconds]
fbidu has quit [Max SendQ exceeded]
<rgb-one> Alright, it has been updated
snockerton has quit [Quit: Leaving.]
opensource_ninja has joined #ruby
iateadonut has quit [Quit: Leaving.]
nemo__ has joined #ruby
kadoppe has joined #ruby
<Ox0dea> rgb-one: You missed one.
Bloomer has quit [Remote host closed the connection]
quaj has joined #ruby
nemo_ has quit [Ping timeout: 240 seconds]
Channel6 has quit [Ping timeout: 268 seconds]
<rgb-one> Sorted.
akem has quit [Quit: Bye]
tlarevo has quit [Read error: Connection reset by peer]
tlarevo has joined #ruby
tlarevo has quit [Read error: Connection reset by peer]
jessemcgilallen has joined #ruby
bruno-_ has quit [Ping timeout: 255 seconds]
snockerton has joined #ruby
DEA7TH has joined #ruby
cyle has joined #ruby
snockerton has quit [Client Quit]
sobering has joined #ruby
sobering has left #ruby [#ruby]
nemo__ has quit [Read error: Connection reset by peer]
ahegyi has quit [Ping timeout: 240 seconds]
nemo_ has joined #ruby
K1MOS has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
snockerton has joined #ruby
chipotle has joined #ruby
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
bruno- has joined #ruby
nemo_ has quit [Read error: Connection reset by peer]
h99h9h88 has joined #ruby
AccordLTN has quit []
jordanloky has quit [Ping timeout: 260 seconds]
fbidu has joined #ruby
tobyx_ has quit [Remote host closed the connection]
nemo_ has joined #ruby
flak has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
tobyx has joined #ruby
rippa has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
segfalt_ has joined #ruby
Guest7778 is now known as ZeeNoodleyGamer
synthroid has joined #ruby
ZeeNoodleyGamer is now known as Iota-Spencer
beauby has quit [Ping timeout: 240 seconds]
centrx has joined #ruby
nemo_ has quit [Read error: Connection reset by peer]
Macaveli has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sepp2k has quit [Quit: Leaving.]
segfalt has quit [Ping timeout: 255 seconds]
segfalt_ is now known as segfalt
sankaber has quit [Remote host closed the connection]
nemo_ has joined #ruby
linocisco has joined #ruby
sankaber has joined #ruby
<linocisco> hi all , is there any asterisk users who is using ruby to interface with asterisk to create powerful Telephony solutions?
blackmesa has quit [Ping timeout: 260 seconds]
<danneu> rofl
<crankharder> is there a file that 'bundle exec' will load automatically?
nemo_ has quit [Read error: Connection reset by peer]
TheHodge has quit [Quit: Connection closed for inactivity]
<crankharder> er, not bundle exec... 'bundle console'
maletor has joined #ruby
<crankharder> and, not my ~/.irbrc -- looking for something local to the project
teclator_ has quit [Quit: leaving]
_djbkd has quit [Quit: My people need me...]
nemo_ has joined #ruby
ht__ has quit [Quit: Konversation terminated!]
diegoaguilar has quit [Ping timeout: 255 seconds]
ht__ has joined #ruby
yfeldblum has joined #ruby
koos303 has quit [Quit: Connection closed for inactivity]
roxtrongo has joined #ruby
dnomyar has quit [Ping timeout: 264 seconds]
ngscheurich has joined #ruby
shadoi has quit [Quit: Leaving.]
musl has quit [Quit: WeeChat 1.1.1]
nemo_ has quit [Read error: Connection reset by peer]
musl has joined #ruby
NeverDie has quit [Quit: http://radiux.io/ -> Manhattan Project]
Juanchito has quit [Quit: Connection closed for inactivity]
nemo_ has joined #ruby
SylarRuby has joined #ruby
NeverDie has joined #ruby
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
linocisco has quit [Quit: Leaving]
h99h9h88 has quit [Remote host closed the connection]
finisherr has joined #ruby
_djbkd has joined #ruby
h99h9h88 has joined #ruby
dc has quit [Remote host closed the connection]
rgb-one has quit [Ping timeout: 244 seconds]
preyalone has left #ruby [#ruby]
kerunaru has joined #ruby
dc has joined #ruby
dc has quit [Remote host closed the connection]
nemo_ has quit [Read error: Connection reset by peer]
jackjackdripper has joined #ruby
kerunaru has quit [Client Quit]
<Ox0dea> eam: To address your analogy from earlier, it's the combination of Struct and OpenStruct that most closely resembles JS Objects; on their own, the former doesn't permit arbitrary property access, the latter doesn't (natively) have behavior.
nemo_ has joined #ruby
<Ox0dea> crankharder: Would a local bundle config not suffice for your purposes?
bMalum has quit [Quit: bMalum]
dnomyar has joined #ruby
h99h9h88 has quit [Ping timeout: 252 seconds]
al2o3-cr has quit [Ping timeout: 240 seconds]
jackjackdripper has quit [Client Quit]
maletor has quit [Quit: Computer has gone to sleep.]
jackjackdripper has joined #ruby
speakingcode has joined #ruby
alexdunne has joined #ruby
jessemcgilallen has quit [Quit: jessemcgilallen]
quaj has left #ruby ["WeeChat 0.4.2"]
zoo-zed has joined #ruby
eminencehc has joined #ruby
beauby has joined #ruby
jdawgaz has joined #ruby
diegoaguilar has joined #ruby
sankaber has quit [Remote host closed the connection]
rgb-one has joined #ruby
sankaber has joined #ruby
nemo_ has quit [Read error: Connection reset by peer]
bMalum has joined #ruby
tjohnson has quit [Quit: Connection closed for inactivity]
alexdunne has quit [Ping timeout: 256 seconds]
sl33k has joined #ruby
zoo-zed_ has joined #ruby
agent_white has quit [Read error: Connection reset by peer]
kimegede has joined #ruby
AccordLTN has joined #ruby
eminencehc has quit [Remote host closed the connection]
Knifelessness has quit [Ping timeout: 246 seconds]
jessemcgilallen has joined #ruby
nemo_ has joined #ruby
blackmesa has joined #ruby
zoo-zed_ has quit [Client Quit]
lkba_ has quit [Remote host closed the connection]
nemo_ has quit [Read error: Connection reset by peer]
agent_white has joined #ruby
VeryBewitching has joined #ruby
AccordLTN has quit [Client Quit]
juanpablo_ has joined #ruby
northfurr has quit [Quit: northfurr]
<shevy> knock knock
nemo_ has joined #ruby
stamina has quit [Ping timeout: 268 seconds]
Pupp3tm4st3r has joined #ruby
<havenwood> shevy: NameError who?
kerunaru has joined #ruby
northfurr has joined #ruby
karapetyan has joined #ruby
kerunaru has quit [Client Quit]
jordanloky has joined #ruby
nemo_ has quit [Read error: Connection reset by peer]
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
baweaver has joined #ruby
<Ox0dea> havenwood: NameError#receiver for missing constants.
<eam> that's a terrible punchline
nemo_ has joined #ruby
_djbkd has quit [Remote host closed the connection]
<havenwood> hah
zoo-zed has quit [Quit: Leaving.]
nateberkopec has quit [Quit: Leaving...]
zoo-zed has joined #ruby
nemo_ has quit [Read error: Connection reset by peer]
ruurd has joined #ruby
nateberkopec has joined #ruby
<shevy> +#define undef_mesg_for(v, k) rb_fstring_cstr("undefined"v" method `%1$s' for "k" `%$s'")
nemo_ has joined #ruby
nemo_ has quit [Read error: Connection reset by peer]
jordanloky has quit [Ping timeout: 255 seconds]
Guest53 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<shevy> C is not very pretty :(
zoo-zed has joined #ruby
zoo-zed has quit [Client Quit]
baweaver has quit [Ping timeout: 250 seconds]
zoo-zed has joined #ruby
northfurr has quit [Quit: northfurr]
nemo_ has joined #ruby
ruurd has quit [Read error: Connection reset by peer]
<shevy> this makes me sad
zoo-zed has quit [Client Quit]
tmtwd has quit [Ping timeout: 268 seconds]
northfurr has joined #ruby
zoo-zed has joined #ruby
<eam> shevy: to be fair that's cpp
<shevy> ah
<shevy> well same ugly heritage!
beauby has quit [Ping timeout: 240 seconds]
<eam> c macros are revolting
<shevy> yeah
zoo-zed has quit [Client Quit]
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
ngscheurich has quit [Ping timeout: 252 seconds]
<shevy> havenwood get ready for http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html - in a few days the november update will be out... will ruby fall out of top 20 all of a sudden?
nemo_ has quit [Read error: Connection reset by peer]
<shevy> ack
<shevy> #define cube( x ) ( ( x ) * ( x ) * ( x ) )
<shevy> LISP!!!
<havenwood> shevy: (\/)!_!(\/)
_blizzy_ has quit [Read error: Connection reset by peer]
kimegede has quit [Quit: Leaving...]
nemo_ has joined #ruby
_blizzy_ has joined #ruby
<eam> did ruby ever support -P ?
<shevy> what is -P doing again?
<Ox0dea> havenwood: Does my nerd sniper need recalibrated, then?
<eam> runs the source code through cpp before ruby reads it
mollusk_ has joined #ruby
<eam> so you can use C macros in ruby
<shevy> ack
dc has joined #ruby
<shevy> hanmac would have found out
m8 has joined #ruby
rgb-one has quit [Read error: Connection reset by peer]
<havenwood> Ox0dea: hehe
kerunaru has joined #ruby
elaptics`away is now known as elaptics
dasher00 has quit [Remote host closed the connection]
<Ox0dea> That block parameters can be as arbitrarily complex as method ones is kinda scary.
willardg has joined #ruby
<Ox0dea> And vim-ruby punts on it completely. :<
AccordLTN has joined #ruby
<eam> looks like no
charliesome has joined #ruby
<eam> perl removed it too :(
kimegede has joined #ruby
bricker_ has joined #ruby
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
elusiveother has joined #ruby
Guest53 has joined #ruby
<crankharder> Ox0dea: "local bundle config" ??
<Ox0dea> crankharder: You've got yourself a mighty Google-able phrase there.
nemo_ has quit [Read error: Connection reset by peer]
bricker has quit [Ping timeout: 264 seconds]
ekinmur has joined #ruby
nemo_ has joined #ruby
nemo_ has quit [Read error: Connection reset by peer]
bricker_ is now known as bricker
baweaver has joined #ruby
<havenwood> Ox0dea: Nope, your aim was true.
nemo_ has joined #ruby
axl_ has quit [Ping timeout: 252 seconds]
axl__ has joined #ruby
bweston has joined #ruby
chouhoulis has quit [Remote host closed the connection]
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
rbennacer has quit [Remote host closed the connection]
allcentury has quit [Quit: WeeChat 1.2]
karapetyan has quit [Remote host closed the connection]
rbennacer has joined #ruby
karapetyan has joined #ruby
karapetyan has quit [Remote host closed the connection]
lacrymology has joined #ruby
karapetyan has joined #ruby
<havenwood> Ox0dea: Stabby lambda to the rescue! :P
jackjackdripper has quit [Quit: Leaving.]
<havenwood> mmm
<Ox0dea> havenwood: Or grouping parens, of course.
<lacrymology> I installed an update on osx and now compass is gone, and I can't install it again (I'm getting a 'failed to build gem native extension' error)
jackjackdripper has joined #ruby
Pupeno has joined #ruby
Pupeno has joined #ruby
AnoHito_ has joined #ruby
<lacrymology> well, it's not even me, it's my girlfriend, and she's not here with me, and I'm having to instruct her online
<Ox0dea> lacrymology: The study of crying?
<lacrymology> can someone please help me
bweston92 has quit [Ping timeout: 240 seconds]
ruurd has joined #ruby
nemo_ has quit [Remote host closed the connection]
Anthony_ has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<lacrymology> Ox0dea: yes, fake philosophy invented by Tool.
<Ox0dea> > fake philosophy
<ccooke> Huh. I didn't realise that ruby was getting more popular again
<ccooke> Nice
<shevy> yeah TIOBE boosts ruby!
decoponio has quit [Quit: Leaving...]
<shevy> WE ARE WINNING THE WAR - says TIOBE
<ccooke> (Well, I'm about to go work for a company that uses ruby in their app stack
<shevy> next month we could drop +40 ranks though
<ccooke> shevy: *grin*
<eam> uh oh ruby is in the top 10? Time to stop using it in favor of something more obscure
<ccooke> it's a useful resource, as long as you don't take it as gospel
<dreinull75> Ox0dea: hi, I've been looking at your Module and I'm not sure why you chse extend. I've now tried prepend but my methods are not caught.
<shevy> TIOBE is my friend
<ccooke> eam: oh, I have a language you can use if you like. *nobody* uses it
<lacrymology> please please help installing gems on osx? I don't even know where to start. I use linux
Igorshp has joined #ruby
blackmesa has quit [Ping timeout: 268 seconds]
<shevy> gem install NAME
<Ox0dea> dreinull75: Which was that, then?
_blizzy_ has quit [Ping timeout: 240 seconds]
AnoHito has quit [Ping timeout: 240 seconds]
<ccooke> eam: Here, go write everything in this: http://granite.earth.gkhs.net/~ccooke/circuit/99_bottles_of_beer.circuit
<dreinull75> Ox0dea let me fix an eval for you...
eminencehc has joined #ruby
<havenwood> lacrymology: Have you installed Homebrew or another package manager for OS X?
eminencehc has quit [Remote host closed the connection]
<lacrymology> havenwood: no. not even knowing where to start would be part of that
<havenwood> lacrymology: Install brew with: ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
<lacrymology> I read that I should use rvm or similar, but I don't know if that means that she'll have to activate the right version every time she wants to run compass or what
<Ox0dea> ccooke: A fan of Befunge, then?
<lacrymology> havenwood: does that need to be `sudo`ed?
Vitor has joined #ruby
<havenwood> lacrymology: Nope.
<ccooke> Ox0dea: I was about fifteen years ago, when I wrote that language
<lacrymology> havenwood: okay, and afterwards?
karapetyan has quit [Remote host closed the connection]
<Ox0dea> ccooke: So you were a fan of Befunge, but not anymore?
<havenwood> lacrymology: brew install ruby-install --HEAD
<havenwood> lacrymology: brew install chruby
<havenwood> lacrymology: Follow chruby instructions ^ to add chruby.sh and auto.sh to a dotfiles that gets sourced.
<ccooke> Ox0dea: well, I'd probably pick a different model if I wanted to write an esolang today. I still like the idea, from an abstract thing of interest point of view
willardg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
baroquebobcat has joined #ruby
willardg has joined #ruby
<ccooke> Hmm. Should keep the off-topic elsewhere, shouldn't I? Oh well. It's been a long day :-)
<adaedra> ?offtopic
<ruboto> this seems to be off-topic. Please move your discussion to #ruby-offtopic, to keep this channel free for Ruby related problems. Thanks!
cdg has joined #ruby
<Ox0dea> ccooke: I looked for you in ^, for what that's worth.
stamina has joined #ruby
<lacrymology> havenwood: that's probably too much for me to explain over facebook chat
raz has joined #ruby
<lacrymology> I could write a bash script that does all that
rshetty has quit [Remote host closed the connection]
eminencehc has joined #ruby
<havenwood> lacrymology: Then just install brew and install compass with your system Ruby: sudo gem install compass
karapetyan has joined #ruby
sepp2k has joined #ruby
<lacrymology> havenwood: will installing brew add the ruby headers?
<havenwood> lacrymology: It makes build tools available.
ldnunes has quit [Quit: Leaving]
<havenwood> lacrymology: You can alternatively do that yourself without installing brew.
cdg has quit [Remote host closed the connection]
<lacrymology> I'll try with brew. Thank you
cdg has joined #ruby
<lacrymology> I'll look into the other thing too, since I'm apparently becoming a ruby dev myself from now on
<lacrymology> (that's RE: is ruby becoming a popular language again)
<havenwood> lacrymology: I should actually probably test this out but here's a spike showing how you can point chruby at brew's Ruby as an alternative or addition to ruby-install'ed rubies: https://gist.github.com/havenwood/ba31f67c1d89ac236400
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
hanmac has quit [Quit: Leaving.]
prestorium has quit [Quit: Leaving]
northfurr has quit [Quit: northfurr]
icarus has joined #ruby
sankaber has quit [Remote host closed the connection]
haxrbyte_ has quit [Read error: Connection reset by peer]
haxrbyte has joined #ruby
sankaber has joined #ruby
hanmac has joined #ruby
sankaber has quit [Remote host closed the connection]
gregoriokusowski has quit [Quit: gregoriokusowski]
<dreinull75> Ox It's not putsing anything. That's confusing.
DexterLB has quit [Read error: Connection reset by peer]
sankaber has joined #ruby
tris has quit [Read error: Connection reset by peer]
<Ox0dea> dreinull75: Well, `Message.included` isn't being invoked, for starters.
haylon has joined #ruby
chipotle has quit [Quit: cheerio]
<dreinull75> Ox0dea prepended it used to be :)
hahuang65 has joined #ruby
<Ox0dea> dreinull75: Even then, the instance methods aren't yet defined at the time you `prepend` it.
_djbkd has joined #ruby
blackmesa has joined #ruby
polishdub has quit [Quit: Leaving]
<dreinull75> yes, that's the problem. Any idea how to include them in this magic?
northfurr has joined #ruby
konr has quit [Quit: Connection closed for inactivity]
<dreinull75> because Sequel seems to add complexity to that business. I don't know when it adds its methods to the classes.
DexterLB has joined #ruby
podman has quit [Quit: Connection closed for inactivity]
but3k4 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
tris has joined #ruby
pocketprotector- has quit [Remote host closed the connection]
pocketprotector- has joined #ruby
banister has quit [Read error: Connection reset by peer]
mostlybadfly has quit [Quit: Connection closed for inactivity]
northfurr has quit [Client Quit]
Icey has quit [Quit: Leaving]
Oatmeal has quit [Ping timeout: 256 seconds]
sl33k has quit [Read error: Connection reset by peer]
<lacrymology> havenwood: after installing brew, `sudo gem install compass` is saying the following: http://dpaste.com/303VRC2
sl33k has joined #ruby
eminencehc has quit [Remote host closed the connection]
Oatmeal has joined #ruby
pmadd has joined #ruby
duckpupp1 has quit [Ping timeout: 268 seconds]
<havenwood> lacrymology: Seems to be an El Capitan thing. Try: sudo gem install -n /usr/local/bin compass
hxegon has joined #ruby
<lacrymology> havenwood: yes, I found it. And I cannot believe apple actually named that version that
<lacrymology> next version will be El Presidente and will pack with a free copy of Tropico 3
rbennacer has quit [Remote host closed the connection]
<shevy> El Presidente
<shevy> El Gato
<shevy> El Crocodilo
eminencehc has joined #ruby
<lacrymology> They're not the same
<shevy> :)
diegoviola has joined #ruby
rwilcox has quit [Ping timeout: 246 seconds]
northfurr has joined #ruby
rbennacer has joined #ruby
sl33k has quit [Ping timeout: 264 seconds]
arthurix_ has joined #ruby
ht__ has quit [Quit: Konversation terminated!]
ss_much has joined #ruby
ht__ has joined #ruby
rwilcox has joined #ruby
malconis has quit [Ping timeout: 264 seconds]
pdoherty has quit [Ping timeout: 256 seconds]
eminencehc has quit [Remote host closed the connection]
northfurr has quit [Client Quit]
cdg_ has joined #ruby
<hxegon> only took me like a week to write this https://gist.github.com/anonymous/62c6234fbe5c79c07efa
arthurix has quit [Ping timeout: 264 seconds]
ivanskie has joined #ruby
<hxegon> but now I know me some hash methods
Pupeno has quit [Remote host closed the connection]
northfurr has joined #ruby
cdg_ has quit [Remote host closed the connection]
<hxegon> hoping someone doesn't come through and drop a one liner like "Oh, why didn't you just do it like..."
bb010g has quit [Quit: Connection closed for inactivity]
cdg has quit [Ping timeout: 244 seconds]
<dreinull75> Ox0dea: https://eval.in/private/df71e62b15fe22 works
northfurr has quit [Client Quit]
baweaver has quit [Remote host closed the connection]
polishdub has joined #ruby
<pipework> hxegon: I would have used a block with default_proc and just swapped that in and out, but I'd need to see an example usage to come up with a nice refactor.
jackjackdripper has quit [Quit: Leaving.]
<hxegon> Idk what default proc is, but one sec for example usage
h99h9h88 has joined #ruby
Igorshp has quit [Remote host closed the connection]
jackjackdripper has joined #ruby
Vitor has quit [Remote host closed the connection]
karapetyan has quit [Remote host closed the connection]
codecop has quit [Remote host closed the connection]
wlch has quit [Quit: Yaaic - Yet another Android IRC client - http://www.yaaic.org]
diegoviola has quit [Ping timeout: 252 seconds]
diego3 has joined #ruby
diego3 has quit [Changing host]
diego3 has joined #ruby
diego3 is now known as diegoviola
dc has quit [Remote host closed the connection]
jgpawletko has quit [Quit: jgpawletko]
petersaints has joined #ruby
h99h9h88 has quit [Ping timeout: 252 seconds]
Pupp3tm4st3r has quit [Remote host closed the connection]
<shevy> sounds as if it can be used when setting default values for a hash
<shevy> oh that code looks non-trivial!
karapetyan has joined #ruby
rwilcox has quit [Ping timeout: 255 seconds]
nfk has joined #ruby
malconis has joined #ruby
<pipework> shevy: It's just a recursive map method that keeps recursing when values are hashes.
<hxegon> yeah
hobo548 has joined #ruby
pdoherty has joined #ruby
skade has quit [Ping timeout: 240 seconds]
<hxegon> but i still went through like 12 versions of that code
<hxegon> :(
<Ox0dea> If we're on an excursion, are we excursing?
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
skade has joined #ruby
<Ox0dea> When we write shitty code, are we incursing technical debt?
chipotle has joined #ruby
bollullera has joined #ruby
<hxegon> incursing from where though?
Igorshp has joined #ruby
<Ox0dea> "Incursing" is not a word.
polishdub has quit [Quit: Leaving]
<hxegon> it is if you believe hard enough
<adaedra> how can it be real if our eyes are not real
<adaedra> (sorry, I go back to my code)
bollullera has quit [Excess Flood]
jessemcgilallen has quit [Quit: jessemcgilallen]
syath has quit [Quit: WeeChat 1.2]
* Ox0dea goes back to a more civilized age when "recur" was the verb form of "recursion".
rwilcox has joined #ruby
maletor has joined #ruby
<pipework> Ox0dea is right, 'incurse' is only 9 bytes. A word, on my machine, is much larger than that.
kimegede has quit [Quit: Leaving...]
jessemcgilallen has joined #ruby
<adaedra> ?rimshot
<Ox0dea> hxegon: Are you intentionally supporting key mapping in your implementation of #rec_map?
<hxegon> yeah
nateberkopec has quit [Read error: Connection reset by peer]
jackjackdripper has quit [Read error: Connection reset by peer]
<Ox0dea> hxegon: It would be nice to be able to say `h.rec_map(&:succ)` to increment every value.
M-Technic has quit [Quit: leaving]
jackjackdripper has joined #ruby
M-Technic has joined #ruby
northfurr has joined #ruby
eminencehc has joined #ruby
kimegede has joined #ruby
synthroid has quit []
<hxegon> is it just yielding a single value that allows that?
kimegede has quit [Client Quit]
<hxegon> I actually had a version that did that, but figured out I needed this instead
skade has quit [Quit: Computer has gone to sleep.]
naftilos76 has quit [Quit: Αποχώρησε]
<crankharder> Ox0dea: not sure I see an available key here that says "yo, execute this file when i start bundle console" http://bundler.io/man/bundle-config.1.html
bollullera has joined #ruby
blackoperat has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
JDiPierro has quit [Remote host closed the connection]
jackjackdripper has quit [Ping timeout: 260 seconds]
<crankharder> also, fwiw, not sure I see anything in these codez that would do it: https://github.com/bundler/bundler/blob/master/lib/bundler/cli/console.rb
malconis has quit [Ping timeout: 264 seconds]
malconis has joined #ruby
<Ox0dea> crankharder: http://git.io/vWFVd
haxrbyte_ has joined #ruby
jdawgaz has joined #ruby
jackjackdripper has joined #ruby
NeverDie has quit [Quit: http://radiux.io/ -> Manhattan Project]
jdawgaz has quit [Client Quit]
roxtrongo has quit [Remote host closed the connection]
hooper has quit [Quit: Leaving.]
haxrbyte has quit [Ping timeout: 250 seconds]
rbennacer has quit [Remote host closed the connection]
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
dasher00 has joined #ruby
pmadd has quit [Read error: Connection reset by peer]
`tim` has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
northfurr has quit [Quit: northfurr]
Nanuq has quit [Ping timeout: 264 seconds]
malconis has quit [Remote host closed the connection]
sharkman has quit [Quit: Leaving]
haylon has quit [Quit: Leaving]
Pupeno has joined #ruby
<shevy> hmm now we have pcre ... and pcre2
northfurr has joined #ruby
Pupeno has quit [Remote host closed the connection]
mois3x has joined #ruby
ht__ has quit [Quit: Konversation terminated!]
ht__ has joined #ruby
SylarRuby has quit [Remote host closed the connection]
jamesaxl|2 has joined #ruby
kerunaru has joined #ruby
malconis has joined #ruby
<Ox0dea> hxegon: I'm a monster: https://eval.in/458858
northfurr has quit [Ping timeout: 260 seconds]
jackjackdripper has quit [Quit: Leaving.]
CJKinni has joined #ruby
jackjackdripper has joined #ruby
Pupeno has joined #ruby
<Ox0dea> I'd swear it used to be the case that that `(&proc)` would be superfluous, but I've gone all the way back to 1.8.7.
<hxegon> Ox0dea: thats the first time I've ever seen &proc
NeverDie has joined #ruby
<hxegon> Ox0dea: or === used in a function
<Ox0dea> Welcome to the jungle, baby.
Pupeno has quit [Remote host closed the connection]
<hxegon> am I going to die, aaaaaaaAAAAAAAAAA
cwong_on_irc has joined #ruby
cwong_on_irc has quit [Max SendQ exceeded]
cwong_on_irc has joined #ruby
<adaedra> worse, you're being moved into /dev/null.
roxtrongo has joined #ruby
<shevy> the black hole of unix
<hxegon> "../, what happens when you go to /dev/null?"
<shevy> your input will be cut off
<Ox0dea> hxegon: /dev/null isn't a directory?
<shevy> /dev/null is pure magic
<hxegon> /dev/null is a file, because unix, correct?
<Ox0dea> It's a "device".
<adaedra> WELL
<Diabolik> can anyone give me any advice as to what's wrong with this function
<pipework> Mmm device nodes
<adaedra> Diabolik: what's the failing test case? It's outside of the visible ones.
<Ox0dea> hxegon: To clarify `&proc`, creating a Proc without providing an explicit block will use the block passed to the method.
<Ox0dea> And all methods receive an implicit block.
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Diabolik> adaedra i can't see it
kfrz has quit [Quit: Leaving.]
<adaedra> Diabolik: scroll?
<Diabolik> the test cases aren't shown for submit..
<hxegon> Ox0dea: I'll have to look into it more. Just starting to get into the world of block accepting methods
Coldblackice has joined #ruby
<Diabolik> all the test cases that are given to me pass
Nanuq has joined #ruby
<Ox0dea> hxegon: https://eval.in/458859
DEA7TH has quit [Quit: DEA7TH]
<adaedra> Diabolik: also, how do your methods behave for `sum_all("hello", "world")` ?
lxsameer has quit [Quit: Leaving]
<adaedra> your method*
<Ox0dea> adaedra: The "world" isn't just one big natural number, you say?
<Ox0dea> s/natural/finite/
<adaedra> Ox0dea: oh, I'm just throwing random questions.
<Ox0dea> And I'm being facetious, but only because it's got all the vowels in order.
<Diabolik> [2] pry(main)> sum_all("hello", "world")
<Diabolik> => "helloworld"
<hxegon> Ox0dea: hmm... this raises more questions than answers for me. Whats the advantage over &block?
<adaedra> Ox0dea: and y?
<shevy> Ox0dea is the man to make simple things complex
<Ox0dea> hxegon: If nothing else, it demonstrates that you're aware of the fact that every method receives an implicit block, but explicit is usually good.
<hxegon> shevy: emergent complexity is a bitch/awesome
akem has joined #ruby
<Ox0dea> There *is* a difference between `proc.call` to invoke the implicit block and `yield`, however; the latter does not bother to create an actual Proc object; it just defers to the block it already knows about internally.
konr has joined #ruby
moeabdol has quit [Ping timeout: 250 seconds]
everbot has joined #ruby
rwilcox has quit [Ping timeout: 240 seconds]
<hxegon> Ox0dea: so does that implementation allow for {}.deep_map(&:whatever) ?
p0wn3d__ has quit [Ping timeout: 250 seconds]
<Ox0dea> hxegon: I provided an example?
<Ox0dea> ~ $ ruby -e "p ARGF.select { |w| w.delete('^aeiouy') == 'aeiouy' }" < words
<Ox0dea> ["abstemiously\n", "facetiously\n", "pareciously\n"]
<Ox0dea> adaedra: ^
<adaedra> mmmh?
<hxegon> Ox0dea: oh duh
<Ox0dea> adaedra: The ones with Y?
<adaedra> ah.
bMalum has quit [Quit: bMalum]
Owner has joined #ruby
<Owner> helo
Owner has left #ruby ["Leaving"]
Pupeno has joined #ruby
Pupeno has quit [Changing host]
Pupeno has joined #ruby
kerunaru has joined #ruby
alexdunne has joined #ruby
sepp2k1 has joined #ruby
sepp2k has quit [Ping timeout: 265 seconds]
dravine_ has joined #ruby
pocketprotector- has quit [Ping timeout: 265 seconds]
nertzy has joined #ruby
mostlybadfly has joined #ruby
Pupeno has quit [Remote host closed the connection]
jord has joined #ruby
Icey has joined #ruby
dravine has quit [Ping timeout: 264 seconds]
dravine_ is now known as dravine
alexdunne has quit [Ping timeout: 252 seconds]
ht__ has quit [Quit: Konversation terminated!]
maletor has quit [Quit: Computer has gone to sleep.]
asianMike has joined #ruby
jessemcgilallen has quit [Quit: jessemcgilallen]
baweaver has joined #ruby
gambl0re has joined #ruby
mikecmpbll has quit [Quit: ciao.]
ElFerna has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
yfeldblum has quit [Quit: Leaving...]
solocshaw has joined #ruby
mary5030 has quit [Remote host closed the connection]
elusiveother has quit [Quit: Leaving]
baweaver has quit [Ping timeout: 244 seconds]
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Icey is now known as IceyEC
baweaver has joined #ruby
northfurr has joined #ruby
xaa has quit [Ping timeout: 240 seconds]
asianMike has quit [Remote host closed the connection]
phil6kites has joined #ruby
skade has joined #ruby
ivanskie has quit [Quit: Textual IRC Client: www.textualapp.com]
IceyEC is now known as Icey
elaptics is now known as elaptics`away
dmolina has joined #ruby
Ameliaa has joined #ruby
s00pcan has quit [Ping timeout: 250 seconds]
dmolina has quit [Client Quit]
centrx has quit [Quit: "You cannot fix a machine by just power-cycling it with no understanding of what is going wrong."]
rbennacer has joined #ruby
s00pcan has joined #ruby
shredding has joined #ruby
northfurr has quit [Ping timeout: 268 seconds]
shredding has quit [Remote host closed the connection]
shredding has joined #ruby
sankaber has quit [Remote host closed the connection]
willardg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
willardg has joined #ruby
sankaber has joined #ruby
Guest53 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
maletor has joined #ruby
akem has quit [Read error: Connection reset by peer]
jessemcgilallen has joined #ruby
akem has joined #ruby
akem has quit [Client Quit]
Gunit__ has joined #ruby
eminencehc has quit [Remote host closed the connection]
nertzy has quit [Quit: This computer has gone to sleep]
Alina-malina has quit [Read error: Connection reset by peer]
nfk|laptop has quit [Quit: yawn]
arthurix has joined #ruby
yfeldblum has joined #ruby
willardg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Gunit__ has left #ruby ["Leaving."]
swgillespie has joined #ruby
yfeldblum has quit [Client Quit]
Anthony_ is now known as _blizzy_
Icey has quit [Ping timeout: 265 seconds]
brushbox has joined #ruby
Alina-malina has joined #ruby
<dreinull75> ok, it's pointless to prepend or extend a delegated class.
arthurix_ has quit [Ping timeout: 256 seconds]
nfk has quit [Quit: Try memory.free_dirty_pages=true in about:config]
<pipework> what's a 'delegated class', and why do you think that it's pointless to what you said to it?
skade has quit [Read error: No route to host]
<Ox0dea> dreinull75: Not if you're on <1.9: https://github.com/banister/remix
m8 has quit [Quit: Sto andando via]
<dreinull75> pipework: I have a Presenter < SimpleDelegator subclass
pwnd_nsfw has quit [Ping timeout: 246 seconds]
willardg has joined #ruby
kies^ has quit [Ping timeout: 255 seconds]
<dreinull75> pipework since you can send pretty much anything to the class I can't just catch all with a prepended module.
yfeldblum has joined #ruby
brushbox has quit [Client Quit]
vF3hNGxc47h8 has joined #ruby
<dreinull75> I'm getting there. It's just a matter of time :)
<pipework> Ox0dea: my goodness, those gems
<Ox0dea> pipework: banister is nuts. <3
pwnd_nsfw has joined #ruby
<pipework> Ox0dea: Truly, he is.
northfurr has joined #ruby
carlisiacampos has joined #ruby
<dreinull75> I guess I need to get down to the object instance level to capture methods instead of the class.
finisherr has quit [Quit: finisherr]
WillAmes has quit [Remote host closed the connection]
diegoaguilar has quit [Ping timeout: 255 seconds]
finisherr has joined #ruby
ruurd has quit [Quit: ZZZzzz…]
juanpablo_ has quit [Quit: (null)]
WillAmes has joined #ruby
juanpablo_ has joined #ruby
finisherr has left #ruby [#ruby]
dnomyar has quit [Ping timeout: 255 seconds]
freerobby has quit [Quit: Leaving.]
<dreinull75> so is it possible to have all that dynamic method definition as singleton methods?
sgambino has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
northfurr has quit [Ping timeout: 240 seconds]
juanpablo__ has joined #ruby
juanpablo_ has quit [Read error: Connection reset by peer]
h99h9h88 has joined #ruby
eminencehc has joined #ruby
pullcheezy has joined #ruby
rbennacer has quit [Remote host closed the connection]
Icey has joined #ruby
[Butch] has quit [Quit: Linkinus - http://linkinus.com]
Oatmeal has quit [Write error: Connection reset by peer]
weemsledeux has joined #ruby
<Ox0dea> dreinull75: Module#singleton_method_added is a thing, if that's what you're asking.
<Ox0dea> As is #define_singleton_method, of course.
jessemcgilallen has quit [Quit: jessemcgilallen]
<dreinull75> Ox0dea not yet sure what I'm exactly looking for.
juanpablo__ has quit [Ping timeout: 256 seconds]
purplexed- has quit [Ping timeout: 240 seconds]
<Ox0dea> dreinull75: It does seem that way. :P
rbennacer has joined #ruby
h99h9h88 has quit [Ping timeout: 256 seconds]
<dreinull75> Objects in a delegated class only have singleton methods?
<Ox0dea> No?
kerunaru has joined #ruby
inteq has quit [Quit: Leaving]
<dreinull75> I don't know. How do I find out?
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
diegoaguilar has joined #ruby
Rickmasta has joined #ruby
karapetyan has quit [Remote host closed the connection]
<Ox0dea> dreinull75: (Unbound)Method#owner seems to be the introspective tool you're after.
karapetyan has joined #ruby
jessemcgilallen has joined #ruby
<dreinull75> Ox0dea doing my reading..
Ropeney has joined #ruby
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
axl__ has quit [Quit: axl__]
Elysia has quit [Quit: WeeChat 1.4-dev]
Oatmeal has joined #ruby
shellie_ has joined #ruby
shellie_ has quit [Client Quit]
Ameliaa has quit []
karapetyan has quit [Ping timeout: 272 seconds]
weemsledeux has quit [Quit: Textual IRC Client: www.textualapp.com]
arup_r has quit [Quit: Leaving]
northfurr has joined #ruby
dfockler has quit [Ping timeout: 255 seconds]
Elysia has joined #ruby
northfurr has quit [Ping timeout: 250 seconds]
<dreinull75> well, time to go- its late
dc has joined #ruby
mordocai has quit [Remote host closed the connection]
cyanide7 has joined #ruby
minimalism has quit [Quit: leaving]
sdwrage has quit [Quit: Leaving]
<cyanide7> Anyone know of a way to extract files from a website? Kind of like a scraper but more specific, I suppose.
<Jamo> wget -r ?
<pipework> An HTTP client, perhaps?
<cyanide7> Close, I gets the html, but not the files themself.
<pipework> 'the files themselves'? What do you mean by this? HTML being returned over HTTP is a 'file' so to speak.
ESpiney has quit [Quit: Leaving]
<pipework> You'll need to describe your desire a bit more fully.
roxtrongo has quit [Remote host closed the connection]
everbot has quit [Ping timeout: 240 seconds]
dc has quit [Remote host closed the connection]
eminencehc has quit [Remote host closed the connection]
<shevy> I desire pipework
<Ox0dea> cyanide7: You're trying to get the actual code that generated the HTML?
<Ox0dea> shevy: Is that a sex thing?
<shevy> it's love!
sepp2k1 has quit [Read error: Connection reset by peer]
<Ox0dea> ~ $ whatis love
<Ox0dea> love: nothing appropriate.
<cyanide7> I mean like scraping a url like "google.com" and being able to download the logo image.
<adaedra> Baby don't hurt me ♫
RegulationD has quit [Remote host closed the connection]
<shevy> eurodance is back for adaedra
<Ox0dea> cyanide7: wget
skade has joined #ruby
<shevy> open-uri!
<Ox0dea> dog!
<eam> mechanical turk
<adaedra> shevy: ?
wldcordeiro has quit [Ping timeout: 268 seconds]
<shevy> adaedra haddaway!!!
<shevy> adaedra now they know how old we are
n0xff has joined #ruby
beast has joined #ruby
chipotle has quit [Quit: cheerio]
m3_del has joined #ruby
<havenwood> cyanide7: What have you tried? Any progress yet?
northfurr has joined #ruby
ruby-lang508 has joined #ruby
hiyosi has joined #ruby
maxz has quit [Quit: Textual IRC Client: www.textualapp.com]
htmldrum has joined #ruby
<ruby-lang508> how can i return a key of a hash without refering to the name? return hash[1] for example?
<eam> ruby-lang508: what do you mean "without refering to the name?"
<shevy> ruby-lang508 1 would be the name
shredding has quit [Ping timeout: 240 seconds]
Cyther_ has joined #ruby
<eam> ruby-lang508: you want the first key in a hash?
Soda has quit [Ping timeout: 268 seconds]
<ruby-lang508> i want to output the current key name to the user
<eam> what's the "current" one?
<ruby-lang508> any of them
<ruby-lang508> whats the proper syntax
<eam> hash.keys.first
northfurr has quit [Ping timeout: 264 seconds]
quazimodo has joined #ruby
<ruby-lang508> well i have a function that turns a users choice into an integer and in another function im trying to interpret there selection.integer to match an available key.
<ruby-lang508> which is a string
<Ox0dea> Why?
<shevy> madness
Cyther has quit [Ping timeout: 265 seconds]
<ruby-lang508> ya well...i started learning the language jsut a couple weeks ago and im about 340 lines deep in this project and just taking one problem at a time
<havenwood> cyanide7: require 'open-uri'; require 'oga'; Oga.parse_html(open 'http://www.google.com', &:read).xpath('//*[@id="hplogo"]/@src').text
mary5030 has joined #ruby
skade has quit [Ping timeout: 255 seconds]
jdawgaz has joined #ruby
Voker57 has quit [Remote host closed the connection]
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
GeissT has joined #ruby
mary5030 has quit [Ping timeout: 265 seconds]
vF3hNGxc47h8 has quit [Read error: Connection reset by peer]
txdv_ is now known as txdv
kobain has joined #ruby
kobain has quit [Max SendQ exceeded]
kobain has joined #ruby
bruno- has quit [Ping timeout: 256 seconds]
charliesome has joined #ruby
moty66 has quit [Ping timeout: 250 seconds]
northfurr has joined #ruby
kobain has quit [Max SendQ exceeded]
krustykoder has joined #ruby
Pupeno has joined #ruby
bruno- has joined #ruby
rbennacer has quit [Remote host closed the connection]
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
moty66_ has joined #ruby
mag42c has quit [Read error: Connection reset by peer]
mag42c has joined #ruby
cyanide7 has left #ruby ["ERC (IRC client for Emacs 24.5.1)"]
kobain has joined #ruby
krustykoder has quit [Client Quit]
juanpablo__ has joined #ruby
skade has joined #ruby
Pupeno has quit [Remote host closed the connection]
northfurr has quit [Ping timeout: 265 seconds]
dfinninger has quit [Remote host closed the connection]
cyle has quit [Ping timeout: 260 seconds]
to_json has quit [Quit: Leaving.]
to_json has joined #ruby
to_json has joined #ruby
tlaxkit has joined #ruby
riotjone_ has joined #ruby
to_json has quit [Client Quit]
northfurr has joined #ruby
CJKinni_ has joined #ruby
juanpablo__ has quit [Ping timeout: 250 seconds]
m3_del has quit [Remote host closed the connection]
segy has quit [Quit: ZNC - http://znc.in]
hahuang65 has quit [Ping timeout: 268 seconds]
shpoont has joined #ruby
arthurix_ has joined #ruby
riotjones has quit [Ping timeout: 256 seconds]
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Rickmasta has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
CJKinni has quit [Ping timeout: 256 seconds]
stamina has quit [Ping timeout: 240 seconds]
hxegon has quit [Ping timeout: 250 seconds]
arthurix has quit [Ping timeout: 256 seconds]
phil6kites has quit [Remote host closed the connection]
skade has quit [Ping timeout: 260 seconds]
pdoherty has quit [Ping timeout: 260 seconds]
Emmanuel_Chanel has quit [Ping timeout: 260 seconds]
northfurr has quit [Quit: northfurr]
jobewan has quit [Read error: Connection reset by peer]
northfurr has joined #ruby
Azure has quit [Remote host closed the connection]
gambl0re has quit [Ping timeout: 264 seconds]
pleiosaur has joined #ruby
northfurr has quit [Client Quit]
wldcordeiro has joined #ruby
CanTonic has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
skade has joined #ruby
charliesome has joined #ruby
devbug has joined #ruby
northfurr has joined #ruby
charliesome has quit [Client Quit]
maletor has quit [Quit: Computer has gone to sleep.]
s00pcan has quit [Ping timeout: 272 seconds]
n_blownapart has joined #ruby
Emmanuel_Chanel has joined #ruby
Emmanuel_Chanel has quit [Max SendQ exceeded]
maletor has joined #ruby
Emmanuel_Chanel has joined #ruby
s00pcan has joined #ruby
m3_del has joined #ruby
alexdunne has joined #ruby
sunya7a has quit [Quit: leaving]
m3_del has quit [Remote host closed the connection]
pdoherty has joined #ruby
startupality has quit [Quit: startupality]
baweaver has quit [Remote host closed the connection]
snockerton has quit [Quit: Leaving.]
skade has quit [Quit: Computer has gone to sleep.]
skade has joined #ruby
skade has quit [Client Quit]
CloCkWeRX has joined #ruby
baweaver has joined #ruby
startupality has joined #ruby
alexdunne has quit [Ping timeout: 255 seconds]
chipotle has joined #ruby
startupality has quit [Client Quit]
RegulationD has joined #ruby
millerti has joined #ruby
<millerti> I have multiple File objects connected to processes via popen. How can I do something like select in C, where it blocks until any one of those File objects has input?
<eam> millerti: IO.select() -- but keep in mind select() isn't meaningful on Files
<eam> (whether in ruby, C or otherwise)
<millerti> eam: These File objects are from popen. Will it work on that?
gambl0re has joined #ruby
<eam> yes, but those won't be File objects, they'll be of IO
<millerti> Oh, ok. Thanks!
Icey has quit [Ping timeout: 246 seconds]
<millerti> Yes, it's IO.popen. Cool.
<eam> >> File.superclass
<ruboto> eam # => IO (https://eval.in/458917)
RegulationD has quit [Ping timeout: 256 seconds]
<eam> millerti: and btw, if you're messing with stuff at this level I'd recommend using sysread/syswrite instead of read/write
<millerti> I'm running as many optimization processes as I have CPU cores (28), and each process dumps some output to stdout. To keep things totally busy, I need to wake when any one of them finishes.
charliesome has joined #ruby
sunya7a has joined #ruby
bmurt has joined #ruby
<millerti> eam: Will that be faster by pre-reserving a maximum amount of space in the receiving string? I'm not sure I need to optimize for that.
<millerti> eam: Or is this for different exceptions?
<eam> the difference is the stdio layer, essentially fwrite(3) vs write(2)
<eam> do you want the read/write to be the amount actually read/written to the fd? Or do you want a buffer that may need a flush()
pullcheezy has quit [Ping timeout: 256 seconds]
<millerti> eam: I'm just consuming the whole stdin from the process I'm running, into a string, which I then parse into lines and parse further.
<millerti> eam: If I'm using IO.select, do I have to use sysread?
<eam> you don't have to
sunya7a_ has joined #ruby
<eam> the issue with an i/o layer is you can have data that's been read(2) but is sitting in a buffer because something like readline hasn't read it at the ruby i/o layer
<millerti> OK, then I'm going to tuck this away in my memory for future use.
rodfersou has quit [Quit: leaving]
<millerti> eam: I'm just doing ioobject.read into a string and closeing the stream.
jackjackdripper has quit [Quit: Leaving.]
startupality has joined #ruby
<eam> that should be fine, but sysread should be fine too
jackjackdripper has joined #ruby
mag42c has quit [Quit: mag42c]
n_blownapart has quit [Remote host closed the connection]
Lucky__ has joined #ruby
<eam> in general if you're polling an fd you don't want a stdio layer between you
<eam> millerti: btw, maybe check out https://rubygems.org/gems/mssh
<millerti> eam: I see what you're saying. I think it's okay, though, because I'm not polling multiple times.
swgillespie has joined #ruby
<millerti> eam: Hey, that looks really useful. Thanks!
<eam> it's probably done better in other gems, but I made that for exactly this purpose: forking out batches of processes and collecting their stdout
<eam> at a minimum it's a fairly simple example of this
swgillespie has quit [Client Quit]
h99h9h88 has joined #ruby
bigmac__ has joined #ruby
<eam> the use case is parallel ssh, so it's built around forking at most X jobs and working through a (potentially huge) log
<eam> but it'll work for any subprocess
baroquebobcat has quit [Quit: baroquebobcat]
<bigmac__> hash.repeated_permutation(200).map(&:join)[0]