ljarvis changed the topic of #ruby-lang to: Ruby 2.1.2; 2.0.0-p481; 1.9.3-p547: http://ruby-lang.org || Paste code on http://gist.github.com
stardiviner has joined #ruby-lang
banister has joined #ruby-lang
RobertBirnie has joined #ruby-lang
dik_dak has joined #ruby-lang
banister has quit [Max SendQ exceeded]
<dacamp> i have the name, but if the user is already in the userdb, no need to parse as a string
brianpWins has quit [Quit: brianpWins]
lewix has quit [Remote host closed the connection]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
lewix has joined #ruby-lang
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
stamina has joined #ruby-lang
sepp2k1 has joined #ruby-lang
sepp2k has quit [Ping timeout: 264 seconds]
lewix has quit [Ping timeout: 264 seconds]
agarie has quit [Remote host closed the connection]
apeiros has quit [Remote host closed the connection]
banister has joined #ruby-lang
apeiros has joined #ruby-lang
hellome has joined #ruby-lang
tkuchiki has quit [Remote host closed the connection]
ddv has quit [Ping timeout: 260 seconds]
ddv has joined #ruby-lang
banister has quit [Ping timeout: 250 seconds]
David__ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
vintik has quit [Remote host closed the connection]
vintik has joined #ruby-lang
stamina has quit [Ping timeout: 250 seconds]
<dacamp> zenspider: I need to call rb_num2uint against the returned rb_Integer value it looks like
hahuang65 has quit [Ping timeout: 256 seconds]
Vyse007 has joined #ruby-lang
vintik has quit [Ping timeout: 240 seconds]
lewix has joined #ruby-lang
omosoj has joined #ruby-lang
Squeatus has quit [Quit: Leaving]
Vyse007 has quit []
tkuchiki has joined #ruby-lang
QuintinAdam has joined #ruby-lang
amerine_ has joined #ruby-lang
amerine has quit [Ping timeout: 245 seconds]
QuintinAdam has quit [Client Quit]
freedrull has quit [Remote host closed the connection]
freedrull has joined #ruby-lang
djbkd has quit [Remote host closed the connection]
yliu has quit [Ping timeout: 272 seconds]
djbkd has joined #ruby-lang
yliu has joined #ruby-lang
seanhagen has quit [Ping timeout: 272 seconds]
ledestin has quit [Ping timeout: 260 seconds]
djbkd has quit [Ping timeout: 264 seconds]
QuintinAdam has joined #ruby-lang
willmarshall has joined #ruby-lang
deg- has quit [Ping timeout: 256 seconds]
seanhagen has joined #ruby-lang
deg- has joined #ruby-lang
freedrull has quit [Ping timeout: 256 seconds]
yliu has quit [Ping timeout: 245 seconds]
blowmage has quit [Ping timeout: 256 seconds]
freedrull has joined #ruby-lang
yliu has joined #ruby-lang
blowmage has joined #ruby-lang
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ledestin has joined #ruby-lang
David__ has joined #ruby-lang
lewix has quit [Remote host closed the connection]
borkabrak has quit [Ping timeout: 240 seconds]
lewix has joined #ruby-lang
lewix has quit [Ping timeout: 255 seconds]
Cakey has joined #ruby-lang
Sirupsen has joined #ruby-lang
|jemc| has joined #ruby-lang
alexju has quit [Remote host closed the connection]
Cakey has quit [Ping timeout: 245 seconds]
sarkyniin has quit [Ping timeout: 256 seconds]
nofxx has quit [Ping timeout: 240 seconds]
amclain has joined #ruby-lang
Averna has joined #ruby-lang
saarinen has quit [Quit: saarinen]
shinnya has quit [Ping timeout: 260 seconds]
mistym has quit [Remote host closed the connection]
vintik has joined #ruby-lang
Miphix has joined #ruby-lang
lsegal has joined #ruby-lang
m3k40 has quit [Ping timeout: 245 seconds]
m3k40 has joined #ruby-lang
jxie has quit [Quit: leaving]
jmeeuwen has quit [Quit: Disconnecting from stoned server.]
jmeeuwen has joined #ruby-lang
omosoj has quit [Quit: Leaving]
torrieri has joined #ruby-lang
spastorino has quit [Quit: Connection closed for inactivity]
weems|mac has joined #ruby-lang
|jemc| has quit [Quit: WeeChat 0.4.3]
lewix has joined #ruby-lang
mistym has joined #ruby-lang
jlovick has quit [Ping timeout: 245 seconds]
lewix has quit [Remote host closed the connection]
lewix has joined #ruby-lang
monees has joined #ruby-lang
lewix_ has joined #ruby-lang
tectonic has joined #ruby-lang
lewix has quit [Read error: Connection reset by peer]
|jemc| has joined #ruby-lang
jbardin has quit [Quit: jbardin]
David__ has quit [Quit: Textual IRC Client: www.textualapp.com]
wallerdev has quit [Quit: wallerdev]
Cakey has joined #ruby-lang
monees has quit [Remote host closed the connection]
microdex has joined #ruby-lang
r3zn0r has joined #ruby-lang
tectonic has quit []
Sirupsen has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dknox has quit [Quit: Textual IRC Client: www.textualapp.com]
michaeldeol has joined #ruby-lang
wallerdev has joined #ruby-lang
Sirupsen has joined #ruby-lang
saarinen has joined #ruby-lang
QuintinAdam has quit [Remote host closed the connection]
Sirupsen has quit [Quit: Textual IRC Client: www.textualapp.com]
saarinen has quit [Quit: saarinen]
saarinen has joined #ruby-lang
tectonic has joined #ruby-lang
weems|mac has quit [Quit: weems|mac]
tectonic has quit [Client Quit]
92AAAD736 has joined #ruby-lang
heftig has quit [Ping timeout: 272 seconds]
vvikus has joined #ruby-lang
lsegal has quit [Read error: Connection reset by peer]
lsegal has joined #ruby-lang
tectonic has joined #ruby-lang
lewix_ is now known as Lewix
Lewix has quit [Changing host]
Lewix has joined #ruby-lang
tectonic has quit [Client Quit]
vintik has quit [Remote host closed the connection]
torrieri has quit [Quit: Leaving...]
RobertBirnie has quit [Ping timeout: 240 seconds]
nofxx has joined #ruby-lang
92AAAD736 has quit [Remote host closed the connection]
stardiviner has quit [Ping timeout: 272 seconds]
torrieri has joined #ruby-lang
symm- has quit [Ping timeout: 250 seconds]
blueclaude has joined #ruby-lang
<blueclaude> nil.class.superclass.superclass.superclass == nil
<blueclaude> Whoa
gix has quit [Ping timeout: 255 seconds]
sirene has joined #ruby-lang
agrinb has joined #ruby-lang
<whitequark> >> nil.class.superclass.superclass.superclass
<Mon_Robot> whitequark: => nil (https://eval.in/173370)
<whitequark> huh
gix has joined #ruby-lang
agrinb has quit [Ping timeout: 260 seconds]
mehlah has quit [Ping timeout: 240 seconds]
heftig has joined #ruby-lang
nathanstitt has quit [Quit: I growing sleepy]
wallerdev_ has joined #ruby-lang
mehlah has joined #ruby-lang
wallerdev_ has quit [Client Quit]
sepp2k1 has quit [Read error: Connection reset by peer]
r3zn0r has quit [Ping timeout: 255 seconds]
blueclaude has quit [Ping timeout: 246 seconds]
mistym_ has joined #ruby-lang
mistym has quit [Ping timeout: 250 seconds]
heftig has quit [Ping timeout: 250 seconds]
nathanstitt has joined #ruby-lang
nathanstitt has quit [Client Quit]
QuintinAdam has joined #ruby-lang
QuintinAdam has quit [Remote host closed the connection]
mistym_ is now known as mistym
tectonic has joined #ruby-lang
duderonomy has joined #ruby-lang
borkabrak has joined #ruby-lang
hanu_ has joined #ruby-lang
m3k40 has quit [Ping timeout: 255 seconds]
Lewix has quit [Remote host closed the connection]
Lewix has joined #ruby-lang
weems|mac has joined #ruby-lang
djbkd has joined #ruby-lang
Lewix has quit [Ping timeout: 250 seconds]
yfeldblu_ has joined #ruby-lang
saarinen has quit [Quit: saarinen]
yfeldblum has quit [Ping timeout: 240 seconds]
microdex has quit [Remote host closed the connection]
yfeldblu_ has quit [Ping timeout: 240 seconds]
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
danijoo has quit [Read error: Connection reset by peer]
karamazov has quit [Remote host closed the connection]
danijoo has joined #ruby-lang
karamazov has joined #ruby-lang
djbkd has quit [Quit: My people need me...]
m3k40 has joined #ruby-lang
karamazov has quit [Ping timeout: 256 seconds]
skade has joined #ruby-lang
karamazov has joined #ruby-lang
vikasyaligar has joined #ruby-lang
iamnot has joined #ruby-lang
karamazov has quit [Remote host closed the connection]
karamazov has joined #ruby-lang
kaiza has quit [Ping timeout: 255 seconds]
vikasyaligar has quit []
skade has quit [Quit: Computer has gone to sleep.]
vikasyaligar has joined #ruby-lang
kaiza has joined #ruby-lang
karamazov has quit [Ping timeout: 256 seconds]
clamstar has quit [Ping timeout: 255 seconds]
verto has quit [Ping timeout: 272 seconds]
skade has joined #ruby-lang
heftig has joined #ruby-lang
verto has joined #ruby-lang
clamstar has joined #ruby-lang
Lewix has joined #ruby-lang
michaeldeol has joined #ruby-lang
skade has quit [Ping timeout: 245 seconds]
CaptainJet has quit []
vvikus has quit [Quit: WeeChat 0.4.2]
vvikus has joined #ruby-lang
vintik has joined #ruby-lang
jsullivandigs has quit [Read error: Connection reset by peer]
heftig has quit [Ping timeout: 250 seconds]
jsullivandigs has joined #ruby-lang
hahuang65 has joined #ruby-lang
borkabrak has left #ruby-lang ["Leaving"]
relix has joined #ruby-lang
torrieri has quit [Quit: Leaving...]
yfeldblum has joined #ruby-lang
iamnot is now known as simple-user
Kabaka has quit [Ping timeout: 255 seconds]
yfeldblum has quit [Remote host closed the connection]
Rylee has quit [Max SendQ exceeded]
yfeldblum has joined #ruby-lang
Rylee has joined #ruby-lang
mehlah has quit [Quit: Leaving...]
stardiviner has joined #ruby-lang
tectonic has quit []
Kabaka has joined #ruby-lang
apeiros has quit [Read error: Connection reset by peer]
apeiros_ has joined #ruby-lang
amclain has quit [Quit: Leaving]
ur5us has quit [Remote host closed the connection]
heftig has joined #ruby-lang
charliesome has quit [Ping timeout: 260 seconds]
vikasyaligar has quit [Quit: Going out ...]
spuk has quit [Ping timeout: 250 seconds]
charliesome has joined #ruby-lang
saarinen has joined #ruby-lang
hakunin has joined #ruby-lang
<hakunin> i was trying to use a Set as a pool to avoid keeping thousands of identical objects in memory
<hakunin> but i'm not sure how to reference an object currently in set
<hakunin> looks quite impossible…
toastynerd has joined #ruby-lang
<hakunin> would appreciate if anyone knows
tectonic has joined #ruby-lang
toastynerd has quit [Remote host closed the connection]
ItSANgo has quit [Quit: Leaving...]
ikrima has joined #ruby-lang
weems|mac has quit [Quit: weems|mac]
danijoo has quit [Read error: Connection reset by peer]
danijoo has joined #ruby-lang
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
apeiros_ is now known as apeiros
tectonic has quit []
saltsa_ has quit [Ping timeout: 240 seconds]
eeezkil has quit [Quit: Leaving.]
ItSANgo has joined #ruby-lang
<hakunin> x-posted (and resolved) in #ruby, thanks
_ht has joined #ruby-lang
tbuehlmann has joined #ruby-lang
apeiros has quit [Remote host closed the connection]
apeiros has joined #ruby-lang
jhass|off is now known as jhass
luiz_ has joined #ruby-lang
luiz_ is now known as Guest59959
hanu_ has quit [Remote host closed the connection]
apeiros has quit [Ping timeout: 255 seconds]
luiz_lha has quit [Ping timeout: 255 seconds]
michaeldeol has quit [Quit: Textual IRC Client: www.textualapp.com]
willmarshall has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
hanu_ has joined #ruby-lang
rsl has quit [Read error: Connection reset by peer]
rsl has joined #ruby-lang
sMecKs has quit [Read error: Connection reset by peer]
rsl has quit [Read error: Connection reset by peer]
rsl has joined #ruby-lang
relix has joined #ruby-lang
|jemc| has quit [Quit: WeeChat 0.4.3]
vintik has quit [Remote host closed the connection]
vintik has joined #ruby-lang
Raycaster has quit [Quit: Leaving.]
vintik has quit [Ping timeout: 260 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ddv has quit [Changing host]
ddv has joined #ruby-lang
banister has joined #ruby-lang
Mon_Ouie has joined #ruby-lang
arBmind has quit [Quit: Leaving.]
skade has joined #ruby-lang
heftig has quit [Ping timeout: 272 seconds]
dik_dak has quit [Quit: Leaving]
mistym has quit [Remote host closed the connection]
vintik has joined #ruby-lang
heftig has joined #ruby-lang
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
saarinen has quit [Quit: saarinen]
arBmind has joined #ruby-lang
gix has quit [Ping timeout: 250 seconds]
gix has joined #ruby-lang
apeiros has joined #ruby-lang
arBmind1 has joined #ruby-lang
AKASkip has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
arBmind has quit [Ping timeout: 256 seconds]
solars has joined #ruby-lang
Forgetful_Lion has joined #ruby-lang
ruby-lang042 has joined #ruby-lang
tomkadwill has joined #ruby-lang
<ruby-lang042> hi i got this error when try to compass watch "LoadError on line ["1637"] of /usr/lib/ruby/1.9.1/rubygems/specification.rb: Unable to activate toolkit-2.0.0, because sass-3.2.19 conflicts with sass (~> 3.3.0)"
<ruby-lang042> can u please help me
Benny1992 has quit [Quit: leaving]
Benny1992 has joined #ruby-lang
Benny1992 has quit [Client Quit]
Benny1992 has joined #ruby-lang
brianpWins has joined #ruby-lang
hanu_ has quit [Remote host closed the connection]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<zenspider> ruby-lang042: what'd you change?
danijoo_ has joined #ruby-lang
danijoo has quit [Read error: Connection reset by peer]
Averna has quit [Quit: Leaving.]
spuk has joined #ruby-lang
vvikus has quit [Quit: WeeChat 0.4.2]
relix has joined #ruby-lang
simple-user has quit [Ping timeout: 255 seconds]
<ruby-lang042> i've changed nothing
wallerdev has quit [Quit: wallerdev]
<ruby-lang042> compass watch and press enter i've got this error
<zenspider> cmon...
<ruby-lang042> zenspider
<zenspider> you changed something
<zenspider> shit doesn't just break out of the blue
mikecmpbll has joined #ruby-lang
<ruby-lang042> thats y i'm asking...
skade has joined #ruby-lang
<zenspider> and so I'm asking what you changed... this isn't hard, is it?
<ohsix> unpack it again and diff :]
skade_ has joined #ruby-lang
<ruby-lang042> see, i've given a pre-setup site to do some css change, it has been using sass, so i've installed ruby and gems(compass, sass..) after that when i enter the "compass watch" command i've got this
<zenspider> they didn't provide a Gemfile.lock?
skade has quit [Ping timeout: 250 seconds]
fullybaked has joined #ruby-lang
vintik has quit [Remote host closed the connection]
vintik has joined #ruby-lang
elia has joined #ruby-lang
<ruby-lang042> just a Gemfile
<yorickpeterse> morning fleshlings
<zenspider> and the gemfile prolly has bad dependencies
<zenspider> you should have them provide a Gemfile.lock
diegoviola has joined #ruby-lang
<zenspider> or otherwise fix their deps
<yorickpeterse> ruby-lang042: `bundle install`, then run `bundle exec compass watch` and see if that works
skade_ has quit [Quit: Computer has gone to sleep.]
<ruby-lang042> yorickpeterse thanks will try
vintik has quit [Ping timeout: 264 seconds]
<ruby-lang042> yorickpeterse thanks man. it works!
<yorickpeterse> np
Atttwww has quit [Ping timeout: 240 seconds]
danijoo_ has quit [Read error: Connection reset by peer]
danijoo has joined #ruby-lang
kek has joined #ruby-lang
michd is now known as MichD
hanu_ has joined #ruby-lang
hanu___ has joined #ruby-lang
hanu_ has quit [Read error: Connection reset by peer]
ssam2 has joined #ruby-lang
sferik has joined #ruby-lang
Ainieco has joined #ruby-lang
<Ainieco> hello
<Ainieco> what's the difference between string.unpack("M*") and string.unpack("M")?
<yorickpeterse> Ainieco: `ri String#unpack` shows the formats you can use
<Ainieco> tough question sicne docs lacking of "M*" but i found references to it accross internet
<yorickpeterse> aaaaand apparently "*" isn't documented
<Ainieco> yep
<Ainieco> that's why i'masking
<sluukkonen> An asterisk (``*'') will use up
<sluukkonen> all remaining elements.
<sluukkonen> that's what my ri page says.
hanu___ has left #ruby-lang [#ruby-lang]
<Ainieco> sluukkonen: remaining elements of what?
<Ainieco> ah i think i got it, thanks
<yorickpeterse> it consumes the remainder of the void
* yorickpeterse said that with a scary voice
<Ainieco> also got small question about decoding unpacked things. "=E2=80=99".unpack("M*").first => "\xE2\x80\x99", how can i decode it further so it'll return "’"?
nofxx has quit [Ping timeout: 250 seconds]
Lewix has quit [Remote host closed the connection]
marr has joined #ruby-lang
symm- has joined #ruby-lang
<yorickpeterse> >> "=E2=80=99".unpack("M*").first.force_encoding('UTF-8')
<Mon_Robot> yorickpeterse: => "’" (https://eval.in/173589)
<yorickpeterse> (note that it is there for me locally)
<Ainieco> yorickpeterse: ah, i needed to force_encoding, thanks. i failed with ".encode" method which refused to encode it
<yorickpeterse> There's some pack value you can use to properly pack/unpack UTF8 stuff but I forgot which one
<yorickpeterse> I think it was U* but it only works for integers
brianpWins has quit [Quit: brianpWins]
<yorickpeterse> e.g.
<yorickpeterse> >> [201, 111, 111].pack('U*')
<Mon_Robot> yorickpeterse: => "Éoo" (https://eval.in/173590)
<yorickpeterse> errr
<yorickpeterse> derp I suck at pack today
<yorickpeterse> Either way, there's one for that :P
<Ainieco> IIRC there was force_encoding kind of thing that accpeted attribute for replacing "unknown"/broker/invalid unicode with supplied value
<Ainieco> am i dreaming?
vintik has joined #ruby-lang
<yorickpeterse> No, I think only String#encode takes extra options
<Ainieco> ah, it's "String#encode" but it doesn't work with "\xE2\x80\x99" things
<Ainieco> yorickpeterse: yeah
<yorickpeterse> >> "a\x80".encode('UTF-8', :invalid => :replace, :replace => 'icecream')
<Mon_Robot> yorickpeterse: => "aicecream" (https://eval.in/173592)
<Ainieco> >> "=E2=80=99".unpack("M*").first.encode('UTF-8') # too bad it fails here
<Mon_Robot> Ainieco: => Encoding::UndefinedConversionError: "\xE2" from ASCII-8BIT to UTF-8 (https://eval.in/173595)
<Ainieco> there must be a reason tho, /me is to dumb to know which one
<yorickpeterse> well, the resulting string of unpack() in this case is basically garbage
<yorickpeterse> Also, if the original input wasn't UTF8 forcing it to UTF8 won't always work
<Ainieco> yorickpeterse: yep, that makes sense
workmad3 has joined #ruby-lang
skade has joined #ruby-lang
Ainieco has quit [Quit: leaving]
Ainieco has joined #ruby-lang
<Ainieco> thank you guys for the help!
<yorickpeterse> np
ikrima has quit [Ping timeout: 255 seconds]
symm- has quit [Ping timeout: 250 seconds]
Cakey has quit [Ping timeout: 250 seconds]
skade has quit [Read error: Connection reset by peer]
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
skade has joined #ruby-lang
symm- has joined #ruby-lang
jxie has joined #ruby-lang
ruby-lang583 has joined #ruby-lang
<ruby-lang583> when installing bundle i've got this error "Gem::InstallError: celluloid requires Ruby version >= 1.9.2. An error occurred while installing celluloid (0.15.2), and Bundler cannot continue. Make sure that `gem install celluloid -v '0.15.2'` succeeds before bundling." my ruby version is 1.9.3
ssam2 has quit [Remote host closed the connection]
ssam2 has joined #ruby-lang
robmiller has joined #ruby-lang
jxie has quit [Ping timeout: 255 seconds]
vintik has quit [Remote host closed the connection]
jxie has joined #ruby-lang
vintik has joined #ruby-lang
<yorickpeterse> run `ruby --version`, what is the output?
robmiller has quit [Client Quit]
robmiller has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
Miphix has quit [Quit: Leaving]
sferik has joined #ruby-lang
vintik has quit [Ping timeout: 245 seconds]
<ruby-lang042> ruby 1.9.3p547 (2014-05-14 revision 45962) [x86_64-linux]
<ruby-lang042> yorickpeterse ruby 1.9.3p547 (2014-05-14 revision 45962) [x86_64-linux]
<yorickpeterse> hm, odd
<workmad3> ruby-lang042: remove and re-install bundler... I've had that sort of thing happen at times, generally because the 'bundle' executable ended up with a hardcoded path to the wrong ruby
<yorickpeterse> gem pristine --all --env-shebang
Ainieco has quit [Quit: leaving]
<yorickpeterse> ^ run that
<workmad3> ^^ that would be better (I'm useless as remembering that command :) )
<workmad3> *at
<ruby-lang583> will try
ruby-lang042 has quit [Ping timeout: 246 seconds]
stef_204 has joined #ruby-lang
bin7me has joined #ruby-lang
kyb3r_ has quit [Read error: Connection reset by peer]
AKASkip has quit [Read error: No route to host]
stamina has joined #ruby-lang
AKASkip has joined #ruby-lang
vikasyaligar has joined #ruby-lang
tkuchiki_ has joined #ruby-lang
saltsa has joined #ruby-lang
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tkuchiki has quit [Ping timeout: 255 seconds]
tkuchiki_ has quit [Ping timeout: 240 seconds]
Fushi has joined #ruby-lang
vintik has joined #ruby-lang
workmad3 has quit [Quit: Lost terminal]
workmad3 has joined #ruby-lang
elia has quit [Quit: Computer has gone to sleep.]
ironhide_604 has joined #ruby-lang
elia has joined #ruby-lang
elia has quit [Quit: Computer has gone to sleep.]
vintik has quit [Remote host closed the connection]
vintik has joined #ruby-lang
vintik has quit [Ping timeout: 255 seconds]
davispuh has joined #ruby-lang
yfeldblum has quit [Remote host closed the connection]
dangerousdave has joined #ruby-lang
matp has quit [Quit: ZZZzzz…]
Cakey has joined #ruby-lang
relix has quit [Ping timeout: 260 seconds]
relix has joined #ruby-lang
sarkyniin has joined #ruby-lang
thang_ has joined #ruby-lang
mehlah has joined #ruby-lang
thang has quit [Ping timeout: 240 seconds]
ldnunes has joined #ruby-lang
arBmind1 has quit [Quit: Leaving.]
Miphix has joined #ruby-lang
thang_ has quit [Ping timeout: 240 seconds]
spastorino has joined #ruby-lang
katlogic has quit [Read error: Connection reset by peer]
<igalic> hello happy people! Can someone help me unravel what this advise means: https://github.com/puppetlabs/puppetlabs-mysql/pull/548#issuecomment-50747108 ( stub out a function in an rspec test to return different values )
thang has joined #ruby-lang
<yorickpeterse> igalic: in rspec you can stub out methods, meaning you replace what they normally do
<yorickpeterse> e.g.
<yorickpeterse> some_object.stub(:foo).and_return(10; some_object.foo # => 10
<igalic> yorickpeterse: what if .foo has a parameter?
yalue has joined #ruby-lang
<yorickpeterse> You can also stub that I believe
<tbuehlmann> yea, there is #with iirc
<tbuehlmann> also, there's a newer syntax for that: `allow(object).to receive(:foo) { 10 }`
katlogic has joined #ruby-lang
<igalic> so I'd go, allow(version_check).to receive('10.0.0-MariaDB') { false }
tomkadwill has quit [Remote host closed the connection]
<tbuehlmann> no
<tbuehlmann> try this: allow(object).to receive(:version_check).with('10.0.0-MariaDB') { false }
<igalic> oh.
<igalic> I see, we're directly manipulating the object object.
<tbuehlmann> that'd be like object.version_check('10.0.0-MariaDB') # => false
<igalic> okay! Thanks.
sferik has joined #ruby-lang
yatish27 has joined #ruby-lang
earthquake has quit [Quit: earthquake]
sferik has quit [Client Quit]
<igalic> almost, https://gist.github.com/igalic/cdea95d0e15940d74dbd - anyway, lunch now.
sferik has joined #ruby-lang
elia has joined #ruby-lang
vikasyaligar has quit [Remote host closed the connection]
tomkadwill has joined #ruby-lang
vikasyaligar has joined #ruby-lang
charliesome has joined #ruby-lang
Sgeo has quit [Read error: Connection reset by peer]
relix_ has joined #ruby-lang
heftig has quit [Ping timeout: 272 seconds]
relix has quit [Ping timeout: 260 seconds]
heftig has joined #ruby-lang
diegoviola has quit [Read error: Connection reset by peer]
diegovio1 has joined #ruby-lang
QuintinAdam has joined #ruby-lang
pskosinski has joined #ruby-lang
kek_ has joined #ruby-lang
diegovio1 is now known as diegoviola
kek has quit [Ping timeout: 250 seconds]
kek has joined #ruby-lang
kek_ has quit [Ping timeout: 245 seconds]
yatish27 has quit [Remote host closed the connection]
yfeldblum has joined #ruby-lang
[spoiler] has joined #ruby-lang
dwknoxy has joined #ruby-lang
yfeldblum has quit [Ping timeout: 245 seconds]
kek has quit [Remote host closed the connection]
kek_ has joined #ruby-lang
amystephen has joined #ruby-lang
mehlah has quit [Quit: Leaving...]
weems|mac has joined #ruby-lang
hanu____ has joined #ruby-lang
stamina has quit [Ping timeout: 245 seconds]
<igalic> yah! Changed allow object to allow subject.provider, and I've gone from one error to three, https://gist.github.com/igalic/cdea95d0e15940d74dbd - that means I'm doing something right.
pskosinski has quit [Quit: Til rivido Idisti! | http://www.ido.li]
Forgetful_Lion has quit [Quit: ChatZilla 0.9.90.1 [Firefox 31.0/20140716183446]]
malconis has joined #ruby-lang
vondruch has quit [Ping timeout: 245 seconds]
hanu____ has left #ruby-lang [#ruby-lang]
apeiros is now known as officialbot
officialbot is now known as apeiros
stef_204 has quit [Remote host closed the connection]
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
workmad3_ has joined #ruby-lang
HammyJammy has joined #ruby-lang
tomkadwi_ has joined #ruby-lang
Squarepy has joined #ruby-lang
eval-in has joined #ruby-lang
centrx has joined #ruby-lang
eval-in has quit [Remote host closed the connection]
eval-in has joined #ruby-lang
Mellett68_ has joined #ruby-lang
Rubennn_ has joined #ruby-lang
Mon_Robot_ has joined #ruby-lang
GaelanAintAround has quit [Ping timeout: 245 seconds]
tomkadwill has quit [Ping timeout: 245 seconds]
lguardiola has quit [Ping timeout: 245 seconds]
`micro_ has quit [Ping timeout: 245 seconds]
Soilent__ has quit [Ping timeout: 245 seconds]
dostoyevsky has quit [Ping timeout: 245 seconds]
GitNick has quit [Ping timeout: 245 seconds]
Mon_Robot has quit [Ping timeout: 245 seconds]
mfn has quit [Ping timeout: 245 seconds]
Mellett68 has quit [Ping timeout: 245 seconds]
hachiya has quit [Read error: Connection reset by peer]
dostoyevsky has joined #ruby-lang
sharpmac_ has joined #ruby-lang
aledovsky has quit [Ping timeout: 240 seconds]
fullybaked has quit [Ping timeout: 240 seconds]
fumduq has quit [Ping timeout: 240 seconds]
Maitiu has quit [Ping timeout: 240 seconds]
zz_sMecKs has quit [Ping timeout: 240 seconds]
workmad3 has quit [Ping timeout: 240 seconds]
rsl has quit [Ping timeout: 240 seconds]
levifig has quit [Ping timeout: 240 seconds]
Rubennn has quit [Ping timeout: 240 seconds]
[spoiler] has quit [Ping timeout: 240 seconds]
Mon_Ouie has quit [Ping timeout: 240 seconds]
t_ has quit [Ping timeout: 240 seconds]
sharpmachine has quit [Ping timeout: 240 seconds]
nino has joined #ruby-lang
sMecKst has joined #ruby-lang
ssam2 has quit [Ping timeout: 245 seconds]
Rylee has quit [Ping timeout: 245 seconds]
sirene has quit [Ping timeout: 245 seconds]
jtperreault has quit [Ping timeout: 245 seconds]
PaulePanter has quit [Ping timeout: 245 seconds]
diegoviola has quit [Ping timeout: 240 seconds]
JammyHammy has quit [Ping timeout: 240 seconds]
queue has quit [Ping timeout: 240 seconds]
cid404 has quit [Ping timeout: 240 seconds]
jamooo has quit [Ping timeout: 240 seconds]
PaulePanter has joined #ruby-lang
lguardiola has joined #ruby-lang
Rylee has joined #ruby-lang
queue has joined #ruby-lang
ssam2 has joined #ruby-lang
sirene has joined #ruby-lang
ironhide_604 has quit [Ping timeout: 250 seconds]
`micro has joined #ruby-lang
cid404 has joined #ruby-lang
rsl has joined #ruby-lang
levifig has joined #ruby-lang
fumduq has joined #ruby-lang
aledovsky has joined #ruby-lang
GitNick has joined #ruby-lang
`micro is now known as Guest46876
GaelanAintAround has joined #ruby-lang
Mon_Ouie has joined #ruby-lang
jtperreault has joined #ruby-lang
t_ has joined #ruby-lang
mfn has joined #ruby-lang
hachiya has joined #ruby-lang
marr has quit [Ping timeout: 256 seconds]
ironhide_604 has joined #ruby-lang
Maitiu has joined #ruby-lang
Soilent__ has joined #ruby-lang
torrieri has joined #ruby-lang
torrieri has quit [Client Quit]
karamazov has joined #ruby-lang
jamooo has joined #ruby-lang
nathanstitt has joined #ruby-lang
apeiros_ has joined #ruby-lang
fullybaked has joined #ruby-lang
ironhide_604 has quit [Ping timeout: 250 seconds]
nathanstitt has quit [Client Quit]
apeiros has quit [Ping timeout: 264 seconds]
rcvalle has joined #ruby-lang
ironhide_604 has joined #ruby-lang
charliesome has quit [Ping timeout: 240 seconds]
jxie has quit [Ping timeout: 255 seconds]
jxie has joined #ruby-lang
torrieri has joined #ruby-lang
weems|mac has quit [Quit: weems|mac]
K3dare has joined #ruby-lang
danijoo has quit [Read error: Connection reset by peer]
danijoo has joined #ruby-lang
robbyoconnor has quit [Ping timeout: 250 seconds]
jgpawletko has quit [Quit: jgpawletko]
charliesome has joined #ruby-lang
mehlah has joined #ruby-lang
mehlah has quit [Client Quit]
mehlah has joined #ruby-lang
ruby-lang583 has quit [Ping timeout: 246 seconds]
JohnFord has joined #ruby-lang
skade has joined #ruby-lang
apeiros_ has quit [Read error: Connection reset by peer]
momomomomo has joined #ruby-lang
kith_ has joined #ruby-lang
Xzyx987X has quit [Ping timeout: 255 seconds]
kith has quit [Ping timeout: 250 seconds]
alekst has joined #ruby-lang
loincloth has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
robbyoconnor has joined #ruby-lang
Yulli has joined #ruby-lang
relix has joined #ruby-lang
Yulli has left #ruby-lang ["Bye"]
relix_ has quit [Ping timeout: 255 seconds]
nathanstitt has joined #ruby-lang
kith_ is now known as kith
diegoviola has joined #ruby-lang
davidfrey has joined #ruby-lang
Xzyx987X has joined #ruby-lang
agarie has joined #ruby-lang
tkuchiki has joined #ruby-lang
agrinb has joined #ruby-lang
sarkyniin has quit [Remote host closed the connection]
sarkyniin has joined #ruby-lang
Mon_Robot_ has quit [Remote host closed the connection]
|jemc| has joined #ruby-lang
mistym has joined #ruby-lang
workmad3_ is now known as workmad3
tomkadwi_ has quit [Remote host closed the connection]
tomkadwill has joined #ruby-lang
robbyoconnor has quit [Ping timeout: 255 seconds]
marr has joined #ruby-lang
mistym has quit [Remote host closed the connection]
cmhobbs has joined #ruby-lang
cmhobbs has joined #ruby-lang
Fushi has quit [Quit: Connection closed for inactivity]
nofxx has joined #ruby-lang
bruno- has joined #ruby-lang
bruno- has quit [Remote host closed the connection]
sferik has joined #ruby-lang
sferik has quit [Client Quit]
davidfrey has quit [Remote host closed the connection]
davidfrey has joined #ruby-lang
bruno- has joined #ruby-lang
jlovick has joined #ruby-lang
mistym has joined #ruby-lang
chouhoulis has joined #ruby-lang
davidfrey has quit [Ping timeout: 272 seconds]
<karamazov> I've finished POODOR but still don't feel like I fully understand how to actually implement OOD.
<centrx> karamazov, What's the confusion?
davidfrey has joined #ruby-lang
<karamazov> centrx: I understand the concepts and get the idea behind TRUE. I'm trying to test my knowledge out by doing TicTacToe and don't really feel like I know what I'm doing.
<karamazov> Sandi talked about interfaces but didn't really show how to implement them
<centrx> What is "TRUE"?
<karamazov> Transparency, Reasonable, Usable, Exemplary
davidfrey has quit [Remote host closed the connection]
davidfrey has joined #ruby-lang
<centrx> I assume there's a chapter on each one of those? Who can argue with "Reasonable" and "Usable"
symm- has quit [Ping timeout: 255 seconds]
AKASkip has quit [Ping timeout: 250 seconds]
<centrx> karamazov, The main principle of object-oriented design is that each class represent a coherent thing with actual attributes and behaviors.
<centrx> karamazov, For TicTacToe, you could have a Player class and a Tile class for example
robbyoconnor has joined #ruby-lang
<karamazov> That's what I was leaning towards and the Player class would have Human and Computer as sub classes
<centrx> karamazov, These are actual things in the real-world if you were to play TicTacToe in the real-world. You could even have a Writer/Pencil class, a StrategicThinking class for an AI player...
<centrx> karamazov, exactly
<karamazov> I should separate Player < Computer and the Thinking?
sferik has joined #ruby-lang
sferik has quit [Client Quit]
jlovick has quit [Quit: No Ping reply in 180 seconds.]
<centrx> karamazov, I was just giving an example. It depends on how significant that portion of the program is. It's often more a practical issue whether to split a new class out.
Xzyx987X_ has joined #ruby-lang
davidfrey has quit [Ping timeout: 250 seconds]
sferik has joined #ruby-lang
<karamazov> Sure - Sandi talks about that in the book. Deciding whether or not to break out and comparing the cost of it.
sferik has quit [Client Quit]
jlovick has joined #ruby-lang
<centrx> karamazov, One could make classes for every minute component of program, or make one monolithic class without differentiation, at the extremes.
sferik has joined #ruby-lang
seamon has joined #ruby-lang
chouhoulis has quit [Remote host closed the connection]
<centrx> karamazov, This may be where the TRUE comes in. You want your class architecture/design to be Transparent -- both easily understandable and matching up with the "real" object with as little extra or confusing added on
<karamazov> I found an example online (done by the company I'm interviewing for) and the guy had a position class and a TTT class. Didn't really seem OOD.
Xzyx987X has quit [Ping timeout: 255 seconds]
chouhoulis has joined #ruby-lang
<centrx> karamazov, TicTacToe is ultimately a simple game, so it does not necessarily warrant many classes. I would probably do it with a Player and Tile class as the main engines
<centrx> maybe a Referee/RuleSystem
monees has joined #ruby-lang
<karamazov> centrx: You're correct - it can be done in less than 200 lines of code. I think I'll go for Player and Tile (or Board)
<centrx> yeah, Player and Board, even better
<karamazov> It's weird - I know the fundamentals of Ruby but am struggling with this simple game. Most of my time is spent trying to figure out how to test the console output correctly.
Cakey has quit [Ping timeout: 264 seconds]
<workmad3> karamazov: I'd keep the console UI separated from the board and have it able to take an Input object and an Output object
momomomomo_ has joined #ruby-lang
<workmad3> karamazov: oh, and a board or somesuch for it to print
<karamazov> workmad3: I'm not sure I follow
<workmad3> karamazov: then you can pass in StringIO instances for testing and verify the right stuff is added to them with the board in certain states
<workmad3> karamazov: rather than testing output on STDOUT
matp has joined #ruby-lang
<karamazov> Oh like $STDIN and $STDOUT?
momomomomo has quit [Ping timeout: 255 seconds]
momomomomo_ is now known as momomomomo
cmhobbs has quit [Quit: Leaving]
cmhobbs has joined #ruby-lang
<workmad3> (very simplified)
Cakey has joined #ruby-lang
<karamazov> Checking it out now
stamina has joined #ruby-lang
<karamazov> workmad3: $STDOUT and $STDIN are variables that are part of console, correct?
<workmad3> karamazov: $STDIN and $STDOUT are your input and output pipes
<workmad3> karamazov: if you run the app in a terminal, they'll be connected up to the terminals stdin and stdout
apeiros has joined #ruby-lang
<karamazov> workmad3: Gotcha - so the console_printer should be separate from the actual board and game logic?
<workmad3> karamazov: that's how I'd do it
<karamazov> The actual console_printer will be pretty simple if I understand correctly?
<workmad3> karamazov: yeah... it takes a board and prints it out to the provided output :)
<workmad3> karamazov: you may also want a PlayerInput class that also takes a board and asks the player for their next move (and an AIInput class that does the same but doesn't need to get user input)
<karamazov> workmad3: Thanks for the help! I had trouble figuring out what the STDOUT and STDIN actually were. A lot of the answers were a bit over my head.
|jemc| has quit [Ping timeout: 264 seconds]
<karamazov> workmad3: Ah, so reprinting the board for each turn?
<workmad3> karamazov: when it comes to testing, it's useful to recognise that STDIN and STDOUT are global variables... so relying on them in the guts of your app makes a hidden dependency :)
<workmad3> karamazov: sure... you could later on create something like an NCursesPrinter that uses curses to redraw the board
<workmad3> karamazov: but for starters, I'd just reprint each time ;)
<karamazov> workmad3: Which is why you've using StringIO.new in the testing? To rid that dependency?
<workmad3> karamazov: having the printer take an output object makes the dependency explicit
<workmad3> karamazov: and then StringIO looks like an IO object (which is what STDOUT also is), so you can then replace the dependency in your tests
<workmad3> karamazov: it's a very simple form of dependency injection ;)
<karamazov> workmad3: I can't quite wrap my head around that being dependency injection but I'll keep staring at it till it makes sense
<workmad3> karamazov: dependency injection == passing in dependencies rather than relying on globals or creating them in an object
<workmad3> karamazov: in a very simple sense
<karamazov> workmad3: I understand the idea of dependency injection I think it's just feeling abstract because of the global variables.
diegoviola has quit [Quit: WeeChat 0.4.3]
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<karamazov> workmad3: I think I get it though. If I didn't have the print and just had the board then the board would know far too much about the output. All the board needs is the output and it doens't need to know how that output is created?
sferik has joined #ruby-lang
<workmad3> karamazov: that's more single-responsibility principle
<karamazov> Oi :(
<workmad3> karamazov: and if you'll note, in the gist the board doesn't need to know anything about output, or even to know that output is possible :)
K3dare has quit [Ping timeout: 250 seconds]
<workmad3> karamazov: it's the printer that needs to know about the board, not the board about the printer ;)
sepp2k has joined #ruby-lang
<karamazov> hmm.
K3dare has joined #ruby-lang
stamina has quit [Ping timeout: 260 seconds]
ironhide_604 has quit [Ping timeout: 250 seconds]
yfeldblum has joined #ruby-lang
_`_ has joined #ruby-lang
toastynerd has joined #ruby-lang
toastyne_ has joined #ruby-lang
bin7me has quit [Quit: Leaving]
toastynerd has quit [Ping timeout: 245 seconds]
RobertBirnie has joined #ruby-lang
mistym has quit [Remote host closed the connection]
saarinen has joined #ruby-lang
karamazov has quit []
davidfrey has joined #ruby-lang
saarinen has quit [Quit: saarinen]
davidfrey has quit [Client Quit]
toastyne_ has quit [Remote host closed the connection]
skade has joined #ruby-lang
davispuh has quit [Ping timeout: 245 seconds]
karamazov has joined #ruby-lang
ender|dkm has joined #ruby-lang
wallerdev has joined #ruby-lang
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
elia has quit [Quit: Computer has gone to sleep.]
stamina has joined #ruby-lang
davispuh has joined #ruby-lang
sferik has joined #ruby-lang
loincloth has quit [Remote host closed the connection]
loincloth has joined #ruby-lang
_`_ has left #ruby-lang ["('_')/"]
mistym has joined #ruby-lang
__butch__ has joined #ruby-lang
tbuehlmann has quit [Remote host closed the connection]
kek has joined #ruby-lang
ender|dkm has quit [Ping timeout: 240 seconds]
loincloth has quit [Ping timeout: 260 seconds]
centrx has quit [Quit: Mead error: Connection reset by beer]
arBmind has joined #ruby-lang
shinnya has joined #ruby-lang
kek_ has quit [Ping timeout: 272 seconds]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
kek has quit [Ping timeout: 264 seconds]
tomkadwill has quit []
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ta_ has joined #ruby-lang
JohnFord has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
apeiros has quit []
dangerousdave has quit [Read error: Connection reset by peer]
dangerou_ has joined #ruby-lang
ta has quit [Ping timeout: 240 seconds]
apeiros has joined #ruby-lang
rippa has joined #ruby-lang
flak has joined #ruby-lang
seamon has quit [Quit: seamon]
monees has quit [Ping timeout: 272 seconds]
momomomomo has quit [Quit: momomomomo]
monees has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
brianpWins has joined #ruby-lang
dangerou_ has quit [Read error: Connection reset by peer]
stardiviner has quit [Ping timeout: 240 seconds]
dangerousdave has joined #ruby-lang
mikecmpbll has quit [Ping timeout: 250 seconds]
skade has joined #ruby-lang
skade has quit [Client Quit]
Cakey has quit [Ping timeout: 240 seconds]
Miphix has quit [Quit: Leaving]
fullybaked has quit [Ping timeout: 245 seconds]
wallerdev has quit [Quit: wallerdev]
toastynerd has joined #ruby-lang
torrieri has quit [Quit: Linkinus - http://linkinus.com]
malconis has joined #ruby-lang
torrieri has joined #ruby-lang
toastynerd has quit [Ping timeout: 256 seconds]
loincloth has joined #ruby-lang
ender|dkm has joined #ruby-lang
zzak___ has quit []
r0bby_ has joined #ruby-lang
ender|dkm has quit [Ping timeout: 255 seconds]
robbyoconnor has quit [Ping timeout: 264 seconds]
jperry has joined #ruby-lang
hahuang65 has quit [Ping timeout: 272 seconds]
wallerdev has joined #ruby-lang
JohnFord has joined #ruby-lang
mistym has quit [Remote host closed the connection]
mbj has joined #ruby-lang
nino is now known as [spoiler]
mistym has joined #ruby-lang
Cakey has joined #ruby-lang
arBmind has quit [Quit: Leaving.]
Cakey has quit [Ping timeout: 240 seconds]
ItSANgo has quit [Quit: Leaving...]
vintik has joined #ruby-lang
djbkd has joined #ruby-lang
AKASkip has joined #ruby-lang
workmad3 has quit [Ping timeout: 255 seconds]
ssam2 has quit [Quit: Leaving]
ItSANgo has joined #ruby-lang
David_ has joined #ruby-lang
David_ has quit [Client Quit]
yfeldblum has quit [Remote host closed the connection]
toastynerd has joined #ruby-lang
yfeldblum has joined #ruby-lang
mbj has quit [Quit: leaving]
torrieri has quit [Quit: Leaving...]
robmiller has quit [Quit: Leaving.]
shinnya has quit [Ping timeout: 272 seconds]
flak has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
yfeldblum has quit [Ping timeout: 255 seconds]
stamina has quit [Quit: WeeChat 0.4.3]
arBmind has joined #ruby-lang
dangerousdave has quit [Read error: Connection reset by peer]
dangerousdave has joined #ruby-lang
JohnFord has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
weems|mac has joined #ruby-lang
queue has quit [Ping timeout: 245 seconds]
JohnFord has joined #ruby-lang
toastynerd has quit [Ping timeout: 245 seconds]
jbardin has joined #ruby-lang
hahuang65 has joined #ruby-lang
fullybaked has joined #ruby-lang
apofis has joined #ruby-lang
loincloth has quit [Remote host closed the connection]
ender|dkm has joined #ruby-lang
QuintinAdam has quit [Remote host closed the connection]
QuintinAdam has joined #ruby-lang
queue has joined #ruby-lang
tbuehlmann has joined #ruby-lang
QuintinAdam has quit [Ping timeout: 240 seconds]
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mikecmpbll has joined #ruby-lang
malconis has quit [Remote host closed the connection]
malconis has joined #ruby-lang
danijoo has quit [Read error: Connection reset by peer]
riffraff has joined #ruby-lang
danijoo has joined #ruby-lang
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby-lang
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sferik has joined #ruby-lang
yfeldblum has joined #ruby-lang
relix has joined #ruby-lang
vikasyaligar has quit []
r0bby_ has quit [Ping timeout: 240 seconds]
malconis has joined #ruby-lang
dik_dak has joined #ruby-lang
mehlah has quit [Quit: Leaving...]
momomomomo has joined #ruby-lang
djbkd has quit [Quit: My people need me...]
skade has joined #ruby-lang
momomomomo has quit [Client Quit]
saarinen has joined #ruby-lang
skade_ has joined #ruby-lang
chouhoul_ has joined #ruby-lang
malconis has quit [Ping timeout: 240 seconds]
JohnFord has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
skade has quit [Ping timeout: 245 seconds]
djbkd has joined #ruby-lang
djbkd has quit [Remote host closed the connection]
skade_ has quit [Client Quit]
SpeakerToMeat has joined #ruby-lang
<SpeakerToMeat> No
SpeakerToMeat has left #ruby-lang [#ruby-lang]
SpeakerToMeat has joined #ruby-lang
chouhoulis has quit [Ping timeout: 256 seconds]
loincloth has joined #ruby-lang
djbkd has joined #ruby-lang
MichD is now known as michd
agarie has quit [Remote host closed the connection]
malconis has joined #ruby-lang
jgpawletko has joined #ruby-lang
ikrima has joined #ruby-lang
monees has quit [Remote host closed the connection]
momomomomo has joined #ruby-lang
bin7me has joined #ruby-lang
JohnFord has joined #ruby-lang
mcantor has joined #ruby-lang
<mcantor> When I run 'gem rdoc --all', WHERE is the HTML placed?
<mcantor> How do I acces it?
enkristoffer has joined #ruby-lang
symm- has joined #ruby-lang
elia has joined #ruby-lang
havenwood has joined #ruby-lang
<Mon_Ouie> If you run "gem server" you can access it at the url it gives you
momomomomo has quit [Quit: momomomomo]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
toretore has quit [Ping timeout: 255 seconds]
<mcantor> Mon_Ouie: Isn't there a way to just spit out the HTML? I don't fully understand why a server is necessary
michd is now known as MichD
<mcantor> Mon_Ouie: Plus, if I want to view ALL docs in one place--gems AND stdlib--then the server approach is rather broken. (In fact, I think that yardoc server and gem server both try to use the same port by default)
momomomomo has joined #ruby-lang
<Mon_Ouie> I just don't know where they're located
r0bby_ has joined #ruby-lang
<mcantor> seems like they're in #{RbConfig::CONFIG["prefix"]}/lib/ruby/gems/#{RbConfig::CONFIG["ruby_version"]}/doc/#{GEM}/rdoc
alekst has quit [Quit: Computer has gone to sleep.]
alekst has joined #ruby-lang
momomomomo has quit [Quit: momomomomo]
dangerousdave has quit [Read error: Connection reset by peer]
dangerou_ has joined #ruby-lang
momomomomo has joined #ruby-lang
vintik has quit [Remote host closed the connection]
ascarter has joined #ruby-lang
ascarter has quit [Client Quit]
vintik has joined #ruby-lang
ascarter has joined #ruby-lang
ascarter has quit [Read error: No route to host]
ascarter has joined #ruby-lang
elia has quit [Quit: Computer has gone to sleep.]
vintik has quit [Ping timeout: 255 seconds]
momomomomo has quit [Quit: momomomomo]
r0bby_ is now known as robbyoconnor
torrieri has joined #ruby-lang
wallerdev has quit [Quit: wallerdev]
djbkd has quit [Remote host closed the connection]
AKASkip has quit [Ping timeout: 240 seconds]
yfeldblu_ has joined #ruby-lang
AKASkip has joined #ruby-lang
yfeldblu_ has quit [Read error: Connection reset by peer]
toretore has joined #ruby-lang
elia has joined #ruby-lang
yfeldblu_ has joined #ruby-lang
yfeldblum has quit [Ping timeout: 245 seconds]
_ht has quit [Remote host closed the connection]
apt-get_ has joined #ruby-lang
sarkyniin has quit [Ping timeout: 255 seconds]
postmodern has joined #ruby-lang
<darix> mcantor: wrong
<darix> mcantor: ask rubygems for the path
<darix> mcantor: it has options for this too
araujo has quit [Ping timeout: 264 seconds]
fowlduck has joined #ruby-lang
<mcantor> darix: What did I say that's wrong, specificaly?
<mcantor> *specifically
<fowlduck> I'm working on a fix for some SSL issues with zencoder.com's ruby client and I happened upon a solution for adding the default openssl ca bundle paths to the cert store but I'm not entirely certain about the security implications
<fowlduck> is anyone here familiar enough with net/https to know if there are any issues with this approach?
bin7me has quit [Read error: Connection timed out]
djbkd has joined #ruby-lang
bin7me has joined #ruby-lang
<fowlduck> the change is essentially to manually build a OpenSSL::X509::Store and add the default paths. that seems like something the default cert store should be doing, though...
<fowlduck> I mean, it seems like the default store *is* already doing this: https://github.com/ruby/ruby/blob/v2_1_2/ext/openssl/lib/openssl/ssl.rb
<fowlduck> and net/http seems to be using the set_params method for the context, even https://github.com/ruby/ruby/blob/v2_1_2/lib/net/http.rb#L893
jbardin has quit [Quit: jbardin]
toretore has quit [Ping timeout: 255 seconds]
ikrima has quit [Read error: Connection reset by peer]
[spoiler] has quit [Quit: Leaving]
<darix> mcantor: ruby -rrubygems -e 'print Gem::Specification.new.base_dir'
loincloth has quit [Remote host closed the connection]
[spoiler] has joined #ruby-lang
loincloth has joined #ruby-lang
momomomomo has joined #ruby-lang
molgrew has joined #ruby-lang
[spoiler] has quit [Client Quit]
<havenwood> >> Gem.default_dir
<eval-in> havenwood => "/execpad/interpreters/ruby-2.1.2/lib/ruby/gems/2.1.0" (https://eval.in/173989)
loincloth has quit [Ping timeout: 250 seconds]
centrx has joined #ruby-lang
weems|mac has quit [Quit: weems|mac]
loincloth has joined #ruby-lang
wallerdev has joined #ruby-lang
<havenwood> Gem::Specification.find_by_name(gem_name).doc_dir
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
<drbrain> fowlduck: building a Store and setting the default paths is the way to go
_sillymarkets has joined #ruby-lang
<drbrain> along with setting VERIFY_PEER
molgrew has quit [Quit: leaving]
molgrew has joined #ruby-lang
elia has quit [Quit: Computer has gone to sleep.]
<_sillymarkets> Can someone help me with basic iteration through an array?
<_sillymarkets> https://gist.github.com/anonymous/911d7925b8519528586b | I'm not understanding why my function "second_worst" works correctly, but "top_four" fails
<_sillymarkets> instead of creating 4 separate functions to find the worst numbers in the array and names, I figured I could do one function and iterate through it?
agarie has joined #ruby-lang
<_sillymarkets> names[index_for_names] fails
<wallerdev> that code seems really weird lol
<wallerdev> why not just ary.sort[0, 4]
<_sillymarkets> I'm sure it is, I'm a beginner
<_sillymarkets> Well, I have one columnn of names, and I want to print the worst 4 percentages, along with their names
<_sillymarkets> those exist in two different cells. So if i sort the array with percentages, it won't align up to the correct name
jbardin has joined #ruby-lang
<wallerdev> wel your while loop doesnt really run does it?
<_sillymarkets> I figured, i could pull the index value of the array in sort, and then use that index_for_names to print the name related to that index
<wallerdev> it starts at x = 0
<wallerdev> and runs while x is less than -4
<wallerdev> so itd have to be -5 or -6 etc
havenwood has quit [Remote host closed the connection]
<_sillymarkets> and im subtracting 1 from x, everytime
<_sillymarkets> so shouldnt i run till x is -3 ?
<_sillymarkets> it*
<wallerdev> no lol
<wallerdev> the first run through, you subtract 1 from x and get x = -1
<wallerdev> then it checks is -1 < -4
<wallerdev> which is false
<wallerdev> and it exits the loop
molgrew has quit [Quit: leaving]
agarie has quit [Ping timeout: 240 seconds]
kyb3r_ has joined #ruby-lang
<_sillymarkets> ok, so i got the loop to run, switched it to > -4
riffraff has quit [Quit: This computer has gone to sleep]
<_sillymarkets> but "puts @names[index_for_names] still fails
<_sillymarkets> no implicit conversion of Array into integer
<wallerdev> well
<wallerdev> index_for_names is an array
<wallerdev> what do you expect it to output?
<wallerdev> if you had x = [1, 2, 3, 4]; and did x[[7, 2, 8, 9]] im not sure what you expect to get from that
<_sillymarkets> I want index_for_names to save the values of top 4, so it'll be like [3, 2, 5, 6] and then i wanted puts @names[index_for_names
<_sillymarkets> to iterate through and print the names associated with the names array, but using the index_for_names values
stevednd has quit [Quit: Leaving]
<wallerdev> you probably need to loop through index_for_names
<wallerdev> like index_for_names.each { |i| puts @names[i] }
stevednd has joined #ruby-lang
<_sillymarkets> hmm, okay. I was thinking along that path too
<drbrain> @names.values_at(*index_for_names)
stevednd has quit [Client Quit]
<drbrain> >> %w[a b c d e f].values_at 2, 3, 4
<eval-in> drbrain => ["c", "d", "e"] (https://eval.in/174000)
vintik has joined #ruby-lang
stevednd has joined #ruby-lang
<fowlduck> drbrain: ok, so, what I'm doing there is fine?
<drbrain> let me double check, but what you described is what RubyGems and net-http-persistent do
<_sillymarkets> thanks wallerdev, that works ! :)
Atttwww has joined #ruby-lang
<drbrain> _sillymarkets: look at my >> above, it's the simpler way
<fowlduck> drbrain: copied more or less for how the default cert store is setup in openssl in ruby 2.1.2
<fowlduck> drbrain: and thanks :)
<drbrain> fowlduck: yep, looks good
<fowlduck> I need to check previous ruby versions to make sure this is sane, too
<fowlduck> awesome, thanks!
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
momomomomo_ has joined #ruby-lang
<_sillymarkets> that works too drbrain , but i don't follow the logic as well. I'll have to read through passing * arrays again
<drbrain> _sillymarkets: values_at accepts an arbitrary number of indices to extract values from
<drbrain> not an array of indices
momomomomo has quit [Ping timeout: 255 seconds]
momomomomo_ is now known as momomomomo
<drbrain> the * converts an array of indices into arguments for the method
<wallerdev> * is magic
<_sillymarkets> very interesting
<_sillymarkets> thanks
ender|dkm has quit [Ping timeout: 255 seconds]
fullybaked has quit []
MichD is now known as michd
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby-lang
elia has joined #ruby-lang
chouhoul_ has quit [Remote host closed the connection]
ender|dkm has joined #ruby-lang
chouhoulis has joined #ruby-lang
Soilent_ has quit [Ping timeout: 255 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mark06 has joined #ruby-lang
araujo has joined #ruby-lang
araujo has joined #ruby-lang
<mark06> how can I compile ruby code native to windows/linux?
<mark06> or maybe compile to c
djbkd has quit [Remote host closed the connection]
<_sillymarkets> wallerdev, another quick question. How can I use the "end while" condition to end when it matches a value in the cell ? The value would be a string.
<mark06> web search didn't show anything useful
<_sillymarkets> or drbrain
chouhoulis has quit [Ping timeout: 264 seconds]
<whitequark> mark06: basically, you can't
<_sillymarkets> drbrain: , wallerdev:
<mark06> whitequark: no
djbkd has joined #ruby-lang
ur5us has joined #ruby-lang
<wallerdev> the while loop will loop while the condition is true
<wallerdev> sooooo if you want it to end when two strings match, you want it to loop WHILE the two terms do not match
<wallerdev> so while x != "cool"; keep looping; end
Soilent_ has joined #ruby-lang
<whitequark> mark06: "no" ?
mistym has quit [Remote host closed the connection]
<_sillymarkets> thanks wallerdev: i must have learned it backwards
<_sillymarkets> now im getting an error, saying "undefined method '[]' for nil:NilClass (NoMethodError)
<_sillymarkets> but @names is defined?
djbkd has quit [Remote host closed the connection]
<apeiros> whitequark: no.
<apeiros> *scnr* :)
dangerou_ has quit []
Soilent_ has quit [Ping timeout: 255 seconds]
symm- has quit [Ping timeout: 260 seconds]
<_sillymarkets> end while "
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<_sillymarkets> end while "#{string_to_match}" = "Total" | does not work ;\
Soilent_ has joined #ruby-lang
sepp2k has quit [Quit: Konversation terminated!]
jgpawletko has quit [Quit: jgpawletko]
ldnunes has quit [Quit: Leaving]
mark06 has left #ruby-lang [#ruby-lang]
<_sillymarkets> https://gist.github.com/anonymous/23e5fdf6e541bd362996 | How come I'm getting undefined method '[]' here ?
Soilent_ has quit [Ping timeout: 245 seconds]
<apeiros> whitequark: I think he thinks he knows better than you - oddly enough he still has to ask about it. I love irc.
agrinb has quit [Remote host closed the connection]
SpeakerToMeat has quit [Ping timeout: 272 seconds]
djbkd has joined #ruby-lang
enkristoffer has quit [Quit: ❤]
weems|mac has joined #ruby-lang
agarie has joined #ruby-lang
TheMoonMaster has quit [Excess Flood]
jhass is now known as jhass|off
TheMoonMaster has joined #ruby-lang
agarie has quit [Remote host closed the connection]
karamazov has quit [Remote host closed the connection]
momomomomo_ has joined #ruby-lang
momomomomo has quit [Ping timeout: 240 seconds]
momomomomo_ is now known as momomomomo
alekst has quit [Quit: Computer has gone to sleep.]
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mehlah has joined #ruby-lang
djbkd has quit [Remote host closed the connection]
sferik has joined #ruby-lang
sMecKs has joined #ruby-lang
djbkd has joined #ruby-lang
loincloth has quit []
_djbkd has joined #ruby-lang
djbkd has quit [Remote host closed the connection]
tbuehlmann has quit [Remote host closed the connection]
_djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby-lang
loincloth has joined #ruby-lang
sepp2k has joined #ruby-lang
x0f has quit [Ping timeout: 256 seconds]
weems|mac has quit [Quit: weems|mac]
x0f has joined #ruby-lang
jlovick has quit [Ping timeout: 240 seconds]
karamazov has joined #ruby-lang
yfeldblu_ has quit [Remote host closed the connection]
yfeldblum has joined #ruby-lang
centrx has quit [Quit: Mead error: Connection reset by beer]
jxie has quit [Quit: leaving]
nathanstitt has quit [Quit: I growing sleepy]
ascarter has joined #ruby-lang
apeiros has quit [Remote host closed the connection]
apeiros has joined #ruby-lang
__butch__ has quit [Quit: Leaving.]
djbkd has quit [Remote host closed the connection]
charliesome has joined #ruby-lang
dwknoxy has quit [Quit: Textual IRC Client: www.textualapp.com]
Squarepy has quit [Remote host closed the connection]
brianpWins has quit [Ping timeout: 250 seconds]
godd2 has joined #ruby-lang
earthquake has joined #ruby-lang
_sillymarkets has quit [Ping timeout: 246 seconds]
djbkd has joined #ruby-lang
yfeldblum has quit [Remote host closed the connection]
cmhobbs has quit [Remote host closed the connection]
yfeldblum has joined #ruby-lang
Sgeo has joined #ruby-lang
yfeldblum has quit [Ping timeout: 272 seconds]
vvikus has joined #ruby-lang
saarinen has quit [Quit: saarinen]
mcantor has quit [Quit: leaving]
yfeldblum has joined #ruby-lang
mehlah has quit [Quit: Leaving...]
yfeldblum has quit [Remote host closed the connection]
stevednd has quit [Quit: Leaving]
stevednd has joined #ruby-lang
yfeldblum has joined #ruby-lang
loincloth has quit [Remote host closed the connection]
yfeldblum has quit [Ping timeout: 255 seconds]
momomomomo has quit [Ping timeout: 250 seconds]
momomomomo has joined #ruby-lang
danijoo has quit [Read error: Connection reset by peer]
|jemc| has joined #ruby-lang
danijoo has joined #ruby-lang
solars has quit [Ping timeout: 240 seconds]
rue has joined #ruby-lang
torrieri has quit [Quit: Leaving...]
hahuang65 has quit [Ping timeout: 255 seconds]
arBmind has quit [Quit: Leaving.]
mistym has joined #ruby-lang
JohnFord has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
stardiviner has joined #ruby-lang
skade has joined #ruby-lang
yfeldblum has joined #ruby-lang
saarinen has joined #ruby-lang
AKASkip has quit [Ping timeout: 272 seconds]
skade has quit [Read error: Connection reset by peer]
yfeldblum has quit [Remote host closed the connection]
yfeldblum has joined #ruby-lang
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
weems|mac has joined #ruby-lang
stardiviner has quit [Quit: my website: http://stardiviner.dyndns-blog.com/]
ikrima has joined #ruby-lang
skade has joined #ruby-lang
yfeldblum has quit [Ping timeout: 240 seconds]
ender|dkm has quit [Ping timeout: 255 seconds]
skade has quit [Read error: Connection reset by peer]
bin7me has quit [Quit: Leaving]
dik_dak has quit [Quit: Leaving]
ender|dkm has joined #ruby-lang
stardiviner has joined #ruby-lang
ender|dkm has quit [Client Quit]
skade has joined #ruby-lang
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
charliesome has joined #ruby-lang
yfeldblum has joined #ruby-lang
earthquake has quit [Quit: earthquake]
yfeldblum has quit [Ping timeout: 264 seconds]
ikrima has quit [Ping timeout: 260 seconds]
banister has quit [Ping timeout: 245 seconds]
banister_ has joined #ruby-lang
banister_ has quit [Max SendQ exceeded]
skade has quit [Quit: Computer has gone to sleep.]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
weems|mac has quit [Quit: weems|mac]
torrieri has joined #ruby-lang
saarinen has quit [Quit: saarinen]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
ruby-lang205 has joined #ruby-lang
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
wallerdev has quit [Quit: wallerdev]
danijoo has quit [Read error: Connection reset by peer]
danijoo has joined #ruby-lang
wallerdev has joined #ruby-lang
banister has quit [Ping timeout: 272 seconds]
elia has quit [Quit: Computer has gone to sleep.]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
ascarter has joined #ruby-lang
saarinen has joined #ruby-lang
banister has joined #ruby-lang
ikrima has joined #ruby-lang
banister has quit [Client Quit]
torrieri has quit [Quit: Leaving...]
bruno- has quit [Ping timeout: 255 seconds]
hahuang65 has joined #ruby-lang