apeiros changed the topic of #ruby to: Ruby 2.0.0-p247: http://ruby-lang.org (Ruby 1.9.3-p448) || Paste >3 lines of text on http://gist.github.com || this channel is logged at http://irclog.whitequark.org, other public logging is prohibited
mikeg has joined #ruby
somnambulically0 has joined #ruby
cody-- has joined #ruby
iamjarvo has joined #ruby
reset has quit [Quit: Leaving...]
hydrozen has quit [Ping timeout: 245 seconds]
Ziarkaen has quit [Remote host closed the connection]
ssvo_ has quit [Ping timeout: 245 seconds]
Coolhand_ has quit [Quit: No Ping reply in 180 seconds.]
locriani has joined #ruby
kvirani_ has quit [Remote host closed the connection]
Coolhand has joined #ruby
fridim__ has quit [Ping timeout: 260 seconds]
kvirani has joined #ruby
mikeg has quit [Ping timeout: 276 seconds]
cj3kim_ has joined #ruby
chrishough has quit [Quit: chrishough]
brain_shim has joined #ruby
JaTochNietDan has quit [Quit: Right.]
clov3r has quit [Remote host closed the connection]
jerius has joined #ruby
jerius has quit [Max SendQ exceeded]
JaTochNietDan has joined #ruby
mansi has joined #ruby
cj3kim_ has quit [Ping timeout: 245 seconds]
kvirani has quit [Ping timeout: 276 seconds]
brain_shim has quit [Ping timeout: 264 seconds]
zzz_taion809 is now known as taion809
jerius has joined #ruby
<a1ph4g33k> bnagy, so ... other than your changes ... do you have any feedback on my code ( other than the "no globals" comment earlier ? )
<a1ph4g33k> your changes meaning, the changes based on your suggested algorithm.
<bnagy> the most recent one? Looked reasonable
<a1ph4g33k> There's a final cleanup version after that one.
<a1ph4g33k> I removed the globals.
mmitchell has joined #ruby
<a1ph4g33k> and then I linked it to the gist from maasha ... hoping he will eventually come back and give us a performance comparison.
chopmo has joined #ruby
<bnagy> :)
<a1ph4g33k> ( once he gets his working ) ... ( apologies if maasha is female )
jerius has quit [Client Quit]
soheil has joined #ruby
tabolario has joined #ruby
hydrozen_ has quit [Quit: Computer has gone to sleep.]
dmiller has joined #ruby
<a1ph4g33k> time to start the commute home ... thanks for the nice place to hang out ... g'nite.
<bnagy> night
chopmo has quit [Ping timeout: 276 seconds]
cody-- has quit [Quit: derp]
a1ph4g33k has left #ruby ["Leaving"]
sambao21 has quit [Ping timeout: 248 seconds]
ferdev has joined #ruby
cody-- has joined #ruby
DrCode has quit [Ping timeout: 240 seconds]
io_syl has quit []
fridim__ has joined #ruby
jasontorres is now known as powerhead
|jemc| has quit [Ping timeout: 264 seconds]
brain_shim has joined #ruby
rins has joined #ruby
nari has quit [Ping timeout: 245 seconds]
axl_ has quit [Quit: axl_]
maletor has quit [Quit: Computer has gone to sleep.]
brianpWins has quit [Quit: brianpWins]
simoz has joined #ruby
dkamioka has quit [Remote host closed the connection]
emmanuelux has quit [Remote host closed the connection]
hogeo has joined #ruby
tkuchiki has quit [Remote host closed the connection]
fomatin has joined #ruby
ismaelrb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
lukec has quit [Quit: lukec]
angusiguess has joined #ruby
Kabaka has quit [Ping timeout: 240 seconds]
lfox has joined #ruby
mercwithamouth has joined #ruby
taternuts has joined #ruby
lfox has quit [Client Quit]
thorn__ has quit [Quit: Lost terminal]
ravster has quit [Quit: Leaving.]
snovak has joined #ruby
ehc has quit [Quit: ehc]
splud has quit [Quit: splud]
Kabaka has joined #ruby
rins has quit [Ping timeout: 248 seconds]
dodosan has quit [Remote host closed the connection]
JohnE has joined #ruby
dallasm has joined #ruby
mansi has quit [Ping timeout: 264 seconds]
snovak has quit [Ping timeout: 276 seconds]
RORgasm has quit [Remote host closed the connection]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
saarinen has quit [Quit: saarinen]
snath has quit [Ping timeout: 256 seconds]
Kamijou_Touma has quit [Quit: yawn]
heftig has quit [Quit: Quitting]
simoz has quit [Ping timeout: 248 seconds]
Ox6abe has joined #ruby
alexju has joined #ruby
michalkozminski has quit [Ping timeout: 245 seconds]
dhruvasagar has joined #ruby
sambao21 has joined #ruby
emergion has joined #ruby
sniffingcats has quit [Quit: Til rivido Idisti!]
emergion has quit [Max SendQ exceeded]
kvirani has joined #ruby
|jemc| has joined #ruby
phantasm66 has joined #ruby
phantasm66 has joined #ruby
emergion has joined #ruby
phantasm66 has quit [Client Quit]
false_economy has quit [Remote host closed the connection]
vlad_starkov has joined #ruby
emergion has quit [Max SendQ exceeded]
threesome has quit [Ping timeout: 245 seconds]
hpekdemir has left #ruby [#ruby]
emergion has joined #ruby
m8 has quit [Quit: Sto andando via]
Voodoofish430 has left #ruby [#ruby]
emergion has quit [Max SendQ exceeded]
sambao21 has quit [Client Quit]
Ox6abe has quit [Remote host closed the connection]
kreisys has joined #ruby
emergion has joined #ruby
Collin_ has quit [Ping timeout: 256 seconds]
emergion has quit [Max SendQ exceeded]
oliver_ has quit [Remote host closed the connection]
emergion has joined #ruby
vlad_starkov has quit [Ping timeout: 276 seconds]
dayepa has quit [Quit: dayepa]
Soda has quit [Read error: Connection reset by peer]
dayepa has joined #ruby
emergion has quit [Max SendQ exceeded]
rburton- has quit [Quit: Linkinus - http://linkinus.com]
emergion has joined #ruby
emergion has quit [Client Quit]
Ripp__ has quit []
msuszczy has quit [Read error: Operation timed out]
pothibo has quit [Quit: pothibo]
kilophoton has joined #ruby
<taternuts> if I have an object that has a 'to_a' call that returns an array with 3 values, is this valid?: x, y, z = object.to_a
mmitchell has quit [Remote host closed the connection]
cooldman224 has quit [Remote host closed the connection]
aeontech has joined #ruby
<taternuts> probably have to split it
cj3kim_ has joined #ruby
saarinen has joined #ruby
jonahR has quit [Quit: jonahR]
Ox6abe has joined #ruby
Domon has joined #ruby
msuszczy has joined #ruby
mfridh has quit [Read error: Connection reset by peer]
sarlalian has quit [Ping timeout: 245 seconds]
dankest has quit [Quit: Peace]
tkuchiki has joined #ruby
dagnachew has joined #ruby
cody-- has quit [Quit: derp]
jaimef has quit [Excess Flood]
cj3kim_ has quit [Ping timeout: 264 seconds]
<|jemc|> >> x,y,z = [1,2,3].to_a; [x,y,z]
<eval-in> |jemc| => [1, 2, 3] (https://eval.in/49053)
<|jemc|> looks valid
jaimef has joined #ruby
P1RATEZ has joined #ruby
dlovell_ has joined #ruby
<taternuts> thanks!
DrCode has joined #ruby
mwmnj has quit [Ping timeout: 248 seconds]
<dlovell_> I'm trying to run packer.io docs locally per https://github.com/mitchellh/packer/tree/master/website#running-the-site-locally
clov3r has joined #ruby
snath has joined #ruby
<dlovell_> when I do 'bundle', I get: /usr/lib/ruby/vendor_ruby/bundler/rubygems_ext.rb:8:in `require': no such file to load -- rubygems (LoadError)
<dlovell_> and then some other stuff
<dlovell_> What am I missing?
parzo has joined #ruby
<dlovell_> but don't think I have multiple versions of ruby installed and don't want to start installing a whole bunch of things all willy nilly
<xybre> dlovell_: Is rubygems installaed and up to date?
<dlovell_> I don't think so. I'm on ubuntu and trying to execute 'rubygems' doesn't return a suggestion to install a package
<dlovell_> so I'm not sure how to install rubygems
kreisys has quit [Quit: Computer has gone to sleep.]
<dlovell_> ah, trying 'gem' gives me the prompt
dankest has joined #ruby
dankest has quit [Read error: Connection reset by peer]
dankest has joined #ruby
<dlovell_> ok, rubygems installed, now I get: /opt/packer/website/Gemfile:3:in `evaluate': undefined method `ruby' for #<Bundler::Dsl:0x7f44f0ee5048> (NoMethodError) ...
<xybre> dlovell_: you probably want a recent version of ruby, not the ancient versions that come with Ubuntu
<xybre> dlovell_: https://rvm.io/rvm/install
freerobby has joined #ruby
<dlovell_> xybre: thanks, will give it a go
<onewheelskyward> rbenv is another option for ruby management.
<onewheelskyward> I know it has packages within ubuntu.
DanKnox_away is now known as DanKnox
michalkozminski has joined #ruby
baroquebobcat has joined #ruby
heftig has joined #ruby
<xybre> rbenv doesn't install rubies, which is the bigger problem he's dealing with. ruby-build does allow you to, but requires additional setup, rvm does everything out of the box without effort.
<postmodern> why not ruby-install, it also handles installing build dependencies
* xybre sighs
randomautomator has quit [Ping timeout: 264 seconds]
<postmodern> chruby+ruby-install works, but RVM is the best if you want a turn-key solution
Ox6abe has quit [Remote host closed the connection]
<|jemc|> adding ruby-build to rbenv is a one-liner
digital-ghost has quit [Remote host closed the connection]
<|jemc|> git clone https://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build
jprovazn has quit [Ping timeout: 276 seconds]
hamakn has joined #ruby
Ox6abe has joined #ruby
tvw has quit [Ping timeout: 260 seconds]
sevenseacat has joined #ruby
snovak has joined #ruby
michalkozminski has quit [Ping timeout: 245 seconds]
cody-- has joined #ruby
<|jemc|> if you do choose rbenv, I recommend following the github instructions rather than using the Ubuntu package
lukec has joined #ruby
<|jemc|> other than tracking down build dependencies as postmodern noted, it's as easy as pasting the right commands in a terminal
<dlovell_> per https://rvm.io/rvm/install, my process (so far) is
browndawg has joined #ruby
<|jemc|> and you don't even need root access
<dlovell_> \curl -L https://get.rvm.io | bash
<dlovell_> rvm install ruby-1.9.3-p448
<postmodern> basically, you have plenty of viable options
<dlovell_> I don't mind using root
<postmodern> all of which are 2-3 commands
<dlovell_> and in fact, am curious how they did the root part
<dlovell_> I'm about to release some stuff that is currently a two part install
<dlovell_> root and then user
felixjet_ has joined #ruby
chrisja has quit [Quit: leaving]
<dlovell_> but if I could query the user for sudo passwd, that would be good
snovak has quit [Ping timeout: 264 seconds]
JumpMast3r has joined #ruby
dankest has quit [Quit: dankest]
saarinen has quit [Quit: saarinen]
felixjet has quit [Ping timeout: 260 seconds]
saarinen has joined #ruby
io_syl has joined #ruby
hydrozen has joined #ruby
sloucher has quit [Quit: sloucher]
thesheff17 has joined #ruby
appendonly has joined #ruby
peregrine81 has joined #ruby
nari has joined #ruby
clov3r has quit [Remote host closed the connection]
Ox6abe has quit [Remote host closed the connection]
knigitz has quit [Read error: Connection reset by peer]
kvirani has quit [Remote host closed the connection]
knigitz has joined #ruby
kvirani has joined #ruby
cody-- has quit [Quit: derp]
knigitz has quit [Read error: Connection reset by peer]
michalkozminski has joined #ruby
sambao21 has joined #ruby
iliketurtles has quit [Quit: zzzzz…..]
aeontech has quit [Quit: aeontech]
P1RATEZ has quit []
JohnE has quit [Ping timeout: 260 seconds]
dagnachew has quit [Quit: WeeChat 0.4.1]
AdmiraI has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dagnachew has joined #ruby
Croms has joined #ruby
kvirani has quit [Ping timeout: 276 seconds]
sambao21 has quit [Read error: Connection reset by peer]
dodosan has joined #ruby
Croms has quit [Quit: Croms]
<dlovell_> awesome, it worked
<dlovell_> thanks all for the suggestions
<xybre> woot
julweber_ has joined #ruby
iamjarvo has quit [Quit: Leaving.]
rins has joined #ruby
d34th4ck3r has joined #ruby
julweber has quit [Ping timeout: 264 seconds]
iamjarvo has joined #ruby
clov3r has joined #ruby
DanKnox is now known as DanKnox_away
Urizen has quit [Ping timeout: 264 seconds]
xjiujiu has joined #ruby
ixti has quit [Ping timeout: 248 seconds]
ssvo has joined #ruby
radic_ has joined #ruby
jonahR has joined #ruby
EvolutionXJ has joined #ruby
hydrozen has quit [Quit: Computer has gone to sleep.]
rins has quit [Ping timeout: 276 seconds]
forced_request has quit [Read error: Connection reset by peer]
Aryasam has joined #ruby
radic__ has quit [Ping timeout: 240 seconds]
browndawg1 has joined #ruby
zjc has joined #ruby
EvolutionXJ has quit [Quit: Leaving]
sailias has quit [Ping timeout: 248 seconds]
hydrozen has joined #ruby
mercwithamouth has quit [Ping timeout: 264 seconds]
__username__ has quit [Ping timeout: 264 seconds]
saarinen has quit [Quit: saarinen]
tjbiddle_ has joined #ruby
saarinen has joined #ruby
Aryasam has quit [Read error: Connection reset by peer]
Aryasam has joined #ruby
tjbiddle has quit [Ping timeout: 245 seconds]
tjbiddle_ is now known as tjbiddle
browndawg has quit [Ping timeout: 256 seconds]
dallasm has quit []
mlpinit has quit [Remote host closed the connection]
Targen has quit [Read error: Operation timed out]
T_T has joined #ruby
simoz has joined #ruby
ssvo has quit [Ping timeout: 245 seconds]
clov3r has quit [Remote host closed the connection]
danman has joined #ruby
danman has quit [Client Quit]
Seich has quit [Quit: Computer has gone to sleep.]
simoz has quit [Ping timeout: 245 seconds]
mercwithamouth has joined #ruby
ewnd9 has joined #ruby
dagnachew has quit [Quit: WeeChat 0.4.1]
peregrine81 has quit []
hydrozen has quit [Ping timeout: 260 seconds]
NealJ has quit [Quit: :c]
Cyrus has joined #ruby
pierre1 has joined #ruby
dankest has joined #ruby
endash has quit [Quit: endash]
selim has joined #ruby
mary5030 has joined #ruby
iamjarvo has quit [Quit: Leaving.]
aagdbl has joined #ruby
zjc has quit [Quit: Lost terminal]
dkamioka has joined #ruby
snovak has joined #ruby
ericmathison has quit [Quit: Lost terminal]
iliketurtles has joined #ruby
alexju has quit [Remote host closed the connection]
Monie has joined #ruby
DanKnox_away is now known as DanKnox
selim has quit [Ping timeout: 248 seconds]
jonahR has quit [Quit: jonahR]
Seich has joined #ruby
snovak has quit [Ping timeout: 276 seconds]
ndngvr has quit [Ping timeout: 240 seconds]
ndngvr` has joined #ruby
headius has joined #ruby
varfoo has joined #ruby
browndawg1 has quit [Quit: Leaving.]
agent_white has quit [Quit: leaving]
iamjarvo has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
Seich has quit [Ping timeout: 245 seconds]
eka has quit [Quit: Computer has gone to sleep.]
iamjarvo has quit [Client Quit]
vlad_starkov has joined #ruby
dankest has quit [Quit: dankest]
aagdbl has quit [Quit: Leaving.]
iamjarvo has joined #ruby
pontiki has quit [Quit: "Poets have been mysteriously silent on the subject of cheese." -- G.K.Chesterson]
AdmiraI has joined #ruby
aagdbl has joined #ruby
varfoo has quit [Quit: WeeChat 0.4.0]
dankest has joined #ruby
yaymukund has quit [Ping timeout: 276 seconds]
taternuts has quit [Ping timeout: 245 seconds]
simoz has joined #ruby
mwmnj has joined #ruby
Urizen has joined #ruby
vlad_starkov has quit [Ping timeout: 245 seconds]
<yfeldblum> does ruby ship with ecc curve25519?
iamjarvo has quit [Ping timeout: 256 seconds]
freerobby has quit [Quit: Leaving.]
ssvo has joined #ruby
alvaro_o has quit [Quit: Ex-Chat]
Seich has joined #ruby
alexju has joined #ruby
cj3kim_ has joined #ruby
stkowski has joined #ruby
thecodethinker has joined #ruby
Targen has joined #ruby
casheew_ has joined #ruby
mmozuras_ has joined #ruby
<heftig> yfeldblum: does openssl?
Niamkik_ has joined #ruby
cj3kim_ has quit [Ping timeout: 260 seconds]
jacobat_ has joined #ruby
Seich has quit [Ping timeout: 245 seconds]
joschi has joined #ruby
BeanDip__ has joined #ruby
vadviktor__ has joined #ruby
airtonix_ has joined #ruby
emdub_ has joined #ruby
m_3 has joined #ruby
paul__k has joined #ruby
rtl_ has joined #ruby
havenwood has quit [Remote host closed the connection]
[lewellyn] has joined #ruby
Scorchin_ has joined #ruby
bartj3_ has joined #ruby
mumblet has joined #ruby
zeroXten_ has joined #ruby
mpereira_ has joined #ruby
lancepantz_ has joined #ruby
undert- has joined #ruby
Lindrian_ has joined #ruby
niftylettuce has quit [*.net *.split]
Kneferilis has quit [*.net *.split]
Scorchin has quit [*.net *.split]
joschi_ has quit [*.net *.split]
Guest65452 has quit [*.net *.split]
araujo has quit [*.net *.split]
m_3_ has quit [*.net *.split]
mpereira has quit [*.net *.split]
rtl has quit [*.net *.split]
braincra- has quit [*.net *.split]
Lindrian has quit [*.net *.split]
undert has quit [*.net *.split]
paul_k has quit [*.net *.split]
mmozuras has quit [*.net *.split]
jeekl has quit [*.net *.split]
mattp_ has quit [*.net *.split]
aggregatebot has quit [*.net *.split]
casheew has quit [*.net *.split]
lancepantz has quit [*.net *.split]
didlix has quit [*.net *.split]
mumblerit has quit [*.net *.split]
Niamkik has quit [*.net *.split]
noxgirl has quit [*.net *.split]
airtonix has quit [*.net *.split]
shtirlic has quit [*.net *.split]
zz_dbRenaud has quit [*.net *.split]
zeroXten has quit [*.net *.split]
keeeh has quit [*.net *.split]
emdub has quit [*.net *.split]
lewellyn has quit [*.net *.split]
bartj3 has quit [*.net *.split]
jacobat has quit [*.net *.split]
billy_ran_away has quit [*.net *.split]
BeanDip_ has quit [*.net *.split]
cliffstah has quit [*.net *.split]
maloik has quit [*.net *.split]
vadviktor_ has quit [*.net *.split]
lancepantz_ is now known as lancepantz
mumblet is now known as mumblerit
shtirlic_ has joined #ruby
didlix has joined #ruby
Alina-malina has quit [Ping timeout: 248 seconds]
braincrash has joined #ruby
autumn has joined #ruby
billy_ran_away_ has joined #ruby
felixjet_ has quit [Read error: No buffer space available]
RealMarc is now known as Marc
machuga is now known as machuga|away
thecodethinker has quit [Ping timeout: 276 seconds]
mattp_ has joined #ruby
mumblerit is now known as Guest91255
cliffstah has joined #ruby
zz_dbRenaud has joined #ruby
Marc is now known as Guest9012
Alina-malina has joined #ruby
hydrozen has joined #ruby
maloik has joined #ruby
felixjet_ has joined #ruby
[lewellyn] is now known as lewellyn
mdst has quit [Read error: Connection reset by peer]
mdst has joined #ruby
__username__ has joined #ruby
araujo_ has joined #ruby
headius has quit [Ping timeout: 275 seconds]
sumark has quit [Ping timeout: 240 seconds]
sumark has joined #ruby
araujo_ has quit [Read error: Connection reset by peer]
bartj3_ is now known as bartj3
keee has joined #ruby
Scorchin_ is now known as Scorchin
iamjarvo has joined #ruby
thecodethinker has joined #ruby
mrsolo has joined #ruby
iliketurtles has quit [Quit: zzzzz…..]
mwmnj has quit [Ping timeout: 245 seconds]
iliketurtles has joined #ruby
dlovell_ has quit [Quit: leaving]
fflush has quit [Remote host closed the connection]
Domon has quit [Remote host closed the connection]
Domon has joined #ruby
Guest91255 is now known as mumblerit
Ubercow has joined #ruby
Spami has quit [Quit: This computer has gone to sleep]
hogeo has quit [Remote host closed the connection]
rezzack1 has joined #ruby
jeekl has joined #ruby
Domon has quit [Ping timeout: 248 seconds]
Guest65452 has joined #ruby
rezzack has quit [Ping timeout: 245 seconds]
araujo has joined #ruby
soba has joined #ruby
Bira has joined #ruby
Domon has joined #ruby
pierre1 has quit [Ping timeout: 245 seconds]
nadirvardar has joined #ruby
iamjarvo has quit [Remote host closed the connection]
Aryasam has quit [Ping timeout: 245 seconds]
freerobby has joined #ruby
iamjarvo has joined #ruby
simoz has quit [Ping timeout: 256 seconds]
Aryasam has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
freerobby has quit [Ping timeout: 256 seconds]
fgo has joined #ruby
<xybre> Ruby doesn't do crypto on its own, it uses the standard libaries like SSL and NaCl.
dhruvasagar has quit [Ping timeout: 276 seconds]
clov3r has joined #ruby
dankest has quit [Quit: dankest]
fgo has quit [Remote host closed the connection]
clov3r has quit [Read error: Connection reset by peer]
Aryasam has quit [Ping timeout: 256 seconds]
snovak has joined #ruby
Aryasam has joined #ruby
fgo_ has joined #ruby
xiphiasx_ has quit [Quit: bye for now]
huoxito has joined #ruby
dankest has joined #ruby
lfox has joined #ruby
Aryasam_ has joined #ruby
Aryasam has quit [Read error: Connection reset by peer]
snovak has quit [Ping timeout: 256 seconds]
iamjarvo1 has joined #ruby
dodosan has quit [Ping timeout: 245 seconds]
dodosan has joined #ruby
dankest has quit [Quit: Peace]
mercwithamouth has quit [Ping timeout: 276 seconds]
Minos__ has joined #ruby
Lewix has joined #ruby
iamjarvo1 has quit [Ping timeout: 264 seconds]
browndawg has joined #ruby
fomatin has quit [Quit: Computer has gone to sleep.]
tomzx_mac has quit [Ping timeout: 264 seconds]
saarinen has quit [Quit: saarinen]
aagdbl has quit [Quit: Leaving.]
Fin1te has joined #ruby
kstephens has quit [Read error: Connection reset by peer]
kstephens has joined #ruby
niftylettuce has joined #ruby
cj3kim_ has joined #ruby
havenwood has joined #ruby
thecodethinker has quit [Ping timeout: 245 seconds]
dodosan has quit [Read error: Connection timed out]
dankest has joined #ruby
dodosan has joined #ruby
dankest has quit [Client Quit]
Splourian has joined #ruby
c0rn has quit [Quit: Computer has gone to sleep.]
cj3kim_ has quit [Ping timeout: 264 seconds]
ner0x has quit [Quit: Leaving]
zephdev has joined #ruby
havenwood has quit [Read error: Connection reset by peer]
lfox has quit [Quit: ZZZzzz…]
mercwithamouth has joined #ruby
mary5030 has quit [Remote host closed the connection]
JesseH has quit [Ping timeout: 264 seconds]
mary5030 has joined #ruby
hydrozen has quit [Quit: Computer has gone to sleep.]
aagdbl has joined #ruby
xjiujiu has quit [Ping timeout: 245 seconds]
yacks has quit [Quit: Leaving]
dodosan has quit [Remote host closed the connection]
huoxito has quit [Quit: Leaving]
ta has quit [Read error: Connection reset by peer]
ta has joined #ruby
julian-delphiki has joined #ruby
Fin1te has quit [Quit: Later tater.]
vxxr has quit [Quit: leaving]
simoz has joined #ruby
bean has quit [Ping timeout: 245 seconds]
consolationprize has joined #ruby
fgo_ has quit [Remote host closed the connection]
consolationprize has left #ruby [#ruby]
felixjet_ has quit [Quit: felixjet_]
felixjet has joined #ruby
macmartine has joined #ruby
polaco is now known as polaco_zZz
mansi has joined #ruby
fridim__ has quit [Ping timeout: 276 seconds]
osvico has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
mansi has quit [Remote host closed the connection]
m00nlight has joined #ruby
simoz has quit [Ping timeout: 256 seconds]
mansi has joined #ruby
baroquebobcat has joined #ruby
iamjarvo_ has joined #ruby
T_T has quit [Remote host closed the connection]
freerobby has joined #ruby
Seich has joined #ruby
Aryasam_ has quit [Ping timeout: 256 seconds]
iamjarvo has quit [Ping timeout: 256 seconds]
mansi has quit [Ping timeout: 245 seconds]
baroquebobcat has quit [Client Quit]
Deele has joined #ruby
fomatin has joined #ruby
lukec has quit [Quit: lukec]
zeropx has joined #ruby
Seich has quit [Client Quit]
freerobby has quit [Ping timeout: 260 seconds]
mikepack has joined #ruby
Domon has quit [Remote host closed the connection]
Domon has joined #ruby
iamjarvo has joined #ruby
codezombie has quit [Ping timeout: 256 seconds]
snovak has joined #ruby
Domon has quit [Ping timeout: 245 seconds]
appendonly has left #ruby [#ruby]
mrsolo has joined #ruby
alexju has quit [Remote host closed the connection]
sayan has joined #ruby
kobain has quit []
alexju has joined #ruby
alexju has quit [Read error: Connection reset by peer]
jprovazn has joined #ruby
alexju has joined #ruby
iamjarvo has quit [Ping timeout: 276 seconds]
dodosan has joined #ruby
marcgg has quit [Read error: Connection reset by peer]
marcgg has joined #ruby
snovak has quit [Ping timeout: 264 seconds]
aagdbl has quit [Quit: Leaving.]
Aryasam has joined #ruby
aryaching has joined #ruby
dmiller has quit [Remote host closed the connection]
Arreis has joined #ruby
yekta has quit [Quit: yekta]
Aryasam has quit [Quit: Bye]
fgo has joined #ruby
Lewix has quit [Remote host closed the connection]
ananthakumaran has joined #ruby
zephdev has quit [Remote host closed the connection]
browndawg has left #ruby [#ruby]
noop has joined #ruby
|jemc| has quit [Quit: WeeChat 0.4.1]
|jemc| has joined #ruby
intuxicated has joined #ruby
zeade has quit [Quit: Leaving.]
ssvo has quit [Ping timeout: 245 seconds]
moli has joined #ruby
jprovazn has quit [Ping timeout: 248 seconds]
dhruvasagar has joined #ruby
girija has joined #ruby
baroquebobcat has joined #ruby
bean has joined #ruby
__username__ has quit [Ping timeout: 256 seconds]
dodosan has quit [Remote host closed the connection]
cj3kim_ has joined #ruby
iamjarvo_ has quit [Remote host closed the connection]
cutmail has joined #ruby
tomsthumb has quit [Ping timeout: 276 seconds]
iamjarvo has joined #ruby
julian-delphiki has quit [Ping timeout: 276 seconds]
mary5030 has quit [Remote host closed the connection]
cj3kim_ has quit [Ping timeout: 248 seconds]
ukd1 has quit [Remote host closed the connection]
iamjarvo has quit [Ping timeout: 248 seconds]
aagdbl has joined #ruby
bricker`LA has quit [Ping timeout: 245 seconds]
codecop has joined #ruby
schaerli has joined #ruby
sarlalian has joined #ruby
Ripp__ has joined #ruby
kil0byte has quit [Remote host closed the connection]
alexju has quit [Remote host closed the connection]
butblack has quit [Quit: butblack]
alexju has joined #ruby
byprdct has joined #ruby
byprdct has quit [Max SendQ exceeded]
DanKnox is now known as DanKnox_away
nadirvardar has quit [Quit: Computer has gone to sleep.]
aryaching has quit [Ping timeout: 256 seconds]
tobago has joined #ruby
schaerli has quit [Remote host closed the connection]
Arreis has quit [Read error: Connection reset by peer]
sarlalian has quit [Ping timeout: 248 seconds]
aagdbl1 has joined #ruby
aagdbl has quit [Ping timeout: 256 seconds]
alexju_ has joined #ruby
alexju has quit [Ping timeout: 256 seconds]
Arreis has joined #ruby
codecop has quit [Remote host closed the connection]
popl has joined #ruby
codecop has joined #ruby
mansi has joined #ruby
tjbiddle has quit [Quit: tjbiddle]
ananthakumaran has quit [Quit: Leaving.]
Urizen has quit [Ping timeout: 264 seconds]
baroquebobcat has quit [Quit: baroquebobcat]
macmartine has quit [Quit: Computer has gone to sleep.]
freerobby has joined #ruby
cfi30 has quit [Quit: WeeChat 0.4.1]
popl has quit [Quit: We must make an idol of our fear, and call it God.]
mansi has quit [Ping timeout: 248 seconds]
mikepack has quit [Remote host closed the connection]
brianpWins has joined #ruby
Domon has joined #ruby
tagrudev has joined #ruby
tjad has joined #ruby
iamjarvo has joined #ruby
ewnd9 has quit [Remote host closed the connection]
freerobby has quit [Ping timeout: 248 seconds]
Urizen has joined #ruby
m00nlight has quit [Remote host closed the connection]
m00nlight has joined #ruby
mansi has joined #ruby
iamjarvo has quit [Ping timeout: 256 seconds]
intuxicated_ has joined #ruby
braoru has joined #ruby
soba has quit [Ping timeout: 264 seconds]
intuxicated has quit [Quit: Leaving]
intuxicated_ has quit [Client Quit]
intuxicated has joined #ruby
mansi has quit [Ping timeout: 245 seconds]
fomatin has quit [Quit: Computer has gone to sleep.]
fgo has quit [Ping timeout: 260 seconds]
snovak has joined #ruby
m00nlight has quit [Read error: Connection reset by peer]
m00nlight has joined #ruby
m00nlight has quit [Read error: Connection reset by peer]
m00nlight has joined #ruby
Seich has joined #ruby
snovak has quit [Ping timeout: 245 seconds]
<|jemc|> anybody here have a good grasp of the use of MonitorMixin::ConditionVariable ?
alexju_ has quit [Remote host closed the connection]
yfeldblum has quit [Ping timeout: 264 seconds]
JesseH has joined #ruby
<|jemc|> I'm trying to use one, and having problems doing so
alexju has joined #ruby
Seich has quit [Ping timeout: 245 seconds]
<|jemc|> but the example deadlocks for me
Bira has quit [Remote host closed the connection]
<|jemc|> (the fourth code block on the page; the first using #new_cond)
thecodethinker has joined #ruby
codecop has quit [Remote host closed the connection]
ericmathison has joined #ruby
<|jemc|> to me it makes sense that it would deadlock, given that both the waiting block in the waiting thread and the signalling block in the signalling thread are trying to acquire the same monitor
<bnagy> I've never seen or heard of that
<|jemc|> yeah, it doesn
<bnagy> and it looks like a weird approach
<|jemc|> 't seem well documented
<|jemc|> and yeah, it's a very forced example
<|jemc|> but I'm curious about the correct way to be using this object
alexju has quit [Ping timeout: 248 seconds]
ananthakumaran has joined #ruby
Banistergalaxy has quit [Ping timeout: 264 seconds]
DanKnox_away is now known as DanKnox
codecop has joined #ruby
<|jemc|> hm. it looks like the wait method actually releases the lock, despite being inside the #synchronize block
DanKnox is now known as DanKnox_away
<|jemc|> and it even raises if it's not the current owner at call time
<bnagy> that makes sense to me now
m00nlight has quit [Remote host closed the connection]
<bnagy> I was wondering why I never heard of it - on the rare occasions I use a mutex I don't need it reentrant
<|jemc|> oh, you hadn
ehaliewicz has quit [Remote host closed the connection]
<|jemc|> 't heard of Monitor
<|jemc|> I thought you meant you hadn't heard of MonitorMixin::ConditionVariable
dodosan has joined #ruby
<bnagy> or that :)
<|jemc|> but yeah, I've got a good grasp on the re-entrancy
<|jemc|> unfortunately that link doesn't mention #new_cond at all...
threeturn has joined #ruby
<|jemc|> which is the nearly undocumented feature of Monitor I'm trying to find out about
<|jemc|> I mean, there's an rdoc for it (http://ruby-doc.org/stdlib-2.0/libdoc/monitor/rdoc/MonitorMixin/ConditionVariable.html), but very little explanation and no use case
JumpMast3r has quit [Quit: JumpMast3r]
awarner_ has joined #ruby
Bosox20051 has joined #ruby
RichardBaker has joined #ruby
<bnagy> so this is just academic curiosity, right?
<|jemc|> mostly so
awarner has quit [Ping timeout: 276 seconds]
<|jemc|> but I might use it if it ends up working how I want it to
<bnagy> ok :)
iliketurtles has quit [Quit: zzzzz…..]
freerobby has joined #ruby
speakingcode-wor has quit [Ping timeout: 276 seconds]
<|jemc|> ha. found another 'resource'. would be more helpful if the comments were in my language (http://doc.ruby-lang.org/ja/1.8.7/class/MonitorMixin.html)
speakingcode-wor has joined #ruby
ayaz has joined #ruby
prometheanfire has left #ruby [#ruby]
T_T has joined #ruby
<|jemc|> at least that example isn't deadlocking for me
iliketurtles has joined #ruby
Xeago has joined #ruby
freerobby has quit [Ping timeout: 256 seconds]
m00nlight has joined #ruby
coderhs has joined #ruby
aganov has joined #ruby
fgo has joined #ruby
ta has quit [Remote host closed the connection]
ananthakumaran1 has joined #ruby
ananthakumaran1 has quit [Read error: Connection reset by peer]
ananthakumaran1 has joined #ruby
ananthakumaran has quit [Read error: Connection reset by peer]
Xeago has quit [Remote host closed the connection]
beneggett has joined #ruby
tziOm has joined #ruby
<beneggett> Anyone know of any great resources for explaining OOP to some programming beginners? (ideally easy to understand videos, or the like)
<beneggett> if the context is Ruby based, all the better..
powerhead has left #ruby [#ruby]
hamakn has quit [Read error: Connection reset by peer]
hamakn has joined #ruby
fgo has quit [Ping timeout: 256 seconds]
corpuscle has joined #ruby
ananthakumaran1 has quit [Ping timeout: 264 seconds]
ananthakumaran has joined #ruby
lemonsparrow has joined #ruby
ananthakumaran has quit [Max SendQ exceeded]
ananthakumaran has joined #ruby
<mercwithamouth> is anyone here reading or already read Kestrels, Quirky Birds, and Hopeless Egocentricity???
<|jemc|> bnagy: I think I finally got it doing my bidding. it's actually pretty elegant in this context
<bnagy> I think we may be about to disagree, but gist code :)
<|jemc|> well, it's in a larger context that is at the moment really messy
<|jemc|> let me clean up a bit and I'll link it to you
Ubercow has quit [Quit: Computer has gone to sleep.]
<|jemc|> it's basically a way to avoid busywaiting
<|jemc|> I've got a future events scheduler that should be sleeping between events
<|jemc|> but combinations of sleep and logic are always a little thread-unsafe unless the decision to sleep is atomic with the sleep itself
RichardBaker has quit [Quit: RichardBaker]
tjad has quit [Read error: Connection reset by peer]
tjad has joined #ruby
user258467 has joined #ruby
<|jemc|> that is to say, 'sleep unless @dont_sleep' has a small 'gap' in which an interrupting thread that changes the value of @dont_sleep could screw you up
sarkis has quit [Ping timeout: 256 seconds]
Ubercow has joined #ruby
Ubercow has quit [Max SendQ exceeded]
<|jemc|> and if you surround that operation with a lock to keep it from being interrupted, that thread holds the lock throughout sleep
zephdev has joined #ruby
<|jemc|> which means you can't acquire it in the thread that should wake it from sleep if a new future event is scheduled
Teddy2steper has joined #ruby
RichardBaker has joined #ruby
stkowski has quit [Quit: stkowski]
<|jemc|> so I think the only solution is to tie into the lock object itself
<|jemc|> which I think I'm accomplishing properly with this #new_cond feature of Monitor
yllox has quit [Quit: Bye!]
LMolr has joined #ruby
<bnagy> woop, gtg
<bnagy> but drop the link whenever, sounds interesting
rezzack1 has quit [Quit: Leaving.]
iamjarvo has joined #ruby
<|jemc|> yeah, I'd be happy to get feedback
<|jemc|> g'night
somnambulically0 has quit [Quit: somnambulically0]
ru has joined #ruby
ru has quit [Client Quit]
underway47 has joined #ruby
oliver_ has joined #ruby
Monie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
end_guy has joined #ruby
iamjarvo has quit [Ping timeout: 264 seconds]
Teddy2steper has quit [Remote host closed the connection]
end_guy_ has quit [Ping timeout: 240 seconds]
aagdbl1 has quit [Quit: Leaving.]
ta has joined #ruby
razi has joined #ruby
zephdev has quit [Remote host closed the connection]
iliketurtles has quit [Quit: zzzzz…..]
threeturn has quit [Quit: threeturn]
mansi has joined #ruby
|jemc| has quit [Ping timeout: 276 seconds]
Teddy2steper has joined #ruby
sayan has quit [Ping timeout: 256 seconds]
workmad3 has joined #ruby
mansi has quit [Ping timeout: 256 seconds]
sr78ger has joined #ruby
buibex has joined #ruby
snovak has joined #ruby
toah has joined #ruby
chihhsin has quit [Quit: leaving]
chihhsin has joined #ruby
snovak has quit [Ping timeout: 276 seconds]
workmad3 has quit [Ping timeout: 264 seconds]
T_T has quit [Remote host closed the connection]
relix has joined #ruby
mrsolo has quit [Quit: Leaving]
noop has quit [Ping timeout: 264 seconds]
chopmo has joined #ruby
threeturn has joined #ruby
andikr has joined #ruby
AdmiraI has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
threeturn has quit [Client Quit]
noop has joined #ruby
clocKwize has joined #ruby
tjad has quit [Ping timeout: 245 seconds]
ehaliewicz has joined #ruby
parzo has quit [Ping timeout: 256 seconds]
filipe has joined #ruby
funburn has quit [Quit: funburn]
persand has joined #ruby
ahawkins has joined #ruby
vlad_starkov has joined #ruby
Arreis has quit [Read error: Connection reset by peer]
Arreis has joined #ruby
RichardBaker has quit [Quit: RichardBaker]
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
freerobby has joined #ruby
Elhu has joined #ruby
BadQuanta has quit [Quit: Leaving]
Ripp__ has quit []
headius has joined #ruby
Teddy2steper has quit [Remote host closed the connection]
cutmail has quit [Remote host closed the connection]
Arreis has quit [Read error: Connection reset by peer]
schaerli has joined #ruby
cutmail has joined #ruby
ewnd9 has joined #ruby
fgo has joined #ruby
ru has joined #ruby
c0rn has joined #ruby
apeiros has joined #ruby
Arreis has joined #ruby
_maes_ has joined #ruby
claymore has joined #ruby
dangerousdave has joined #ruby
cutmail has quit [Ping timeout: 245 seconds]
fgo has quit [Ping timeout: 245 seconds]
hanmac has joined #ruby
<ru> Hi, n00b question here - if I have a completely static class (just using class as a namespace for methods), is it better to `extend self`, or to write `self.x` in the `def` statement for every method?
tjad has joined #ruby
<apeiros> ru: you can't use extend with a class. the argument to Object#extend must be a module.
<apeiros> and IMO extend self is an anti-pattern. use module_function instead. that's how core modules like Kernel and Math do it.
cutmail has joined #ruby
<ru> gah sorry - coming from python/php background - module is what I meant.
<apeiros> it works like private/protected, means you can just write it once and all subsequently defined methods become module functions.
jamesfung14 has joined #ruby
<apeiros> e.g. module X; module_function; def foo; end; def bar; end; end
toah has quit [Ping timeout: 248 seconds]
<apeiros> advantage over extend self: the instance method variant is private, the class method variant is public. that way you don't mess with method_missing when you include/extend it somewhere.
Xeago has joined #ruby
alup has joined #ruby
_maes_ has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
justsee has joined #ruby
justsee has joined #ruby
gyzmodo has joined #ruby
Spami has quit [Quit: This computer has gone to sleep]
<ru> apeiros: so with the example you gave, what is `module_function` ? I understand that module X contains it, and `foo` is a method within it, but what would module_function.kind_of? give me?
Splourian has quit [Quit: Leaving]
yrp has quit [Quit: Page closed]
Spami has joined #ruby
<xybre> ru: module_function is a "directive" like "private" or "public", but it defines all following methods in two places, 1 privately on the "instance" space, and publically in the "class" (eigenclass) space.
sayan has joined #ruby
tesuji has joined #ruby
camilasan has joined #ruby
threeturn has joined #ruby
jkline has joined #ruby
<jkline> What does question mark mean in these contexts ? `if first == ?~`
<jkline> `when ?/`
rdark has joined #ruby
threesome has joined #ruby
beneggett has quit [Quit: Textual IRC Client: www.textualapp.com]
thecodethinker has quit [Ping timeout: 264 seconds]
aloshkarev has joined #ruby
<ru> jkline: the ascii code of tilde
<ru> >> p ?~
<ru> 126
<eval-in> ru => "~" ... (https://eval.in/49077)
<ru> => nil
Urizen has quit [Ping timeout: 248 seconds]
<ru> err, yeah. sorry new to irc.
<jkline> ru: huh. Ok. What operator is that?
<jkline> >> p ?a
<eval-in> jkline => "a" ... (https://eval.in/49078)
ewnd9 has quit [Remote host closed the connection]
threesome has quit [Max SendQ exceeded]
aeontech has joined #ruby
cj3kim has joined #ruby
<xybre> The question mark is a parser hint that the next character is a single character string. Its basically the same as '~'.
threesome has joined #ruby
<jkline> interesting
dash_ has joined #ruby
<jkline> ru: the ascii code of tilde? How do you get that?
<xybre> Maybe ru is using 1.8?
<ru> I am. apologies if it caused any confusion.
<xybre> Ahh. It's been like 5 years since I touched 1.8 :)
noop has quit [Ping timeout: 245 seconds]
<xybre> I swear there was some way to use ?x notation to specify control characters.
<xybre> But I can't figure out how.
brtdv has joined #ruby
<ru> really? lucky bastard.. I am doomed to the distributions shipped with the OS, which in almost any case is 1.8 in any enterprise-ready distro I know of.
julweber_ has quit [Remote host closed the connection]
<ru> maybe ubuntu has 1.9.3
<xybre> Ew. Why?
wallerdev has quit [Quit: wallerdev]
<jkline> ok, i see the 1.8 vs 1.9 difference now
hkon has joined #ruby
<ru> i work for cisco ... :x
ephemerian has joined #ruby
<xybre> :(
<jkline> in what city?
<ru> san jose CA
<jkline> if you come work with me you can use ruby 1.9… :)
oliver_ has quit [Remote host closed the connection]
* xybre is in SF
* jkline is also in SF
aagdbl has joined #ruby
Coffers has joined #ruby
ewnd9 has joined #ruby
<ru> yeah stay up there. you guys make cool stuff, then it wafts down to the slums in SJ.
jinie has quit [*.net *.split]
flowerhack_ has quit [*.net *.split]
LBRapid has quit [*.net *.split]
kaichanvong has quit [*.net *.split]
maroloccio has quit [*.net *.split]
C0deMaver1ck has quit [*.net *.split]
mark| has quit [*.net *.split]
ddv has quit [*.net *.split]
dangerousdave has quit [Quit: Leaving...]
ddv has joined #ruby
<xybre> Yeah I don't plan on leaving yet :)
C0deMaver1ck has joined #ruby
kaichanvong has joined #ruby
LBRapid has joined #ruby
mansi has joined #ruby
flowerhack_ has joined #ruby
flowerhack_ has quit [Changing host]
flowerhack_ has joined #ruby
C0deMaver1ck is now known as Guest67358
<jkline> well, to be fare, it wafted north first
<jkline> fair?
<jkline> \ferry?
m00nlight has quit [Read error: No route to host]
mark- has joined #ruby
<ru> so what is your take on code climate? I thought it was cool when I tried it out, but my first gem did not detect anything about "yo dawg, dont extend self if you dont have to"
jinie has joined #ruby
<ru> is it completely biased?
freeayu has joined #ruby
aagdbl has quit [Client Quit]
<xybre> I dig CodeClimate
<apeiros> I see little value in such tools
maroloccio has joined #ruby
m00nlight has joined #ruby
<xybre> Especially for pointing out complexity of classes and methods
<apeiros> but that might be because IMO they're often used inappropriately. as source of "truth", where they're really a guide at max.
<xybre> Yeah, metrics often become chains, when they should be tools.
aryaching has joined #ruby
<ru> ok yeah i can see what both of you are saying. I definitely noticed it caught any ghetto stuff easily, but it definitely didnt check best practices.
<ru> i started ruby like a month ago and it told me on first run my project was a 4.0, which ... yeah you get it. haha
<xybre> Yeah there are other tools for that. Check out Rubocop, but take it with a grain of salt.
mansi has quit [Ping timeout: 245 seconds]
<Boohbah> i try to follow worst practices
<xybre> Well, CodeClimate only detects a few things, and if your project is small and new, it'll probably be a 4.
<xybre> That will often change as your project grows. The ROM.rb guys follow that suff religiously though, so even though they're making huge complex tools, they enforce the metrics.
oliver_ has joined #ruby
gstamp has quit [Quit: Computer has gone to sleep.]
razi has quit [Ping timeout: 245 seconds]
<xybre> >> ?\u2404
<eval-in> xybre => "␄" (https://eval.in/49079)
snovak has joined #ruby
kilophoton has quit [Ping timeout: 264 seconds]
timonv has joined #ruby
Es0teric has quit [Quit: Computer has gone to sleep.]
noop has joined #ruby
snovak has quit [Ping timeout: 245 seconds]
oliver_ has quit [Remote host closed the connection]
ta has quit [Ping timeout: 276 seconds]
coderhs has quit [Remote host closed the connection]
aeontech has quit [Quit: aeontech]
<ru> alright gentlement, i must adjourn. thanks for the tips. beers on me. ttyl
ru has quit [Quit: leaving]
krz has joined #ruby
cam`_ has quit [Ping timeout: 260 seconds]
bluehavana has quit [Ping timeout: 260 seconds]
ix007 has quit [Ping timeout: 260 seconds]
m00nlight has quit [Remote host closed the connection]
flori_ has quit [Ping timeout: 262 seconds]
Martz^ has joined #ruby
m00nlight has joined #ruby
rhys has quit [Ping timeout: 263 seconds]
framling has quit [Ping timeout: 263 seconds]
Drakevr has quit [Ping timeout: 263 seconds]
ix007 has joined #ruby
flori has joined #ruby
XenoWolf has quit [Ping timeout: 260 seconds]
framling has joined #ruby
XenoWolf has joined #ruby
coderhs has joined #ruby
Martz has quit [Ping timeout: 258 seconds]
Martz^ is now known as Martz
Martz has quit [Changing host]
Martz has joined #ruby
canton7 has quit [Remote host closed the connection]
canton7 has joined #ruby
timonv has quit [Remote host closed the connection]
s0ny123 has joined #ruby
k0rupted has quit [Ping timeout: 260 seconds]
RTG` has joined #ruby
Spami has quit [Quit: This computer has gone to sleep]
caveat- has quit [Ping timeout: 248 seconds]
decoponio has joined #ruby
threeturn has quit [Quit: threeturn]
mercwithamouth has quit [Ping timeout: 256 seconds]
yeltzooo has joined #ruby
threeturn has joined #ruby
ghr has joined #ruby
ta has joined #ruby
threeturn has quit [Client Quit]
k0rupted has joined #ruby
caveat- has joined #ruby
zeroXten_ is now known as zeroXten
St_Marx has joined #ruby
hkon has quit [Read error: Connection reset by peer]
timonv has joined #ruby
allsystemsarego has joined #ruby
allsystemsarego has joined #ruby
senayar has joined #ruby
senayar has quit [Remote host closed the connection]
senayar has joined #ruby
kaspergrubbe has joined #ruby
hkon has joined #ruby
radic_ has quit [Quit: Verlassend]
rhys has joined #ruby
RDash[AW] is now known as RDash
fgo has joined #ruby
blackmesa has joined #ruby
m00nlight has quit [Remote host closed the connection]
barratt has joined #ruby
m00nlight has joined #ruby
tatsuya_o has joined #ruby
fgo has quit [Ping timeout: 256 seconds]
ferdev has quit [Quit: ferdev]
dash_ has quit [Quit: dash_]
jkline has quit [Quit: jkline]
radic has joined #ruby
yeltzooo6 has quit [Ping timeout: 260 seconds]
jonkri has joined #ruby
hkon has quit [Read error: Connection reset by peer]
oliver_ has joined #ruby
LMolr has quit [Ping timeout: 245 seconds]
dangerousdave has joined #ruby
codecop has quit [Read error: Operation timed out]
codecop has joined #ruby
Nenor has joined #ruby
shaunbaker has joined #ruby
shaunbak_ has joined #ruby
radic has quit [Quit: Verlassend]
camilasan has quit [Remote host closed the connection]
camilasan has joined #ruby
jacobat_ is now known as jacobat
adambeynon has joined #ruby
cj3kim has quit [Remote host closed the connection]
shaunbaker has quit [Ping timeout: 248 seconds]
radic has joined #ruby
mercwithamouth has joined #ruby
dawkirst has quit [Ping timeout: 245 seconds]
elaptics`away is now known as elaptics
aloshkarev has quit [Quit: aloshkarev]
radic has quit [Client Quit]
radic has joined #ruby
atno has quit [Ping timeout: 276 seconds]
dodosan has quit [Remote host closed the connection]
aagdbl has joined #ruby
noname001 has joined #ruby
razi has joined #ruby
s0ber has quit [Ping timeout: 268 seconds]
atmosx has joined #ruby
<atmosx> Hi can you check out this web form and tell me if its SSLed? http://getpebble.com/pages/replacement-cable Beucase I get the feeling that it's not and it's asking me for my data (okay) and my credit card right after that.
<atmosx> and I'm sitting in a public library, jeez
radic has quit [Quit: Verlassend]
radic has joined #ruby
<atmosx> ah the JS seem to ssled
sayan has quit [Ping timeout: 256 seconds]
mansi has joined #ruby
clocKwize has quit [Quit: clocKwize]
_maes_ has joined #ruby
Kar- has joined #ruby
selim has joined #ruby
ferdev has joined #ruby
atmosx has quit [Quit: Lost in trance]
Drakevr has joined #ruby
Drakevr has quit [Changing host]
Drakevr has joined #ruby
musl has quit [Ping timeout: 260 seconds]
predator117 has joined #ruby
leehambley has quit [Ping timeout: 260 seconds]
Arreis has quit [Read error: Connection reset by peer]
mansi has quit [Ping timeout: 264 seconds]
mikecmpbll has joined #ruby
predator217 has quit [Ping timeout: 248 seconds]
c0rn has quit [Quit: Computer has gone to sleep.]
hkon has joined #ruby
selim has quit [Ping timeout: 276 seconds]
Arreis has joined #ruby
io_syl has quit []
Zai00 has joined #ruby
snovak has joined #ruby
skaflem has joined #ruby
funburn has joined #ruby
kreisys has joined #ruby
jibi has joined #ruby
Nanuq has quit [Ping timeout: 245 seconds]
intuxicated has quit [Ping timeout: 264 seconds]
wmoxam has quit [Ping timeout: 245 seconds]
gyre007 has joined #ruby
snovak has quit [Ping timeout: 264 seconds]
bw_ has joined #ruby
Maokomioko has joined #ruby
Nanuq has joined #ruby
kidstark has joined #ruby
wmoxam has joined #ruby
funburn has quit [Quit: funburn]
adambeynon has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
funburn has joined #ruby
awarner has joined #ruby
cj3kim has joined #ruby
awarner_ has quit [Ping timeout: 248 seconds]
tabolario has quit [Ping timeout: 256 seconds]
d34th4ck3r has quit [Quit: d34th4ck3r]
Arreis has quit [Read error: Connection reset by peer]
aagdbl has quit [Quit: Leaving.]
Arreis has joined #ruby
intuxicated has joined #ruby
d34th4ck3r has joined #ruby
kidstark has quit [Quit: kidstark]
lkba has quit [Ping timeout: 245 seconds]
txdv has quit [Ping timeout: 264 seconds]
nari has quit [Ping timeout: 264 seconds]
clocKwize has joined #ruby
gyre007 has quit [Remote host closed the connection]
Arreis has quit [Read error: Connection reset by peer]
cutmail has quit [Remote host closed the connection]
jamesfung14 has quit [Ping timeout: 264 seconds]
aaronmcadam has joined #ruby
Criztian has joined #ruby
fgo has joined #ruby
Arreis has joined #ruby
timonv has quit [Remote host closed the connection]
sevenseacat has quit [Quit: Leaving.]
fgo has quit [Ping timeout: 245 seconds]
aagdbl has joined #ruby
s0ny123 has quit [Quit: leaving]
mklappstuhl has joined #ruby
dsferreira has joined #ruby
s0ny123 has joined #ruby
brugidou has quit [Ping timeout: 245 seconds]
brugidou has joined #ruby
adambeynon has joined #ruby
camilasan has quit [Remote host closed the connection]
camilasan has joined #ruby
tvw has joined #ruby
elaptics is now known as elaptics`away
headius has quit [Quit: headius]
camilasan has quit [Remote host closed the connection]
camilasan has joined #ruby
elaptics`away is now known as elaptics
Voiden has joined #ruby
fly-away has quit [Remote host closed the connection]
Voiden has quit [Max SendQ exceeded]
LMolr has joined #ruby
Voiden has joined #ruby
threeturn has joined #ruby
Voiden has quit [Read error: Connection reset by peer]
intuxicated has quit [Remote host closed the connection]
buibex has quit [Remote host closed the connection]
buibex has joined #ruby
atno has joined #ruby
hogeo has joined #ruby
marcgg has quit [Remote host closed the connection]
felixjet_ has joined #ruby
julian-delphiki has joined #ruby
bean has quit [Read error: Connection reset by peer]
shaunbak_ has quit [Read error: Connection reset by peer]
ehaliewicz has quit [Ping timeout: 248 seconds]
felixjet has quit [Read error: Connection reset by peer]
shaunbaker has joined #ruby
rippa has joined #ruby
<triptec> is there anyway to get host from Errno::ECONNREFUSED
<triptec> ?
jibi has quit [Quit: .]
mansi has joined #ruby
leehambley has joined #ruby
LMolr has quit [Ping timeout: 264 seconds]
bricker`LA has joined #ruby
dash_ has joined #ruby
staafl has joined #ruby
mklappstuhl has quit [Remote host closed the connection]
s0ber has joined #ruby
wildroman has joined #ruby
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dodosan has joined #ruby
mansi has quit [Ping timeout: 256 seconds]
troessner has joined #ruby
threeturn has quit [Quit: threeturn]
m8 has joined #ruby
<jrobeson> triptec, why don't you inspect the e and find out?
dv_ has quit [Ping timeout: 256 seconds]
<jrobeson> that is.. rescue Errno::ECONNREFUSED => e
gyzmodo has quit [Remote host closed the connection]
<mikecmpbll> triptec: don't think so, afaik Errno exceptions originate from the operating system and are mapped to from the error number that the OS spits out
<Xeago> >> "" || "foo"
pygospa has joined #ruby
<eval-in> Xeago => "" (https://eval.in/49085)
<jrobeson> as expected..
<triptec> mikecmpbll: thanks
jibi has joined #ruby
camilasan has quit [Remote host closed the connection]
<mikecmpbll> triptec, but you can get the host other ways i'm sure.
camilasan has joined #ruby
dodosan has quit [Ping timeout: 245 seconds]
TheRealPygo has quit [Ping timeout: 245 seconds]
snovak has joined #ruby
vmoravec has joined #ruby
camilasa_ has joined #ruby
dsferreira has quit [Quit: This computer has gone to sleep]
vlad_starkov has quit [Remote host closed the connection]
camilasan has quit [Read error: Operation timed out]
relix has joined #ruby
dv_ has joined #ruby
oliver__ has joined #ruby
cam`_ has joined #ruby
camilasa_ has quit [Remote host closed the connection]
camilasan has joined #ruby
mengu has joined #ruby
mengu has quit [Changing host]
mengu has joined #ruby
bluehavana has joined #ruby
mengu has quit [Remote host closed the connection]
schaerli has quit [Remote host closed the connection]
<triptec> involves alot of hassle
Anarch has quit [Read error: Operation timed out]
snovak has quit [Ping timeout: 264 seconds]
mklappstuhl has joined #ruby
oliver_ has quit [Ping timeout: 264 seconds]
selim has joined #ruby
cascalheira has joined #ruby
bigkevmcd has quit [Quit: Ex-Chat]
bigkevmcd has joined #ruby
dangerousdave has quit [Quit: Leaving...]
dash_ has quit [Quit: dash_]
robertjpayne has joined #ruby
<robertjpayne> Are there any methods in ruby that can compare strings of two different encodings? I'm thinking there must be an easier way than constantly enforcing an encoding and then checking?
mengu has joined #ruby
dangerousdave has joined #ruby
Domon has quit [Remote host closed the connection]
<shevy> good old encoding...
<shevy> sweet 1.8.x days
Domon has joined #ruby
aryaching has quit [Ping timeout: 264 seconds]
tomzx_mac has joined #ruby
threeturn has joined #ruby
Domon__ has joined #ruby
<Veejay> Encodings are the worst
soba has joined #ruby
<Veejay> I wish we'd all settle for some encoding and be done with it
DaniG2k has joined #ruby
Domon has quit [Read error: Connection reset by peer]
<Veejay> If only English had more accented characters
<Veejay> We'd probably be there already
<DaniG2k> guys I know that if I have a method is_numeric?(str) I can pass in a tring and check its numericality, but what if I want to do str.is_numeric?
<DaniG2k> how'd I do that?
<DaniG2k> my method is a one-liner
razi has quit [Ping timeout: 256 seconds]
<DaniG2k> do I need to do def is_numeric?; regex === self; end ?
<DaniG2k> it doesnt seem to work though
sergicles has joined #ruby
Domon__ has quit [Remote host closed the connection]
hanmac has quit [Quit: Leaving.]
Anarch has joined #ruby
<canton7> what's 'regex'?
YaNakilon has quit [Ping timeout: 256 seconds]
fgo has joined #ruby
cj3kim has quit [Remote host closed the connection]
<tobiasvl> can't you just do this:
<tobiasvl> class String; def is_numeric?; is_numberic?(self); end; end
<tobiasvl> s/numberic/numeric
blackmesa has quit [Ping timeout: 240 seconds]
dangerousdave has quit [Quit: Leaving...]
blackmes1 has joined #ruby
Stygia has joined #ruby
dangerousdave has joined #ruby
camilasan has quit [Remote host closed the connection]
sayan has joined #ruby
camilasan has joined #ruby
d34th4ck3r has quit [Quit: d34th4ck3r]
YaNakilon has joined #ruby
camilasan has quit [Read error: Connection reset by peer]
fgo has quit [Ping timeout: 256 seconds]
vlad_starkov has joined #ruby
d34th4ck3r has joined #ruby
alexander25 has joined #ruby
mlpinit has joined #ruby
gyre007 has joined #ruby
ferdev has quit [Quit: ferdev]
d34th4ck3r has quit [Client Quit]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
musl has joined #ruby
s0ny123 has quit [Ping timeout: 248 seconds]
ferdev has joined #ruby
mlpinit has quit [Ping timeout: 256 seconds]
gyre007 has quit [Ping timeout: 264 seconds]
r0bglees0n has quit [Ping timeout: 245 seconds]
Lindrian_ is now known as Lindrian
alexander25 has quit [Ping timeout: 250 seconds]
Lindrian has quit [Changing host]
Lindrian has joined #ruby
blackmes1 has quit [Ping timeout: 240 seconds]
atno has quit [Ping timeout: 245 seconds]
kaspergrubbe has quit [Remote host closed the connection]
schaerli has joined #ruby
yrp has joined #ruby
aryaching has joined #ruby
wildroman has quit [Remote host closed the connection]
nfk has joined #ruby
mephux has quit [Ping timeout: 260 seconds]
bricker`LA has quit [Ping timeout: 248 seconds]
timonv has joined #ruby
mephux has joined #ruby
mephux is now known as Guest53177
wildroman has joined #ruby
postmodern has quit [Quit: Leaving]
wildroman has quit [Remote host closed the connection]
aryaching has quit [Client Quit]
wildroman has joined #ruby
siwica has joined #ruby
m00nlight has quit [Remote host closed the connection]
Stalkr_ has joined #ruby
hanmac has joined #ruby
ananthakumaran1 has joined #ruby
lkba has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
dhruvasa1ar has joined #ruby
wchun has joined #ruby
wchun has quit [Client Quit]
buibex has quit [Remote host closed the connection]
wchun has joined #ruby
peregrine81 has joined #ruby
Ox6abe has joined #ruby
ananthakumaran has quit [Ping timeout: 264 seconds]
threeturn has quit [Quit: threeturn]
dhruvasagar has quit [Ping timeout: 276 seconds]
greengriminal has joined #ruby
michael_mbp is now known as zz_michael_mbp
mansi has joined #ruby
kaspergrubbe has joined #ruby
Anarch has quit [Ping timeout: 245 seconds]
Arreis has quit [Ping timeout: 245 seconds]
mikecmpbll has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
mikecmpbll has joined #ruby
aryaching has joined #ruby
mansi has quit [Ping timeout: 264 seconds]
hkon has quit [Remote host closed the connection]
DrCode has quit [Remote host closed the connection]
julweber has joined #ruby
h_kon has joined #ruby
brtdv has quit [Ping timeout: 245 seconds]
atno has joined #ruby
funburn has quit [Quit: funburn]
DrCode has joined #ruby
siwica has quit [Quit: siwica]
dkamioka has quit [Remote host closed the connection]
timonv has quit [Remote host closed the connection]
ananthakumaran1 has quit [Read error: Connection reset by peer]
ismaelrb has joined #ruby
timonv has joined #ruby
blackmes1 has joined #ruby
ismaelrb has quit [Client Quit]
ananthakumaran has joined #ruby
swordsmanz has joined #ruby
timonv has quit [Read error: No route to host]
tagrudev has quit [Remote host closed the connection]
Ox6abe has quit [Remote host closed the connection]
headius has joined #ruby
evenix has joined #ruby
aryaching has quit [Ping timeout: 245 seconds]
julweber has quit [Remote host closed the connection]
aryaching has joined #ruby
tkuchiki has quit [Remote host closed the connection]
hanmac has quit [Quit: Leaving.]
ericmathison has quit [Ping timeout: 256 seconds]
sevenseacat has joined #ruby
emergion has joined #ruby
ananthakumaran has quit [Read error: Connection reset by peer]
dsferreira has joined #ruby
emergion has quit [Max SendQ exceeded]
yacks has joined #ruby
tomsthumb has joined #ruby
emergion has joined #ruby
maasha has joined #ruby
ananthakumaran has joined #ruby
emergion has quit [Max SendQ exceeded]
blackmes1 has quit [Ping timeout: 240 seconds]
mklappstuhl has quit [Remote host closed the connection]
lessless has joined #ruby
emergion has joined #ruby
<maasha> hi
<lessless> what's wrong with ["02", "2811", "8.822483102098898"].inject({visits:0}) {|memo, obj| puts memo[:visits] += obj[1].to_i} - it throws NoMethodError: undefined method `[]' for nil:NilClass
emergion has quit [Max SendQ exceeded]
atno has quit [Read error: Operation timed out]
emergion has joined #ruby
<maasha> I have just discovered a broken test which arose after upgrading from Ruby 1.9->2.0. Array.to_s is no longer invoking the .to_s method of all elements and returning a list of these.
<maasha> Right?
emergion has quit [Max SendQ exceeded]
emergion has joined #ruby
swordsmanz has quit [Quit: swordsmanz]
emergion has quit [Max SendQ exceeded]
nari has joined #ruby
tomsthumb has quit [Ping timeout: 256 seconds]
<canton7> lessless, #inject uses the *return value* of the block asmemo for the next iteration
<canton7> and a hash element assignment return the hash element
<maasha> So now we have to add .map(&:to_s)
<canton7> use #each_with_object
<canton7> or return memo from the block
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
maroloccio has quit [Ping timeout: 245 seconds]
<lessless> wow, this stretchs my brain a bit :))
emergion has joined #ruby
JohnBat26 has joined #ruby
dhruvasa1ar is now known as dhruvasagar
<canton7> >> h = {}; h[:a] = :b
<eval-in> canton7 => :b (https://eval.in/49086)
<canton7> see that assignment returns :b, not {:b => :b}
<canton7> *{:a => :b}
emergion has quit [Max SendQ exceeded]
<lessless> yeah
<lessless> this is just me expecting different behavior :)
soba has quit [Ping timeout: 245 seconds]
emergion has joined #ruby
<canton7> and the way #inject works is "take the return value from the last time the block was called, and pass it in as the first parameter next time to block is called"
<lessless> ok, i see
<canton7> like I say, #each_with_object henaves as you expt it
<canton7> *expect
<lessless> each_with_objects suits better for my needs
<lessless> *task
locriani has quit [Remote host closed the connection]
fgo has joined #ruby
<lessless> this is what I'm trying to achieve https://gist.github.com/dirty-hippie/6607655
locriani has joined #ruby
airtonix_ is now known as airtonix
swordsmanz has joined #ruby
relix has joined #ruby
ananthakumaran has quit [Read error: Connection reset by peer]
buibex has joined #ruby
ananthakumaran has joined #ruby
locriani has quit [Ping timeout: 248 seconds]
fgo has quit [Ping timeout: 248 seconds]
sailias has joined #ruby
swordsmanz has quit [Client Quit]
atno has joined #ruby
emergion has quit [Max SendQ exceeded]
Stalkr_ has quit [Read error: Connection reset by peer]
emergion has joined #ruby
LMolr has joined #ruby
vlad_starkov has joined #ruby
mercwithamouth has quit [Ping timeout: 260 seconds]
emergion has quit [Max SendQ exceeded]
hamakn has quit [Remote host closed the connection]
hamakn has joined #ruby
swordsmanz has joined #ruby
emergion has joined #ruby
tkuchiki has joined #ruby
emergion has quit [Max SendQ exceeded]
vlad_starkov has quit [Remote host closed the connection]
dash_ has joined #ruby
obiwahn has joined #ruby
maroloccio has joined #ruby
emergion has joined #ruby
snovak has joined #ruby
ananthakumaran has quit [Read error: Connection reset by peer]
Ox6abe has joined #ruby
emergion has quit [Max SendQ exceeded]
mlpinit has joined #ruby
emergion has joined #ruby
ananthakumaran has joined #ruby
emergion has quit [Max SendQ exceeded]
camilasan has joined #ruby
hamakn has quit [Ping timeout: 260 seconds]
emergion has joined #ruby
hanmac has joined #ruby
zephdev has joined #ruby
<lessless> hey folks another interesting question
snovak has quit [Ping timeout: 264 seconds]
dash_ has quit [Ping timeout: 256 seconds]
emergion has quit [Max SendQ exceeded]
<lessless> what is the difference between |(*arr, i), o| and |*arr, i, o| in ["31", "2492", "11.436597110754414", "30", "2443", "13.548915268112976"].each_slice(2).with_index.with_object({date:0, visits: 0, rate: 0 }) { |(*arr, i), o| puts "#{arr.flatten(1).inspect}, #{i}, #{o}"}
ananthakumaran has quit [Read error: Connection reset by peer]
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
ananthakumaran has joined #ruby
emergion has joined #ruby
Urizen has joined #ruby
m00nlight has joined #ruby
emergion has quit [Max SendQ exceeded]
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
m00nlight has quit [Remote host closed the connection]
emergion has joined #ruby
blackmes1 has joined #ruby
emergion has quit [Max SendQ exceeded]
mercwithamouth has joined #ruby
fgo has joined #ruby
jgrau has joined #ruby
ldnunes has joined #ruby
emergion has joined #ruby
KobraKao has joined #ruby
<jgrau> hi group. I have an array of objects that i want to split into two arrays based on a property of the object
<jgrau> is there a method for that?
emergion has quit [Max SendQ exceeded]
Urizen has quit [Ping timeout: 256 seconds]
<jgrau> basicly i have a bunch of objects that are either pinned? or not. I want to move all the pinned objects to the beginning of the array
emergion has joined #ruby
<sevenseacat> just sort them?
hydrozen has joined #ruby
<jgrau> if I use sort, then for reason my sorting by creation date is no longer working
emergion has quit [Max SendQ exceeded]
<lessless> sevenseacat, can you look on my last question, please? :)
ksh has quit [Remote host closed the connection]
ananthakumaran has quit [Read error: Connection reset by peer]
emergion has joined #ruby
<lessless> what is the sense of using braces in (*arr, i) in ["31", "2492", "11.436597110754414", "30", "2443", "13.548915268112976"].each_slice(2).with_index.with_object({date:0, visits: 0, rate: 0 }) { |(*arr, i), o| puts "#{arr.flatten(1).inspect}, #{i}, #{o}"}
sailias has quit [Ping timeout: 245 seconds]
emergion has quit [Max SendQ exceeded]
<sevenseacat> lessless: if i knew the answer, i would.
ananthakumaran has joined #ruby
cascalheira has quit [Quit: Leaving...]
emergion has joined #ruby
gyre007 has joined #ruby
emergion has quit [Max SendQ exceeded]
<lessless> sevenseacat, I used this statement to resolve this task https://gist.github.com/dirty-hippie/6607655#file-data-rb
workmad3 has joined #ruby
<lessless> but it's pretty unreadable
KobraKao has quit [Ping timeout: 276 seconds]
emergion has joined #ruby
KobraKao has joined #ruby
emergion has quit [Max SendQ exceeded]
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
emergion has joined #ruby
mansi has joined #ruby
emergion has quit [Max SendQ exceeded]
MrZYX|off is now known as MrZYX
emergion has joined #ruby
<apeiros> lessless: different destructuring of the array
mklappstuhl has joined #ruby
<apeiros> |(*arr, i), o| # takes an array with two values, and assigns the first value to (*arr, i) and the second to o
emergion has quit [Max SendQ exceeded]
jibi has quit [Quit: .]
<apeiros> the first value being assigned to (*arr, i) must be an array too and is further destructured by assigning the last value to i and the rest (via splat) to arr
emergion has joined #ruby
fgo has quit [Remote host closed the connection]
yfeldblum has joined #ruby
emergion has quit [Max SendQ exceeded]
<apeiros> >> ((*arr, i), o) = [[1,2,3],4]; {arr: arr, i: i, o: o}
<eval-in> apeiros => {:arr=>[1, 2], :i=>3, :o=>4} (https://eval.in/49088)
jbpros has joined #ruby
<apeiros> @ lessless ^
clocKwize_ has joined #ruby
emergion has joined #ruby
<lessless> >> ((arr, i), o) = [[1,2,3],4]; {arr: arr, i: i, o: o}
<eval-in> lessless => {:arr=>1, :i=>2, :o=>4} (https://eval.in/49089)
<apeiros> @ sevenseacat ^, in case you're interested
wildroman has quit [Remote host closed the connection]
cascalheira has joined #ruby
ananthakumaran has quit [Read error: Connection reset by peer]
<lessless> >> (arr, i, o) = [[1,2,3],4]; {arr: arr, i: i, o: o}
<eval-in> lessless => {:arr=>[1, 2, 3], :i=>4, :o=>nil} (https://eval.in/49090)
<apeiros> lessless: use irb
<lessless> lol :D
<sevenseacat> always :) my general ruby knowledge is a lot weaker than my rails-fu so i try to absorb a lot
gyre007 has quit [Ping timeout: 264 seconds]
ferdev has quit [Quit: ferdev]
mercwithamouth has quit [Ping timeout: 260 seconds]
mansi has quit [Ping timeout: 264 seconds]
<apeiros> (or pry)
vlad_starkov has joined #ruby
<apeiros> sevenseacat: for me it's the other way round :)
<apeiros> the ruby is strong with me, but I feel more comfortable off-rails
ananthakumaran has joined #ruby
<mikecmpbll> you're off the rails, boy.
<apeiros> damit, I need wooden swords… (compiling)
<clocKwize_> anyone use textual?
zephdev has quit [Remote host closed the connection]
<mikecmpbll> clocKwize_: yep.
<clocKwize_> I'm trying it.. seems nicer than Colloquay
<apeiros> no, noone never did
<mikecmpbll> i like it.
<mikecmpbll> i still haven't bought it so every two hours i face palm when they disconnect me
KobraKao has quit [Quit: Saindo]
Elhu has quit [Quit: Computer has gone to sleep.]
graydot has joined #ruby
graydot has quit [Client Quit]
jkamenik has joined #ruby
kiri has quit [Ping timeout: 268 seconds]
<sevenseacat> still havent found a client i like as much as pidgin.
shaunbaker has quit [Remote host closed the connection]
<clocKwize_> heh
Xeago_ has joined #ruby
Xeago has quit [Read error: Operation timed out]
kayloos has joined #ruby
theRoUS has joined #ruby
<cout> pidgin didn't work well for me
<cout> can't remember what didn't work
<cout> empathy worked but felt klunky
<cout> but maybe anything is going to feel klunky to someone who grew up on ircII and BitchX
<jrobeson> i need to setup my xmpp irc gateway again..
<jrobeson> i used to use gajim for everything via gateways
<jrobeson> atm i'm using xchat though.. mostly because empathy has no out of the box support for timestamps
<jrobeson> you have to add a custom adium theme for it
<jrobeson> and it never looked right
iartarisi has joined #ruby
<jrobeson> plus.. i like the guide in xchat
<iartarisi> does ruby have anything similar to clojure's if-let?
<jrobeson> iartarisi, you'd have to explain if-let .. don't assume people know it
<iartarisi> it's kinda hard to explain :), basically it checks for a condition and if it's true, it assigns the result of another expression to a variable and executes a block
ananthakumaran has quit [Read error: Connection reset by peer]
<iartarisi> maybe some examples would help? http://clojuredocs.org/clojure_core/clojure.core/if-let
ananthakumaran has joined #ruby
<sevenseacat> thats a scary-looking language
vlad_starkov has quit [Remote host closed the connection]
<iartarisi> basically I'd want to use this with an Array.detect call
nomenkun has joined #ruby
Elhu has joined #ruby
eka has joined #ruby
shaunbaker has joined #ruby
<mikecmpbll> iartarisi: i still don't really know what it is but i think it's safe to say the answer is no.
tkuchiki has quit [Remote host closed the connection]
shaunbak_ has joined #ruby
<canton7> but probably also quite easy to write?
peregrine81 has quit []
Alina-malina has quit [Read error: Connection reset by peer]
<iartarisi> sure, I can just write result = ary.detect ... ; if result ... end
<iartarisi> but it's not as nice
Alina-malina has joined #ruby
<canton7> no, as in write a method on Enumerable or ARray
<iartarisi> right, that would also be easy
hydrozen has quit [Quit: Computer has gone to sleep.]
wildroman has joined #ruby
ksh has joined #ruby
joshwines has quit [Remote host closed the connection]
taternuts has joined #ruby
taternuts has quit [Client Quit]
pushpak has joined #ruby
wildroman has quit [Remote host closed the connection]
wildroman has joined #ruby
<mikecmpbll> iartarisi: i'm intrigued now. can you do a proper example of equivalent ruby
<jrobeson> iartarisi, i only see something like let.. not if-let
<jrobeson> via .tap
adambeynon has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
wildroman has quit [Remote host closed the connection]
shaunbaker has quit [Ping timeout: 245 seconds]
dkamioka has joined #ruby
wildroman has joined #ruby
shredding has joined #ruby
<iartarisi> I don't care so much about the lexical block, even passing another block would be good enough
robertjpayne has quit [Remote host closed the connection]
<jrobeson> iartarisi, well does that blog post help
<jrobeson> on a related note.. https://www.ruby-forum.com/topic/557224 a ticket for let() in ruby
LMolr has quit [Ping timeout: 276 seconds]
<iartarisi> yeah, I'm looking at tap now, I didn't know about it
lkba has quit [Ping timeout: 260 seconds]
<mikecmpbll> still don't get it.
<jrobeson> oh here's the ticket actually https://redmine.ruby-lang.org/issues/show/4102
<jrobeson> but it was rejected
girija has quit [Ping timeout: 256 seconds]
toah has joined #ruby
burlyscudd has joined #ruby
<jrobeson> rejected as "The definition of let would be: "def let() yield; end"; I don't think it's worth to add."
<jrobeson> it shows some more examples of stuff with block and tap though.. so still worth a read for ya perhaps
<jrobeson> ruby is nice in that it lets you play with serious functional stuff.. while still being comffy with OO
krz has quit [Quit: krz]
locriani has joined #ruby
osvico has quit [Ping timeout: 248 seconds]
<iartarisi> mikecmpbll: something like this: https://gist.github.com/mapleoin/6608341
<mikecmpbll> ohhh.
fgo has joined #ruby
burlyscudd has quit [Quit: Leaving.]
<mikecmpbll> i just do an assignment in the condition.
<mikecmpbll> if (res = my_array.find{|i| i>2}); puts res; end
<iartarisi> but then you don't have the object inside the if block
<iartarisi> do you?
<mikecmpbll> everyone will probably bawk
<mikecmpbll> yeah i do.
machuga|away is now known as machuga
<iartarisi> aaah, then that's it :)
<mikecmpbll> :)
<lupine> you have to be careful with intentional assignment in conditions. it's not always obvious 3 months later whether it's meant to be = or ==
Tricon has joined #ruby
hanmac has quit [Quit: Leaving.]
<iartarisi> agreed
<lupine> so I tend to leave a comment on every single instance of it
sailias has joined #ruby
<iartarisi> but anyway, that works, thanks!
<mikecmpbll> i don't see the confusion.
NealJ has joined #ruby
<lupine> if (res = my_array.find{|i| i>2}); puts res; end vs. if (res == my_array.find{|i| i>2}); puts res; end
<lupine> either could be valid, but they mean very different things
<mikecmpbll> same as any line of code
sailias has quit [Client Quit]
<iartarisi> yeah
* mikecmpbll shrugs
<lupine> it has been a problem in practice here
browndawg has joined #ruby
<lupine> which is why we now comment each instance
hanmac has joined #ruby
<lupine> typically just like if (res = my_array.find{|i| i>2}); puts res; end # intentional assignment
<mikecmpbll> can't harm.
fgo has quit [Ping timeout: 245 seconds]
underway47 has quit [Ping timeout: 256 seconds]
kayloos has quit [Remote host closed the connection]
underway47 has joined #ruby
snovak has joined #ruby
<canton7> one convention, at least in C, is the stick an extra pair of brackets around it if it's an intentional assignment
<canton7> if ((thing = foo()))
mklappstuhl has quit [Remote host closed the connection]
emergion has quit [Quit: Computer has gone to sleep.]
girija has joined #ruby
locriani has quit [Ping timeout: 248 seconds]
IceyEC has joined #ruby
mark_locklear has joined #ruby
snovak has quit [Ping timeout: 245 seconds]
workmad3 has quit [Ping timeout: 248 seconds]
sambao21 has joined #ruby
snath has quit [Ping timeout: 245 seconds]
kayloos has joined #ruby
kofno has quit [Ping timeout: 256 seconds]
mklappstuhl has joined #ruby
hamakn has joined #ruby
tesuji has quit [Read error: Connection reset by peer]
tesuji has joined #ruby
mercwithamouth has joined #ruby
staafl has quit [Ping timeout: 264 seconds]
sloucher has joined #ruby
hamakn has quit [Ping timeout: 245 seconds]
ravster has joined #ruby
jbpros has quit [Quit: jbpros]
Ox6abe has quit [Remote host closed the connection]
Ox6abe has joined #ruby
a1ph4g33k has joined #ruby
sloucher has quit [Client Quit]
breakingthings has joined #ruby
<maasha> a1ph4g33k: eh, what gist?
vlad_starkov has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
hydrozen has joined #ruby
Ox6abe has quit [Ping timeout: 245 seconds]
<a1ph4g33k> Good morning all.
mklappstuhl has quit [Remote host closed the connection]
shredding has quit [Ping timeout: 276 seconds]
dhruvasagar has quit [Ping timeout: 276 seconds]
mansi has joined #ruby
mdst2 has quit [Remote host closed the connection]
yaymukund has joined #ruby
ehc has joined #ruby
pothibo has joined #ruby
mikecmpbll has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
fridim__ has joined #ruby
kaldrenon has joined #ruby
mikecmpbll has joined #ruby
mattlins has joined #ruby
lfox has joined #ruby
aryaching has quit [Ping timeout: 256 seconds]
mklappstuhl has joined #ruby
mansi has quit [Ping timeout: 264 seconds]
shredding has joined #ruby
krawchyk has joined #ruby
lfox has quit [Client Quit]
buibex has quit [Remote host closed the connection]
mattlins has quit [Client Quit]
JumpMast3r has joined #ruby
jp- has joined #ruby
mattlins has joined #ruby
buibex has joined #ruby
alekst has joined #ruby
lfox has joined #ruby
brain_shim has quit [Ping timeout: 245 seconds]
sailias has joined #ruby
fridim__ has quit [Ping timeout: 264 seconds]
kvirani has joined #ruby
pothibo has quit [Quit: pothibo]
schaerli has quit [Remote host closed the connection]
cody-- has joined #ruby
snovak has joined #ruby
dawkirst has joined #ruby
justsee has quit [Ping timeout: 276 seconds]
Monie has joined #ruby
jamesaanderson has joined #ruby
zarubin has joined #ruby
snovak has quit [Ping timeout: 276 seconds]
girija has quit [Ping timeout: 264 seconds]
adambeynon has joined #ruby
cads has joined #ruby
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Clooth has joined #ruby
Beoran_ has quit [Ping timeout: 246 seconds]
dawkirst has quit [Ping timeout: 245 seconds]
Suit_Of_Sables has joined #ruby
brain_shim has joined #ruby
shaunbak_ has quit [Remote host closed the connection]
Maokomioko has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dawkirst has joined #ruby
Ox6abe has joined #ruby
kiri has joined #ruby
<Suit_Of_Sables> might one think of a method yeilding to a block (as in: array.each { |x| puts x } ) as kind of a return value being passed to the block that doesn't terminate the original method? (unlike normal use of the return statement) ??
schaerli has joined #ruby
leehambley has quit [Ping timeout: 256 seconds]
freerobby has quit [Read error: Connection reset by peer]
snovak has joined #ruby
<canton7> mmm. it's more like syntactic sugar for the block being called (in the same way that one method calls another) with a particular argument
phantasm66 has joined #ruby
phantasm66 has joined #ruby
phantasm66 has quit [Changing host]
aryaching has joined #ruby
ferdev has joined #ruby
leehambley has joined #ruby
adambeynon has quit [Quit: Textual IRC Client: www.textualapp.com]
yacks has quit [Quit: Leaving]
jprovazn has joined #ruby
adambeynon has joined #ruby
<Suit_Of_Sables> canton7: ah, so the yield is like a call on the block with whatever it is yielding as a parameter(if of course, the block is set to use them)? Also, the block itself has the same 'scope' as the area in which the method to it's left (the .each call in my above example) was made correct?
jamesaanderson has joined #ruby
LMolr has joined #ruby
<canton7> "same 'scope' as the area in which the method to it's left"? the block is a closure - it captures the scope at the point at which it is defined
<canton7> (put very broadly and slightly incorrectly)
aagdbl has quit [Quit: Leaving.]
<canton7> `def i_call_blocks(&block) ; block.call("yay"); end ` and `def i_call_blocks(); yield "yay"; end` are equivalent
swordsmanz has quit [Quit: swordsmanz]
DaniG2k has quit [Read error: Operation timed out]
<Suit_Of_Sables> canton7: that is what I ment. meaning if there is a variable 'x' declared before the method-with-{block} statement, x = 3 in the method itself would not affect that original variable, but x = 3 in the block WOULD (unless declared explicitly as local variable with |;x|) right?
pierre1 has joined #ruby
Beoran_ has joined #ruby
gr33n7007h has joined #ruby
swordsmanz has joined #ruby
<canton7> Suit_Of_Sables, yup sounds about right
jbpros has joined #ruby
DrForr_ is now known as DrForr
girija has joined #ruby
<canton7> now you get more complex situations where the scoping of a block can be redefined by the method to which it's passed
<canton7> so you define a block, pass it to a method, the method goes "ok, I'm going to evaluate this block in this other scope I've got"
<canton7> see instance_eval and friends. they're less common outside of DSLs
shaunbaker has joined #ruby
<Suit_Of_Sables> canton7: Ok, just seemed counter intuitive to me at first as, if thinking of the yield (or call on the block) as being like a method call I would have thought at first that the scope narrowed from initial method call to block call but in fact it is more of a cycle with the block being almost like snapshot of the preview scope state(unless, as you said, it is overridden) at least that is how it makes sense to me
<Suit_Of_Sables> now
<Suit_Of_Sables> canton7: thanks for your help!
oliver__ has quit [Read error: Connection reset by peer]
snath has joined #ruby
oliver_ has joined #ruby
Zai00_ has joined #ruby
polaco_zZz is now known as polaco
Zai00 has quit [Ping timeout: 245 seconds]
Zai00_ is now known as Zai00
<Suit_Of_Sables> It seems to me that once you have some experience programming most language specific instructional books don't help much outside of a basic intro to syntax. It seems to all be about actually diving into the documentation yourself and learning the API
locriani has joined #ruby
<Suit_Of_Sables> That is, diving into the documention is what one should do.
iamjarvo has joined #ruby
LMolr has quit [Ping timeout: 260 seconds]
jbpros has quit [Ping timeout: 256 seconds]
cody-- has quit [Quit: derp]
wmoxam_ has joined #ruby
wmoxam has quit [Disconnected by services]
shaunbak_ has joined #ruby
brain_shim has quit [Ping timeout: 276 seconds]
wmoxam_ is now known as wmoxam
wmoxam has joined #ruby
wmoxam has quit [Changing host]
mercwithamouth has quit [Ping timeout: 264 seconds]
locriani has quit [Ping timeout: 256 seconds]
shredding has quit [Quit: shredding]
BizarreCake has joined #ruby
<Ox6abe> How can I tell in my ruby code whether I am using normal order vs applicative order?
kayloos has quit [Remote host closed the connection]
<Ox6abe> aka lazy evaluation or not
shaunbaker has quit [Ping timeout: 264 seconds]
cascalheira has quit [Quit: Leaving...]
<hoelzro> Ox6abe: sorry, could you offer a little more clarification?
<kaldrenon> Is anyone here familiar with the pry gem? I'm wondering if it's possible to access pry's command history inside a custom method
mklappstuhl has quit [Remote host closed the connection]
<Ox6abe> hoelzro: check out the link
rcedillor has joined #ruby
toah has quit [Remote host closed the connection]
devoldmx has joined #ruby
kofno has joined #ruby
r0bglees0n has joined #ruby
<hoelzro> Ox6abe: afaik, Ruby always strictly evaluates
<hoelzro> there's no built-in laziness
<Ox6abe> So then always normal order
<Ox6abe> sorry i mean applicative
<hoelzro> if you want to defer some evalulation, you can wrap it in a block
devoldmx has quit [Client Quit]
devoldmx has joined #ruby
shredding has joined #ruby
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Ox6abe> ok hoelzro, let me make sure i am understaing you right
nanoxd has joined #ruby
<Ox6abe> so the blocks i am passing will be lazy evaluation since I am passing each one separately to the each function and they are bing called later on the object?
iamjarvo has quit [Remote host closed the connection]
<Ox6abe> being*
iamjarvo has joined #ruby
<hoelzro> I wouldn't think of it as lazy evaluation
<a1ph4g33k> no, the block will be evaluated as the interpretter hits it ... but the block will not be executed until yielded to.
<canton7> Suit_Of_Sables, yeah that fits with my mental model
<hoelzro> what a1ph4g33k said
<canton7> Suit_Of_Sables, hmm yeah, I see learning a language as learning 3 parts: syntax, api, style. books with a lot with the first and a bit with the second two
<Ox6abe> So it is still all applicative order
<Ox6abe> Makes sense
<a1ph4g33k> ... yes & no.
<a1ph4g33k> The bindings won't be resolved until the block is executed.
<canton7> hmm, stdlib is probably a better word than api
<Ox6abe> maybe I am still confused on the two then
<a1ph4g33k> so ... in the normal case, the bindings will stay what they were as the block was defined, if instance_eval or class_eval is used, the bindings will be updated.
Maokomioko has joined #ruby
<hoelzro> blocks are just closures
peregrine81 has joined #ruby
renanoronfle has joined #ruby
<Ox6abe> Ruby and closures are still new to me
kayloos has joined #ruby
<hoelzro> what's your background?
hanmac has quit [Read error: Connection reset by peer]
<Ox6abe> C, C++, Java
hanmac has joined #ruby
<hoelzro> hmm
<Ox6abe> C# etc ...
<hoelzro> oh, C# might help a bit
mengu has quit [Quit: This computer has gone to sleep]
jlast has joined #ruby
<hoelzro> I remember it has some sort of lambdas
<hoelzro> but it's been a while since I've written C#
freerobby has joined #ruby
<hoelzro> so a closure is a function that "closes over" a set of variables
cascalheira has joined #ruby
devoldmx has quit [Ping timeout: 260 seconds]
mengu has joined #ruby
gyre007 has joined #ruby
vlad_starkov has joined #ruby
<hoelzro> so a closure can still access the variables it closes over, even if the original stack frame of those variables is gone
<Ox6abe> Binding the variable to the variable in the closure
devoldmx has joined #ruby
mary5030 has joined #ruby
mary5030 has quit [Remote host closed the connection]
<hoelzro> in the case of sum = 0; array.each { |x| sum += x }
rickmasta has joined #ruby
<hoelzro> the block here is a closure which has access to the sum variable in the enclosing scope
mary5030 has joined #ruby
<hoelzro> so when the each method executes the block (known as "yielding")
<hoelzro> it can access it
<Ox6abe> I am guessing the C code it has two pointers then ?
<Ox6abe> hmmm
<coderhs> hey how to get session id of a bosh communication from ruby
<hoelzro> I'm not privy to the details of the implementation
brbcoding has joined #ruby
<Ox6abe> oh ok
jerius has joined #ruby
ananthakumaran has quit [Quit: Leaving.]
Mokosha has quit [Read error: Operation timed out]
<Suit_Of_Sables> is the only real difference between array's .map and .each methods that .map returns a new array as modified by the block? Is that about it?
<cout> yes
<Suit_Of_Sables> cout: thanks, well that makes it easy to remember
clocKwize_ has quit [Quit: Textual IRC Client: www.textualapp.com]
<Suit_Of_Sables> cout: I'm assuming then that .map actually uses .each in it's implementation and just adds to it?
vlad_starkov has quit [Ping timeout: 256 seconds]
<hoelzro> it certainly could
cads has quit [Ping timeout: 245 seconds]
<Suit_Of_Sables> Learnin' is fun ^_^
clov3r has joined #ruby
interactionjaxsn has joined #ruby
coderhs has left #ruby ["Leaving"]
<cout> Suit_Of_Sables: Array#map does not, but Enumerable#map does
<cout> I think that's for performance reasons
mmitchell has joined #ruby
devoldmx3 has joined #ruby
tkuchiki has joined #ruby
kvirani has quit [Remote host closed the connection]
kvirani has joined #ruby
__username__ has joined #ruby
duggiefresh has joined #ruby
devoldmx has quit [Ping timeout: 256 seconds]
Monie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
locriani has joined #ruby
ksh has quit [Ping timeout: 240 seconds]
nyuszika7h has left #ruby ["WeeChat 0.4.2-rc1"]
gyre007 has quit [Remote host closed the connection]
devoldmx has joined #ruby
sr78ger has quit [Read error: Operation timed out]
s0ny123 has joined #ruby
shaunbak_ has quit [Remote host closed the connection]
kvirani has quit [Ping timeout: 276 seconds]
devoldmx3 has quit [Read error: Connection reset by peer]
locriani has quit [Ping timeout: 245 seconds]
jamesaanderson has joined #ruby
senayar_ has joined #ruby
akhkharu has joined #ruby
devoldmx has quit [Read error: Connection reset by peer]
devoldmx3 has joined #ruby
jamesaanderson has quit [Client Quit]
senayar_ has quit [Remote host closed the connection]
DaniG2k has joined #ruby
senayar_ has joined #ruby
senayar has quit [Read error: Connection reset by peer]
h_kon has quit [Remote host closed the connection]
yrp has quit [Quit: Page closed]
sayan has quit [Ping timeout: 276 seconds]
Soda has joined #ruby
Criztian has quit [Remote host closed the connection]
codecop has quit [Remote host closed the connection]
mklappstuhl has joined #ruby
huoxito has joined #ruby
underway47 has quit [Ping timeout: 276 seconds]
duggiefresh has quit [Read error: Connection reset by peer]
Guest85329 has joined #ruby
duggiefresh has joined #ruby
tomzx_mac has quit [Ping timeout: 256 seconds]
alexju has joined #ruby
YaNakilon has quit [Ping timeout: 245 seconds]
wildroman has quit [Remote host closed the connection]
avril14th has joined #ruby
buibex has quit [Remote host closed the connection]
hydrozen has left #ruby ["Textual IRC Client: www.textualapp.com"]
sarkis has joined #ruby
aryaching_ has joined #ruby
kevind has joined #ruby
Guest67358 has quit [Changing host]
Guest67358 has joined #ruby
Guest67358 is now known as C0deMaver1ck
devoldmx3 has quit [Read error: Connection reset by peer]
jamesaanderson has joined #ruby
YaNakilon has joined #ruby
clov3r has quit [Remote host closed the connection]
buibex has joined #ruby
platzhirsch has joined #ruby
enebo has joined #ruby
justsee has joined #ruby
justsee has joined #ruby
jamesaanderson has quit [Client Quit]
wildroman has joined #ruby
mengu has quit [Quit: This computer has gone to sleep]
aryaching has quit [Ping timeout: 245 seconds]
optimusprimem has quit [Ping timeout: 245 seconds]
blackmes1 has quit [Ping timeout: 240 seconds]
jdeeburke has joined #ruby
jdeeburke has quit [Max SendQ exceeded]
jamesaanderson has joined #ruby
jprovazn has quit [Ping timeout: 264 seconds]
jdeeburke has joined #ruby
mansi has joined #ruby
jokke has quit [Quit: WeeChat 0.4.1]
jamesaanderson has quit [Client Quit]
jdeeburke has left #ruby [#ruby]
jokke has joined #ruby
tziOm has quit [Remote host closed the connection]
ksh has joined #ruby
mansi has quit [Remote host closed the connection]
mansi has joined #ruby
kayloos has quit [Read error: No route to host]
kayloos has joined #ruby
bio has joined #ruby
bio is now known as Guest96486
mrsolo has joined #ruby
ner0x has joined #ruby
__username__ has quit [Quit: none 0.4.1]
ayaz has quit [Quit: Textual IRC Client: www.textualapp.com]
brain_shim has joined #ruby
kobain has joined #ruby
ixti has joined #ruby
brain_shim has quit [Max SendQ exceeded]
optimusprimem has joined #ruby
brain_shim has joined #ruby
utdemir has joined #ruby
lukec has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
anonymuse has joined #ruby
<utdemir> Hi. On Turkish language I is uppercase of ı and İ is uppercase of i. However, UnicodeUtils.downcase("I", "tr"|"tur"|"turkish") doesn't work, it just converts it to "i" instead of "ı". How can I fix this behavior?
kayloos has quit [Remote host closed the connection]
s0ny123 has quit [Read error: Operation timed out]
tjad has quit [Ping timeout: 276 seconds]
obs has joined #ruby
thecodethinker has joined #ruby
Ox6abe has quit [Remote host closed the connection]
endash has joined #ruby
pushpak has quit [Ping timeout: 240 seconds]
s0ny123 has joined #ruby
gianlucadv has quit [Max SendQ exceeded]
rickmasta has quit [Quit: Leaving...]
dml_ has joined #ruby
gianlucadv has joined #ruby
dawkirst has quit [Ping timeout: 256 seconds]
hogeo has quit [Remote host closed the connection]
DaniG2k has quit [Ping timeout: 245 seconds]
braoru has quit [Quit: Leaving]
kofno has quit [Ping timeout: 245 seconds]
RORgasm has joined #ruby
<canton7> utdemir, like http://unicode-utils.rubyforge.org/UnicodeUtils.html#method-c-downcase says, the langauge_id needs to be the two-letter language code *as a symbol*
Kar- has quit [Ping timeout: 256 seconds]
<canton7> respecting that, my test works fine
sambao21 has joined #ruby
shredding has quit [Quit: shredding]
duggiefr_ has joined #ruby
pothibo has joined #ruby
io_syl has joined #ruby
kayloos has joined #ruby
<utdemir> canton7, Thank you very much! You're right.
<canton7> :)
duggiefresh has quit [Ping timeout: 245 seconds]
failshell has joined #ruby
freeayu__ has joined #ruby
freeayu has quit [Ping timeout: 264 seconds]
baordog_ has joined #ruby
canton7 has quit [Remote host closed the connection]
ta has quit [Remote host closed the connection]
freeayu__ has quit [Client Quit]
canton7 has joined #ruby
wildroman has quit [Remote host closed the connection]
cody-- has joined #ruby
hamakn has joined #ruby
aryaching_ has quit [Ping timeout: 264 seconds]
kofno has joined #ruby
hamakn has quit [Read error: Connection reset by peer]
thecodethinker has quit [Ping timeout: 256 seconds]
hamakn has joined #ruby
a1ph4g33k has quit [Quit: Leaving]
dawkirst has joined #ruby
platzhirsch has left #ruby [#ruby]
wallerdev has joined #ruby
thecodethinker has joined #ruby
BillCriswell has joined #ruby
Urizen has joined #ruby
claymore has quit [Quit: Leaving]
persand has quit [Quit: persand]
rjhunter has joined #ruby
gchaturvedi has joined #ruby
Xeago_ has quit [Remote host closed the connection]
mikecmpbll has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
alex__c2022 has joined #ruby
Xeago has joined #ruby
rickmasta has joined #ruby
fgo has joined #ruby
sevenseacat has quit [Quit: Leaving.]
kayloos has quit [Remote host closed the connection]
robertjpayne has joined #ruby
atno has quit [Ping timeout: 260 seconds]
mansi has quit [Remote host closed the connection]
mansi has joined #ruby
buibex_ has joined #ruby
luke has joined #ruby
shredding has joined #ruby
luke is now known as Guest91512
Banistergalaxy has joined #ruby
wmoxam has quit [Ping timeout: 256 seconds]
girija has quit [Read error: Operation timed out]
locriani has joined #ruby
wmoxam has joined #ruby
jprovazn has joined #ruby
Gooder has joined #ruby
buibex has quit [Ping timeout: 276 seconds]
mansi has quit [Ping timeout: 264 seconds]
kevind_ has joined #ruby
mansi has joined #ruby
axl_ has joined #ruby
kvirani has joined #ruby
barratt has quit [Ping timeout: 260 seconds]
YaNakilon has quit [Ping timeout: 276 seconds]
aryaching has joined #ruby
splud_ has joined #ruby
awarner_ has joined #ruby
kayloos has joined #ruby
Guest91512 has quit [Ping timeout: 276 seconds]
cpruitt has joined #ruby
kevind has quit [Ping timeout: 276 seconds]
awarner has quit [Ping timeout: 245 seconds]
kevind_ is now known as kevind
Xeago has quit [Remote host closed the connection]
YaNakilon has joined #ruby
gchaturvedi has quit [Quit: gchaturvedi]
baggypants has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
Stalkr^ has joined #ruby
underway47 has joined #ruby
kayloos has quit [Remote host closed the connection]
kevind_ has joined #ruby
alexju has quit [Remote host closed the connection]
Stalkr^ has quit [Client Quit]
alexju has joined #ruby
alex__c2022 has quit [Quit: alex__c2022]
kreisys has quit [Ping timeout: 264 seconds]
maasha has quit [Quit: Page closed]
alexju has quit [Remote host closed the connection]
yacks has joined #ruby
alexju has joined #ruby
Spami has joined #ruby
kevind has quit [Ping timeout: 276 seconds]
atno has joined #ruby
kevind_ is now known as kevind
baggypants has quit [Client Quit]
Guest85329 has quit [Remote host closed the connection]
baggypants has joined #ruby
Stalkr_ has joined #ruby
flowerhack_ is now known as flowerhack
Monie has joined #ruby
atno has quit [Read error: Connection reset by peer]
tjad has joined #ruby
freeayu has joined #ruby
Monie has quit [Client Quit]
atno has joined #ruby
Xeago has joined #ruby
ta has joined #ruby
dash_ has joined #ruby
mikecmpbll has joined #ruby
tricon_ has joined #ruby
sniffingcats has joined #ruby
locriani has quit [Remote host closed the connection]
bamdad has joined #ruby
threesome has quit [Ping timeout: 276 seconds]
locriani has joined #ruby
sr78ger has joined #ruby
girija has joined #ruby
bamdad has left #ruby [#ruby]
headius has quit [Quit: headius]
ahawkins has quit [Quit: leaving]
pzula has joined #ruby
zzak is now known as zzakh
Seich has joined #ruby
atno has quit [Ping timeout: 264 seconds]
Tricon has quit [Remote host closed the connection]
ramblex has joined #ruby
mando has joined #ruby
dash_ has quit [Ping timeout: 245 seconds]
sr78ger has quit [Client Quit]
tricon_ has quit [Quit: Bye!]
tesuji has quit [Ping timeout: 264 seconds]
Tricon has joined #ruby
sr78ger has joined #ruby
brianpWins has quit [Quit: brianpWins]
girija has quit [Ping timeout: 245 seconds]
aganov has quit [Remote host closed the connection]
ScottRadcliff has joined #ruby
mrsolo has joined #ruby
jaynewstrom has quit [Remote host closed the connection]
ananthakumaran has joined #ruby
ananthakumaran has quit [Max SendQ exceeded]
dawkirst has quit [Ping timeout: 264 seconds]
Maokomioko has quit [Ping timeout: 264 seconds]
ananthakumaran has joined #ruby
ananthakumaran has quit [Max SendQ exceeded]
ananthakumaran has joined #ruby
|jemc| has joined #ruby
mary5030 has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
freerobby has quit [Quit: Leaving.]
freerobby has joined #ruby
jaynewstrom has joined #ruby
oliver_ has quit [Remote host closed the connection]
<utdemir> Hey, can you see any syntax error here?: terms.values.map{ |i| i[:lessons] }.flatten.each{ |i| counts[i[:id][0..2]]++ }
<|jemc|> ++ doesn't exist in ruby
bricker`LA has joined #ruby
s0ny123 has quit [Quit: leaving]
<|jemc|> you have to use +=1
Bira has joined #ruby
browndawg has quit [Quit: Leaving.]
rjhunter has quit [Remote host closed the connection]
<utdemir> |jemc|, oh, thanks
baroquebobcat has joined #ruby
Bira has quit [Remote host closed the connection]
coderhs has joined #ruby
clov3r has joined #ruby
dawkirst has joined #ruby
Xeago has joined #ruby
mansi has quit [Remote host closed the connection]
<baggypants> How do I check if an array's index is out of bounds ?
mansi has joined #ruby
rins has joined #ruby
greengriminal has quit [Quit: Leaving]
geggam_ has joined #ruby
<MrZYX> >= .size but there's a better solution in ruby most of the time
kayloos has joined #ruby
<canton7> utdemir, ++ would mutate the number, and in ruby numbers don't tend to mutate
jprovazn has quit [Quit: Leaving]
<shevy> baggypants will you remove your pants?
Kar- has joined #ruby
<baggypants> lol…no :)
graft has joined #ruby
graft has joined #ruby
<baggypants> this was my old AIm screename from like middle school
<shevy> hehe
buibex_ has quit [Remote host closed the connection]
bricker`1A has joined #ruby
<baggypants> yeah..i was checking index == nil but what if nil is in the array
kayloos has quit [Remote host closed the connection]
mansi has quit [Ping timeout: 245 seconds]
<MrZYX> what's your real problem?
<shevy> you could always use .compact on the array, then apply .size on that
<baggypants> i'm doing a problem on coderwars
buibex has joined #ruby
<|jemc|> as MrZYX said, you should probably be using some other solution, like #each and friends
<baggypants> ok
<|jemc|> #each_with_index may be helpful
<baggypants> basically i'm given an array and an index..and a default value
<baggypants> if the index is in the array..return the value at that index
<baggypants> if not..return the default value
<baggypants> but one of their test cases is passing in [nil, nil] for the array
<baggypants> and my if index == nil fails
hanmac has quit [Quit: Leaving.]
bricker`LA has quit [Ping timeout: 248 seconds]
<baggypants> ahh awesome.
Criztian has joined #ruby
hanmac has joined #ruby
MrThePlague has joined #ruby
<baggypants> wow this form of docs is way better than ruby-doc.org
RichardBaker has joined #ruby
RichardBaker has quit [Client Quit]
yekta has joined #ruby
relix has joined #ruby
Dave has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
hamed_r has joined #ruby
Bira has joined #ruby
Dave is now known as Guest39178
Bira has quit [Remote host closed the connection]
maletor has joined #ruby
RichardBaker has joined #ruby
mansi has joined #ruby
snath has quit [Ping timeout: 248 seconds]
clov3r has quit [Read error: Connection reset by peer]
clov3r has joined #ruby
buibex has quit [Remote host closed the connection]
ssvo has joined #ruby
Xeago has quit [Remote host closed the connection]
JumpMast3r has quit [Quit: JumpMast3r]
Xeago has joined #ruby
noop has quit [Ping timeout: 245 seconds]
buibex has joined #ruby
LMolr has joined #ruby
Bira has joined #ruby
duggiefresh has joined #ruby
noop has joined #ruby
dodosan has joined #ruby
duggiefr_ has quit [Ping timeout: 276 seconds]
Splourian has joined #ruby
Seich has quit [Ping timeout: 245 seconds]
tobago has quit [Remote host closed the connection]
Liquid-- has joined #ruby
dankest has joined #ruby
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
sloucher has joined #ruby
g0bl1n has joined #ruby
g0bl1n has joined #ruby
g0bl1n has quit [Max SendQ exceeded]
splud_ has quit [Quit: splud_]
xiphias has joined #ruby
g0bl1n has joined #ruby
Seich has joined #ruby
mklappstuhl has quit [Remote host closed the connection]
Urizen has quit [Ping timeout: 256 seconds]
user258467 has quit [Quit: Quitte]
<Suit_Of_Sables> my only complaint with ruby is the lack of the ++ or -- unary operators. I know it is silly, I just have an irrational fondness for them
schaerli has quit [Remote host closed the connection]
digital-ghost has joined #ruby
<canton7> do you know why they don't exist?
nari has quit [Ping timeout: 264 seconds]
<Suit_Of_Sables> canton7: Oooo, tell me!
Bosox20051 has quit [Read error: Connection reset by peer]
jkline has joined #ruby
<shevy> because numbers in ruby cheat
<Suit_Of_Sables> because they are objects?
<shevy> not so much
<canton7> ++ would mutate the number. mutation isn't a very good idea when you've got lambdas capturing stuff all over the place
<apeiros> and numbers are immutable
<canton7> ^^ exactly
Speed has joined #ruby
<Suit_Of_Sables> but you can make method calls on numbers right? like 5.times so they are objects right?
<shevy> Suit_Of_Sables x = 5.5; def x.hi; puts "hi"; end; TypeError: cant define singleton method "hi" for Float
browndawg has joined #ruby
<|jemc|> python cheats in the same way, but retains those operators. However, I've never eeven really wanted to use them in ruby because the enumerables are so great
<|jemc|> I rarely if ever have to increment an index by hand
<Suit_Of_Sables> I just like how concise and clean n++ looks :p
<apeiros> there was some rationale why aliasing a++ to (a = a.succ) was a bad idea…
<apeiros> wonder what that was
<shevy> Suit_Of_Sables doesn't n+ look cleaner? :P
<Suit_Of_Sables> apeiros: yeah, I was just going to ask about .succ being used to increment a number like ++
<apeiros> for one it would obviously not work with literals, e.g. 5++, but that could be special cased to just alias as (5.succ)
<hanmac> Suit_Of_Sables: you can overload the +@ method … ;P but its not nice
<shevy> 5.succ # => 6
dodosan has quit [Remote host closed the connection]
<apeiros> not sure C would actually allow 5++
<Suit_Of_Sables> shevy: not as pretty though O_O
hamed_r has quit [Quit: Ex-Chat]
lethjakman has joined #ruby
<canton7> apeiros, http://codepad.org/Bk3NDJWq
<lethjakman> hrm, I just learned inject and I think it's really cool. is there anywhere that's good for learning other cool tools ruby provides?
<canton7> lethjakman, read the doc pages for Array, String, Enumerable, Hash
<shevy> only the cold dark world that is called reallife
<apeiros> canton7: hah, ok, so that wouldn't even be an issue.
<shevy> and rails people
<canton7> Enumerable is probably the one to start with
<shevy> like apeiros (!!!)
utdemir has quit [Quit: Leaving]
<Suit_Of_Sables> hanmac: so the addition operator is just a method in Ruby? Like how in an asignment statement the '=' actually refers to a method?
<lethjakman> canton7: fair enough, that's what I was doing.
Elhu has quit [Quit: Computer has gone to sleep.]
<Xeago> Suit_Of_Sables: correct!
<apeiros> hm, really wonder now what the reason against the transformation of `a++` --> `(a = a.succ)` is then
<canton7> >> a = 2; a.+(2)
<eval-in> canton7 => 4 (https://eval.in/49128)
<Xeago> there is also the 'indexer' method: #[](index)
<|jemc|> Suit_Of_Sables: yes, but not all operators in ruby are overloadable methods
<apeiros> maybe the precedence part of prefix/suffix ++/--
xiphias has quit [Quit: leaving]
<MrZYX> apeiros: discourage the usage of classical for loops?
<Xeago> >> a=[1,2,3]; a.[](1)
<eval-in> Xeago => 2 (https://eval.in/49129)
xiphias has joined #ruby
<|jemc|> MrZYX: +1
<Xeago> >> a=[1,2,3]; a[1]
<eval-in> Xeago => 2 (https://eval.in/49130)
<apeiros> Suit_Of_Sables: assignment is not a method
<hanmac> Suit_Of_Sables: yes … a - b is a method call … but -a is also an method call (compare −1 and (- 1) )
<apeiros> there are methods which end with '=', but those are technically not assignments ;-)
brbcoding has quit []
<hanmac> >> defined?(-1)
<eval-in> hanmac => "expression" (https://eval.in/49131)
<hanmac> >> defined?(- 1)
<eval-in> hanmac => "method" (https://eval.in/49132)
<apeiros> -1 is parsed as a literal
<apeiros> -a invokes -@
<Suit_Of_Sables> apeiros: well NOW I'm confused :p
<hanmac> apeiros: yeah thats what i wanted to show him
<apeiros> Suit_Of_Sables: `a = 1` -- assignment, not a method call
<apeiros> Suit_Of_Sables: `x.a = 1` -- method call, not an assignment. calls the method "a=" on the object referenced by the expression `x`
<Suit_Of_Sables> but because numbers are immutable you can't have stuff like a+!1 to increment it in place?
Lewix has joined #ruby
Spami has quit [Quit: This computer has gone to sleep]
<apeiros> you can't have e.g. 2.succ!
jprovazn has joined #ruby
alup has quit [Quit: Leaving]
<apeiros> or `a = 2; a.succ!; a # => 3`
underway47 has quit [Ping timeout: 264 seconds]
dsferreira has quit [Quit: This computer has gone to sleep]
<apeiros> that's because the object is immutable.
graft has quit [Ping timeout: 264 seconds]
<apeiros> the distinction between variable and object is important.
<hanmac> hm you can when you put the 2 into an decorator object that handles the succ! method via method missing
<Suit_Of_Sables> apeiros: ah, yeah I was just going to ask that
<apeiros> the only way to change a *variable* is by assignment
<apeiros> the only way to change an *object* is through mutation
<Suit_Of_Sables> apeiros: because the variable is only a reference?
<apeiros> so `a = "hello"; a.succ!` - the variable is untouched. the object itself is being changed
<hanmac> yeah you get it ! :D
<apeiros> Suit_Of_Sables: correct
brianpWins has joined #ruby
<Suit_Of_Sables> yay!
lele has quit [Ping timeout: 245 seconds]
underway47 has joined #ruby
<Suit_Of_Sables> I must say ruby is the first language I've found where the syntax and method names are intuitive. But I guess that is what they were going for. It almost makes coding... dun!
snath has joined #ruby
<Suit_Of_Sables> *fun!
<apeiros> dun dun dun!
<yaymukund> dun!
<apeiros> ;-)
<yaymukund> :D
<Suit_Of_Sables> beethoven's 5th eh?
awarner_ has quit [Ping timeout: 245 seconds]
<hanmac> hm it also makes "pun" ;D
filipe has quit [Read error: Connection reset by peer]
<apeiros> wasn't it the 9th?
<apeiros> blerp
<Suit_Of_Sables> <-- idiot
<apeiros> no idea :)
<hanmac> in ruby everything succs … even symbols :D
<hanmac> >> :symbol.succ
<eval-in> hanmac => :symbom (https://eval.in/49133)
jkline has quit [Quit: jkline]
oliver_ has joined #ruby
<|jemc|> ha
<Suit_Of_Sables> bwah!? I'll have to .succ a symbol in irb and experiment
jkline has joined #ruby
brain_shim has quit [Ping timeout: 264 seconds]
Zolo has joined #ruby
<hanmac> Suit_Of_Sables: there are some methods in symbol that calls automaticly to_s.meth.to_sym … like symbol.upcase
<hanmac> >> :abc.upcase
<eval-in> hanmac => :ABC (https://eval.in/49134)
kayloos has joined #ruby
graft has joined #ruby
graft has joined #ruby
lele has joined #ruby
<hanmac> some methods return the same as if symbol where a string
<hanmac> >> :abc[/b/]
<eval-in> hanmac => "b" (https://eval.in/49137)
ziyadb has quit [Quit: Connection closed for inactivity]
iamjarvo has quit [Remote host closed the connection]
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
AdmiraI has joined #ruby
kayloos has quit [Remote host closed the connection]
iamjarvo has joined #ruby
<Suit_Of_Sables> hehe this was in my ruby book to explain map: ['H', 'A', 'L'].map { |x| x.succ } => ['I', 'B', 'M']
<Suit_Of_Sables> for you 2001 fans
Clooth has quit [Read error: Connection reset by peer]
Elhu has joined #ruby
xiphias has quit [Quit: leaving]
xiphias has joined #ruby
timonv has joined #ruby
<hanmac> it can be shorted into
<hanmac> >> %w{H A L}.map &:succ
<eval-in> hanmac => ["I", "B", "M"] (https://eval.in/49138)
nadirvardar has joined #ruby
<lethjakman> hanmac: how does that &: work?
<Xeago> &: is shorthand for symbol to proc
havenwood has joined #ruby
Stygia has quit [Remote host closed the connection]
<lethjakman> Xeago: proc?
kofno has quit [Ping timeout: 248 seconds]
IceyEC has quit [Quit: IceyEC]
<Xeago> Proc's are ruby constructs, kinda like lambda's, closures etc
<lethjakman> ahh ok.
<|jemc|> >> pr=Proc.new { |x| x+5 }; pr.call 5
<eval-in> |jemc| => 10 (https://eval.in/49140)
<hanmac> lethjakman: &:succ is short for {|s| s.succ }
rupee has joined #ruby
<hanmac> ok its not the same but similar enough
<lethjakman> hanmac: interesting...can you do multiple lines like that?
<lethjakman> how's it different?
<apeiros> obj.foo(&other_object) --> invokes other_object.to_proc, then passes the result as the block to foo
<shevy> lethjakman sure
jonkri has quit [Quit: jonkri]
<shevy> lethjakman one difference is that it looks like shit
iamjarvo has quit [Ping timeout: 264 seconds]
kofno has joined #ruby
<|jemc|> anytime you see a do..end block - it is passing a proc imnplicitly
<apeiros> and :foo.to_proc returns the equivalent of proc { |receiver, *args| receiver.foo(*args) }
Croms has joined #ruby
* hanmac prefers {} over do .. end even for multiline
<lethjakman> shevy: lol. it is a little confusing...but I didn't know if this was commonly used in ruby.
<apeiros> or more abstract, it returns proc { |receiver, *args| receiver.__send__(self, *args) }
<|jemc|> and the things you are passing to #map and #each are procs as well
<shevy> lethjakman it is ok if you want to chop off some characters, but it is also slower
<apeiros> hence x.map(&:succ) becomes { |e| e.succ }
Liquid-- has quit [Quit: Computer has gone to sleep.]
<lethjakman> shevy: is it really?
<lethjakman> why?
andikr has quit [Remote host closed the connection]
<|jemc|> an extra call to #to_proc
<lethjakman> is there a name for this? &: isn't bring up any good search results.
<shevy> [" abc", "def ", " g hi "].map(&:strip) # => ["abc", "def", "g hi"]
<shevy> [" abc", "def ", " g hi "].map {|_| _.strip} # => ["abc", "def", "g hi"]
<|jemc|> http://symbolhound.com/ is good for searching for programming-related symbols
Xeago has quit [Remote host closed the connection]
<shevy> lethjakman dunno, google for to proc conversions
<lethjakman> ok, thanks guys
LMolr has quit [Remote host closed the connection]
<lethjakman> interesting way of doing things
<shevy> it's for lazy people
<ccooke> some people prefer to call to_proc directly.
<shevy> in ruby a lot of the magic exists because people are so lazy
<shevy> now java, these are brave guys
cody-- has quit [Quit: derp]
<lethjakman> shevy: I don't think I'd use it if it's slower, and harder to read. but I'm sure I'll see it somewhere.
<shevy> they never get tired of verbose code
<shevy> lethjakman do you use ruby for the speed?
<lethjakman> some may say too verbose
AdmiraI is now known as Admiral
T_T has joined #ruby
Speed has left #ruby ["WeeChat 0.4.1"]
<shevy> lethjakman for the simple examples it is not that much harder to read
<hanmac> shevy: i will make a ticket so that &:sym should be get the same speed as {|s| s.sym} ;P i mean maybe the parser can be tweaeked in this way ;P
<lethjakman> shevy: no, but if something saves me < 3 lines and makes an impact I probably won't use it. especially if it affects ureadability.
<shevy> (&:strip) vs {|_| _.strip}
iartarisi has quit [Remote host closed the connection]
DanKnox_away is now known as DanKnox
Spami has quit [Quit: This computer has gone to sleep]
<Suit_Of_Sables> wow, the inject method is bananas
<shevy> & is a bit cleaner and shorter but not that much
<shevy> it adds a : character which I hate
sarlalian has joined #ruby
<shevy> well actually
<hanmac> shevy _ is also an magical variable because ruby does not warn you when use use them multible times in the same block
Ox6abe has joined #ruby
<lethjakman> Suit_Of_Sables: isn't it cool?
<shevy> I am fine with : but just not when it is connected with &
Coolhand has quit [Ping timeout: 276 seconds]
jkline has quit [Quit: jkline]
awarner has joined #ruby
yekta has quit [Quit: yekta]
kayloos has joined #ruby
<shevy> cat = Cat.new; cat.jump_to :home
<shevy> cat = Cat.new; cat.jump_to(:home)
<shevy> cat = Cat.new; cat.jump_to(&:home)
EIA has joined #ruby
BillCris_ has joined #ruby
<shevy> lethjakman have you seen the -> construct yet?
<lethjakman> shevy: I don't think so.
<shevy> lethjakman ok... be prepared for REALLY ugly shit ...
<shevy> _ = ->(x){ x+1 }
<shevy> there you go!
<lethjakman> shevy: is that like a lambda?
<lethjakman> looks like coffeescript to me.
VTLob has joined #ruby
IceyEC has joined #ruby
<shevy> yeah
<hanmac> shevy: this one is also an variant that is similar to the first ones: cat = Cat.new; cat.jump_to:home
<shevy> the above will yield:
<lethjakman> didn't realize ruby could do that.
<shevy> #<Proc:0xac13018@(irb):4 (lambda)>
<shevy> so you can use .call on the result to call the value
kayloos has quit [Remote host closed the connection]
Coolhand has joined #ruby
<shevy> but I hate this particular syntax
<ccooke> shevy: it's ugly
<shevy> p = lambda {|a,b,c| a+b+c}
<lethjakman> shevy: it's short, but it is ugly.
<shevy> p = -> a,b,c {a+b+c}
<shevy> !!!
<shevy> yeah, it's indeed shorter
<Suit_Of_Sables> lethjakman: yeah, summing an array with arr.inject(:+) :)
<shevy> I think in ruby, a major design principle is shortness
<ccooke> it's not much shorter, and a *lot* less clear
<shevy> and as a side-effect of that comes elegance hehehe
kilophoton has joined #ruby
<shevy> except for when new operators are added
<ccooke> and it's less defendable than &:sym
jkline has joined #ruby
<shevy> or existing rules behave differently
<shevy> agreed ccooke
BillCriswell has quit [Ping timeout: 245 seconds]
<shevy> I am scared of ruby 3.0 already :(
<shevy> hanmac surely loves it already
<ccooke> because & has a long history of "hey, I'm probably going to do something with callable code here"
Bira has quit []
<shevy> lethjakman I think matz indeed thought that -> looks like a lambda character
<ccooke> (okay, c uses it for an address, but one of the key uses was the address of a function)
nadirvardar has quit [Quit: Computer has gone to sleep.]
noop has quit [Ping timeout: 245 seconds]
Coolhand has quit [Client Quit]
<hanmac> shevy no you are not scared of ruby3.0 … you are scared what Hanmac will do with ruby3.0 :D
Coffers has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
Bira has joined #ruby
mikecmpbll has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
rupee has quit [Quit: Leaving]
JohnBat26 has quit [Ping timeout: 260 seconds]
dodosan has joined #ruby
IceyEC has quit [Quit: IceyEC]
<banisterfiend> shevy haskell uses \ (which they think also look like lambda character bb)
ta has quit [Remote host closed the connection]
Zolo has quit [Remote host closed the connection]
rickmasta has quit [Quit: Be back later]
Elhu has quit [Quit: Computer has gone to sleep.]
dodosan has quit [Remote host closed the connection]
ghr has quit [Quit: Computer has gone to sleep.]
<Suit_Of_Sables> I'm pretty annoyed that my school has no CS classes using Ruby ;(
kofno has quit [Ping timeout: 245 seconds]
<banisterfiend> Suit_Of_Sables what language do they use?
jkline has quit [Quit: jkline]
<BraddPitt> when making a method that takes no paramters, is it okay to use empty parens?
<BraddPitt> or should i omit them completely
<hanmac> Suit_Of_Sables: let me guess … they have C# but no C++ ? ;P
<Suit_Of_Sables> It's all C, Java, Objective C, Shell Scripting, and a little python
threesome has joined #ruby
<yaymukund> BraddPitt: typically you omit them
tabolario has joined #ruby
<yaymukund> BraddPitt: if they're there, it looks like python code
<yaymukund> imo
<Suit_Of_Sables> Not very forward thinking or open minded at the university it would seem
<BraddPitt> i know ( ≖‿≖)
<BraddPitt> (i came from python)
kofno has joined #ruby
randomautomator has joined #ruby
<Suit_Of_Sables> I was trying to see if MIT had any courses that used Ruby
dhruvasagar has joined #ruby
lfox has quit [Quit: ZZZzzz…]
<BraddPitt> ah no, thank you hanmac
kaspergrubbe has quit [Read error: Operation timed out]
<BraddPitt> never seen that
iamjarvo has joined #ruby
timonv has quit [Remote host closed the connection]
vmoravec has quit [Quit: Leaving]
<banisterfiend> Suit_Of_Sables obj-c is cool, you're lucky to learn that
Voodoofish430 has joined #ruby
<banisterfiend> i really like the obj-c OO model
robertjpayne has quit [Remote host closed the connection]
rins has quit [Ping timeout: 245 seconds]
<Suit_Of_Sables> banisterfiend: good to hear, I was hesitant
<banisterfiend> Suit_Of_Sables obj-c and ruby are conceptually very similar
<banisterfiend> of course their syntax is very different
<banisterfiend> but they both have smalltalk style OO
kofno has quit [Ping timeout: 245 seconds]
<Suit_Of_Sables> I should be studying C right now, but Ruby stole my heart
kofno has joined #ruby
DanKnox is now known as DanKnox_away
<Suit_Of_Sables> Oooh well, my C class is a joke
* hanmac tamed C and C++ so they workship for me and my evil ruby plans ;D
<banisterfiend> Suit_Of_Sables C is very important
<banisterfiend> Suit_Of_Sables if you know C you can do a tonne of interesting stuff in Ruby (write C extensions, hack on internals, debug complicated issues, etc)
Splourian has quit [Quit: Leaving]
noname001 has quit [Ping timeout: 264 seconds]
DanBoy has quit [Remote host closed the connection]
<Suit_Of_Sables> banisterfiend: I do like C, don't get me wrong. I've been having much more fun working with it than with *shudder* Java
bricker`LA has joined #ruby
<Suit_Of_Sables> C is one language I want to become more compitent with. Right now I'm trying to maintain focus on it and Ruby
<hanmac> like banister said "hack on internals" is the veryDarkArt of Ruby … (like changing the ruby class inplace ;P )
bricker`1A has quit [Ping timeout: 256 seconds]
mikepack has joined #ruby
Ripp__ has joined #ruby
freerobby has quit [Quit: Leaving.]
<lethjakman> Suit_Of_Sables: I'm with you, I feel like C and C++ are a lot more fun to ork in than java.
<Suit_Of_Sables> I find that learning multiple languages at once is actually helpful. I've even found that to be the case in spoken language. Somehow seeing the differences helps you understand each one that much better and it also makes the similarities that much cleaer
freerobby has joined #ruby
<lethjakman> Suit_Of_Sables: what languages do you know?
Gooder has quit [Ping timeout: 264 seconds]
DanBoy has joined #ruby
rickmasta has joined #ruby
kofno has quit [Ping timeout: 276 seconds]
pontiki has joined #ruby
iamjarvo has quit [Remote host closed the connection]
<Suit_Of_Sables> lethjakman: C, Java, Ruby, and a little Python. I only started coding recently. And I'm not very confident in any of them. I want to try a functional language next. I'm leaning towards haskell but I guess I should peek at clojure and scala as well eh?
<BraddPitt> I don't mind java that much
<BraddPitt> but i fucking HATE maven
<BraddPitt> and spring, but to a lesser extent
iamjarvo has joined #ruby
<lethjakman> Suit_Of_Sables: clojure is really interesting to learn, you'll have a great understanding of some weird concepts if you go with that one.
ddv has quit [Changing host]
ddv has joined #ruby
<lethjakman> it just lays things out differently.
<lethjakman> I like it a lot, I wish it were more popular.
girija has joined #ruby
<banisterfiend> lethjakman weider concepts if he learns haskell instead ;)
<banisterfiend> weider*
<banisterfiend> weirder* damnit
pushpak has joined #ruby
<Suit_Of_Sables> weird is good
<Suit_Of_Sables> haskell more mathy?
<lethjakman> banisterfiend: yeah? I don't know haskell. I know they have some odd concepts with their lazy loading though.
<lethjakman> Suit_Of_Sables: nah.
SJr has quit [Max SendQ exceeded]
<lethjakman> languages aren't erally mathy unless you're doing math.
SJr has joined #ruby
<banisterfiend> lethjakman haskell is definitely 'mathy'
<lethjakman> banisterfiend: how?
<lethjakman> maybe I don't understand the term mathy.
kevinykchan has quit [Quit: Computer has gone to sleep.]
<Suit_Of_Sables> well, do some languages have a way of representing infinity built into their core library?
<banisterfiend> lethjakman category theory, monoids, algebras, co-algebras
<lethjakman> banisterfiend: but how is that built into one language differently than another?
<banisterfiend> lethjakman even its type system (algebraic types) is 'mathy' :)
<lethjakman> huh
<lethjakman> sounds like fun, I'll put it on my to play with list.
iamjarvo has quit [Ping timeout: 245 seconds]
<banisterfiend> lethjakman because it's explicit in haskell i guess, it even uses the same terminology as category theory, functors, applicative functors, monoids, monads
Guest39178 has quit [Quit: Leaving...]
<Suit_Of_Sables> sorry, this is a very silly and basic question. Can one actually read the source code implementation of all of the built in java classes/methods to see exactly how they are implemented? Is that on the doc site as well?
mercwithamouth has joined #ruby
<banisterfiend> Suit_Of_Sables java or ruby?
<Suit_Of_Sables> ruby
<banisterfiend> Suit_Of_Sables you said java ;)
<banisterfiend> Suit_Of_Sables yes, check out pry for that: http://pryrepl.org
kidoz has joined #ruby
<Suit_Of_Sables> Oh, i'm an idiot
<banisterfiend> Suit_Of_Sables i think some doc sites offer code browsing too, but I'm not sure
DanKnox_away is now known as DanKnox
<Suit_Of_Sables> banisterfiend: Thanks, I think that will be most helpful in really breaking this down
<hanmac> Suit_Of_Sables: it depends on the Ruby implementation … the MRI ruby (the reference) is written in C … but there is also JRuby in java and other ones (like Topaz is in Python-like)
chrisja has joined #ruby
girija has quit [Read error: Operation timed out]
geox_ has joined #ruby
senayar_ has quit [Remote host closed the connection]
<hanmac> Suit_Of_Sables: this http://www.ruby-doc.org/core-2.0/ shows the source
cj3kim has joined #ruby
dodosan has joined #ruby
axl_ has quit [Quit: axl_]
<Suit_Of_Sables> hanmac: sweeeet thanks!
pzula has quit [Quit: Lost terminal]
pzula has joined #ruby
carraroj has joined #ruby
JJasonClark has joined #ruby
jgrep has joined #ruby
<geox_> hey guys, I'm completely new to web programming but I have a projet that I'd like to start to learn with. I've already written a lot of code in python that I want to make usable through a web interface. The thing is, it's computationally intensize--matrix multiplications and things. What's the standard for this kind of thing? Place the burden on the client or server? Is ruby a good fit?
<jgrep> just moving from perl to ruby
<jgrep> any idea whats the idea of having a ? in function
rehat has joined #ruby
<jgrep> like h.has_key?('name')
<jgrep> its confusing
thecodethinker has quit [Ping timeout: 245 seconds]
<banisterfiend> jgrep predicate method
<Todd-> jgrep, it's expected that it will return a boolean
thecodethinker has joined #ruby
<banisterfiend> Todd- or simply that its return value should be treated as boolean
tabolario has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Todd-> banisterfiend, true
dangerousdave has joined #ruby
<jgrep> so if it returns a int or string then we dont use ?
<crowell> geox_: why not use python?
Coolhand has joined #ruby
aeontech has joined #ruby
BraddBitt has joined #ruby
<crowell> if you are already comfortable with it, python's matplotlib is a lot better than anything that ruby has
JJasonClark has left #ruby [#ruby]
<Todd-> banisterfiend, though our internal policy states that methods which are prefixed with ? will always return a boolean
carraroj has quit [Client Quit]
<geox_> crowell: that's part of my question. If I decide to use python, does that mean I need to use something like django or web2py?
carraroj has joined #ruby
<Todd-> banisterfiend, suffixed rather
apeiros has quit [Remote host closed the connection]
<BraddBitt> man
<BraddBitt> why does ruby not have ++/00
<BraddBitt> er
BraddPitt has quit [Ping timeout: 264 seconds]
<BraddBitt> --
adambeynon has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
RichardBaker has quit [Quit: RichardBaker]
BraddBitt is now known as BraddPitt
<crowell> geox_: there are plenty of python frameworks
<banisterfiend> Todd- fair enough, that's only an issue when playing in the console though i expect
saarinen has joined #ruby
<jgrep> thnx
<crowell> django, bottle, etc.
Monie has joined #ruby
chopmo has quit [Remote host closed the connection]
<crowell> geox_: depends on the scale and what you are trying to achieve
saarinen has quit [Client Quit]
<banisterfiend> Todd- right?
Targen has quit [Ping timeout: 256 seconds]
<jgrep> crowell: why no just a cgi? it totally depends on what is it you are trying to achieve
<Veejay> BraddPitt: += does the same thing
kaldrenon has quit [Remote host closed the connection]
<crowell> jgrep: that too :P, I was thinking more along the lines of using a python framework
<geox_> jgrep: To clarify, cgi is code that's run server side, requested with some parameters by the client?
<Suit_Of_Sables> in general will shell scripts run faster on a linux machine than a comperable ruby script? When I write stuff stuff for bash it is just so damn ugly. I guess I shouldn't be concerned about speed.
RichardBaker has joined #ruby
kaldrenon has joined #ruby
<geox_> Is it necessary that I use a python framework to use the python that I have?
<Suit_Of_Sables> *comparable
<jgrep> geox_: doesnt python / ruby also run on the server side
<|jemc|> Suit_Of_Sables: that might be true but you should value your time more than your processor's time in most cases
Seich has quit [Ping timeout: 264 seconds]
interactionjaxsn has quit [Remote host closed the connection]
<geox_> jgrep: I'm confused what you're asking. Are you asking if my python code runs on my computer?
aliljet_ is now known as aliljet
cj3kim has quit [Remote host closed the connection]
<jgrep> never mind :)
lfox has joined #ruby
interactionjaxsn has joined #ruby
shredding has quit [Quit: shredding]
adambeynon has joined #ruby
<jgrep> ok i was trying this http://www.humblelittlerubybook.com/book/html/images/references.jpg shouldnt it only store the reference
<hanmac> geox_ & jgrep it depends … i have seen an ruby interpreter written in javascript … which would run on client side ;D
<Todd-> banisterfiend, I suppose. (sorry for the lag I'm playing with my xchat theme)
<Todd-> banisterfiend, We have less than desirable people working with our framework doing UI testing so... consistency is really important to keep them from doing things incorrectly.
girija has joined #ruby
noop has joined #ruby
Todd- is now known as Todd
kaldrenon has quit [Ping timeout: 240 seconds]
<Suit_Of_Sables> |jemc|: exactly, I will sacrifice a few milliseconds if it means my code is shorter and/or easier to read
baggypants has quit [Quit: Textual IRC Client: www.textualapp.com]
Seich has joined #ruby
<geox_> Is it common nowadays for a framework to work with html5? If I want to create a canvas element, specifically a graph, would I be able to do with with django?
<jgrep> same with strings http://pastebin.com/hmHJS3ZB why isnt it storing a reference
codecop has joined #ruby
alexju has quit [Remote host closed the connection]
<banisterfiend> Todd fairynuff
<crowell> geox_: yes
alexju has joined #ruby
tylersmith has joined #ruby
<crowell> geox_: you can just use the python to create the needed html markup depending on your data
freeayu has quit [Remote host closed the connection]
interactionjaxsn has quit [Ping timeout: 268 seconds]
premera_j_n_h has joined #ruby
vadviktor__ has quit [Read error: Operation timed out]
premera_j_n has quit [Ping timeout: 248 seconds]
DanKnox is now known as DanKnox_away
vadviktor_ has joined #ruby
<hanmac> jgrep: you assign ObjectA to a, then you assign the object in a (ObjectA) to b, then you assign ObjectB to b … the variable a stays untouched … (i think you may look for the replace method)
Teddy2steper has joined #ruby
optimusprimem has quit [Ping timeout: 245 seconds]
duggiefr_ has joined #ruby
alexju has quit [Ping timeout: 240 seconds]
cody-- has joined #ruby
Teddy2steper has quit [Remote host closed the connection]
duggiefresh has quit [Ping timeout: 245 seconds]
jdeeburke has joined #ruby
ixti has quit [Ping timeout: 256 seconds]
jdeeburke has quit [Max SendQ exceeded]
Bira has quit [Read error: Connection reset by peer]
tonni has joined #ruby
jdeeburke has joined #ruby
jdeeburke has left #ruby [#ruby]
c0rn has joined #ruby
Bosox20051 has joined #ruby
baggypants has joined #ruby
kaldrenon has joined #ruby
Cyrus has quit [Quit: Cyrus.sleep()]
mercwithamouth has quit [Ping timeout: 248 seconds]
Teddy2steper has joined #ruby
alexju has joined #ruby
duggiefresh has joined #ruby
Teddy2steper has quit [Remote host closed the connection]
<BraddPitt> so for ``private'' in a class, every method UNDER that keyword is private?
<jgrep> is there some doc whee i can understand things like ! and ? that are used in ruby
saarinen has joined #ruby
mercwithamouth has joined #ruby
<MrZYX> BraddPitt: if you give no argument to it
Urizen has joined #ruby
freerobby has quit [Quit: Leaving.]
<MrZYX> jgrep: !smthg is a method call, so look for the ! method on objects. ? in what context?
RichardBaker has quit [Quit: RichardBaker]
ravster has quit [Quit: Leaving.]
<BraddPitt> MrZYX example of arguments? I'm just learning classes
kidoz has quit [Quit: Ухожу я от вас]
duggiefr_ has quit [Ping timeout: 264 seconds]
<MrZYX> private :foo makes the method foo private
<BraddPitt> ah okay, thank you
mark_locklear has quit [Ping timeout: 260 seconds]
RichardBaker has joined #ruby
<Suit_Of_Sables> for what I'm reading it looks like :method_name is the syntaxed used when passing a method as a parameter (like to an enum or to the inject method). Can you attempt to pass any old method to any other method? Or does one or both of them require some specific implementation (I'm thinking of Interface but that is Java-speak and don't know if it's applicable here) to allow for this sort of behaviour?
Spami has joined #ruby
Spami has joined #ruby
Spami has quit [Changing host]
alexju has quit [Ping timeout: 264 seconds]
<banisterfiend> Suit_Of_Sables in ruby we don't typically pass methods aronds, we pass blocks around
<Suit_Of_Sables> hmm are we just passing a symbol in the call arry.inject(:+) and if so, does that symbol refer to the + method?
<hanmac> you can also pass method objects around ;P like
<Suit_Of_Sables> or, should I say, the symbol refers to a block that contains the + method?
<hanmac> >> a=3.method(:+); a.call(4)
<eval-in> hanmac => 7 (https://eval.in/49142)
alexju has joined #ruby
Zai00 has quit [Quit: Zai00]
<MrZYX> .inject just does an implicit to_proc when given a symbol and no block
ffranz has joined #ruby
elaptics is now known as elaptics`away
<Suit_Of_Sables> MrZYX: ah, is that the same for enums?
<reactormonk> is there a way to get the method object of the current method?
<hanmac> Suit_Of_Sables & MrZYX: inject is a bit different … there is inject(:+) and inject(&:+) … last one does makes a proc, first one does not
<banisterfiend> reactormonk method(__method__)
<MrZYX> Suit_Of_Sables: what enums?
<MrZYX> never saw on in ruby
<reactormonk> banisterfiend, sweet
<MrZYX> Suit_Of_Sables: or are you referring to methods in Enumerable?
<Suit_Of_Sables> hanmac: So in your first example does the inject method get passed the + method itself? Or a symbol that refers to it?
obs has quit [Quit: Konversation terminated!]
jbrechtel has joined #ruby
<MrZYX> it's a symbol
fgo has quit [Remote host closed the connection]
<Suit_Of_Sables> MrZYX: Enumerable objects, like 'a' in: a = "string".enum_for(:each_char)
<MrZYX> that are Enumerator's
optimusprimem has joined #ruby
optimusprimem has joined #ruby
mercwithamouth has quit [Ping timeout: 268 seconds]
<MrZYX> (they include Enumerable though)
gianlucadv has quit [Quit: ZNC - http://znc.sourceforge.net]
SJr has quit [Ping timeout: 245 seconds]
<MrZYX> and .each_char already returns one if given no block
<MrZYX> no need to wrap it into another one
jbrechtel has quit [Remote host closed the connection]
<Suit_Of_Sables> if this was java we would say something like "they implement the enumberable interface"?
ramblex has quit [Read error: Connection reset by peer]
<pontiki> this isn't java
<pontiki> this is sparta
<|jemc|> ha
spider-mario has joined #ruby
<Suit_Of_Sables> pontiki: I know, i know
<MrZYX> Enumerable is a module that's mixed into the class, it's more than an interface, it includes the implementation
<hanmac> Suit_Of_Sables: interfaces in java or PHP are a totally joke because in ruby they works totally different
<pontiki> no, seriously, there is not a one-to-one mapping of concepts in this case
ZoanthusR has joined #ruby
ZoanthusR has quit [Client Quit]
<MrZYX> in ruby we define needed interfaces in the documentation and don't restrict programmers to it
mengu has joined #ruby
jgrep has quit [Ping timeout: 256 seconds]
gianlucadv has joined #ruby
<Suit_Of_Sables> pontiki: ok, but when you say a class 'includes' enumerable that means it inherits it's methods right?
<MrZYX> in code we just assume it's there
sambao21 has quit [Quit: Computer has gone to sleep.]
ixti has joined #ruby
<pontiki> yes, it does
<reactormonk> was there anything to get local variables parametric besides eval?
<hanmac> reactormonk: no
sr78ger has quit [Ping timeout: 248 seconds]
<MrZYX> reactormonk: sounds like you actually want a Hash
SJr has joined #ruby
<reactormonk> hanmac, ok
<banisterfiend> reactormonk there is in 2.1 i think
<reactormonk> banisterfiend, ok
<banisterfiend> reactormonk it's something like binding.get_local("x") i think
RichardBaker has quit [Quit: RichardBaker]
Tuxist has joined #ruby
iamjarvo has joined #ruby
adambeynon has quit [Quit: Textual IRC Client: www.textualapp.com]
Collin has joined #ruby
<Suit_Of_Sables> so one main difference is that in a java interface, these methods are decalred but not explicitly implemented, while in ruby something that is include inherits a fully implemented method from the included class? (Though I suppose it could be overrided in the class doing the including much like you can override the default .to_s method?) ?? Is that atleast one of the ways in which these concepts don't equate?
<banisterfiend> Suit_Of_Sables included module*
lukec has quit [Quit: lukec]
<Suit_Of_Sables> banisterfiend: ooops module, not class
girija has quit [Ping timeout: 240 seconds]
<hanmac> Suit_Of_Sables: extreme sample:
<hanmac> >> o = Object.new; o.extend(Enumerable); p o.respond_to?(:sort); o.sort
<eval-in> hanmac => true ... (https://eval.in/49143)
<banisterfiend> Suit_Of_Sables and yes the class including the module can provide its own definition
nomenkun has quit [Ping timeout: 260 seconds]
amacgregor has quit [Read error: No route to host]
<banisterfiend> Suit_Of_Sables module inclusion is more or less equivalent to inheritance, so the module is just inserted into the lookup chain
<Suit_Of_Sables> banisterfiend: but it comes defined?
nadirvardar has joined #ruby
apeiros has joined #ruby
<banisterfiend> Suit_Of_Sables yes, if a module defines a method then the class that includes that module will have that method in its lookup chain
rickmasta has quit [Quit: Leaving...]
<reactormonk> banisterfiend, ok
<hanmac> the Enumerable module implments the sort method (so respond returns true), but the sort method depends on each which is neigher declared not implemented
<banisterfiend> reactormonk if u say 'ok' one more time I'm going to beat u
Bira has joined #ruby
hamakn has quit [Remote host closed the connection]
johnjohnson has joined #ruby
dankest has quit [Quit: Peace]
justsee has quit [Ping timeout: 245 seconds]
hamakn has joined #ruby
Targen has joined #ruby
freerobby has joined #ruby
Bira has quit [Remote host closed the connection]
nadirvardar has quit [Max SendQ exceeded]
<Suit_Of_Sables> thanks for being patient with me folks
<apeiros> the ruby community is awesome that way ;-)
rins has joined #ruby
optimusprimem has quit [Ping timeout: 245 seconds]
nadirvardar has joined #ruby
<hanmac> only the rails-tribe are idiots ;O
<hanmac> ;P
<apeiros> na
<apeiros> I'd disagree. but, whatever :)
dankest has joined #ruby
<banisterfiend> hanmac aren't you a php programmer in your day job? :P
allanm has joined #ruby
<hanmac> banisterfiend: yeah … (also with magento) … and i curse every minute of it ;P
<banisterfiend> hanmac wouldn't you rather do rails than php?
<SloggerKhan> Most people who do PHP don't have much of a choice.
hamakn has quit [Ping timeout: 268 seconds]
<hanmac> banisterfiend: i dont think so … (some rails code i have seen is worse than php)
<lethjakman> hanmac: oh my god
<lethjakman> I'm not alone!
<SloggerKhan> I ended up doing PHP in my first job because I couldn't find Django or Rails jobs without moving to the bay area.
<hanmac> lethjakman: you also need to do magento?
<lethjakman> yep. worst framework I've ever seen
<banisterfiend> SloggerKhan couldn't find a remote job either?
kofno has joined #ruby
sarlalian has quit [Quit: WeeChat 0.4.1]
<BraddPitt> SloggerKhan move the bay area
<lethjakman> they could at least release some good documentation...
<BraddPitt> its beautiful here
sarlalian has joined #ruby
interactionjaxsn has joined #ruby
carraroj has quit [Quit: Konversation terminated!]
<SloggerKhan> I like where I'm at. I'm getting a nice house with a mortgage that's lower than my rent is biking distance from work.
<SloggerKhan> And in any case, now I'm starting to use rails at my job.
Ripp__ has quit []
<hanmac> lethjakman: newest bug i have found in magento: when you make cms pages … and you pastie your code into them, and then save the page and open it again with the editor … the code has changed!!!! and it doesnt even ask you if you wanted that !!!
<SloggerKhan> *and is
<lethjakman> hanmac: ....ugh. I don't do the CMS stuff, I'm more data heavy/backend.
<lethjakman> oh my god...their tables. they couldn't have made them any more inconsistant.
hukl has joined #ruby
platzhirsch has joined #ruby
<platzhirsch> What's up in the Ruby mine?
<hanmac> i normally also do not so much cms but i get angry after the wysiwyg editor plays ugly games with me ...
<SloggerKhan> I have family in the bay area... getting anywhere takes an hour and the cheapest rent is like 3x what it is here for something nice.
<BraddPitt> where is ``here''
<BraddPitt> also you sound much older than me so maybe the city doesn't entice you as much as it does me
ghost2060 has joined #ruby
<SloggerKhan> Eh. I'm in my late 20s... lol.
pel_daniel has joined #ruby
<BraddPitt> yeah i'm 22, living inSF
<RubyPanther> Portland has as many Rubyists as SF, very low rent for its size, and an active urban geek culture
girija has joined #ruby
<BraddPitt> i want to visit portland
<BraddPitt> but >no surf
<SloggerKhan> I think Portland would be better than SF.
<platzhirsch> oh, west coast. I will soon start to prepare for job interviews again
<RubyPanther> Yeah it is 60 miles and a wet suit away from surfing
RichardBaker has joined #ruby
<ghost2060> SD, ruby + surf
<BraddPitt> same with SF but at least we have good waves here
<BraddPitt> s/good/decent
<BraddPitt> still would enjoy visiting though
<platzhirsch> So if anyone is looking for a new grad developer and is able to sponsor H1B, give me a hint :P
<BraddPitt> for coffee and drugs and camping
<BraddPitt> platzhirsch HN ``who's hiring?'' threads
<RubyPanther> Oregon has huge waves, if you're brave enough. The big thing now is kite surfing
<platzhirsch> BraddPitt: yeah...
<hanmac> hm it reminds me … i need to collect some ruby developers that want to work on some funny open-source project … (the bad thing is it would be cool if they can do C and C++ too)
Ripp__ has joined #ruby
<RubyPanther> <3 Ruby C
d2dchat has joined #ruby
<|jemc|> rubians.collect { |dev| dev.knows? :C }
DanKnox_away is now known as DanKnox
<platzhirsch> C and Ruby sounds like a nice combination. Strict rules on the one hand and anarchy on the other
kofno has quit [Ping timeout: 260 seconds]
Teddy2steper has joined #ruby
<hanmac> platzhirsch: its funny what extensions you can build with the mighty Power of C ;D
Monie has quit [Ping timeout: 268 seconds]
<platzhirsch> but don't mention C++
<platzhirsch> I'd rather go for object-oriented C :P
geox_ has quit [Quit: Page closed]
sam113101 is now known as sam113101_afk
<ghost2060> Question: after looping through an array, I test to see if I am at the last item in the array using an unless statement as I don't want to modify that item. When I'm at the last item, it skips the modification which is perfect; however, I get a TypeError: can't convert nil into String since the unless statement returns nil. How can I avoid that?
<crowell> platzhirsch: go with vala :-)
<hanmac> platzhirsch: hmhm i dont know obj-C … and the libs i bind are in C++ so i think i do ont have much choice
graft has quit [Ping timeout: 256 seconds]
<crowell> ghost2060: can you paste the code
<RubyPanther> the ruby C api provides most of a stdlib replacement, it can useful to embed a ruby interpreter in a C app just for the string processing and GC
<hanmac> ghost2060: use each_with_index or similar
Teddy2steper has quit [Remote host closed the connection]
Advocation has joined #ruby
awarner_ has joined #ruby
graft has joined #ruby
<BraddPitt> instance variables can be accessed from anywhere inside the class, right?
<platzhirsch> crowell: no, this http://www.cs.rit.edu/~ats/books/ooc.pdf !
sam113101_afk is now known as sam113101
npras has joined #ruby
brbcoding has joined #ruby
awarner has quit [Read error: Connection reset by peer]
<platzhirsch> hanmac: yeah... naturally. Just letting my inner language snop out
<apeiros> BraddPitt: depends which ivars
<apeiros> BraddPitt: in class scope, the ivars belong to the class object itself and not its instances.
<npras> hi
<hanmac> RubyPanther: the otherway around is also fun (or what about an ruby interpreter inside an C app, requiring an C++ gem? ;D )
<crowell> platzhirsch: no thanks
<BraddPitt> okay, ty
<ghost2060> crowell: this is the last line in my each do loop: note[i] << "..." unless i == last_note
<platzhirsch> crowell: I cannot tolerate your behavior
<crowell> ghost2060: yeah, you are going to want to do each_with_index
dangerousdave has quit [Read error: Connection reset by peer]
mark_locklear has joined #ruby
<waxjar> ghost2060 why don't you do something like arr[0..-2].each { … } instead?
dangerousdave has joined #ruby
<ghost2060> ok, i'll give that a shot - thanks all
npras has left #ruby [#ruby]
<crowell> ghost2060: something like arr.each_with_index{|v,i| blah unless i == arr.count}
<crowell> but what waxjar said is probably better
<crowell> platzhirsch: ;-)
lukec has joined #ruby
<platzhirsch> in each case I have to tidy up my C knowledge at hand, because I smell C coding interview questions in my near future.. can't help it
<crowell> most of the "c" i write, I end up having to throw the c++ compiler at it because I'm lazy
<platzhirsch> :]
lukec has quit [Client Quit]
<crowell> at least I don't default to boost
<RubyPanther> I like to write the autotools input files first, so I don't have to think too much about the compiler
<RubyPanther> let somebody at the FSF know about compilers
Clooth has joined #ruby
lukec has joined #ruby
<hanmac> crowell: use a.size not a.count … the second one is much slower
<crowell> hanmac: ah, didn't know that. Ideally you call it outside of the loop, so it is only called once though ;)
<crowell> hanmac: I was under the impression that they were aliases
grzywacz has joined #ruby
grzywacz has joined #ruby
grzywacz has quit [Changing host]
Spami has quit [Quit: This computer has gone to sleep]
Ox6abe has quit [Remote host closed the connection]
rippa has joined #ruby
<hanmac> >> [1].cycle.size
<eval-in> hanmac => Infinity (https://eval.in/49147)
<hanmac> >> [1].cycle.count
<eval-in> hanmac => (https://eval.in/49148)
chopmo has joined #ruby
<hanmac> crowell: as you see, size is calculated, while count is really counting ...
<crowell> hanmac: good to know
browndawg has left #ruby [#ruby]
sambao21 has joined #ruby
YaNakilon has quit [Ping timeout: 245 seconds]
a1ph4g33k has joined #ruby
* a1ph4g33k nodss
kofno has joined #ruby
false_economy has joined #ruby
<a1ph4g33k> I have a question regarding rack/sinatra & ARGV ... anybody up for hearing it ?
jkline has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
dangerousdave has quit [Quit: Leaving...]
hamakn has joined #ruby
<apeiros> crowell, hanmac: count without argument is also more of a niche. the primary purpose of count is to actually count things in the enumerable.
digital-ghost has quit [Read error: No route to host]
jgrep has joined #ruby
jgrep has quit [Max SendQ exceeded]
zodiak has joined #ruby
Ox6abe has joined #ruby
digital-ghost has joined #ruby
jgrep has joined #ruby
Es0teric has joined #ruby
jgrep has quit [Max SendQ exceeded]
YaNakilon has joined #ruby
tomsthumb has joined #ruby
apeiros has quit [Read error: Connection reset by peer]
<crowell> a1ph4g33k: don't ask to ask, just ask :-)
apeiros has joined #ruby
rupee has joined #ruby
Es0teric has quit [Max SendQ exceeded]
<a1ph4g33k> I have a Sinatra-based web service ... I invoke as <script> <config_file_path>
zodiak has quit [Max SendQ exceeded]
rdark has quit [Quit: leaving]
<a1ph4g33k> ... I'm trying to wrap it up for use through rack ... so I can use Unicorn to run it instead of WEBrick ...
cascalheira has quit [Quit: Linkinus - http://linkinus.com]
Spami has joined #ruby
jgrep has joined #ruby
zodiak has joined #ruby
<a1ph4g33k> the script currently uses ARGV.pop to get that file path ...
jgrep has quit [Max SendQ exceeded]
jgrep has joined #ruby
jgrep has quit [Max SendQ exceeded]
<a1ph4g33k> what is the best way to get the result I want ?
jgrep has joined #ruby
jgrep has quit [Max SendQ exceeded]
<a1ph4g33k> as in the script can access the filepath ...
jgrep has joined #ruby
jgrep has quit [Max SendQ exceeded]
<a1ph4g33k> I know I could re-write the script to not receive the configuration on the command line ... but this is just one script within a larger framework and I'm trying to keep the interface between the scripts the same.
jgrep has joined #ruby
jgrep has quit [Max SendQ exceeded]
thecodethinker has quit [Ping timeout: 240 seconds]
jgrep has joined #ruby
Nisstyre-laptop has joined #ruby
ferdev has quit [Quit: ferdev]
hamakn has quit [Ping timeout: 240 seconds]
greenride has joined #ruby
senayar has joined #ruby
ericmathison has joined #ruby
ewnd9 has quit [Ping timeout: 245 seconds]
Zai00 has joined #ruby
duggiefresh has quit [Ping timeout: 264 seconds]
buibex has quit [Remote host closed the connection]
<BraddPitt> I've finished rubymonk's primer and chris pine's ruby tutorial. Should i move on to a personal project now?
duggiefresh has joined #ruby
<BraddPitt> or are there better ruby tutorials i could work through?
<a1ph4g33k> ... just figured it out ...
<waxjar> check out one of the option parser libraries a1ph4g33k (slop and clap are both really nice and light)
Ubercow has joined #ruby
<a1ph4g33k> thanks anyways ... ( FYI you can provide additional command line arguments when you invoke unicorn )
Ubercow has quit [Max SendQ exceeded]
selim has quit [Ping timeout: 248 seconds]
OneMT has joined #ruby
tabolario has joined #ruby
ananthakumaran has quit [Quit: Leaving.]
[flip] has joined #ruby
fgo has joined #ruby
Minos__ has quit [Ping timeout: 264 seconds]
v0n has quit [Ping timeout: 264 seconds]
enebo has quit [Quit: enebo]
<[flip]> question.... class AbstractClass; def self.x; self; end; class A < AbstractClass; end .... i want A.x to return A and not AbstractClass... is there a way?
tatsuya_o has quit [Remote host closed the connection]
<apeiros> [flip]: it does?
<apeiros> >> class AbstractClass; def self.x; self; end; class A < AbstractClass; end; A.x
<eval-in> apeiros => /tmp/execpad-d7d4e4fa4838/source-d7d4e4fa4838:7: syntax error, unexpected end-of-input, expecting keyword_end (https://eval.in/49157)
Zai00 has quit [Quit: Zai00]
<apeiros> >> class AbstractClass; def self.x; self; end; end; class A < AbstractClass; end; A.x
<eval-in> apeiros => A (https://eval.in/49158)
<apeiros> [flip]: not sure why you're asking - seems to me you already have the solution
<[flip]> hm hm hm... lol... moment, thanks for your fast answer btw! :-D
T_T has quit [Remote host closed the connection]
oliver_ has quit [Remote host closed the connection]
alekst has quit [Quit: Computer has gone to sleep.]
tvw has quit []
buibex has joined #ruby
carlyle has joined #ruby
havenwood has quit [Remote host closed the connection]
Seich has quit [Quit: Computer has gone to sleep.]
agent_white has joined #ruby
Advocation has quit [Quit: Advocation]
<[flip]> lol.. thanks... yes, it's acting like it should... refactoring a class name was the mistake :-D
Es0teric has joined #ruby
alex__c2022 has joined #ruby
<[flip]> @ apeiros
T_T has joined #ruby
EIA has quit [Ping timeout: 250 seconds]
jremi has joined #ruby
Nisstyre-laptop has quit [Quit: Leaving]
cpruitt has quit [Ping timeout: 260 seconds]
<hanmac> some day i also will refactor my ruby code … when the hell freeze or the USA does not sell Weapons to there own "enemies" anymore
|jemc| has quit [Ping timeout: 245 seconds]
<jremi> What is the easiest way to update the value of a hash that is using symbols for the hash keys ?
rezzack has joined #ruby
<MrZYX> hash[:symbol] = value?
<jremi> maybe
<jremi> let me try something
<Eiam> ^
<jremi> yeah thats good
<jremi> MrZYX that does the trick
troessner has quit [Quit: Leaving]
<MrZYX> I just got confused because that should be covered by every basic ruby tutorial ;)
<jremi> off course, it should
<jremi> I'm on the beginner levl
buibex has quit [Remote host closed the connection]
<apeiros> for multiple keys/values you can use update/merge!
Bira has joined #ruby
<apeiros> hash.update a: 1, b: 2, c: 3
buibex has joined #ruby
rcosta has joined #ruby
jgrep has quit [Ping timeout: 245 seconds]
<jremi> yeah that was actually something i was going to ask
<jremi> because for hash you will use update method and for array you can use push method?
<jremi> i don't think you can use push for both hash and array
dangerousdave has joined #ruby
<apeiros> different things
<jremi> is that true
<jremi> .
soheil has quit [Remote host closed the connection]
<apeiros> and no, Hash does not define #push
soheil has joined #ruby
<apeiros> neither does Array define #update or #merge!
rcosta has quit [Remote host closed the connection]
Bosox20051 has quit [Ping timeout: 248 seconds]
<jremi> kk
tonni has quit [Remote host closed the connection]
jbpros has joined #ruby
selim has joined #ruby
senayar has quit [Remote host closed the connection]
Ubercow has joined #ruby
Ubercow has quit [Max SendQ exceeded]
T__T has joined #ruby
justsee has joined #ruby
justsee has joined #ruby
staafl has joined #ruby
T_T has quit [Ping timeout: 268 seconds]
Ubercow has joined #ruby
Ubercow has quit [Max SendQ exceeded]
<a1ph4g33k> Althought you could define a similar update function for Array.
buibex has quit [Remote host closed the connection]
<jremi> what would you recommend for the update on array
<apeiros> jremi: []=
<apeiros> it can operate on slices too
soulcake has joined #ruby
<apeiros> if you have to update multiple non-consecutive indices, you should question yourself why you're using an array
<jremi> makes sense
<a1ph4g33k> >> class Array ; def update( elements_as_hash ) ; elements_as_hash.each_pair { |k,v| self[k] = v } ; end ; end ; a = [ 1, 2, 3 ]; puts a; a.update( 1 => 4 ); puts a
<eval-in> a1ph4g33k => 1 ... (https://eval.in/49166)
axl_ has joined #ruby
camilasan has quit [Remote host closed the connection]
alekst has joined #ruby
<apeiros> a1ph4g33k: should return self
<a1ph4g33k> true.
soulcake has quit [Client Quit]
<a1ph4g33k> >> class Array ; def update( elements_as_hash ) ; elements_as_hash.each_pair { |k,v| self[k] = v } ; self ; end ; end ; a = [ 1, 2, 3 ]; puts a; a.update( 1 => 4 ); puts a
<eval-in> a1ph4g33k => 1 ... (https://eval.in/49167)
justsee has quit [Ping timeout: 245 seconds]
<jremi> just getting my feet wet over the past few weeks, what is a good sample program i should be able to write before i am ready to move on to rails.
<apeiros> a1ph4g33k: also merge accepts a block which it invokes on collisions. I find that a nice feature. makes a bit less sense on an array, though.
fgo has quit [Remote host closed the connection]
<jremi> something simple, but would be a good test for learning
aki_ has joined #ruby
devdazed has quit [Read error: Connection reset by peer]
<crowell> jremi: depends on what you want to learn!
<jremi> rails
<apeiros> jremi: your own webframework
<jremi> I'm getting the basics of ruby
<apeiros> doesn't need to be as big as rails
<jremi> then i want to get into rails
decoponio has quit [Quit: Leaving...]
<jremi> so what would be a good basic ruby program that would be good for learning
<crowell> jremi: if you want to learn how to rails, just grab rails and start working with it
<a1ph4g33k> learn to use sinatra & one of the templating libs like erb or haml to build simple web sites.
<a1ph4g33k> Then you can move into all the bells and whistles of rails.
<jremi> yeah, i could use sinatra first
<crowell> if you want just a primer on ruby, take something you've done before and port it
|jemc| has joined #ruby
sayan has joined #ruby
<jremi> but i have been told that its best to know how to operate the oven before you bake the turkey
devdazed has joined #ruby
<pzula> jremi: agreed
splittingred has joined #ruby
<pzula> jremi: try the Jumpstart Lab tutorials
soulcake has joined #ruby
johnjohnson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<jremi> @pzula
<jremi> let me check
<pzula> jremi: tutorials.jumpstartlab.com/
<BraddPitt> jremi irc bot
<BraddPitt> ( ≖‿≖)
Collin has quit [Ping timeout: 248 seconds]
Collin has joined #ruby
<jremi> so far…. I have completed the Codeacademy Beginners Ruby course…. that was helpful, and have gone thru the first few chapters of the Pragmatics Ruby book
false_economy has quit [Remote host closed the connection]
_maes_ has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
<a1ph4g33k> Just play with it until you understand it.
<a1ph4g33k> build things you need.
<a1ph4g33k> that's what I do.
Criztian has quit [Remote host closed the connection]
<pzula> jremi: jremi have you ever programmed before?
<pzula> it makes a difference
<banisterfiend> jremi why did you do code academy rather than code school?
Dave has joined #ruby
<jremi> i started with code school but i actually liked the style of code academy better
<jremi> so i did that course first
<a1ph4g33k> sorry, not trying to be noise ... just trying to be helpful.
<jremi> i have not coded before really
<banisterfiend> jremi how come?
Dave is now known as Guest52594
<jremi> just basic stuff
<banisterfiend> jremi why did you prefer code academy over code school
<pzula> jremi: then the jumpstart labs will definitely get you there
<jremi> i was getting annoying reload issues on code school
iliketurtles has joined #ruby
swistak35 has quit [Excess Flood]
<pzula> jremi: do the Ruby ones
Nisstyre-laptop has joined #ruby
<jremi> paula, I'm going to review that now
<jremi> much thanks for the link
<pzula> jremi: Then under Independent work do those projects too
<jremi> ok
<pzula> jremi: when you get stuck, redo the previous tutorials
<jremi> yeah
<pzula> jremi: the answers are all within the work you do
swistak35 has joined #ruby
<jremi> makes sense
<pzula> jremi: if all else falls, there is always previous people's work on github
<pzula> jremi: but don't cheat yourself out from learning
<jremi> yeah i have noticed that if you keep just doing beginner tutorials and reading , you will eventually get the hang of the syntax
<jremi> and can then begin to construct basic logic
<pzula> jremi: it's more than sytax
<pzula> jremi: exactly
<pzula> jremi: and understanding WHY things do what they do
<jremi> yeah the logic behind it and how to then apply that later on
<jremi> yep
Advocation has joined #ruby
Ox6abe has quit [Remote host closed the connection]
<jremi> u have heard of the book Pragmatic Programmers for Ruby?
saarinen has quit [Quit: saarinen]
<pzula> jremi: you're off to the right start :) stick with learning ruby before rails and you will have a better understanding of why things are the way they are
<pzula> jremi: yes, I have
<pzula> jremi: that is good also
<pzula> once you get a taste of all of that, move on to Eloquent Ruby
intuxicated has joined #ruby
<jremi> yeah its good, but a lot of the newer web-based learning tools really are helping alot
dangerousdave has quit [Ping timeout: 264 seconds]
<jremi> i like the more interactive based tools
alvaro_o has joined #ruby
<pzula> indeed - and Eloquent Ruby, the book, will help you understand how to write your code
Guest52594 has quit [Ping timeout: 248 seconds]
grzywacz has quit [Ping timeout: 240 seconds]
underway47 has quit [Ping timeout: 276 seconds]
<jremi> i like this link u gave me with the exercises
<jremi> I'm going to start reviewing them
tkuchiki has quit [Remote host closed the connection]
<jremi> peace
<pzula> jremi: see ya
pzula has quit [Quit: Lost terminal]
jremi has quit [Quit: jremi]
sarlalian has quit [Quit: WeeChat 0.4.1]
sarlalian has joined #ruby
Ox6abe has joined #ruby
senayar has joined #ruby
Apocalypse has quit [Ping timeout: 260 seconds]
jgrau has quit [Remote host closed the connection]
<hanmac> banisterfiend: look at this gif http://jacoboneal.com/car-engine/
sarlalian has quit [Client Quit]
Apocalypse has joined #ruby
skaflem has quit [Quit: Leaving]
Seich has joined #ruby
JohnBat26 has joined #ruby
sarlalian has joined #ruby
jkline has quit [Quit: jkline]
dangerousdave has joined #ruby
Ox6abe has quit [Remote host closed the connection]
noop has quit [Ping timeout: 260 seconds]
sniffingcats has quit [Quit: Til rivido Idisti!]
Steve009 has joined #ruby
<Steve009> I converted a string into a DateTime using Date.strptime() and when i view the output as a string i get: #<Date: 2010-12-01 ((2455532j,0s,0n),+0s,2299161j)
<Steve009> any ideas why?
<Steve009> When i run the same command in another ruby file i get the correct fommating
<Steve009> Appears to be no difference in my implementation
jbpros has quit [Quit: jbpros]
pygospa has quit [Disconnected by services]
TheRealPygo has joined #ruby
<hanmac> Steve009: are you sure you want Date.strptime and not DateTime.strptime ?
Seich has quit [Ping timeout: 260 seconds]
<Steve009> Ya, I am only working with Dates, no times
<Steve009> DateTime gives me: #<DateTime: 2010-12-01T00:00:00+00:00 ((2455532j,0s,0n),+0s,2299161j)>
jerrad has joined #ruby
jerrad is now known as Underbyte
Underbyte has quit [Changing host]
Underbyte has joined #ruby
T__T has quit [Ping timeout: 248 seconds]
reset has joined #ruby
Collin has quit [Ping timeout: 264 seconds]
dkamioka has quit [Read error: Connection reset by peer]
devoldmx has joined #ruby
dkamioka has joined #ruby
kilophoton has quit [Ping timeout: 245 seconds]
timonv has joined #ruby
v0n has joined #ruby
T_T has joined #ruby
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
apeiros has quit [Remote host closed the connection]
apeiros has joined #ruby
<hanmac> Steve009: i think i need more code to look what is wrong
<Steve009> Have a array with hashes in it that looks like this: [{"_id"=>{"year"=>2012, "month"=>10}, "number"=>53}
kayloos has joined #ruby
<Steve009> When i parse the data using a block i use this: temp = DateTime.strptime(x["_id"]["month"].to_s + " " + x["_id"]["year"].to_s, '%m %Y')
<Steve009> dateFormatChangeHash[temp] = x["number"]
jdeeburke has joined #ruby
<Steve009> If i were to run dateFormatChangeHash.keys the dates appear in the correct format
workmad3 has joined #ruby
BizarreCake has quit [Ping timeout: 276 seconds]
baggypants has quit [Quit: Textual IRC Client: www.textualapp.com]
<Steve009> No errors of anything have appeared. It is just when you view the data using something like puts dateFormatChangeHash or puts dateFormatChangeHash.to_s
Bry8Star{T2 has quit [Remote host closed the connection]
tvw has joined #ruby
nmabry has joined #ruby
tonni has joined #ruby
senayar has quit [Remote host closed the connection]
girija has quit [Ping timeout: 248 seconds]
brbcoding has quit [Ping timeout: 260 seconds]
Soda has quit [Read error: Connection reset by peer]
ferdev has joined #ruby
splittingred has quit [Ping timeout: 240 seconds]
jdeeburke has left #ruby [#ruby]
splittingred has joined #ruby
grzywacz has joined #ruby
<hanmac> Steve009: i think his is how the to_s method of Hash works … and your stringbuild should be more ruby like "#{x["_id"]["month"]} #{x["_id"]["year"]}" … or better: x["_id"].values_at('month', 'year').join(" ")
Falcore has quit [Quit: Falcore]
mrsolo has joined #ruby
<hanmac> Steve009: why dont you use Date.new ?
Bry8Star{T2 has joined #ruby
Criztian has joined #ruby
Criztian has quit [Remote host closed the connection]
Urizen has quit [Ping timeout: 248 seconds]
<Steve009> I could use Date.new. But my confusion is more about it not working in this new .rb file. The exact code works as expected in another file
ScottRadcliff has quit [Remote host closed the connection]
audibleblink has joined #ruby
<Steve009> AHHHHH
<Steve009> just found what caused it
<Steve009> group date gem was having a impact
<SloggerKhan> If Net::SFTP with its sftp.file.open and file.puts commands acts like it works, but doesn't, and I can upload a file with an identical name and contents successfully using curl on the command line are there any common culprits?
<Steve009> If you run the same code as before by without require 'groupdate' it formats in the weird way
fgo has joined #ruby
<Steve009> When groupdate is required you get: {Wed, 01 Dec 2010=>1, Mon, 01 Aug 2011=>8
Advocation has quit [Quit: Advocation]
hololeap has joined #ruby
tatsuya_o has joined #ruby
vlad_starkov has joined #ruby
axl_ has quit [Quit: axl_]
dsferreira has joined #ruby
fgo has quit [Ping timeout: 268 seconds]
tjad has quit [Ping timeout: 276 seconds]
dangerousdave has quit [Read error: Connection reset by peer]
carlyle has quit [Remote host closed the connection]
dangerousdave has joined #ruby
mahlon_ is now known as mahlon
maroloccio has quit [Ping timeout: 245 seconds]
Advocation has joined #ruby
swordsmanz has quit [Quit: ooh ponies kinkeyyy]
timonv has quit [Remote host closed the connection]
coderhs has quit [Ping timeout: 276 seconds]
aaronmcadam has quit [Quit: Leaving...]
yxhuvud has quit [Quit: Nettalk6 - www.ntalk.de]
iamjarvo has quit [Remote host closed the connection]
iamjarvo has joined #ruby
atmosx has joined #ruby
BillCris_ is now known as BillCriswell
<atmosx> hello
maroloccio has joined #ruby
iamjarvo has quit [Ping timeout: 248 seconds]
mando has quit [Remote host closed the connection]
ksh has quit [Ping timeout: 240 seconds]
Steve009 has quit [Quit: Steve009]
Apocalypse has quit [Ping timeout: 260 seconds]
banisterfiend is now known as banister`gym
ksh has joined #ruby
iamjarvo has joined #ruby
Apocalypse has joined #ruby
[flip] has quit [Quit: Leaving.]
tjad has joined #ruby
apeiros has quit [Remote host closed the connection]
apeiros has joined #ruby
robustus has quit [Ping timeout: 245 seconds]
Targen has quit [Quit: No Ping reply in 180 seconds.]
vlad_starkov has quit [Remote host closed the connection]
coderhs has joined #ruby
Targen has joined #ruby
aki_ has left #ruby ["'kbye.'"]
Kar- has quit [Quit: leaving]
kofno has quit [Ping timeout: 264 seconds]
interactionjaxsn has quit [Remote host closed the connection]
robustus has joined #ruby
platzhirsch has left #ruby [#ruby]
<Bourbon> do child classes inherit included modules/mixins?
sayan has quit [Ping timeout: 264 seconds]
<workmad3> Bourbon: yes
<|jemc|> >> module Mix; end; class A; include Mix; end; class B < A; A.ancestors
<eval-in> |jemc| => /tmp/execpad-47d1f1adb58f/source-47d1f1adb58f:7: syntax error, unexpected end-of-input, expecting keyword_end (https://eval.in/49173)
momomomomo has joined #ruby
<|jemc|> >> module Mix; end; class A; include Mix; end; class B < A; end; A.ancestors
<eval-in> |jemc| => [A, Mix, Object, Kernel, BasicObject] (https://eval.in/49174)
greenrose has quit [Ping timeout: 248 seconds]
<|jemc|> >> module Mix; end; class A; include Mix; end; class B < A; end; B.ancestors
<eval-in> |jemc| => [B, A, Mix, Object, Kernel, BasicObject] (https://eval.in/49175)
dsferreira has quit [Quit: This computer has gone to sleep]
<Bourbon> ok... not where this is blowing up
<Bourbon> http://alan-ruby.appredeemdev.com/message/test? < what's blowing up
<hanmac> Bourbon they also inherit extened and prepended modules
<workmad3> Bourbon: you haven't loaded ActiveModel
atmosx has quit [Quit: Lost in trance]
<Bourbon> how should I go about this?
TheFuzzball has joined #ruby
rbennacer has joined #ruby
<rbennacer> hello
<Bourbon> do I first need ActiveModel::Model ?
Notte has joined #ruby
<rbennacer> why would <code> if "" ;puts "test";end</code> print out test
<workmad3> Bourbon: you could try doing 'require "active_model" '
<rbennacer> isn't an empty string a false value?
<workmad3> rbennacer: no
<rbennacer> how can i test for an empty string then
<rbennacer> ?
<hoelzro> ''.empty?
<workmad3> >> ''.empty?
<eval-in> workmad3 => true (https://eval.in/49176)
<rbennacer> mmmm ok
<rbennacer> thank you guys
brianpWins has quit [Quit: brianpWins]
<workmad3> rbennacer: only two values are falsey in rails... false and nil
carlyle has joined #ruby
<hanmac> rbennacer: remember, only nil and false are a "false value"
<workmad3> rbennacer: everything else, when used as a boolean, is truthy ;)
<rbennacer> ok cool
Nisstyre-laptop has quit [Ping timeout: 268 seconds]
* apeiros smacks workmad3 with a rail
<workmad3> rbennacer: this catches out lots of people btw... for quite a while, I kept on doing 'if 0' and expecting a false value, for example :)
<workmad3> apeiros: :(
<apeiros> "only two values are falsey in ***rails***"? wtf? :D
allsystemsarego has quit [Quit: Leaving]
<rbennacer> hahaha
<workmad3> apeiros: ah, d'oh
<canton7> technically true
<rbennacer> yeah this is confusing
<workmad3> apeiros: sorry, was flipping between here and #rubyonrails too much... and this is my first day of holiday :P
<matti> :)
brunoro has joined #ruby
dkamioka has quit [Remote host closed the connection]
dnyy has quit [Ping timeout: 246 seconds]
OneMT has quit [Quit: OneMT]
atmosx has joined #ruby
apeiros_ has joined #ruby
T_T has quit [Remote host closed the connection]
staafl has quit [Ping timeout: 240 seconds]
<workmad3> rbennacer: where I said 'rails' read 'ruby', sorry :(
kenichi has quit [Quit: ZNC - http://znc.sourceforge.net]
kofno has joined #ruby
kenichi has joined #ruby
obs has joined #ruby
duggiefr_ has joined #ruby
carlyle has quit [Ping timeout: 245 seconds]
apeiros has quit [Ping timeout: 264 seconds]
brianpWins has joined #ruby
duggiefresh has quit [Ping timeout: 240 seconds]
<Bourbon> workmad3: thanks - I thought it was somehow included as part of Rails' magic
* apeiros_ hates his ISP right now
mando has joined #ruby
vlad_starkov has joined #ruby
<apeiros_> what's 150MBit/s worth if a 200KB/s (1.6MBit/s) stream is lagging like hell? (and it's not the stream - it worked fine at work on a 10MBit/s line…)
soulcake has quit [Read error: Connection reset by peer]
<|jemc|> apeiros_: are you being "shaped"?
<apeiros_> no
<apeiros_> officially they don't shape
<apeiros_> and I'm nowhere near exceptional use
<|jemc|> every ISP shapes
soulcake has joined #ruby
<apeiros_> also raw throughput isn't the problem
<apeiros_> it might be an issue related to how caching works. trying to remember the name…
staafl has joined #ruby
maroloccio has quit [Quit: WeeChat 0.4.0]
<apeiros_> re raw throughput: if I e.g. download stuff from apple store I get ~10MByte/s easily
wmoxam has quit [Read error: Connection reset by peer]
<apeiros_> s/apple/app/
wmoxam has joined #ruby
<apeiros_> ah, bufferbloat was the name
alex__c2022 has quit [Quit: alex__c2022]
Falcore has joined #ruby
Nisstyre-laptop has joined #ruby
false_economy has joined #ruby
T_T has joined #ruby
<|jemc|> there's a good term to remember
<|jemc|> thanks
<|jemc|> yeah, that's what I've been reading
yekta has joined #ruby
Advocation has quit [Quit: Advocation]
nadirvardar has quit [Ping timeout: 248 seconds]
mansi has quit [Remote host closed the connection]
lotherk has quit [Ping timeout: 264 seconds]
radic has quit [Ping timeout: 276 seconds]
aquarian_1981 has joined #ruby
krawchyk has quit [Remote host closed the connection]
lotherk has joined #ruby
nadirvardar has joined #ruby
aquarian_1981 has left #ruby [#ruby]
mansi has joined #ruby
cody-- has quit [Quit: derp]
schaerli has joined #ruby
carlyle has joined #ruby
swordsmanz has joined #ruby
vxxr has joined #ruby
Tuxist has quit [Read error: Connection reset by peer]
atno has joined #ruby
digital-ghost has quit [Remote host closed the connection]
spider-mario has quit [Quit: No Ping reply in 180 seconds.]
Falcore has quit [Quit: Falcore]
spider-mario has joined #ruby
wmoxam has quit [Ping timeout: 268 seconds]
alex__c2022 has joined #ruby
schaerli has quit [Ping timeout: 268 seconds]
wmoxam has joined #ruby
Ripp__ has quit []
fgo has joined #ruby
jbpros has joined #ruby
tonni has quit [Remote host closed the connection]
Urizen has joined #ruby
senayar has joined #ruby
fgo has quit [Ping timeout: 248 seconds]
Es0teric has quit [Quit: Computer has gone to sleep.]
RDash is now known as RDash[AW]
swistak35 has quit [Quit: ZNC - http://znc.in]
apeiros has joined #ruby
<Eiam> steam is another nice one to shove down your pipe
<Eiam> I've seen 50 MB/s from them
angusiguess has quit [Ping timeout: 245 seconds]
swistak35 has joined #ruby
senayar has quit [Ping timeout: 240 seconds]
<Eiam> buffer bloat huh, thats a new one.
jkline has joined #ruby
aeontech has quit [Quit: aeontech]
jbpros has quit [Ping timeout: 240 seconds]
iamjarvo has quit [Remote host closed the connection]
apeiros_ has quit [Ping timeout: 264 seconds]
jkamenik has quit [Quit: Leaving.]
iamjarvo has joined #ruby
endash has quit [Quit: endash]
pierre1 has quit [Ping timeout: 248 seconds]
gerep has joined #ruby
<gerep> Hi all. hey, I came to this: "4242424242424242".gsub /^[0-9]{0,12}/, "*" the problem is that it replaces with * only the last of the 12 first characters, the output is *4242 and should be ************4242. Any ideas?
devoldmx has quit [Ping timeout: 260 seconds]
Donovan is now known as dyoung522
soheil has quit [Read error: Connection timed out]
devoldmx has joined #ruby
Xuerian has quit [Remote host closed the connection]
iamjarvo has quit [Ping timeout: 245 seconds]
Bosox20051 has joined #ruby
Bosox20051 has quit [Read error: Connection reset by peer]
soheil has joined #ruby
maZtah is now known as Guest
Xuerian has joined #ruby
<SloggerKhan> gerep - if you know the length of digits every time using a regex seems excessive
Guest is now known as maZtah
<gerep> SloggerKhan: it's a credit card number
<gerep> SloggerKhan: And I need to get the last for and replace the others with *
optimusprimem has joined #ruby
optimusprimem has joined #ruby
optimusprimem has quit [Changing host]
<gerep> SloggerKhan: I have used this example with a cc with 16 numbers, I'm not sure if all of them have the same amount
<gerep> SloggerKhan: But if they do, what's the other way I can do it?
<SloggerKhan> v = '************' + v[12..-1] or something.
<SloggerKhan> Credit card numbers are all 16 digit now
<SloggerKhan> Amex used to have a few that were fewer digits but they were phased out
postmodern has joined #ruby
<SloggerKhan> I think there's probably a more elegant way to do it
chopmo_ has joined #ruby
<SloggerKhan> but I doubt you really need to use a regex
tatsuya_o has quit [Read error: Connection reset by peer]
chopmo has quit [Read error: Connection reset by peer]
<SloggerKhan> if you're validating input then you'll know you've got 16 digits to begin with
<MrZYX> ('*'*12)+number[-4..-1] doesn't really assume length
dnyy has joined #ruby
rbennacer has left #ruby ["Leaving"]
<gerep> SloggerKhan: right
katsrc has joined #ruby
<gerep> both examples returned TypeError: can't convert Range into Integer
pkrnj has joined #ruby
<MrZYX> which ruby version?
SHyx0rmZ has joined #ruby
<gerep> 1.9.3
<SloggerKhan> MrZYX's is more elegant than my quickie
<MrZYX> hm, works for me across all versions
<MrZYX> are you sure your number is a string?
<apeiros> '*'*(number.length-4)+number[-4,4]
<apeiros> gerep: and why it didn't replace the way you wanted: you said "replace zero to twelve digits with ONE *"
<apeiros> so it did just that - it replaced 12 digits with one *
<lethjakman> what does the '*'* do?
<gerep> MrZYX: yes
<apeiros> lethjakman: String#*, repeats the string N times
<apeiros> >> "hello"*5
<eval-in> apeiros => "hellohellohellohellohello" (https://eval.in/49180)
<SloggerKhan> It's ruby so string multiply does repeats
radic has joined #ruby
<lethjakman> ohhh ok.
<lethjakman> that makes more sense
<MrZYX> gerep: copy paste the code raising that error
<gerep> apeiros: so I need to do something like *{12} ?
<lethjakman> I knew that, just looked weird. thank you!
<apeiros> gerep: not quite. your issue is that you want "substitute ONE digit with ONE *", but twelve times. and gsub can't do that.
<gerep> MrZYX: ('*'*12)+"4242424242424242"[-4..-1]
<gerep> apeiros: got it
tatsuya_o has joined #ruby
<MrZYX> >> ('*'*12)+"4242424242424242"[-4..-1]
<eval-in> MrZYX => "************4242" (https://eval.in/49181)
<gerep> MrZYX: I didn't mention but I'm testing it on a rails console, maybe that's a problem?
jbpros has joined #ruby
<SloggerKhan> Yeah, I like the '*' * (number.length-4) + number[-4,4] expression
clov3r has quit [Remote host closed the connection]
<gerep> MrZYX: I'll try it on irb
T_T has quit [Read error: Connection reset by peer]
soheil has quit [Remote host closed the connection]
<SloggerKhan> It works for me in irb
Xeago has joined #ruby
T_T has joined #ruby
<MrZYX> works for me on a rails console too (3.2)
<gerep> working here too
<gerep> the problem was something with the console, closing and opening again works :)
<gerep> thanks a lot guys :)
Ox6abe has joined #ruby
mark_locklear has quit [Ping timeout: 248 seconds]
phantasm66 has quit [Quit: *sleeeep….]
lfox has quit [Quit: ZZZzzz…]
reset has quit [Quit: Leaving...]
cj3kim_ has joined #ruby
Ripp__ has joined #ruby
Banistergalaxy has quit [Read error: Connection reset by peer]
JohnBat26 has quit [Ping timeout: 248 seconds]
sailias has quit [Quit: Leaving.]
carlyle has quit [Remote host closed the connection]
Banistergalaxy has joined #ruby
funburn has joined #ruby
wmoxam has quit [Ping timeout: 248 seconds]
<a1ph4g33k> another way you could do the regex for the above is: "4242424242424242".gsub( /\d(?=.*\d{4}$)/, '*' )
<a1ph4g33k> another way you could do the regex for the above is:
axl_ has joined #ruby
<a1ph4g33k> >> "4242424242424242".gsub( /\d(?=.*\d{4}$)/, '*' )
<eval-in> a1ph4g33k => "************4242" (https://eval.in/49182)
rcosta has joined #ruby
<a1ph4g33k> ( for any match of a digit followed by at least 4 digits, replace with a '*' )
carlyle has joined #ruby
<hanmac> a1ph4g33k: you can also use []= for that
lfox has joined #ruby
ukd1 has joined #ruby
ehaliewicz has joined #ruby
<hanmac> or normal sub
hololeap has quit [Ping timeout: 240 seconds]
<a1ph4g33k> yes, you could do:
Banistergalaxy has quit [Ping timeout: 240 seconds]
goodcodeguy has joined #ruby
<a1ph4g33k> >> str="4242424242424242"; str[0..-5] ='*' * ( str.length - 4 )
<eval-in> a1ph4g33k => "************" (https://eval.in/49183)
<a1ph4g33k> >> str="4242424242424242"; str[0..-5] ='*' * ( str.length - 4 ) ; puts str
<eval-in> a1ph4g33k => ************4242 ... (https://eval.in/49184)
tjad has quit [Ping timeout: 268 seconds]
<a1ph4g33k> I figured the regex that didn't make you deal with string length was a nice solution.
breakingthings has quit []
renotarize43 has joined #ruby
bradhe has joined #ruby
<a1ph4g33k> the only challenge is that mine still doesn't validate the string is all digits & appropriate length for a CC ( 16, 15, etc )
<a1ph4g33k> could change it to:
<a1ph4g33k> >> "4242424242424242".gsub( /\d(?=\d*\d{4}$)/, '*' )
<eval-in> a1ph4g33k => "************4242" (https://eval.in/49185)
<a1ph4g33k> at least now it's all digits ...
gerep has quit [Remote host closed the connection]
<a1ph4g33k> >> "abc2424242424242".gsub( /\d(?=\d*\d{4}$)/, '*' )
<eval-in> a1ph4g33k => "abc*********4242" (https://eval.in/49186)
<a1ph4g33k> >> "abc2424242424242".gsub( /(?<=(\d|\*)*)\d(?=\d*\d{4}$)/, '*' )
<eval-in> a1ph4g33k => /tmp/execpad-ad58d2028dff/source-ad58d2028dff:2: invalid pattern in look-behind: /(?<=(\d|\*)*)\d(?=\d*\d{4}$)/ (https://eval.in/49187)
timonv has joined #ruby
<a1ph4g33k> ... darn'd back references .
mary5030 has joined #ruby
timonv has quit [Remote host closed the connection]
phracker has quit [Ping timeout: 240 seconds]
timonv has joined #ruby
JoeHazzers has quit [Ping timeout: 240 seconds]
ner0x has quit [Quit: Leaving]
deavid has quit [Read error: Connection reset by peer]
jp- has quit [Quit: OK, I believe you… but my tommy gun don't]
katherinem13 has quit [Ping timeout: 240 seconds]
deavid has joined #ruby
katherinem13 has joined #ruby
JoeHazzers has joined #ruby
matrixise has quit [Ping timeout: 240 seconds]
awkisopen has quit [Ping timeout: 240 seconds]
reset has joined #ruby
goodcodeguy has quit [Quit: leaving]
matrixise has joined #ruby
clov3r has joined #ruby
awkisopen has joined #ruby
Tricon has quit [Quit: Bye!]
kaldrenon has quit [Remote host closed the connection]
<a1ph4g33k> >> "abc2424242424242".gsub( /(?=(\d|\*)*)\d(?=\d*\d{4}$)/, '*' )
<eval-in> a1ph4g33k => "abc*********4242" (https://eval.in/49190)
cody-- has joined #ruby
mmitchell has quit [Remote host closed the connection]
<a1ph4g33k> >> "abc2424242424242".gsub( /(?=^[0-9*]*)\d(?=\d*\d{4}$)/, '*' )
<eval-in> a1ph4g33k => "abc2424242424242" (https://eval.in/49191)
<apeiros> >> "abc2424242424242".gsub(/\d(?=\d{4})/, '*')
<eval-in> apeiros => "abc*********4242" (https://eval.in/49192)
<Eiam> a1ph4g33k: ....
<MrZYX> ^
<Eiam> a1ph4g33k: go use pry dude, this isn't a REPL
<a1ph4g33k> Yeah, I had that ... I want it to not change a string that isn't all digits.
<a1ph4g33k> ... sorry ... was hoping somebody would show me what I missed..
<apeiros> a1ph4g33k: easy, look only one behind and check whether it's a boundary or a * already
<apeiros> though, alternations in lookbehinds are ugly
mmitchell has joined #ruby
timonv has quit [Ping timeout: 268 seconds]
phracker has joined #ruby
greenride has quit [Changing host]
greenride has joined #ruby
<apeiros> hm, no, doesn't work. gsub doesn't reevaluate the string.
kilophoton has joined #ruby
claymore has joined #ruby
Es0teric has joined #ruby
spider-mario has quit [Read error: Connection reset by peer]
jkline has quit [Quit: jkline]
Stalkr_ has quit [Quit: Leaving...]
sarkis has quit [Ping timeout: 260 seconds]
Notte has quit [Remote host closed the connection]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
soheil has joined #ruby
<a1ph4g33k> yeah, I'm not having any luck with it either ... but again sorry for the noise ...
funburn has quit [Quit: funburn]
<Todd> can anyone provide a code review for some meta stuff I'm attempting to do? the code works but I'm curious if I'm "doing it right" if you will... https://gist.github.com/toddedw/645e0b4f99cb6b0af878
ldnunes has quit [Quit: Leaving]
carlyle has quit [Remote host closed the connection]
g0bl1n has quit [Quit: Ex-Chat]
SHyx0rmZ has quit [Quit: ネウロイを負かさなきゃならないね]
lfox has quit [Quit: ZZZzzz…]
soheil has quit [Remote host closed the connection]
<apeiros> Todd: I'm sorry, but when I read `self.included`, I already start screaming and run away.
<apeiros> (I know, not a helpful criticism, sorry. too tired I guess.)
evenix has quit [Remote host closed the connection]
<Todd> apeiros, well.. *shrug*
<Todd> apeiros, it's either that or have 600 lines of methods that do the same thing over and over
<Todd> apeiros, what's another way to do it?
Suit_Of_Sables has quit [Quit: WeeChat 0.4.0]
<apeiros> Todd: no, the point is `self.included` is the wrong way.
solars has joined #ruby
<Todd> apeiros, ok then.. what's the right way
<apeiros> but I'd need to see the whole thing to tell you a better way. and for that, I don't have the energy left today.
<apeiros> usually it'd be: use extend. but I don't think that applies here.
johnjohnson has joined #ruby
lfox has joined #ruby
saarinen has joined #ruby
jbpros has quit [Quit: jbpros]
dhruvasagar has quit [Ping timeout: 245 seconds]
end_guy has quit [Ping timeout: 240 seconds]
<Todd> apeiros, hmm
mary5030 has quit [Remote host closed the connection]
<Todd> apeiros, it's 5pm.. I'm done as well.
<apeiros> given that you don't seem to rely on anything, it seems to me you could just make it a class method on the module, though
<apeiros> Foo.improvify_class(klass)
evenix has joined #ruby
<Todd> I'll have to think about that.
<apeiros> and then just rename `included` to `improvify` (obviously you should choose a more apt name)
<apeiros> but what you do doesn't seem to have anything to do with actually including a module.
saarinen has quit [Client Quit]
<apeiros> it'd also allow you to decouple that @browser hidden in that code
<apeiros> parametrize it and use @browser as the default
dhruvasagar has joined #ruby
jkline has joined #ruby
<Todd> if I parameterize it it's available to my page classes
hanmac has quit [Quit: Leaving.]
<Todd> which I don't want
<apeiros> o0
end_guy has joined #ruby
codecop has quit [Remote host closed the connection]
<apeiros> I mean like this: def self.improvify_class(base, browser=@browser); …
aryaching has quit [Ping timeout: 248 seconds]
<Todd> I suppose my Ruby knowledge is lacking here.
<apeiros> then in line 19, just use `browser` instead of `@browser`
<Todd> ah
yekta has quit [Quit: yekta]
<apeiros> also, define_method accepts a block
<apeiros> define_method(:foo) { … }
<Todd> yeah I changed it to a send during troubleshooting
<Todd> that's what I originally had
<apeiros> no need to write it verbosely as: define_method(:foo, lambda { … })
<Todd> I know now :)
theRoUS has quit [Ping timeout: 264 seconds]
<apeiros> though… not sure whether the latter actually might perform arg-count checking whereas the former does not…
<Todd> the latter does perform arg-count checks
saarinen has joined #ruby
<Todd> I've proven that
<apeiros> define_method always arg-count checks as it seems. even in its block-form.
<apeiros> (blocks normally don't arg-count check, since they're procs, not lambdas)
<Todd> yeah I originally had a typo in my CONTROL_ENUMERATORS and got some arg-count errors
<apeiros> .gsub(/s$/, '') --> .sub(/s\z/, '')
<apeiros> unless you really mean "at the end of every line"
aeontech has joined #ruby
Xeago has quit [Remote host closed the connection]
tonni has joined #ruby
selim has quit [Read error: Connection reset by peer]
<Todd> end of string.. interesting
<Todd> thank you
<Todd> I will finish this tomorrow. I need to run to the cleaner before they close.
<Todd> Thank you.
<apeiros> line 16-21: use map instead of each, lets you drop 2 lines of code and declaring `result`
<apeiros> kk
mary5030 has joined #ruby
jkline has quit [Quit: jkline]
workmad3 has quit [Ping timeout: 245 seconds]
hamakn has joined #ruby
jkline has joined #ruby
jbpros has joined #ruby
jbpros has quit [Client Quit]
mary5030 has quit [Remote host closed the connection]
jbpros has joined #ruby
maroloccio has joined #ruby
mary5030 has joined #ruby
cj3kim_ has quit [Remote host closed the connection]
sambao21 has quit [Quit: Computer has gone to sleep.]
BillCriswell has quit [Remote host closed the connection]
atmosx has quit [Quit: Lost in trance]
Bira has quit [Ping timeout: 240 seconds]
echevemaster has quit [Ping timeout: 276 seconds]
TehCraw has joined #ruby
hamakn has quit [Ping timeout: 268 seconds]
hololeap has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
osvico has joined #ruby
<TehCraw> Hmm, this channel is rather quiet for having 854 people on it.
optimusprimem has quit [Ping timeout: 245 seconds]
d2dchat has quit [Remote host closed the connection]
<|jemc|> all you have to do is say "I miss python because ruby doesn't do #{x}"
alekst has quit [Quit: Computer has gone to sleep.]
<|jemc|> and you'd be surprised ;)
<TehCraw> LOL
cody-- has quit [Quit: derp]
<a1ph4g33k> or some new guy joins the channel and talks too much.
mando has quit [Remote host closed the connection]
<TehCraw> what if I say that PHP is far better than Ruby? would that get some attention? :D
alekst has joined #ruby
<onewheelskyward> Probably not.
SHyx0rmZ has joined #ruby
scriabin has joined #ruby
dhruvasagar has quit [Read error: Operation timed out]
T_T has quit [Ping timeout: 248 seconds]
<TehCraw> Dang, I thought people were usually very passionate about defending their language of choice.
SHyx0rmZ has quit [Client Quit]
Nisstyre-laptop has quit [Quit: Leaving]
<|jemc|> well, nobody actually feels threatened by php, I would imagine
<TehCraw> Good point.
carlyle has joined #ruby
coderhs has quit [Ping timeout: 240 seconds]
<TehCraw> PHP is aweful. And that comes from a guy who spent the last five years using it.
<TehCraw> >.>
<scriabin> guys help me get my head straight. In a ruby class, one should only use self if 1.) defining a method which applies to the Class (i.e. def GenClass.hello == def self.hello) 2.) calling a setter method for an attribute (i.e. self.last_name ="Smith" != last_name = "
<scriabin> "Smith"
pushpak has quit [Quit: Linkinus - http://linkinus.com]
dhruvasagar has joined #ruby
<|jemc|> the rules for what 'self' is can sometimes get a little hairy
<onewheelskyward> self.hairy?
<|jemc|> what I do when I'm unsure is just throw in a 'puts self'
<scriabin> indeed
<|jemc|> and see what object is referred to
<|jemc|> you start to get a feel for it pretty quickly after you start paying attention to it, though
SHyx0rmZ has joined #ruby
mando has joined #ruby
<scriabin> ok so can somebody tell me if there's any harm in using self to refer to an instance attribute? Like DoMagicWorker.perform_async(self.id)
hukl_ has joined #ruby
<scriabin> within a class method
<apeiros> |jemc|: better `p self` than `puts self`
<|jemc|> apeiros: yeah, I do use p. not sure why I wrote puts there
<apeiros> scriabin: puts uses to_s, which is usually used for printing. p uses inspect, which is what you see in irb/pry and is meant for debugging
<|jemc|> maybe I thought the intent would be more obvious
<|jemc|> but yeah, p is more reliable
nisstyre has quit [Ping timeout: 245 seconds]
<scriabin> thanks I was wondering
<apeiros> scriabin: explicit self can prohibit calling private methods
alexju has quit [Remote host closed the connection]
<|jemc|> for example, puts nil will print an empty line
<apeiros> scriabin: try `self.puts "hi"`
<|jemc|> whereas p nil will print 'nil'
hukl has quit [Read error: Operation timed out]
<onewheelskyward> I just use .inspect.
<apeiros> tedious :)
<scriabin> all over my AR model I refer to self.id to mean the instance id
<scriabin> it's seemed to work fine so far
<scriabin> but in one place I'm getting an error I think
<yaymukund> you don't need `self.` if you're just reading AR attributes
<|jemc|> using self.id can help to distinguish between your instance method and a local var,
<|jemc|> but most of the time, you should just avoid those coincident names
<scriabin> ok I think I see
cody-- has joined #ruby
<apeiros> 23:50 scriabin: but in one place I'm getting an error I think
<yaymukund> yeah, I know what you're gonna ask next
<apeiros> this is, um, let me put it gently, a rather bad description
<yaymukund> lol
hukl_ has quit [Ping timeout: 240 seconds]
nadirvardar has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
<yaymukund> "an error" => "what error?"
<apeiros> scriabin: "an error, I think" - do you get an error or not? also, what error? and don't paraphrase it, copy & paste it verbatim.
renotarize43 has quit [Ping timeout: 248 seconds]
<scriabin> apeiros:I know but the next thing you'll say is show me some code and I'm not actually asking about the code, I'm asking if it's possible that self.id could be different than id in this context: within a model method, I have DoMagicWorker.perform_async(self.id)
mmitchell has quit [Ping timeout: 268 seconds]
<apeiros> and "but in one place" - this is absolutely not helpful to people who'd try to help. paste code. state to what line an eventual exception refers to.
TehCraw has left #ruby ["Leaving"]
<apeiros> scriabin: id and self.id can differ in two cases
tatsuya_o has quit [Remote host closed the connection]
<apeiros> a) id exists as a local variable, which takes precedence over a method
<apeiros> b) the method id() is private, then self.id() will raise a NoMethodError
<scriabin> apeiros: the error is: Deployment#appropriate_roles delegated to application.appropriate_roles, but application is nil
<yaymukund> couldn't self also be a local variable?
renotarize43 has joined #ruby
<apeiros> scriabin: yeah, that's totally unrelated to your self.id call I'd say
failshell has quit [Ping timeout: 276 seconds]
Fire-Dragon-DoL has joined #ruby
<apeiros> you call `appropriate_roles` somewhere in your `Deployment` model
sambao21 has joined #ruby
<scriabin> delegate :appropriate_roles, :to => :application, :prefix => false, :allow_nil => true
splittingred_ has joined #ruby
<apeiros> and as the error states, you somewhere told the model to delegate `appropriate_roles` to `application`
<apeiros> interesting that it complains with allow_nil set to true
<scriabin> I have @deployment.appropriate_roles.include?(@r)
nfk has quit [Quit: yawn]
<apeiros> but anyway, IMO completely unrelated to your self.id vs. id question
<apeiros> scriabin: aha, well, then rails is being clever in its error message
<scriabin> apeiros:when I added :allow_nil => true I began to see
<scriabin> nil.include?
<apeiros> if application is nil, then appropriate_roles will be nil
<scriabin> is an error (know what I mean?)
butblack has joined #ruby
<apeiros> and nil.include? is not defined
splittingred has quit [Ping timeout: 268 seconds]
splittingred_ is now known as splittingred
<scriabin> right but I'm certain that @deployment.application_id is not nil err @deployment.application is not nil!
<apeiros> well, ruby vs. you - ruby usually knows better :-p
rcosta_ has joined #ruby
thillux has joined #ruby
hanmac has joined #ruby
<apeiros> but find out why it's nil and/or why it shouldn't be
pushpak has joined #ruby
snovak has quit [Remote host closed the connection]
pushpak has quit [Client Quit]
<scriabin> I know what you mean - this is why I suspect @deployment is nil
snovak has joined #ruby
<scriabin> of course it would be nice if ruby said @deployment.appropriate_roles.include?() @deployment is nil dummy! etc
Nisstyre-laptop has joined #ruby
optimusprimem has joined #ruby
<apeiros> if @deployment was nil, you couldn't even call @deployment.appropriate_roles
<scriabin> in a way it does if an invariant is @deployment.application is not nil
<apeiros> also, "I suspect" -> go and verify it already!
<scriabin> the error is: undefined method `include?' for nil:NilClass
<apeiros> nothing stopping you :)
<apeiros> use p/puts/binding.pry/gdb - whatever floats your boat
rcosta has quit [Ping timeout: 264 seconds]
solars has quit [Ping timeout: 268 seconds]
jbpros has quit [Quit: jbpros]
saarinen has quit [Quit: saarinen]
pkrnj has quit [Ping timeout: 248 seconds]
coderhs has joined #ruby
snovak has quit [Ping timeout: 240 seconds]
thillux has quit [Read error: Connection reset by peer]
nisstyre has joined #ruby
obs has quit [Quit: Konversation terminated!]
mando has quit [Remote host closed the connection]
baordog_ has quit [Remote host closed the connection]
tomsthumb_ has joined #ruby
saarinen has joined #ruby
brain_shim has joined #ruby
m8 has quit [Quit: Sto andando via]
tomsthumb has quit [Ping timeout: 248 seconds]
ffranz has quit [Quit: Leaving]
soulcake has quit [Read error: Connection reset by peer]
Underbyte has quit [Quit: Leaving...]
claymore has quit [Quit: Leaving]
soulcake has joined #ruby
soheil has joined #ruby
sarkis has joined #ruby
burlyscudd has joined #ruby
geggam_ has quit [Remote host closed the connection]
splittingred has quit [Quit: splittingred]
sambao21 has quit [Ping timeout: 248 seconds]
vlad_starkov has joined #ruby
wmoxam has joined #ruby
phracker has quit [Ping timeout: 240 seconds]
wyan has quit [Ping timeout: 240 seconds]
axl_ has quit [Quit: axl_]
splittingred has joined #ruby
Nenor has quit [Quit: Nenor]
RORgasm has quit [Remote host closed the connection]
Akuma has quit [Ping timeout: 264 seconds]
macmartine has joined #ruby
wyan has joined #ruby
radic has quit [Ping timeout: 260 seconds]
alex__c2022 has quit [Quit: alex__c2022]
axl_ has joined #ruby
emergion has joined #ruby
jlast has quit [Remote host closed the connection]
emergion has quit [Max SendQ exceeded]
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
emergion has joined #ruby
tjbiddle has joined #ruby
vlad_starkov has quit [Ping timeout: 264 seconds]
phracker has joined #ruby
sambao21 has joined #ruby
emergion has quit [Max SendQ exceeded]
<tjbiddle> Hey guys - looking at http://www.ruby-doc.org/stdlib-2.0.0/libdoc/logger/rdoc/Logger.html#method-c-new-label-Args - Is it possible to have logger shift every day - but only keep X days?
Ox6abe has quit [Remote host closed the connection]
kvirani has quit [Remote host closed the connection]
emergion has joined #ruby
kofno has quit [Ping timeout: 248 seconds]
kvirani has joined #ruby
emergion has quit [Max SendQ exceeded]
tealmage has joined #ruby
emergion has joined #ruby
Ox6abe_ has joined #ruby
emergion has quit [Max SendQ exceeded]
emergion has joined #ruby
alekst has quit [Quit: Computer has gone to sleep.]
sambao21 has quit [Ping timeout: 240 seconds]
emergion has quit [Max SendQ exceeded]
Ripp__ has quit []
Akuma has joined #ruby
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
jbpros has joined #ruby
kvirani has quit [Ping timeout: 276 seconds]
emergion has joined #ruby
<scriabin> well, I took all the bullshit self references out of my model and I'm still running. Woot!
emergion has quit [Max SendQ exceeded]
<a1ph4g33k> tjbiddle, there is only a single input param ... @shift_age ... it's either a number or a string ... so, I don't see an easy way to make it do both.
MrThePlague has quit [Remote host closed the connection]
emergion has joined #ruby
<a1ph4g33k> ( and by single ... I mean that both "number of old files" & "daily|weekly|monthly| use a single parameter.
<a1ph4g33k> so they are mutually exclusive.
butblack has quit [Quit: butblack]
RichardBaker has quit [Quit: RichardBaker]
emergion has quit [Max SendQ exceeded]
<a1ph4g33k> but, you could also setup a cron job to delete log files...
snovak has joined #ruby
emergion has joined #ruby
momomomomo has quit [Quit: momomomomo]
dangerousdave has quit [Quit: Leaving...]
emergion has quit [Max SendQ exceeded]
robbyoconnor has joined #ruby
Ripp__ has joined #ruby
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
wesside has quit [Quit: I think I heard an ice cream truck..]
scriabin has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
emergion has joined #ruby
Ox6abe_ has quit [Remote host closed the connection]
mlpinit has quit [Remote host closed the connection]
emergion has quit [Max SendQ exceeded]
ewnd9 has joined #ruby
emergion has joined #ruby
threesome has quit [Ping timeout: 260 seconds]
emergion has quit [Max SendQ exceeded]
maroloccio has quit [Quit: WeeChat 0.4.0]
emergion has joined #ruby
_maes_ has joined #ruby
dml_ has quit [Quit: Computer has gone to sleep.]
apeiros has quit [Remote host closed the connection]
popl has joined #ruby
soheil has quit [Read error: Connection timed out]
wesside has joined #ruby
apeiros has joined #ruby
brain_shim has quit [Ping timeout: 245 seconds]
cj3kim_ has joined #ruby
soheil has joined #ruby
gr33n7007h has quit [Ping timeout: 264 seconds]
dodosan has quit [Remote host closed the connection]
snovak has quit [Ping timeout: 264 seconds]
Nisstyre-laptop has quit [Remote host closed the connection]
soheil has quit [Remote host closed the connection]
corpuscle has quit [Quit: WeeChat 0.4.1]
mansi has quit [Remote host closed the connection]
Akuma has quit [Read error: Connection reset by peer]
mansi has joined #ruby
Teddy2steper has joined #ruby
emergion has quit [Ping timeout: 260 seconds]
sloucher has quit [Quit: sloucher]
RichardBaker has joined #ruby
emergion has joined #ruby
Cyrus has joined #ruby
Akuma has joined #ruby
senayar has joined #ruby
VTLob has quit [Quit: VTLob]
cj3kim_ has quit [Ping timeout: 240 seconds]
splittingred has quit [Quit: splittingred]
emergion has quit [Max SendQ exceeded]
Teddy2steper has quit [Remote host closed the connection]
rcedillor has quit [Ping timeout: 264 seconds]
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
emergion has joined #ruby
mansi has quit [Ping timeout: 248 seconds]
emergion has quit [Max SendQ exceeded]
mary5030 has quit [Remote host closed the connection]
ghost2060 has quit [Ping timeout: 268 seconds]
staafl has quit [Ping timeout: 260 seconds]
jbpros has quit [Quit: jbpros]
jerius has quit [Read error: Operation timed out]
ghost2060 has joined #ruby
emergion has joined #ruby
emergion has quit [Max SendQ exceeded]
lkba has joined #ruby
emergion has joined #ruby
soulcake has quit [Ping timeout: 240 seconds]
tvw has quit []
emergion has quit [Max SendQ exceeded]
phracker has quit [Ping timeout: 240 seconds]
emergion has joined #ruby
cody-- has quit [Quit: derp]
awkisopen has quit [Ping timeout: 240 seconds]
thecodethinker has joined #ruby
awkisopen has joined #ruby
phracker has joined #ruby
KobraKao has joined #ruby
soheil has joined #ruby
KobraKao has quit [Client Quit]
macmartine has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
soulcake has joined #ruby
hanmac has quit [Quit: Leaving.]
tatsuya_o has joined #ruby
iamjarvo has joined #ruby
hanmac has joined #ruby
robbyoconnor has quit [Ping timeout: 240 seconds]
radic has joined #ruby
maroloccio has joined #ruby
lfox has quit [Quit: ZZZzzz…]
lfox has joined #ruby
tatsuya_o has quit [Ping timeout: 245 seconds]
peregrine81 has quit []
yasu has quit [Ping timeout: 240 seconds]
yasu has joined #ruby
anonymus_ has joined #ruby
ged_ has joined #ruby
kayloos has quit [Remote host closed the connection]
Caius has quit [Ping timeout: 240 seconds]
ged has quit [Read error: Connection reset by peer]
alo1_ has quit [Ping timeout: 240 seconds]
anonymuse has quit [Read error: Operation timed out]
alo1 has joined #ruby
Caius has joined #ruby
ewnd9 has quit [Remote host closed the connection]
forced_request has joined #ruby
Bira has joined #ruby
senayar has quit [Remote host closed the connection]
tealmage has quit [Remote host closed the connection]
freerobby has quit [Quit: Leaving.]
cody-- has joined #ruby
rhys has quit [Quit: Leaving]
tealmage has joined #ruby
mikepack has quit [Remote host closed the connection]
brisbin_ has joined #ruby
Spami has quit [Quit: This computer has gone to sleep]
brisbin has quit [Quit: WeeChat 0.4.1]
brisbin_ is now known as brisbin
Ox6abe has joined #ruby
iamjarvo has quit [Remote host closed the connection]
iamjarvo has joined #ruby
anonymuse has joined #ruby
tealmage_ has joined #ruby
tealmage has quit [Ping timeout: 260 seconds]
anonymus_ has quit [Read error: Connection reset by peer]
cody-- has quit [Quit: derp]
Deele has quit [Ping timeout: 240 seconds]
dodosan has joined #ruby
anonymus_ has joined #ruby
a1ph4g33k has quit [Quit: "G'nite all."]
cody-- has joined #ruby
iamjarvo has quit [Ping timeout: 240 seconds]
gstamp has joined #ruby
anonymuse has quit [Read error: Operation timed out]
funburn has joined #ruby
pel_daniel has left #ruby [#ruby]
Spami has joined #ruby
soheil has quit [Read error: Operation timed out]
soheil has joined #ruby
hanmac has quit [Quit: Leaving.]
emergion has quit [Quit: Computer has gone to sleep.]
bradhe has quit [Remote host closed the connection]
clov3r has quit [Remote host closed the connection]
anonymuse has joined #ruby
bobinator60_ has joined #ruby
superscott[8] has joined #ruby
<bobinator60_> how can i have two different paths in a Podfile, depending on an environment variable.
<shevy> huh
johnjohnson has quit [Quit: Textual IRC Client: www.textualapp.com]
<shevy> is that a ruby podfile
<bobinator60_> Podfiles are ruby files
devdazed has quit [Read error: Connection reset by peer]
ferdev has quit [Quit: ferdev]
anonymus_ has quit [Ping timeout: 240 seconds]
<shevy> hmm http://file.org/extension/pod "POD is an acronym for Plain Old Documentation. The .pod file extension is most commonly associated with the Perl programming language."
<bobinator60_> cocoapods.org
thecodethinker has quit [Ping timeout: 248 seconds]
ghost2060 has quit [Quit: leaving]
thecodethinker has joined #ruby
<bnagy> you can access ENV from ruby
<bobinator60_> i don't know ruby. that's why i'm here
<bnagy> so I guess you just have some if ENV['blah'] .. do a thing
<bnagy> it's OK I have NFI about this cocoapod thing :)
bobinator60_ has quit [Quit: bobinator60_]
lethjakman has quit [Ping timeout: 245 seconds]
<shevy> a cacao pod man that would be sweet...
<bnagy> nah they're super bitter
<shevy> true :(
Ox6abe has quit [Remote host closed the connection]
RichardBaker has quit [Ping timeout: 248 seconds]
anonymus_ has joined #ruby
nari has joined #ruby
anonymuse has quit [Ping timeout: 264 seconds]
grzywacz has quit [Ping timeout: 264 seconds]
RichardBaker has joined #ruby
kofno has joined #ruby
bobinator60___ has joined #ruby
<bobinator60___> this is an example of what i need to do: https://gist.github.com/rbpasker/3e470d8d84413cc04a43
rcosta_ has quit [Remote host closed the connection]
<bnagy> ok
wmoxam has quit [Ping timeout: 240 seconds]
<bnagy> just put RUNNING_IN_EDITMODE = ENV['POD_EDITMODE']
<bnagy> and set that env var to anything at all
greenrose has joined #ruby
Ripp__ has quit []
<bnagy> at the top of the file with your ruby stuff
|jemc| has quit [Ping timeout: 260 seconds]
rcosta has joined #ruby
<bobinator60___> oh
digifiv5e has quit [Ping timeout: 248 seconds]
<bobinator60___> ok i'll try it
rehat has quit [Remote host closed the connection]
kofno has quit [Ping timeout: 240 seconds]
anonymuse has joined #ruby
cody-- has quit [Quit: derp]
butblack has joined #ruby
snovak has joined #ruby
soheil has quit [Read error: Connection timed out]
<bobinator60___> needs an 'end'
<bobinator60___> thanks
<Eiam> huh, kind of neat http://opalrb.org
<bobinator60___> its like ALGOL-60 all over again
soheil has joined #ruby
zarubin has quit [Ping timeout: 245 seconds]
<Eiam> still, grr.
Ripp__ has joined #ruby
<banister`gym> Eiam waddup
sarkis has quit [Ping timeout: 260 seconds]
<banister`gym> Eiam what does eiam mean btw?
<Eiam> banister`gym: its the initials of my daughters
anonymus_ has quit [Ping timeout: 264 seconds]
<banister`gym> Eiam 4 daughters?
<Eiam> banister`gym: 3+wife
<banister`gym> Eiam no boys?
<Eiam> nope
cj3kim_ has joined #ruby
anonymus_ has joined #ruby
anonymuse has quit [Read error: Connection reset by peer]
<banister`gym> Eiam hehe, i know a family of 4 daughters in my city, it's pretty obvious they kept popping out kids to try to have a son ;)
<banister`gym> Eiam similar in your case?
devoldmx has quit [Read error: Connection reset by peer]
<Eiam> I stopped at 3, but yes
<Eiam> 3 was another dice roll.
stevenhaddox has joined #ruby
lfox has quit [Quit: ZZZzzz…]
Guest76113 has joined #ruby
<banister`gym> Eiam i wouldn't want to be in your shoes once they all turn around 12-13 :)
<bobinator60___> hayes theorem says that the more girls you have, the more you will have
<bobinator60___> hayes = bayes
snovak has quit [Ping timeout: 264 seconds]
<Eiam> bobinator60___: yes, partly why I stopped
justsee has joined #ruby
<shevy> lol
<Eiam> the other reason was I didn't want to buy a bigger car
<Eiam> and I'm already insane, any more I'd have to be committed
<banister`gym> Eiam i lived with a flat full of women before, it's very strange, but their mensturation all seems to sync up
<Eiam> banister`gym: no proof to that biologically speaking
<Eiam> but yes I've heard it mentioned before
<banister`gym> Eiam yeah maybe, but lots anecdotal evidence from most women i speak to as well as my own experience.
<Eiam> yep
<Eiam> I'm okay with staying in a hotel once a month
<banister`gym> hehe
<Eiam> or going camping
* Eiam shrugs
<banister`gym> g'luck :)
<Eiam> I don't have any hair to lose
cj3kim_ has quit [Ping timeout: 240 seconds]
ixti has quit [Read error: No route to host]
freerobby has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
yaymukund has quit [Ping timeout: 245 seconds]
maletor has joined #ruby
carlyle has quit [Remote host closed the connection]
nanoxd_ has joined #ruby
<Eiam> is pry a 501?
<Eiam> doesn't look like it
mikepack has joined #ruby
saarinen has quit [Quit: saarinen]
mansi has joined #ruby
sarkis has joined #ruby
tomzx_mac has joined #ruby
<banister`gym> Eiam what?
<Eiam> 501c
rezzack has quit [Remote host closed the connection]
<Eiam> a non profit
nanoxd has quit [Read error: Operation timed out]
<banister`gym> i'm not american, is that an american concept?
<popl> banister`gym: charity
<Eiam> I guess so =) I was just thinking we do corporate matching with charity donations
flaccid has joined #ruby
<crowell> banister`gym: yeah, that's an american thing
<Eiam> so donations are doubled
<banister`gym> Eiam great, get your boss to send me heaps of money then
<flaccid> is there a shorter/nicer way to do if foo or not bar ?
<crowell> 501c is nonprofit that doens't have to pay taxes
<flaccid> sorry if foo and not bar
rezzack has joined #ruby
<crowell> flaccid: that already seems pretty much as simplified as possible
<Eiam> ^
<banister`gym> flaccid if foo || !bar
babinho has quit [Ping timeout: 245 seconds]
MrZYX is now known as MrZYX|off
<Eiam> meh, ! is hard to see there
<Eiam> prefer the original =)
rezzack has quit [Remote host closed the connection]
superscott[8] has quit [Quit: superscott[8]]
tylersmith has quit [Remote host closed the connection]
funburn has quit [Ping timeout: 260 seconds]
Bira has quit [Remote host closed the connection]
tylersmith has joined #ruby
bradhe has joined #ruby
<flaccid> actually, i'll give the real example with best i have. its a silly case of having to support false and 'false'. if node['aws_developer_tools']['install_ruby?'] || node['aws_developer_tools']['install_ruby?'] != 'false'
rezzack has joined #ruby
jkline has quit [Quit: jkline]
jprovazn has quit [Quit: Leaving]
baroquebobcat has quit [Quit: baroquebobcat]
lukec has quit [Quit: lukec]
tylersmith has quit [Ping timeout: 248 seconds]
RichardBaker has quit [Quit: RichardBaker]
babinho has joined #ruby