jhass changed the topic of #ruby to: Rules & more: http://ruby-community.com || Ruby 2.2.3; 2.1.7; 2.0.0-p647: https://ruby-lang.org || Paste >3 lines of text on https://gist.github.com || log @ http://irclog.whitequark.org/ruby/
robbyoconnor has joined #ruby
phutchins has quit [Ping timeout: 252 seconds]
houhoulis has joined #ruby
czsr has quit [Quit: WeeChat 1.0.1]
ishahnaz has quit []
war_pigs has quit [Quit: later... computer is sleeping]
<Ox0dea> >> 'jhaz'.tr 'h-za', 'a-z'
<ruboto> Ox0dea # => "cats" (https://eval.in/421034)
<Ox0dea> Coincidence? I think not.
Rodya_ has joined #ruby
mary5030 has joined #ruby
gz_rain has quit []
David27 has quit [Remote host closed the connection]
bazbing80 has joined #ruby
chazubell has quit [Read error: Connection reset by peer]
davedev24 has joined #ruby
<Ox0dea> >> 'laxor'.tr 't-za-s', 'a-z'
<ruboto> Ox0dea # => "shevy" (https://eval.in/421035)
dimasg has quit [Ping timeout: 272 seconds]
mary5030 has quit [Ping timeout: 260 seconds]
Ropeney has joined #ruby
marr has quit []
bazbing80 has quit [Quit: Lost terminal]
siemprefresco has joined #ruby
christiandsg has quit [Remote host closed the connection]
catos has quit [Ping timeout: 260 seconds]
Torrieri has joined #ruby
sixyod has joined #ruby
<sixyod> <3 you guys!
sixyod has left #ruby [#ruby]
Torrieri has quit [Client Quit]
christiandsg has joined #ruby
towski_ has quit [Remote host closed the connection]
Ox0dea has quit [Disconnected by services]
Ox0dea has joined #ruby
baweaver has quit [Remote host closed the connection]
FernandoBasso has quit [Quit: May the force be with you.]
christiandsg has quit [Ping timeout: 265 seconds]
eminencehc has joined #ruby
rubie has joined #ruby
davedev2_ has joined #ruby
davedev24 has quit [Ping timeout: 250 seconds]
Porfa has quit [Quit: Porfa]
christiandsg has joined #ruby
eminencehc has quit [Ping timeout: 272 seconds]
jancel has joined #ruby
seanmclaren has joined #ruby
jeadre has quit [Remote host closed the connection]
<shevy> today is so quiet
jancel has quit [Ping timeout: 255 seconds]
jeadre has joined #ruby
above has quit [Ping timeout: 250 seconds]
Torrieri has joined #ruby
Torrieri has joined #ruby
mistermocha has joined #ruby
siemprefresco has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
choke has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
hyy1 has joined #ruby
mistermocha has quit [Read error: Connection reset by peer]
dimasg has joined #ruby
Guest26811 has quit [Quit: This computer has gone to sleep]
beef-wellington has joined #ruby
sevenseacat has joined #ruby
Feyn has joined #ruby
raypulver has joined #ruby
pgatt has joined #ruby
dimasg has quit [Ping timeout: 255 seconds]
JulioPapel has quit [Remote host closed the connection]
Guest26811 has joined #ruby
seanmclaren has quit [Quit: rcirc on GNU Emacs 24.5.1]
pocketprotector has quit [Quit: WeeChat 0.4.3]
Musashi007 has quit [Quit: Musashi007]
pocketprotector has joined #ruby
pocketprotector has quit [Client Quit]
dopamean_ has joined #ruby
bffff_ has joined #ruby
Musashi007 has joined #ruby
christiandsg has quit [Remote host closed the connection]
faces has joined #ruby
war_pigs has joined #ruby
christiandsg has joined #ruby
face has quit [Ping timeout: 272 seconds]
fullofcaffeine has quit [Ping timeout: 240 seconds]
zenguy_pc has quit [Ping timeout: 265 seconds]
oo_ has joined #ruby
sarkyniin has quit [Ping timeout: 252 seconds]
yqt has quit [Ping timeout: 240 seconds]
christiandsg has quit [Ping timeout: 265 seconds]
dimasg has joined #ruby
Yzguy has joined #ruby
jeadre has quit [Remote host closed the connection]
enroxorz has joined #ruby
<enroxorz> hey everyone, how do i add the following into yaml so i can parse it late? Something like
j_mcnall_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jeadre has joined #ruby
<enroxorz> --- route: billing/#{params[:account_number]}/summary/#{params[:billing_number]}
zenguy_pc has joined #ruby
<toretore> yaml doesn't know anything about ruby string interpolation
AlphaAtom has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
fullofcaffeine has joined #ruby
sdfgsdfg has joined #ruby
hololeap has quit [Ping timeout: 256 seconds]
mistermocha has joined #ruby
ftj has joined #ruby
<toretore> >>require 'yaml'; params={account_number: '12345', billing_number: '67890'}; YAML.load(YAML.dump(route: 'billing/%{account_number}/summary/%{billing_number}'))['route'] % params
<ruboto> toretore # => undefined method `%' for nil:NilClass (NoMethodError) ...check link for more (https://eval.in/421042)
<toretore> >>require 'yaml'; params={account_number: '12345', billing_number: '67890'}; YAML.load(YAML.dump(route: 'billing/%{account_number}/summary/%{billing_number}'))[:route] % params
<ruboto> toretore # => "billing/12345/summary/67890" (https://eval.in/421043)
axsuul has quit [Read error: Connection reset by peer]
axsuul has joined #ruby
rubie has quit [Remote host closed the connection]
<enroxorz> thanks
enroxorz has quit [Quit: Page closed]
chipotle has quit [Ping timeout: 255 seconds]
ftj has quit [Ping timeout: 272 seconds]
<shevy> Ox0dea why are you so quiet today
above has joined #ruby
sdwrage has joined #ruby
phutchins has joined #ruby
bruno- has quit [Ping timeout: 252 seconds]
tmtwd has joined #ruby
dorei has quit []
ybian has quit [Remote host closed the connection]
ybian has joined #ruby
phutchins has quit [Ping timeout: 252 seconds]
fullofcaffeine has quit [Remote host closed the connection]
christiandsg has joined #ruby
phutchins has joined #ruby
<Coraline> Hihi
chipotle has joined #ruby
workmad3 has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
war_pigs has quit [Quit: later... computer is sleeping]
kr3ssh has quit [Ping timeout: 264 seconds]
pragmatism has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
phutchins has quit [Ping timeout: 246 seconds]
roolo has joined #ruby
mistermocha has quit [Read error: Connection reset by peer]
workmad3 has quit [Ping timeout: 260 seconds]
mistermocha has joined #ruby
fullofcaffeine has joined #ruby
rbennacer has joined #ruby
JoshGlzBrk has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
closer has quit [Ping timeout: 272 seconds]
roolo has quit [Ping timeout: 244 seconds]
beef-wellington has quit [Ping timeout: 240 seconds]
closer has joined #ruby
dr3w has joined #ruby
devoldmx has joined #ruby
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
haraoka has joined #ruby
war_pigs has joined #ruby
dimasg has quit [Ping timeout: 272 seconds]
zxvcd has quit [Quit: Leaving]
dimasg has joined #ruby
chipotle has quit [Ping timeout: 252 seconds]
Rodya_ has quit [Remote host closed the connection]
Rodya_ has joined #ruby
Ox0dea has quit [Disconnected by services]
c0ncealed has quit [Ping timeout: 250 seconds]
Rodya_ has quit [Remote host closed the connection]
Ox0dea has joined #ruby
ledestin has joined #ruby
<pontiki> hallo o/
war_pigs has quit [Quit: laters.. I'm out.]
mistermocha has quit [Read error: Connection reset by peer]
above has quit [Ping timeout: 245 seconds]
mistermocha has joined #ruby
tkuchiki has joined #ruby
dimasg has quit [Ping timeout: 244 seconds]
Yzguy has quit [Quit: Zzz...]
tkuchiki has quit [Read error: Connection reset by peer]
<shevy> tikihontas!
tkuchiki has joined #ruby
symm- has quit [Ping timeout: 252 seconds]
chipotle has joined #ruby
A124 has quit [Remote host closed the connection]
dr3w has quit [Ping timeout: 260 seconds]
mistermocha has quit [Read error: Connection reset by peer]
mistermocha has joined #ruby
clarkenciel has quit [Ping timeout: 252 seconds]
cluelesscoder has left #ruby ["undefined"]
mistermocha has quit [Read error: Connection reset by peer]
mistermo_ has joined #ruby
A124 has joined #ruby
<Coraline> I'm just back from Madison Ruby. So sad.
mistermo_ has quit [Read error: Connection reset by peer]
tuxero has joined #ruby
<Ox0dea> "Don't cry because it's over, smile because it happened." -- Theodor Geisel
Guest26811 has quit [Quit: This computer has gone to sleep]
<sevenseacat> wise words.
mistermocha has joined #ruby
<shevy> what is madison ruby?
hydrozen has joined #ruby
<Coraline> The best Ruby conference in the world. And this week was the last one ever.
<totimkopf> :(
<totimkopf> why does it have to be the last one?
<cscheib> anyone who could help me reverse engineer how the github_api gem (https://github.com/peter-murach/github) is resolving multiple levels of dots to multiple levels of classes, it would be much appreciated. i.e. github.users.followers.following is mapped to Github::Client::Users::Followers.following
<Coraline> totimkopf: the organizers are burnt out
<totimkopf> Coraline: :(
<cscheib> I'm like half way to understanding, I'm missing a couple leaps
<Ox0dea> cscheib: See #const_get?
tuxero has quit [Read error: Connection reset by peer]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Musashi007 has quit [Quit: Musashi007]
tuxero has joined #ruby
shazaum has quit [Quit: Leaving]
charliesome has joined #ruby
jancel has joined #ruby
Rickmasta has joined #ruby
allcentury has quit [Ping timeout: 244 seconds]
<cscheib> Ox0dea: is that what's doing it? I'm not just talking about constants, they're actually basically translating methods multiple layers deep to a dotted namespace... I'm probably missing something simple
<ght> Question: I was told previously that if you use a conditional statement with ||, where you're checking if one or the other statement is true, if the left statement is true Ruby will not evaluate the right statement.
<Ox0dea> cscheib: Those're probably actual methods, no?
<Ox0dea> ght: That's correct.
jancel has quit [Ping timeout: 255 seconds]
<Ox0dea> This is called "short-circuit" evaluation.
michael_mbp has quit [Excess Flood]
christiandsg has quit [Remote host closed the connection]
michael_mbp has joined #ruby
<cscheib> Ox0dea: yea, I can find where the methods are defined in their classes, and how they could be called with the :: notation as part of their class, just trying to figure out how they're making use of them through dotted notation
<Ox0dea> cscheib: What is "dotted notation", as you understand it?
banjara has quit [Quit: Leaving.]
<Ox0dea> They're just method calls, as best I can tell.
dgutierrez1287 has quit [Remote host closed the connection]
<cscheib> yea
<cscheib> I'm just trying to figure out the methodology they're using to define how to call the methods via dots.
<cscheib> I don't speak super concise developer speak, so apologies.
Guest26811 has joined #ruby
christiandsg has joined #ruby
<cscheib> I'm also kinda diving into the deep end here
<cscheib> I've seen the "simple" method on how to do this... basically define a method in yoru higher level class that maps to the deeper level class
<cscheib> but I can't really find where they're doing that
<Ox0dea> cscheib: http://git.io/vs6z6
<Ox0dea> That seems to be where most of the magic happens.
<cscheib> thanks! that looks like exactly what I've been looking for
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
christiandsg has quit [Ping timeout: 265 seconds]
catoblepa has joined #ruby
mistermo_ has joined #ruby
mistermocha has quit [Read error: Connection reset by peer]
above has joined #ruby
fullofcaffeine has quit [Remote host closed the connection]
mistermo_ has quit [Read error: Connection reset by peer]
mistermocha has joined #ruby
rubie has joined #ruby
choke has joined #ruby
umgrosscol has joined #ruby
charliesome has joined #ruby
Yzguy has joined #ruby
hydrozen has quit [Quit: Textual IRC Client: www.textualapp.com]
faces has quit [Ping timeout: 240 seconds]
face has joined #ruby
<shevy> hmm
catoblepa has quit [Ping timeout: 256 seconds]
choke has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
maletor has joined #ruby
Mon_Ouie has quit [Ping timeout: 250 seconds]
hydrozen has joined #ruby
catoblepa has joined #ruby
catoblepa has quit [Changing host]
catoblepa has joined #ruby
rbennacer has quit [Remote host closed the connection]
jher has joined #ruby
_blizzy_ has quit [Ping timeout: 255 seconds]
phutchins has joined #ruby
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rubie has quit [Remote host closed the connection]
above has quit [Ping timeout: 272 seconds]
tuxero has quit [Ping timeout: 240 seconds]
pocketprotector has joined #ruby
zenguy_pc has quit [Ping timeout: 240 seconds]
psy_ has joined #ruby
preller has quit [Remote host closed the connection]
arescorpio has joined #ruby
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
siemprefresco has joined #ruby
Rodya_ has joined #ruby
minmax has joined #ruby
Rodya_ has quit [Client Quit]
gareim has joined #ruby
christiandsg has joined #ruby
mistermocha has quit [Ping timeout: 250 seconds]
phutchins has quit [Ping timeout: 246 seconds]
mistermocha has joined #ruby
mistermocha has quit [Remote host closed the connection]
jeadre has quit [Remote host closed the connection]
jeadre has joined #ruby
Raymon_ has joined #ruby
astrobunny has joined #ruby
zenguy_pc has joined #ruby
Raymon_ has left #ruby [#ruby]
braincras has quit [Quit: bye bye]
twistedpixels has quit [Ping timeout: 252 seconds]
braincrash has joined #ruby
darkf has joined #ruby
snath has joined #ruby
oo_ has quit [Remote host closed the connection]
oo_ has joined #ruby
phutchins has joined #ruby
mistermocha has joined #ruby
oo_ has quit [Remote host closed the connection]
maletor has quit [Quit: Computer has gone to sleep.]
oo_ has joined #ruby
<zenspider> cscheib: yeah "::" really is just ".", but its use has fallen out of favor for method calls. stick to "."
shinnya has quit [Ping timeout: 250 seconds]
roolo has joined #ruby
yfeldblu_ has joined #ruby
siemprefresco has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
yfeldblum has quit [Ping timeout: 244 seconds]
roolo has quit [Ping timeout: 246 seconds]
tjohnson has quit [Quit: Connection closed for inactivity]
baweaver has joined #ruby
djbkd has joined #ruby
yfeldblum has joined #ruby
Valeness has quit [Disconnected by services]
dimasg has joined #ruby
Valeness has joined #ruby
Valeness has quit [Disconnected by services]
yfeldblu_ has quit [Ping timeout: 246 seconds]
djbkd has quit [Ping timeout: 244 seconds]
Valeness_ has joined #ruby
tuxero has joined #ruby
christiandsg has quit [Remote host closed the connection]
dimasg has quit [Ping timeout: 255 seconds]
christiandsg has joined #ruby
tuxero has quit [Client Quit]
umgrosscol has quit [Quit: Quit]
christiandsg has quit [Ping timeout: 265 seconds]
pgatt has quit [Quit: Connection closed for inactivity]
siemprefresco has joined #ruby
mary5030 has joined #ruby
amystephen has quit [Quit: amystephen]
khebbie has joined #ruby
above has joined #ruby
mistermocha has quit [Ping timeout: 244 seconds]
catoblepa has quit [Ping timeout: 264 seconds]
mistermocha has joined #ruby
JoshGlzBrk has joined #ruby
maletor has joined #ruby
khebbie has quit [Ping timeout: 260 seconds]
JoshGlzBrk has quit [Client Quit]
renderfu_ has joined #ruby
clarkenciel has joined #ruby
mary5030 has quit [Remote host closed the connection]
mary5030 has joined #ruby
saddad has quit [Ping timeout: 252 seconds]
mistermocha has quit [Remote host closed the connection]
renderfu_ has quit [Ping timeout: 246 seconds]
oo_ has quit [Remote host closed the connection]
mary5030 has quit [Ping timeout: 260 seconds]
oo_ has joined #ruby
Musashi007 has joined #ruby
Yzguy has quit [Quit: Cya]
jancel has joined #ruby
rubie has joined #ruby
veduardo has quit [Ping timeout: 272 seconds]
jancel has quit [Ping timeout: 264 seconds]
jeadre has quit [Remote host closed the connection]
grotewold has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
jher has quit [Ping timeout: 264 seconds]
jeadre has joined #ruby
Oog_ has joined #ruby
astrobunny has quit [Remote host closed the connection]
snath has left #ruby ["Leaving"]
jeadre has quit [Remote host closed the connection]
System42 has quit [Quit: Leaving]
clarkenciel has quit [Ping timeout: 252 seconds]
jeadre has joined #ruby
Kallis has quit [Read error: Connection reset by peer]
cornerma1 has joined #ruby
mistermocha has joined #ruby
mistermocha has quit [Remote host closed the connection]
towski_ has joined #ruby
iateadonut has joined #ruby
Musashi007 has quit [Quit: Musashi007]
hydrozen has quit [Quit: Textual IRC Client: www.textualapp.com]
rushed has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
bruno- has joined #ruby
cornerman has quit [Ping timeout: 260 seconds]
cornerma1 is now known as cornerman
houhoulis has quit [Remote host closed the connection]
towski_ has quit [Ping timeout: 265 seconds]
bruno- has quit [Ping timeout: 244 seconds]
rubie has quit [Remote host closed the connection]
banjara has joined #ruby
jhack has quit [Ping timeout: 246 seconds]
<lore-> ugh what happened her
lore- has quit [Quit: leaving]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
c0ncealed has joined #ruby
astrobunny has joined #ruby
<Aeyrix> zenspider: the
<Aeyrix> Paamayim Nekudotayim
<Aeyrix> name for :: of the year, all years
<shevy> hmm... when I try to check for an addon such as CodeRay, I seem to check via defined?(CodeRay) but sometimes also via Object.const_defined? :CodeRay - which variant would be better, in the event that both would do the same?
axsuul has quit [Ping timeout: 240 seconds]
<sevenseacat> Aeyrix: yep.
dgutierrez1287 has joined #ruby
gareim has quit [Read error: Connection reset by peer]
jeadre has quit [Remote host closed the connection]
iamninja has quit [Read error: Connection reset by peer]
iamninja has joined #ruby
jeadre has joined #ruby
fullofcaffeine has joined #ruby
charliesome has joined #ruby
dgutierrez1287 has quit [Ping timeout: 240 seconds]
fullofcaffeine has quit [Remote host closed the connection]
banjara has quit [Quit: Leaving.]
christiandsg has joined #ruby
banjara has joined #ruby
pranny has joined #ruby
dseitz has quit [Ping timeout: 244 seconds]
havenwood has joined #ruby
<zenspider> shevy: define "better"
banjara has joined #ruby
pranny has quit [Remote host closed the connection]
pranny has joined #ruby
christiandsg has quit [Ping timeout: 265 seconds]
banjara has quit [Client Quit]
zenguy_pc has quit [Ping timeout: 252 seconds]
dented42 has joined #ruby
oo_ has quit [Remote host closed the connection]
devbug_ has joined #ruby
fedexo has quit [Ping timeout: 246 seconds]
devbug has quit [Ping timeout: 240 seconds]
oo_ has joined #ruby
Cache_Money has quit [Quit: Cache_Money]
arooni-mobile has joined #ruby
zenguy_pc has joined #ruby
mary5030 has joined #ruby
oo_ has quit [Remote host closed the connection]
lessless has joined #ruby
banjara has joined #ruby
JoshGlzBrk has joined #ruby
mary5030 has quit [Ping timeout: 246 seconds]
h4ckurate has joined #ruby
roolo has joined #ruby
lxsameer has joined #ruby
jtdoncas has quit [Ping timeout: 260 seconds]
chrissonar has joined #ruby
towski_ has joined #ruby
riotjones has joined #ruby
h4ckurate has quit [Remote host closed the connection]
dseitz has joined #ruby
roolo has quit [Ping timeout: 260 seconds]
dhjondoh has joined #ruby
bluOxigen has joined #ruby
riotjones has quit [Ping timeout: 246 seconds]
banjara has quit [Quit: Leaving.]
djbkd has joined #ruby
ryanpc has joined #ruby
jtdoncas has joined #ruby
arescorpio has quit [Quit: Leaving.]
ryanpc has quit [Client Quit]
<flughafen> hey guys
devbug has joined #ruby
mrtomme has joined #ruby
opensource_ninja has quit [Quit: opensource_ninja]
devbug_ has quit [Ping timeout: 250 seconds]
tagrudev has joined #ruby
blueOxigen has joined #ruby
fullofcaffeine has joined #ruby
devoldmx has quit [Remote host closed the connection]
fullofcaffeine has quit [Remote host closed the connection]
dhjondoh has quit [Quit: dhjondoh]
bluOxigen has quit [Ping timeout: 246 seconds]
dc has joined #ruby
banjara has joined #ruby
keen___________2 has joined #ruby
major_majors has quit [Quit: Reconnecting]
major_majors has joined #ruby
keen___________1 has quit [Ping timeout: 252 seconds]
christiandsg has joined #ruby
amystephen has joined #ruby
axsuul has joined #ruby
_blizzy_ has joined #ruby
rehat has joined #ruby
tmtwd has quit [Remote host closed the connection]
major_majors has left #ruby [#ruby]
AlexRussia_ has joined #ruby
amystephen has quit [Ping timeout: 265 seconds]
krz has joined #ruby
_blizzy_ has quit [Ping timeout: 246 seconds]
ferhaty has joined #ruby
banjara has quit [Quit: Leaving.]
christiandsg has quit [Remote host closed the connection]
tmtwd has joined #ruby
toretore has quit [Quit: This computer has gone to sleep]
ollie314 has joined #ruby
christiandsg has joined #ruby
astrobunny has quit [Remote host closed the connection]
jancel has joined #ruby
khebbie has joined #ruby
khebbie has quit [Remote host closed the connection]
Mekkis has quit [Ping timeout: 246 seconds]
christiandsg has quit [Ping timeout: 265 seconds]
jancel has quit [Ping timeout: 244 seconds]
Feyn has quit [Ping timeout: 260 seconds]
oo_ has joined #ruby
flughafen has quit [Remote host closed the connection]
roolo has joined #ruby
duncannz has joined #ruby
riotjones has joined #ruby
TomyLobo has joined #ruby
VanWeyden has joined #ruby
anisha has joined #ruby
dhjondoh has joined #ruby
clarkenciel has joined #ruby
choke has joined #ruby
lsmola has joined #ruby
clarkenciel has quit [Remote host closed the connection]
mutuma has joined #ruby
mutuma is now known as Pathfinder
jas02 has joined #ruby
arooni-mobile has quit [Ping timeout: 244 seconds]
jas02 has quit [Client Quit]
ICantCook has joined #ruby
yardenbar has joined #ruby
hs366 has joined #ruby
sdfgsdfg has quit [Remote host closed the connection]
inteq has quit [Quit: Leaving]
howdoi has joined #ruby
haraoka has quit [Ping timeout: 245 seconds]
jas02 has joined #ruby
sdfgsdfg has joined #ruby
<zenspider> ICantCook: you should learn to cook. it tastes better
astrobunny has joined #ruby
ruurd has joined #ruby
tmtwd has quit [Remote host closed the connection]
dionysus69 has joined #ruby
khebbie has joined #ruby
jtdoncas has quit [Ping timeout: 240 seconds]
rushed has quit [Quit: rushed]
ruurd has quit [Quit: ZZZzzz…]
<ICantCook> zenspider: It's on the list
iateadonut has quit [Read error: No route to host]
blue_deref has quit [Quit: bbn]
aganov has joined #ruby
tonios57 has joined #ruby
iateadonut has joined #ruby
siemprefresco has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
iamninja has quit [Read error: Connection reset by peer]
iamninja has joined #ruby
ruurd has joined #ruby
pranny has quit [Remote host closed the connection]
axsuul has quit [Read error: Connection reset by peer]
axsuul has joined #ruby
ruurd has quit [Client Quit]
TomyLobo has quit [Ping timeout: 252 seconds]
havenwood has quit [Quit: Textual IRC Client: www.textualapp.com]
skade has joined #ruby
lxsameer has quit [Read error: No route to host]
christiandsg has joined #ruby
krz has quit [Ping timeout: 255 seconds]
lxsameer has joined #ruby
djbkd_ has joined #ruby
ndrei has quit [Ping timeout: 272 seconds]
jeadre has quit [Remote host closed the connection]
Coldblackice_ has joined #ruby
_ht has joined #ruby
jeadre has joined #ruby
dumdedum has joined #ruby
kwd has joined #ruby
Coldblackice has quit [Ping timeout: 260 seconds]
rushed has joined #ruby
khebbie has quit [Remote host closed the connection]
christiandsg has quit [Ping timeout: 265 seconds]
codecop has joined #ruby
craysiii has joined #ruby
pocketprotector has quit [Quit: WeeChat 1.2]
jancel has joined #ruby
zimbabawe has joined #ruby
khebbie has joined #ruby
abuzze has joined #ruby
JoshGlzBrk has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
iateadonut has quit [Quit: Leaving.]
roolo has quit [Remote host closed the connection]
AlexRussia_ has quit [Ping timeout: 240 seconds]
iateadonut has joined #ruby
jancel has quit [Ping timeout: 244 seconds]
fibbel has quit [Quit: fibbel]
Musashi007 has joined #ruby
stan_ has joined #ruby
vondruch has joined #ruby
ICantCook has quit [Quit: Leaving]
rehat has quit []
pranny has joined #ruby
kedare has joined #ruby
ruurd has joined #ruby
Musashi007 has quit [Quit: Musashi007]
baweaver has quit [Remote host closed the connection]
towski_ has quit [Remote host closed the connection]
TvL2386 has joined #ruby
zimbabawe has quit [Quit: zimbabawe]
ruurd has quit [Quit: ZZZzzz…]
m8 has joined #ruby
axsuul has quit [Ping timeout: 245 seconds]
axsuul has joined #ruby
edwinvdgraaf has joined #ruby
edwinvdgraaf has quit [Client Quit]
jas02 has quit [Quit: jas02]
jas02 has joined #ruby
jas02 has quit [Client Quit]
jtdoncas has joined #ruby
dhjondoh has quit [Quit: dhjondoh]
armyriad has quit [Quit: Leaving]
iateadonut has quit [Quit: Leaving.]
skade has quit [Quit: Computer has gone to sleep.]
pranny has quit [Remote host closed the connection]
iateadonut has joined #ruby
faces has joined #ruby
face has quit [Ping timeout: 244 seconds]
choke has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ryanMmhmm has quit [Quit: Connection closed for inactivity]
dgutierrez1287 has joined #ruby
UtkarshRay has joined #ruby
vondruch has quit [Quit: Ex-Chat]
jas02 has joined #ruby
Oog_ has quit []
axsuul has quit [Read error: Connection reset by peer]
axsuul has joined #ruby
axsuul has quit [Max SendQ exceeded]
axsuul has joined #ruby
dgutierrez1287 has quit [Ping timeout: 240 seconds]
vondruch has joined #ruby
Timba-as has joined #ruby
jgt has joined #ruby
Ox0dea has quit [Read error: No route to host]
chinmay_dd has joined #ruby
bigkevmcd has quit [Quit: Outta here...]
devoldmx has joined #ruby
jgt has quit [Ping timeout: 244 seconds]
iamninja has quit [Ping timeout: 260 seconds]
sameerynho has joined #ruby
devoldmx has quit [Ping timeout: 246 seconds]
lxsameer has quit [Ping timeout: 256 seconds]
ollie314 has quit [Ping timeout: 264 seconds]
thermatix has joined #ruby
leafybasil has quit [Remote host closed the connection]
dhjondoh has joined #ruby
leafybasil has joined #ruby
Iskarlar has joined #ruby
ruurd has joined #ruby
terlar has joined #ruby
nuttermb has joined #ruby
_blizzy_ has joined #ruby
devbug_ has joined #ruby
Hijiri has quit [Quit: ZNC - http://znc.in]
Hijiri has joined #ruby
VanWeyden has quit [Ping timeout: 244 seconds]
christiandsg has joined #ruby
leafybasil has quit [Ping timeout: 244 seconds]
thermatix has quit [Ping timeout: 246 seconds]
devbug has quit [Ping timeout: 240 seconds]
[k- has joined #ruby
roolo has joined #ruby
Macaveli has joined #ruby
bMalum has joined #ruby
ArnaudM has quit [Quit: plouf]
_blizzy_ has quit [Read error: Connection reset by peer]
ohaibbq has quit [Quit: Leaving...]
<[k-> defined? is a keyword
<[k-> so it cant be overriden!
pawanspace has joined #ruby
_blizzy_ has joined #ruby
roolo has quit [Ping timeout: 245 seconds]
pawanspace has quit [Client Quit]
christiandsg has quit [Ping timeout: 265 seconds]
timonv has joined #ruby
monsieur1 has quit [Quit: Lost terminal]
paradoja has joined #ruby
MatthewRock has joined #ruby
<apeiros> [k-: yupp. can't do what defined? does without a keyword.
krisquigley has joined #ruby
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jgt has joined #ruby
oo_ has quit [Remote host closed the connection]
gagrio has quit [Remote host closed the connection]
xhosae has joined #ruby
gagrio has joined #ruby
oo_ has joined #ruby
davedev2_ has quit [Ping timeout: 246 seconds]
davedev24 has joined #ruby
joonty has joined #ruby
tagrudev has quit [Read error: Connection reset by peer]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bruno- has joined #ruby
tagrudev has joined #ruby
ruurd has quit [Quit: ZZZzzz…]
oo_ has quit [Remote host closed the connection]
oo_ has joined #ruby
krz has joined #ruby
paradoja has quit [Ping timeout: 240 seconds]
workmad3 has joined #ruby
doublemalt_ has quit [Ping timeout: 260 seconds]
ta has quit [Remote host closed the connection]
ollie314 has joined #ruby
ruurd has joined #ruby
dc has quit [Remote host closed the connection]
ta has joined #ruby
vdamewood has joined #ruby
astrobunny has quit [Remote host closed the connection]
<yorickpeterse> morning
yfeldblum has quit [Ping timeout: 244 seconds]
benlovell has joined #ruby
skade has joined #ruby
aspiers has joined #ruby
ruurd has quit [Quit: ZZZzzz…]
Hounddog has joined #ruby
mutuma has joined #ruby
ruurd has joined #ruby
kr3ssh has joined #ruby
matchaw has joined #ruby
djbkd_ has quit [Remote host closed the connection]
Motoservo has quit [Quit: Shhh. I'm trying to get some sleep here.]
Pathfinder has quit [Ping timeout: 264 seconds]
axsuul_ has joined #ruby
axsuul has quit [Ping timeout: 272 seconds]
haxrbyte has joined #ruby
Hounddog has quit [Ping timeout: 260 seconds]
mutuma has quit [Client Quit]
ferhaty has quit []
Hounddog has joined #ruby
matchaw has quit [Client Quit]
astrobunny has joined #ruby
krisquigley has quit []
Ropeney has quit [Quit: Textual IRC Client: www.textualapp.com]
lkba has quit [Ping timeout: 245 seconds]
iateadonut has quit [Quit: Leaving.]
bMalum has quit [Quit: bMalum]
iateadonut has joined #ruby
khebbie has quit [Remote host closed the connection]
khebbie has joined #ruby
bMalum has joined #ruby
stardiviner has joined #ruby
charliesome has joined #ruby
paradoja has joined #ruby
txdv_ is now known as txdv
workmad3 has quit [Ping timeout: 256 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
_blizzy_ has quit [Ping timeout: 255 seconds]
benlovell has quit [Ping timeout: 264 seconds]
einarj has joined #ruby
charliesome has joined #ruby
charliesome has quit [Client Quit]
bumbar_ has joined #ruby
bumbar_ has joined #ruby
jancel has joined #ruby
Iskarlar has joined #ruby
pranny has joined #ruby
marr has joined #ruby
c0m0 has joined #ruby
jancel has quit [Ping timeout: 244 seconds]
<ljarvis> moin
<apeiros> moin
araujo has joined #ruby
pranny has quit [Remote host closed the connection]
ferhaty has joined #ruby
<j416> can anyone remember why I'd put Kernel monkeypatch methods as private?
<j416> I did it for a reason that I foergot
<j416> forgot* even
<yorickpeterse> why would we remember?
khebbie has quit [Remote host closed the connection]
demonlove has joined #ruby
<j416> yorickpeterse: because you are awesome ruby dudes that know why one might want to put things under private
pawnbox has joined #ruby
<j416> aah, because I'm _in_ Kernel
<j416> and putting it private is a way to not pollute other classes (e.g. 5.foo)
<j416> thanks o/
<adaedra> Happy to help
<yorickpeterse> wat
<sevenseacat> good job, you awesome ruby dudes.
AlexAltea has quit [Ping timeout: 240 seconds]
dfockler has joined #ruby
ta has quit [Remote host closed the connection]
ndrei has joined #ruby
<apeiros> j416: because it makes method_missing work correctly
<apeiros> j416: also you wouldn't make them private, you'd make them module_function
<apeiros> that way you follow the common way Kernel methods are implemented.
<apeiros> >> Kernel.puts "hi"
<ruboto> apeiros # => hi ...check link for more (https://eval.in/421271)
<apeiros> >> class X; def method_missing(name, *); "you called #{name} on me"; end; end; X.new.puts "hi" # method missing works properly with private methods
<ruboto> apeiros # => "you called puts on me" (https://eval.in/421272)
<apeiros> >> module Kernel; def boo; "BAD!"; end; end; class X; def method_missing(name, *); "you called #{name} on me"; end; end; X.new.boo "hi" # method missing is not used if the method is not private
<ruboto> apeiros # => wrong number of arguments (1 for 0) (ArgumentError) ...check link for more (https://eval.in/421273)
<apeiros> >> module Kernel; def boo(*); "BAD!"; end; end; class X; def method_missing(name, *); "you called #{name} on me"; end; end; X.new.boo "hi" # method missing is not used if the method is not private
<ruboto> apeiros # => "BAD!" (https://eval.in/421274)
romero has quit [Ping timeout: 264 seconds]
<apeiros> and since Kernel is *everywhere*, you break method missing *everywhere*. so it's kinda a big deal.
<adaedra> Stop breaking everywhere.
romero has joined #ruby
pranny has joined #ruby
romero is now known as Guest65202
chinmay_dd has quit [Quit: See ya!]
paradoja has quit [Ping timeout: 246 seconds]
pranny has quit [Remote host closed the connection]
<j416> adaedra: thanks
<j416> not adaedra, apeiros
pranny has joined #ruby
rushed has quit [Quit: rushed]
pranny has quit [Remote host closed the connection]
DoubleMalt has joined #ruby
michael_mbp has quit [Excess Flood]
khebbie has joined #ruby
Antiarc has quit [Quit: No Ping reply in 180 seconds.]
skade has quit [Quit: Computer has gone to sleep.]
Antiarc has joined #ruby
pranny has joined #ruby
bMalum has quit [Quit: bMalum]
michael_mbp has joined #ruby
khebbie has quit [Remote host closed the connection]
pranny has quit [Remote host closed the connection]
last_staff has joined #ruby
fella5s has joined #ruby
last_staff has quit [Client Quit]
tesuji has joined #ruby
howdoicomputer has joined #ruby
demonlove is now known as atmox
khebbie has joined #ruby
Zai00 has joined #ruby
lessless has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
livathinos has joined #ruby
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
last_staff has joined #ruby
leafybasil has joined #ruby
Karpah has joined #ruby
Macaveli has quit [Read error: Connection reset by peer]
Macaveli has joined #ruby
sevenseacat has quit [Ping timeout: 246 seconds]
Musashi007 has joined #ruby
deg__ has joined #ruby
yfeldblum has joined #ruby
arup_r has joined #ruby
ta has joined #ruby
iamninja has joined #ruby
Blaguvest has joined #ruby
<pawnbox> I am working on a ruby cli app that will have data persistence using pg. The question is how do i structure the app? I have following directories: lib, spec, bin, config(for database connection setup datbase.rb)
<pawnbox> Where do i put database files?
<pawnbox> or classes?
deg_ has quit [Ping timeout: 244 seconds]
roolo has joined #ruby
devoldmx has joined #ruby
<adaedra> you put your code in lib
<pawnbox> yes.
<adaedra> spec is for rspec tests files
<pawnbox> yes
<adaedra> bin for your binary/ies files
<adaedra> I don't see what you mean by "database files", .sql to create the db?
iamninja has quit [Ping timeout: 245 seconds]
<pawnbox> like class that will have sql queries
<adaedra> if those are ruby classes, in lib
<apeiros> it puts the code in the basket
<adaedra> althrough you could also use a rails-like structure with app directory
yfeldblu_ has joined #ruby
<adaedra> but meh
<pawnbox> how would i use database connection object from config directories database.rb file?
<pawnbox> for ececuting database queries?
<adaedra> I would not put .rb files in config personally, just serialized formats (i.e. YAML)
devoldmx has quit [Ping timeout: 265 seconds]
roolo has quit [Ping timeout: 264 seconds]
<pawnbox> that a nice suggesstion
<pawnbox> i'll try that.
<ljarvis> except like.. not YAML
<adaedra> problem with YAML?
<pawnbox> like database.yml?
yfeldblum has quit [Ping timeout: 255 seconds]
<ljarvis> meh, it has its uses
<ljarvis> pawnbox: yes
<adaedra> Then you have some code somewhere that loads it and create your database connection
<adaedra> I suggest using Sequel for database, by the way, really good gem
<pawnbox> yeah i have decided to use pg
<adaedra> that's not incompatible
<adaedra> Sequel will provide a really nice layer over your database including models which could be usefull
stan_ has quit [Quit: Leaving]
<pawnbox> I have requirements to use pg, but i will definitely take a look at sequel
<gregf_> pawnbox: when you say pg? do you mean a database or an orm? sequel is an orm afaik
<gregf_> as in pg == postgresql?
<pawnbox> pg gem.
gambl0re has quit [Remote host closed the connection]
<pawnbox> yes
<pawnbox> database
gambl0re has joined #ruby
<gregf_> so the gem is very specific to posrgres? what if your db changes downthe line *which i suspect it would*
<gregf_> sequel is prolly a orm which used the DBI class under the hood?
<ljarvis> sequel wraps the pg gem, it's an abstraction. It should allow you to keep your code cleaner and may increase security/readability and decrease maintenance burden
<gregf_> s/used/uses/
duncannz has quit [Ping timeout: 256 seconds]
<ljarvis> "would I suspect it would" wat
<ljarvis> which*
senayar has joined #ruby
<gregf_> s/suspect/believe/
stan has joined #ruby
khebbie has quit [Remote host closed the connection]
<gregf_> anyways, no point taking to a tree and ******* :/
<pawnbox> gregf_ Ok. I'll get back to you in a min. GOTTA TALK TO CUSTOMER. HAHA
christiandsg has joined #ruby
pawnbox has quit [Remote host closed the connection]
dgutierrez1287 has joined #ruby
etqqkoiflwhb has joined #ruby
etqqkoiflwhb has quit [Remote host closed the connection]
pawnbox has joined #ruby
imanzarrabian has joined #ruby
christiandsg has quit [Ping timeout: 265 seconds]
leat has quit [Ping timeout: 252 seconds]
axsuul_ has quit [Ping timeout: 256 seconds]
etqqkoiflwhb has joined #ruby
etqqkoiflwhb has quit [Remote host closed the connection]
<pawnbox> gergf_ So I think I won't be migrating to any other sql db because the scope of project is not that big.
dgutierrez1287 has quit [Ping timeout: 245 seconds]
AlexRussia_ has joined #ruby
ferhaty has quit []
<gregf_> pawnbox: the reason i'm saying is we're having nightmares in migrating a project to mongodb as all of the business logic is in mysql. wonders is orm's can deal with mongodb :/
<adaedra> ahahah
<gregf_> s/is/if/
<adaedra> ahahahahahahahahahahahah
Porfa has joined #ruby
<adaedra> sorry
<pawnbox> aha
WilfredTheGreat has joined #ruby
<yorickpeterse> wait
<yorickpeterse> wait
<pawnbox> Let's just say I need not to switch the db.
<yorickpeterse> You're migrating _TO_ MongoDB?
skade has joined #ruby
<gregf_> yorickpeterse: yep; why? nothing new ;)
davedev24 has quit [Remote host closed the connection]
Gribo has joined #ruby
davedev24 has joined #ruby
davedev24 has quit [Remote host closed the connection]
<yorickpeterse> oh sweet baby jesus
<yorickpeterse> I hope you're switching jobs soon
Musashi007 has quit [Quit: Musashi007]
Iskarlar has joined #ruby
<yorickpeterse> If not, you might want to consider that
allcentury has joined #ruby
<gregf_> yorickpeterse: haha, well migration projects are like greenfield projects ;)
matcouto has joined #ruby
<yorickpeterse> No, this sounds like a death march
astrobunny has quit [Remote host closed the connection]
<gregf_> yorickpeterse: if you expect all honey and no bees, then good luck to you :)
<yorickpeterse> There's a big difference between that and outright suicide
<yorickpeterse> There's no other way to put it than "It's fucking dumb to migrate from a relational database to MongoDB"
<yorickpeterse> In doing so you ignore the past, what, 5 years of complains about MongoDB?
<yorickpeterse> And all the proof that it's outright shit?
<yorickpeterse> At least migrate to a sane setup like Postgres
<yorickpeterse> hell, even Oracle would probably be a better choice
<yorickpeterse> In fact, even SQLite3 would be better
<yorickpeterse> Soon that will have JSON support, making Mongo basically obselete for any use case
workmad3 has joined #ruby
<gregf_> well, theres surely got to be a reason why we're switching and the top guys have decided. you dont take such decisions in a matter of days. and yeah, no point you getting so mad at mongodb.
* Karpah gets popcorn
Karpah is now known as sevenseacat
* sevenseacat gets more popcorn
<yorickpeterse> gregf_: you expect people to know what they're talking about
<yorickpeterse> and I have every reason to be mad at Mongo
<yorickpeterse> I've had to deal with it for ~2,5 years
<yorickpeterse> so have plenty of others
<gregf_> yorickpeterse: i've worked on 2 mongo projects with Perl :), so its not a new thing for me
<pawnbox> Guys lets not fight over db's.
<gregf_> not that i'm a big fan of relational db's. you may even go ahead and use a relational db to store hierarchical data.
<gregf_> pawnbox: indeed. no time to argue :/
allcentury has quit [Ping timeout: 256 seconds]
howdoicomputer has quit [Ping timeout: 264 seconds]
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
allcentury has joined #ruby
<sevenseacat> sweet, I get to still argue. you guys have to stop.
<yorickpeterse> I eagerly await the day they realize "Fuck that was a bad choice"
charliesome has joined #ruby
Rickmasta has joined #ruby
Iskarlar has joined #ruby
ruurd has quit [Quit: ZZZzzz…]
above has quit [Ping timeout: 250 seconds]
ruurd has joined #ruby
leat has joined #ruby
<sevenseacat> yorickpeterse: good article
<adaedra> And this day they will do the right choice, putting all data in .csv files.
<adaedra> :v
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<yorickpeterse> adaedra: are you sure it will be comma separated, and not tab separated?
<yorickpeterse> or something else
<yorickpeterse> e.g. we have a company that uses ^|^ as the field separator
_blizzy_ has joined #ruby
<yorickpeterse> I'm not even kidding
Iskarlar has joined #ruby
bruno- has quit [Ping timeout: 265 seconds]
pranny has joined #ruby
hmsimha__ has quit [Ping timeout: 265 seconds]
_blizzy_ has quit [Read error: Connection reset by peer]
ta has quit [Remote host closed the connection]
<adaedra> semi-column separated
_blizzy_ has joined #ruby
jokke has joined #ruby
<jokke> hi
frem has quit [Quit: Connection closed for inactivity]
<jokke> following code: https://p.jreinert.com/7EHV9/ruby
<jokke> rubocop tells me there's a redundant begin
<sevenseacat> hi.
<adaedra> bad ssl
<jokke> i don't understand why
<sevenseacat> then there is
<jokke> following code: http://p.jreinert.com/7EHV9/ruby
<jokke> me
<jokke> h
dabradley has quit [Read error: Connection reset by peer]
<jokke> i gotta update my pastebin..
<adaedra> I see no code :x
<sevenseacat> you should really use the one we recommend, if you want people to click on your links
<jokke> adaedra: yeah
<adaedra> ?gist
<ruboto> https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
<dionysus69> hey all can I use ternary operator with && statement ?
<jokke> suer
<jokke> dionysus69: sure
<sevenseacat> can you? yes. should you? probably not.
<dionysus69> jokke: params[:action] == action ? "active" : nil, how do I add it on this example for example?
<jokke> params[:action] == action && foo ? "active" : nil
<dionysus69> i mean I just have an interest on how to do it , I could use regular if format :D
Zai00 has quit [Quit: Zai00]
<jokke> but it's the wrong approach ther
<jokke> e
<dionysus69> hmm ok thats ok answer too i wont use it then :) thanks jokke sevenseacat
Cust0sLim3n has quit [Ping timeout: 240 seconds]
<jokke> dionysus69: you should think over the code when the else part is just nil
khebbie has joined #ruby
<dionysus69> jokke: ok thanks )
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Liam` has quit [Ping timeout: 246 seconds]
<jokke> adaedra: ok, updated the pastebin, you shoud see code now
stamina has joined #ruby
Cust0sLim3n has joined #ruby
matcouto has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<jokke> so why is this begin redundant?
Macaveli has quit [Quit: Textual IRC Client: www.textualapp.com]
ferhaty has joined #ruby
UtkarshRay has quit [Ping timeout: 244 seconds]
<apeiros> jokke: methods have an implicit begin/end
Billias has quit [Ping timeout: 246 seconds]
<jokke> oh!
_blizzy_ has quit [Ping timeout: 255 seconds]
Billias has joined #ruby
<jokke> i didn't know that
<apeiros> def meth; code; rescue; …; else; …; ensure; …; end # valid
<adaedra> you can remove lines 2 and 9
<jokke> cool
ta has joined #ruby
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Mon_Ouie has joined #ruby
* sevenseacat wonders why we bother directing people to gis
<sevenseacat> t
Timba-as has quit [Quit: Be back later ...]
ruurd has quit [Quit: ZZZzzz…]
Liam` has joined #ruby
<apeiros> hm, I don't. only when they use crap like pastebin
<apeiros> I mean, I do - if they paste code here or ask whether pasting code here is ok. but else, not so much.
Timba-as has joined #ruby
thantos has joined #ruby
* sevenseacat points at channel topic and also channel rules 4 and 5
Gnomethr_ has joined #ruby
iooner has quit [Ping timeout: 246 seconds]
teotwaki has quit [Ping timeout: 246 seconds]
jaxxstorm has quit [Ping timeout: 246 seconds]
Gnomethr_ is now known as Gnomethrower
Gnomethrower has quit [Changing host]
Gnomethrower has joined #ruby
BackEndCoder has quit [Ping timeout: 246 seconds]
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
charliesome has joined #ruby
FastJack has quit [Ping timeout: 246 seconds]
Steve_Jobs has quit [Ping timeout: 246 seconds]
dhjondoh has quit [Quit: dhjondoh]
unreal_ has quit [Ping timeout: 244 seconds]
code_ has quit [Ping timeout: 244 seconds]
catbusters has quit [Ping timeout: 246 seconds]
LBRapid has quit [Ping timeout: 246 seconds]
rodfersou has joined #ruby
ljarvis has quit [Ping timeout: 246 seconds]
_blizzy_ has joined #ruby
stan has quit [Ping timeout: 246 seconds]
nuttermb has quit [Ping timeout: 246 seconds]
Dwarf has quit [Ping timeout: 246 seconds]
george2 has quit [Ping timeout: 246 seconds]
universa1 has quit [Ping timeout: 246 seconds]
danoo_ has quit [Ping timeout: 246 seconds]
AlexC_ has quit [Ping timeout: 246 seconds]
lupine has quit [Ping timeout: 246 seconds]
ebarrett has quit [Ping timeout: 246 seconds]
rvchangue has quit [Ping timeout: 246 seconds]
psy_ has quit [Ping timeout: 246 seconds]
canton7 has quit [Ping timeout: 246 seconds]
Fraeon has quit [Ping timeout: 256 seconds]
Fraeon has joined #ruby
Iskarlar has joined #ruby
* [k- points out that we shouldn't just click any link
ndrei has quit [Ping timeout: 260 seconds]
unreal has joined #ruby
ljarvis has joined #ruby
DaniG2k has joined #ruby
<sevenseacat> +1000 to that too
AlexC_ has joined #ruby
Liam` has quit [Ping timeout: 246 seconds]
ebarrett has joined #ruby
FastJack has joined #ruby
ta has quit [Remote host closed the connection]
sarkyniin has joined #ruby
epochwolf has quit [Ping timeout: 246 seconds]
bffff_ has quit [Ping timeout: 246 seconds]
sfr^ has quit [Ping timeout: 246 seconds]
terrellt has quit [Ping timeout: 246 seconds]
larissa has quit [Ping timeout: 246 seconds]
above has joined #ruby
drbrain has quit [Ping timeout: 246 seconds]
mjmac has quit [Ping timeout: 246 seconds]
zzak has quit [Ping timeout: 246 seconds]
ELCALOR has quit [Ping timeout: 246 seconds]
jeadre has quit [Remote host closed the connection]
Phoop has quit [Ping timeout: 246 seconds]
shelling__ has quit [Ping timeout: 246 seconds]
hoey has quit [Ping timeout: 246 seconds]
hellschreiber has quit [Ping timeout: 246 seconds]
DarkBushido has quit [Ping timeout: 246 seconds]
rdark has joined #ruby
lancetw has quit [Ping timeout: 246 seconds]
znz_jp has quit [Ping timeout: 246 seconds]
efox has quit [Ping timeout: 246 seconds]
cschneid has quit [Ping timeout: 246 seconds]
_blizzy_ has quit [Read error: Connection reset by peer]
LBRapid has joined #ruby
universa1 has joined #ruby
DaniG2k has quit [Client Quit]
skarn has quit [Ping timeout: 246 seconds]
asi_ has quit [Ping timeout: 246 seconds]
<[k-> 1. people use their own pastebins to showoff
canton7 has joined #ruby
canton7 has joined #ruby
johnhamelink has quit [Ping timeout: 246 seconds]
cstrahan has quit [Ping timeout: 246 seconds]
<adaedra> >_>
<[k-> 2. people like to have control over their pastes
rvchangue has joined #ruby
<[k-> even though github already provides these
jeadre has joined #ruby
thesheff17 has quit [Ping timeout: 246 seconds]
preyalone has quit [Ping timeout: 246 seconds]
chridal has quit [Ping timeout: 246 seconds]
djbender has quit [Ping timeout: 246 seconds]
AckZ has quit [Ping timeout: 246 seconds]
zzak has joined #ruby
<[k-> github is also pretty
asi_ has joined #ruby
BackEndCoder has joined #ruby
Phoop has joined #ruby
Aeyrix has quit [Ping timeout: 246 seconds]
AdamMeghji has quit [Ping timeout: 246 seconds]
mlue has quit [Ping timeout: 246 seconds]
cstrahan has joined #ruby
rflot has quit [Read error: Connection reset by peer]
livathinos has quit [Read error: Connection reset by peer]
hoey has joined #ruby
djbender has joined #ruby
mlue has joined #ruby
_blizzy_ has joined #ruby
hellschreiber has joined #ruby
Nightmare has quit [Ping timeout: 246 seconds]
kirun has joined #ruby
thesheff17 has joined #ruby
ELCALOR has joined #ruby
Aeyrix has joined #ruby
shelling__ has joined #ruby
danoo_ has joined #ruby
AdamMeghji has joined #ruby
rflot has joined #ruby
lancetw has joined #ruby
jaxxstorm has joined #ruby
teotwaki has joined #ruby
george2 has joined #ruby
bMalum has joined #ruby
yfeldblu_ has quit [Read error: Connection reset by peer]
Steve_Jobs has joined #ruby
znz_jp has joined #ruby
tobiasvl has quit [Ping timeout: 256 seconds]
chridal has joined #ruby
drbrain has joined #ruby
iooner has joined #ruby
larissa has joined #ruby
DarkBushido has joined #ruby
epochwolf has joined #ruby
psy_ has joined #ruby
cschneid has joined #ruby
yfeldblum has joined #ruby
stan has joined #ruby
mjmac has joined #ruby
sfr^ has joined #ruby
Nightmare has joined #ruby
Liam` has joined #ruby
tvl has joined #ruby
lupine has joined #ruby
tvl is now known as tobiasvl
<apeiros> sevenseacat: yeah, it's where we guide people to as a default.
johnhamelink has joined #ruby
bffff_ has joined #ruby
revoohc has joined #ruby
rdark has quit [Ping timeout: 264 seconds]
ponga has joined #ruby
revoohc has quit [Client Quit]
<apeiros> I prefer having an actually actionable text than an abstract. i.e. I prefer "please use http://some.paste.bin/" over "please use a pastebin service"
sdothum has joined #ruby
code_ has joined #ruby
Dwarf has joined #ruby
terrellt has joined #ruby
AckZ has joined #ruby
<apeiros> gist is there because it's one of the better services. but if there's better suggestions, I don't mind changing it.
revoohc has joined #ruby
manara314 has joined #ruby
skarn has joined #ruby
efox has joined #ruby
ollie314 has quit [Ping timeout: 244 seconds]
catbusters has joined #ruby
<[k-> why dont people listen to us for gist?
preyalone has joined #ruby
<[k-> these people are more likely not to listen to us when we ask them to provide more info
<anker> monsters
<sevenseacat> thats exactly why I don't bother
<anker> i havent found any command line tool for gist yet which is adequatte
tkuchiki has quit [Remote host closed the connection]
MatthewRock has quit [Ping timeout: 246 seconds]
<[k-> and some other person's solely maintained pastebin is better at that?
<[k-> if we plot a bar chart of pastebins over time, pastebin.com is the winner
<[k-> and then the rest
ta has joined #ruby
<[k-> (we should actually plot a graph of pastebin over time, that'll be fun)
Mekkis has joined #ruby
ndrei has joined #ruby
atmox is now known as demonlove
ruurd has joined #ruby
imanzarrabian has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Iskarlar has joined #ruby
pranny has quit [Remote host closed the connection]
pranny has joined #ruby
ndrei has quit [Ping timeout: 252 seconds]
bruno- has joined #ruby
vondruch has quit [Remote host closed the connection]
<shevy> [k- they don't listen to monsters!
<[k-> like your face!
<[k-> ooooo buuuuuuuurn
<[k-> sorry shevy :3
bruno- has quit [Ping timeout: 250 seconds]
roolo has joined #ruby
<Porfa> hellos! whats wrong here…? i get a page in mecha… ( urltemp = agent.page ) and then i (parser= Nokogiri::HTML(open(urltemp)) )
<shevy> so many ()
<[k-> for your convenience, shevy
<shevy> this not lisp!
<shevy> like your face!!!!
<shevy> :D
<arup_r> What this #SOreadytohelp means? People are using http://stackoverflow.com/users/1553787/vamsi-krishna
vondruch has joined #ruby
<arup_r> :)
<[k-> lol
<Zarthus> arup_r: see the 2.5 billion questions answered thing
<shevy> arup_r are you still trying to go for 1 million karma
<arup_r> Zarthus: I saw
<Zarthus> that's where it's from
<arup_r> not able to connect what this hashtag for ?
<Zarthus> it's a hashtag, they're always useless.
<arup_r> Zarthus: Well, should I use it in my profile? that is my question
<shevy> Porfa you should put up the code, in a reproducible manner, including the way how you invoke that code and what the specific error is, all in that pastie/gist
<[k-> its promotional media for stackoverflow
<arup_r> :)
<Zarthus> arup_r: do you want to?
<Zarthus> It's just to show your support to SO
<arup_r> o I see
<[k-> it's like wearing a badge, "i support this event"
<shevy> ^^^ this is how arup_r makes 1 million reputation
<arup_r> I thought if I use it,,, I can get a t-shirt from them
<arup_r> shevy: :)
<shevy> a t-shirt hmm a muscle shirt
fgo has joined #ruby
<arup_r> shevy: I am thin,, :)
_blizzy_ has quit [Ping timeout: 255 seconds]
roolo has quit [Ping timeout: 255 seconds]
dfockler has quit [Ping timeout: 255 seconds]
yqt has joined #ruby
<shevy> yeah, programmer
<[k-> like your face!
yqt has quit [Read error: Connection reset by peer]
cantaberry has quit []
yqt has joined #ruby
<Porfa> I'm kind of ashamed of posting the code on gist… :(
phutchins has quit [Ping timeout: 240 seconds]
phutchins1 has joined #ruby
<Porfa> because … f*** it i will explain...
pandaant has joined #ruby
<Porfa> it's fetlife site.. they have no search for members age/sex so I want to parse all the locals and put them on a nice data table for better browsing experience… it's a sex/meeting site *ASHAMED*
<shevy> Porfa you just have to post code that can reproduce an error, ideally in a minimal variant
ruurd has quit [Quit: ZZZzzz…]
ldnunes has joined #ruby
ruurd has joined #ruby
<shevy> >> 1/0
<ruboto> shevy # => divided by 0 (ZeroDivisionError) ...check link for more (https://eval.in/421339)
<shevy> see? that is a good error ^^^
znz_jp has quit [Quit: kill -QUIT $$]
iamninja has joined #ruby
<shevy> then we can say... it's not good to divide by 0
<[k-> >> shevy
<ruboto> [k- # => undefined local variable or method `shevy' for main:Object (NameError) ...check link for more (https://eval.in/421340)
<[k-> hue hue hue
<shevy> then arup_r can go and ask on stackoverflow for confirmation of that and gain +1000 points
dc has joined #ruby
Iskarlar has quit [Quit: Textual IRC Client: www.textualapp.com]
devoldmx has joined #ruby
demonlove has quit [Quit: Leaving]
znz_jp has joined #ruby
sebyx07 has joined #ruby
_axx has joined #ruby
<arup_r> shevy: :( I have some good answers too
<sebyx07> dependency injection gem for ruby: https://github.com/sebyx07/rubybeans
<pawnbox> arup_r:
<arup_r> pawnbox: ys
<pawnbox> care to elaborate
skade has quit [Quit: Computer has gone to sleep.]
iamninja has quit [Ping timeout: 246 seconds]
<arup_r> pawnbox: Ask shevy:
<[k-> trailing :!
<arup_r> he knows what I meant and I knows what he meant :D
<[k-> the world is ruined!
<_axx> What is the best way to run long-running tcp connections in ruby? I open a few connections that should stay open (listen) until i close them by hand)
ferhaty has quit [Ping timeout: 260 seconds]
<_axx> Just the standard thread mechanism, or spawn processes?
<[k-> too vague
devoldmx has quit [Ping timeout: 245 seconds]
<Porfa> i just need to know how to pass a page mechanize got, into nokogiri :( but ill post the gist, i should make a temporary username/pass for the site though, because if you want to test the code you'll need one
Feyn has joined #ruby
<_axx> [k-: what do you need to know? To be more precise: i open multiple IRC connections (each thread is one connection).
<[k-> a bouncer?
<_axx> yeah and no. similar
<Porfa> there it is.. how do i pass the links I'm getting to nokogiri?… eh
<_axx> [k-: i log everything from one channel to a database and show that via websockets to multiple clients
<[k-> so it's a reallyyyyyy long running thing
<_axx> [k-: the thing is, all those connections are user-provided, so i don't know which server/channel they connect to. I need a reliable, long-running connections.
<_axx> [k-: yeah, basically
<[k-> a process would ensure that the whole thing doesn't crash and burn
<_axx> sure, it *could* reconnect. But those threads/processes should better un without termination
<_axx> [k-: yeah, i guessed so. since threads are not so "stable". :D
<_axx> I just wasn't sure, if there is a "better" or "standard" gem/way/tool
ndrei has joined #ruby
skade has joined #ruby
paradoja has joined #ruby
symm- has joined #ruby
ta has quit [Remote host closed the connection]
but3k4 has joined #ruby
christiandsg has joined #ruby
malcolmva has quit [Ping timeout: 240 seconds]
Kallis has joined #ruby
oo_ has quit [Remote host closed the connection]
[k-_ has joined #ruby
Encapsulation has quit [Quit: Leaving]
sebyx07 has quit [Ping timeout: 246 seconds]
bhorn1|away is now known as bhorn1
aspiers has quit [Ping timeout: 245 seconds]
gagrio has quit [Ping timeout: 246 seconds]
christiandsg has quit [Ping timeout: 265 seconds]
sarkyniin has quit [Ping timeout: 256 seconds]
Iskarlar has joined #ruby
lxsameer_ has joined #ruby
phutchins1 has quit [Ping timeout: 246 seconds]
imanzarrabian has joined #ruby
ferhaty has joined #ruby
gambl0re has quit [Ping timeout: 245 seconds]
tkuchiki has joined #ruby
sameerynho has quit [Ping timeout: 260 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
khebbie has quit [Remote host closed the connection]
dgutierrez1287 has joined #ruby
lele|w has joined #ruby
Voker57 has joined #ruby
Kallis has quit [Ping timeout: 272 seconds]
lessless has joined #ruby
Kallis has joined #ruby
rfmind has joined #ruby
Kallis has quit [Max SendQ exceeded]
pawnbox_ has joined #ruby
pawnbox has quit [Read error: Connection reset by peer]
yqt has quit [Ping timeout: 250 seconds]
newbie1 has joined #ruby
bruno- has joined #ruby
Kallis has joined #ruby
futilegames has joined #ruby
krz has quit [Ping timeout: 264 seconds]
leat has quit [Ping timeout: 250 seconds]
diegoaguilar has joined #ruby
krz has joined #ruby
leat has joined #ruby
imanzarrabian has quit [Ping timeout: 265 seconds]
khebbie has joined #ruby
rfmind has quit [Quit: WeeChat 1.3]
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
DiscoM has joined #ruby
leat has quit [Ping timeout: 265 seconds]
gagrio has joined #ruby
phutchins2 has joined #ruby
rbennacer has joined #ruby
jancel_ has joined #ruby
dEPy has joined #ruby
Zai00 has joined #ruby
dorei has joined #ruby
leat has joined #ruby
Iskarlar has joined #ruby
jancel_ has quit [Ping timeout: 252 seconds]
northfurr has joined #ruby
thantos has quit [Read error: Connection reset by peer]
khebbie has quit [Remote host closed the connection]
terlar has quit [Ping timeout: 252 seconds]
northfurr_ has joined #ruby
IrishGringo has joined #ruby
iamninja has joined #ruby
Porfa has quit [Quit: Porfa]
nw has joined #ruby
leat has quit [Ping timeout: 250 seconds]
sdfgsdfg has quit [Remote host closed the connection]
leat has joined #ruby
livathinos has joined #ruby
UtkarshRay has joined #ruby
leat has quit [Remote host closed the connection]
leat has joined #ruby
ashleyhindle has quit [Quit: Lost terminal]
acke has joined #ruby
paradoja has quit [Ping timeout: 272 seconds]
joonty has quit [Quit: joonty]
M-mistake has quit [Remote host closed the connection]
M-prosodyContext has quit [Remote host closed the connection]
rbennacer has quit [Remote host closed the connection]
d10n-work has joined #ruby
bMalum has quit [Quit: bMalum]
futilegames has quit [Quit: futilegames]
pranny has quit [Read error: Connection reset by peer]
leat has quit [Remote host closed the connection]
pranny has joined #ruby
leat has joined #ruby
paradoja has joined #ruby
bruno- has quit [Ping timeout: 265 seconds]
hinbody has joined #ruby
tmtwd has joined #ruby
Cust0sLim3n has quit [Ping timeout: 252 seconds]
northfurr has quit [Read error: Connection reset by peer]
northfurr_ is now known as northfurr
_joes__ has joined #ruby
bffff_ has quit [Quit: Connection closed for inactivity]
northfurr_ has joined #ruby
Cust0sLim3n has joined #ruby
gamename has quit []
victortyau has joined #ruby
dEPy has quit [Quit: (null)]
mary5030 has joined #ruby
IrishGringo has quit [Ping timeout: 246 seconds]
Encapsulation has joined #ruby
symm- has quit [Ping timeout: 260 seconds]
tmtwd has quit [Ping timeout: 244 seconds]
manara314 has quit [Excess Flood]
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rideh has joined #ruby
mary5030 has quit [Remote host closed the connection]
M-mistake has joined #ruby
M-prosodyContext has joined #ruby
mary5030 has joined #ruby
dhjondoh has joined #ruby
lxsameer_ has quit [Quit: Leaving]
rideh has quit [Max SendQ exceeded]
paradoja has quit [Ping timeout: 245 seconds]
sgambino has joined #ruby
rideh has joined #ruby
KC9YDN has quit [Remote host closed the connection]
haylon has joined #ruby
renderful has joined #ruby
krz has quit [Ping timeout: 244 seconds]
KC9YDN has joined #ruby
KC9YDN has quit [Changing host]
KC9YDN has joined #ruby
iamninja has quit [Read error: Connection reset by peer]
bMalum has joined #ruby
joonty has joined #ruby
devdazed_ has quit [Quit: Computer has gone to sleep.]
dblessing has joined #ruby
tomaz_b has joined #ruby
xhosae has quit [Remote host closed the connection]
allcentury has quit [Ping timeout: 264 seconds]
zenguy_pc has quit [Ping timeout: 246 seconds]
IrishGringo has joined #ruby
dimasg has joined #ruby
paradoja has joined #ruby
havenwood has joined #ruby
ta has joined #ruby
bMalum has quit [Quit: bMalum]
DroidBurgundy has joined #ruby
dstarh has joined #ruby
roolo has joined #ruby
IrishGringo has quit [Ping timeout: 244 seconds]
Kallis has quit [Read error: Connection reset by peer]
bestbrents has quit [Read error: Connection reset by peer]
AnoHito has quit [Read error: Connection reset by peer]
Cust0sLim3n has quit [Ping timeout: 240 seconds]
bestbrents has joined #ruby
codecop has quit [Remote host closed the connection]
AnoHito has joined #ruby
sankaber has joined #ruby
fgo has quit [Quit: WeeChat 1.1.1]
atomical has joined #ruby
crdpink2 has joined #ruby
crdpink has quit [Ping timeout: 246 seconds]
Shidash has quit [Ping timeout: 246 seconds]
wookiehangover has quit [Ping timeout: 246 seconds]
allcentury has joined #ruby
roolo has quit [Ping timeout: 244 seconds]
stan has quit [Ping timeout: 244 seconds]
iooner has quit [Ping timeout: 246 seconds]
segmond has quit [Ping timeout: 246 seconds]
djcp has joined #ruby
IrishGringo has joined #ruby
ferhaty has quit []
lupine has quit [Ping timeout: 246 seconds]
Iskarlar has joined #ruby
JoshL has joined #ruby
jordanm has quit [Ping timeout: 246 seconds]
jerius has joined #ruby
duggiefresh has joined #ruby
catbusters has quit [Ping timeout: 246 seconds]
george2 has quit [Ping timeout: 246 seconds]
dopamean_ has quit [Ping timeout: 250 seconds]
Cust0sLim3n has joined #ruby
Coldblackice_ has quit [Ping timeout: 240 seconds]
kies^ has quit [Ping timeout: 250 seconds]
wookiehangover has joined #ruby
radgeRayden has joined #ruby
iooner has joined #ruby
dhjondoh has quit [Quit: dhjondoh]
bMalum has joined #ruby
jhack has joined #ruby
george2_ has joined #ruby
failshell has joined #ruby
tonios57 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
zenguy_pc has joined #ruby
gamename has joined #ruby
Shidash has joined #ruby
benlovell has joined #ruby
gamename has quit [Remote host closed the connection]
stardiviner has quit [Quit: Weird in coding now, or make love, only two things push me away from IRC.]
segmond has joined #ruby
gamename has joined #ruby
polysics has joined #ruby
ledestin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ckinniburgh has joined #ruby
swills has quit [Quit: leaving]
aspiers has joined #ruby
lupine has joined #ruby
stan has joined #ruby
andikr has joined #ruby
Rutix has joined #ruby
Rutix has joined #ruby
arup_r has quit [Remote host closed the connection]
gamename has quit [Remote host closed the connection]
gamename has joined #ruby
pranny has quit [Remote host closed the connection]
Guest26811 has quit [Ping timeout: 252 seconds]
catbusters has joined #ruby
freerobby has joined #ruby
devoldmx has joined #ruby
rbennacer has joined #ruby
arup_r has joined #ruby
ferhaty has joined #ruby
tmtwd has joined #ruby
arup_r_ has joined #ruby
bMalum has quit [Quit: bMalum]
jordanm has joined #ruby
rdark has joined #ruby
gagrio_ has joined #ruby
bMalum has joined #ruby
rdark has quit [Client Quit]
rdark has joined #ruby
bruno- has joined #ruby
malconis has joined #ruby
devoldmx has quit [Ping timeout: 245 seconds]
arup_r has quit [Ping timeout: 244 seconds]
jhack has quit [Ping timeout: 246 seconds]
jgpawletko has quit [Quit: jgpawletko]
gagrio has quit [Ping timeout: 250 seconds]
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
phutchins2 has quit [Quit: WeeChat 1.1.1]
Feyn has quit [Ping timeout: 245 seconds]
bruno- has quit [Ping timeout: 246 seconds]
oo_ has joined #ruby
fmcgeough has joined #ruby
Iskarlar has joined #ruby
aspiers has quit [Ping timeout: 246 seconds]
Zort0n has joined #ruby
bMalum has quit [Quit: bMalum]
davedev24 has joined #ruby
above has quit [Ping timeout: 260 seconds]
devdazed has joined #ruby
vdamewood has quit [Quit: Life beckons.]
above has joined #ruby
dimasg has quit [Ping timeout: 250 seconds]
abbe has quit [Ping timeout: 246 seconds]
zly has quit [Ping timeout: 246 seconds]
christiandsg has joined #ruby
Olipro has quit [Ping timeout: 246 seconds]
whippythellama has joined #ruby
decoponio has joined #ruby
devbug_ has quit [Read error: Connection reset by peer]
ferhaty has quit []
jgpawletko has joined #ruby
zly has joined #ruby
dgutierrez1287 has quit [Remote host closed the connection]
gagrio has joined #ruby
jhack has joined #ruby
abbe has joined #ruby
msnyon has joined #ruby
tagrudev has quit [Remote host closed the connection]
new2rails has joined #ruby
<new2rails> test
<new2rails> join #rubyonrails
arup_r_ has quit []
gagrio_ has quit [Quit: Leaving...]
gagrio_ has joined #ruby
Olipro has joined #ruby
Soda has joined #ruby
christiandsg has quit [Ping timeout: 265 seconds]
khebbie has joined #ruby
tmtwd has quit [Ping timeout: 246 seconds]
minmax has quit [Quit: WeeChat 0.4.3]
<shevy> test failed!
catbusters has quit [Ping timeout: 246 seconds]
<[k-_> one rabbit blew up
cajone has left #ruby [#ruby]
renderful has quit [Remote host closed the connection]
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
banjara has joined #ruby
catbusters has joined #ruby
dopamean_ has joined #ruby
DoubleMalt has quit [Remote host closed the connection]
andikr has quit [Remote host closed the connection]
<jokke> hi
rbennacer has quit [Read error: Connection reset by peer]
<gregf_> haha
<jokke> anyone know if a version change in yaml has made YAML.load('[foo,:bar,baz]') throw an error?
rbennacer has joined #ruby
Porfa has joined #ruby
banjara has quit [Client Quit]
<jokke> iirc this would have returned ["foo", ":bar", "baz"]
rdark has quit [Ping timeout: 272 seconds]
whippythellama has quit [Ping timeout: 250 seconds]
Gnomethrower has quit [Quit: Textual IRC Client: www.textualapp.com]
above has quit [Ping timeout: 244 seconds]
mhib has joined #ruby
<[k-_> you are supposed to give the array a name
<jokke> no that's not it
<[k-_> hello_this_is_an_array: [foo, :bar, baz]
<jokke> not working
<jokke> it's the colon in front of :bar
<aibo> > YAML.load('[foo,:bar,baz]')
<aibo> => ["foo,:bar,baz"]
<aibo> in ruby 1.8
<jokke> i see
<jokke> so it _is_ a regression
ofdtrinity has joined #ruby
<[k-_> so horrible you people
I has joined #ruby
above has joined #ruby
<aibo> jokke: the output is differnt fom your expected output
chrissonar has quit [Remote host closed the connection]
<jokke> oh you meant that with the quotes
I is now known as Guest63096
<jokke> thought that was a typo
<aibo> i copied it
Iskarlar has joined #ruby
<aibo> so, no typo
<[k-_> ha!
momomomomo has joined #ruby
Iskarlar has quit [Max SendQ exceeded]
aspiers has joined #ruby
<jokke> 1.9.3 throws the same error
cajone has joined #ruby
<jokke> this works though: YAML.load("[foo,':bar',baz]")
fibbel has joined #ruby
Iskarlar has joined #ruby
<[k-_> >> require 'yaml'; YAML.load("foo:\n- bar\n- baz\n- :b\n")
<ruboto> [k-_ # => {"foo"=>["bar", "baz", :b]} (https://eval.in/421415)
phutchins has joined #ruby
<[k-_> tadaaaaaaa
UtkarshRay has quit [Ping timeout: 246 seconds]
<jokke> yeah that works
banister has quit [Read error: Connection reset by peer]
riotjones has quit [Remote host closed the connection]
Zai00 has quit [Quit: Zai00]
dojobo has joined #ruby
khebbie has quit [Remote host closed the connection]
ta has quit [Remote host closed the connection]
dented42 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<[k-_> which is why you should follow the format!
j_mcnally has joined #ruby
<[k-_> shevy: FOLLOW!
umgrosscol has joined #ruby
<adaedra> says the one who writes obfuscation software
<[k-_> nuh uh, i still follow ruby syntax
khebbie has joined #ruby
aganov has quit [Remote host closed the connection]
pranny has joined #ruby
<[k-_> >> require 'yaml'; YAML.load("- bar\n- baz\n- :b\n")
<ruboto> [k-_ # => ["bar", "baz", :b] (https://eval.in/421421)
<[k-_> wow it still works
george2_ is now known as george2
<[k-_> stupid yaml
sarkyniin has joined #ruby
grotewold has joined #ruby
amystephen has joined #ruby
shortythepimp has joined #ruby
shortythepimp has left #ruby [#ruby]
atomical has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
momomomomo has quit [Quit: momomomomo]
beef-wellington has joined #ruby
tomaz_b has quit [Ping timeout: 240 seconds]
hashrocket has joined #ruby
atomical has joined #ruby
bMalum has joined #ruby
shortythepimp has joined #ruby
jas02 has quit [Quit: jas02]
ta has joined #ruby
tjohnson has joined #ruby
nertzy has joined #ruby
khebbie has quit [Remote host closed the connection]
polysics has quit []
lampd1 has quit [Remote host closed the connection]
tonios57 has joined #ruby
pranny has quit [Remote host closed the connection]
lampd1 has joined #ruby
khebbie has joined #ruby
arashb has quit [Remote host closed the connection]
benlovell has quit [Ping timeout: 260 seconds]
bweston92 has quit [Ping timeout: 265 seconds]
sarkyniin has quit [Ping timeout: 246 seconds]
Macaveli has joined #ruby
newbie1 has quit [Ping timeout: 272 seconds]
varesa has joined #ruby
farn has quit [Ping timeout: 245 seconds]
ducklobster has joined #ruby
northfurr_ has quit [Quit: northfurr_]
Zai00 has joined #ruby
njs126 has joined #ruby
bMalum has quit [Quit: bMalum]
<ducklobster> is there any way to impose the same input argument limitations that a regular method has to a block?
<ducklobster> i.e. if i say def mymethod(input), ruby will throw an exception if i pass more or less than a single input
abuzze has quit [Remote host closed the connection]
kies^ has joined #ruby
whippythellama has joined #ruby
rdark has joined #ruby
<ducklobster> however with a block (in particular i am using define_singleton_method(:mymethod) do |input|
<ducklobster> i have to manually check the input length
tmtwd has joined #ruby
Macaveli has quit [Quit: Textual IRC Client: www.textualapp.com]
<jhass> uhm, no, after define_method you don't
dagda1 has joined #ruby
twistedpixels has joined #ruby
abuzze has joined #ruby
bweston92 has joined #ruby
<ducklobster> so checking the input length is the correct approach
<jhass> >> o = Object.new; o.define_singleton_method(:foo) {|a| }; o.foo;
<ruboto> jhass # => wrong number of arguments (0 for 1) (ArgumentError) ...check link for more (https://eval.in/421425)
<[k-_> yup, after that, the block is promoted to a method
<[k-_> no, ducklobster
ta has quit [Remote host closed the connection]
ngscheurich has joined #ruby
futilegames has joined #ruby
<ducklobster> hmmm strange, i am able to pass multiple values and it doesn't seem to complain
<jhass> >> o = Object.new; o.define_singleton_method(:foo) {|a| }; o.foo(1, 2);
<ruboto> jhass # => wrong number of arguments (2 for 1) (ArgumentError) ...check link for more (https://eval.in/421430)
farn has joined #ruby
<jhass> then that's not the reduced version of your code
<ducklobster> yeah let me gist my code
AlexAltea has joined #ruby
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Iskarlar has joined #ruby
abuzze has quit [Ping timeout: 245 seconds]
bruno- has joined #ruby
jefus is now known as jefus_
<[k-_> andddd, how are you using it
jefus_ is now known as jefus
<jhass> mmh, ruby -v might be relevant too actually, never checked
<[k-_> you can also create a symbol like this :"#{field}="
<ducklobster> i use the register with some input field name, which should generate a a custom setter method
<[k-_> >> :"test="
<ruboto> [k-_ # => :test= (https://eval.in/421434)
<jhass> that to_sym is unnecessary btw
<ducklobster> so then i am using the custom setter and mygenerator.name2 = 5, 31
ecnalyr has joined #ruby
<ducklobster> thanks for the symbol tip!
rippa has joined #ruby
<jhass> I meant you can pass a string just fine
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<ducklobster> oh, define_singleton_method will auto convert?
<jhass> I think in assignments the = binds stronger than ,
<ducklobster> i am guessing define_method will too?
<jhass> try .name2=(5, 21)
<jhass> yes
bMalum has joined #ruby
<ducklobster> .name3=(31, 5) => syntax error, unexpected ',', expecting ')'
<jhass> there you go the , just vanishes somewhere
<jhass> >> a = 1, 2
<ruboto> jhass # => [1, 2] (https://eval.in/421438)
<jhass> >> a = 1, 2; a
<ruboto> jhass # => [1, 2] (https://eval.in/421439)
<jhass> mmh
<jhass> okay, actually maybe you get an array?
aspiers has quit [Ping timeout: 240 seconds]
<apeiros> ducklobster: you can (re arg count with blocks), but it's ugly
<ducklobster> that seems like what is happening
<apeiros> >> def foo; yield; end; foo(&->(x) {})
<ruboto> apeiros # => wrong number of arguments (0 for 1) (ArgumentError) ...check link for more (https://eval.in/421440)
bruno- has quit [Ping timeout: 244 seconds]
momomomomo has joined #ruby
Draggor has joined #ruby
<jhass> >> o = Object.new; o.define_singleton_method(:foo=) {|a| p a }; o.foo = 1, 2
<ruboto> jhass # => [1, 2] ...check link for more (https://eval.in/421441)
<jhass> yeah
dimasg has joined #ruby
<jhass> you're assigning an array actually :P
<apeiros> explanation: blocks normally use proc semantics (no arg count validation), lambda's otoh do an arg count validation. ->(){} is a synonym for lambda.
diegoaguilar has quit [Quit: Leaving]
<Draggor> Anyone know where I can look for help with the gollum/omniauth/omnigollum projects?
livathinos has quit []
[k-_ has quit [Quit: Lingo: www.lingoirc.com]
<jhass> Draggor: prolly #RubyOnRails has some folks
futilegames has quit [Quit: futilegames]
tesuji has quit [Ping timeout: 244 seconds]
r0x0rZ has quit []
<Draggor> jhass: as far as I'm aware this is a sinatra project and not RoR?
<jhass> omniauth is popular in the rails community though
<ecnalyr> I've got a method that feels smelly due to the numerous conditionals, I feel I can clean it up by mapping but I'm not 'clicking' this morning - thoughts? https://gist.github.com/ecnalyr/8ff0a7cc8b18e16c3b2a
<havenwood> Draggor: Nonetheless the largest community here familiar with it is #RubyOnRails. There is a #Sinatra as well to try.
<Draggor> jhass: ahh, gotcha
Gribo has quit [Ping timeout: 265 seconds]
<jhass> Draggor: there's a #sinatra too
<jhass> oh, too slow :P
<ducklobster> apeiros: thanks, interesting, i might just end up doing my own validation, easier to understand/read
abuzze has joined #ruby
fullofcaffeine has joined #ruby
pawnbox_ has quit [Remote host closed the connection]
<Draggor> of course after asking I at least get the basics of it down
<jhack> does .sort only sort strings? and not #'s?
momomomomo has joined #ruby
<jhass> ecnalyr: I feel like you can write a single query for this, something like PlacePreference.joins(:roles => :users).where(users: {id: current_user.id}, venue_uuid: current_place.id) or so, but the #RubyOnRails folk might have an actually working idea into that direction
<ecnalyr> jhass good point, thanks
iamninja has joined #ruby
but3k4 has quit [Read error: Connection reset by peer]
shortythepimp has quit [Quit: Page closed]
<jhack> nvm
but3k4 has joined #ruby
ckinniburgh_ has joined #ruby
clarkenciel has joined #ruby
dopamean1 has joined #ruby
<jhass> ecnalyr: actually might not even need to join users and can just restrict the user_id in roles
bMalum has quit [Quit: bMalum]
j_mcnally has joined #ruby
<jhass> ecnalyr: PlacePreference.joins(:roles).where(role: {user_id: current_user.id}, venue_id: current_place.id) does that work?
momomomomo has quit [Client Quit]
<jhass> eh, venue_uuid
ckinniburgh has quit [Ping timeout: 256 seconds]
dopamean_ has quit [Ping timeout: 240 seconds]
sudiptamondal has joined #ruby
yashinbasement has joined #ruby
chouhoulis has joined #ruby
khebbie has quit [Remote host closed the connection]
IrishGringo has quit [Remote host closed the connection]
<ecnalyr> jhass gets me going in the right direction, thanks!
joneshf-laptop has quit [Ping timeout: 250 seconds]
Gribo has joined #ruby
acke has quit [Remote host closed the connection]
jtdoncas_ has joined #ruby
pawnbox has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
roolo has joined #ruby
skade has joined #ruby
kwd has quit [Quit: kwd]
nerdoncall has joined #ruby
joneshf-laptop has joined #ruby
IceyEC has joined #ruby
ta has joined #ruby
Blaguvest has quit [Ping timeout: 272 seconds]
Lucky___ has quit [Ping timeout: 250 seconds]
kies has quit [Ping timeout: 260 seconds]
dimasg has quit [Ping timeout: 244 seconds]
above has quit [Ping timeout: 244 seconds]
diegoaguilar has joined #ruby
roolo has quit [Ping timeout: 264 seconds]
bl4ckpajamas has joined #ruby
kies has joined #ruby
m3ow1504_x has joined #ruby
IceyEC has quit [Client Quit]
bootstrappm has joined #ruby
praveen__ has joined #ruby
fullofcaffeine has quit [Remote host closed the connection]
eminencehc has joined #ruby
juanpaucar has joined #ruby
praveen__ has quit [Client Quit]
paradoja has quit [Ping timeout: 260 seconds]
dopamean1 has quit [Ping timeout: 255 seconds]
sarkyniin has joined #ruby
unver has joined #ruby
lessless has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
countryHick has joined #ruby
cschneid_ has joined #ruby
sldkjfsldkjf has joined #ruby
Iskarlar has joined #ruby
lkba has joined #ruby
dopamean_ has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
bl4ckpajamas has quit [Quit: Leaving]
bl4ckpajamas has joined #ruby
riotjones has joined #ruby
sldkjfsldkjf has quit [Client Quit]
mkopriva has joined #ruby
pranny has joined #ruby
ruurd has quit [Quit: ZZZzzz…]
Exuma has joined #ruby
<cschneid_> Does anybody know if unicorn exposes a "is this a worker or a preloaded master process" method?
Torrieri has quit [Quit: Be back later ...]
nertzy has quit [Quit: This computer has gone to sleep]
riotjones has quit [Ping timeout: 250 seconds]
bl4ckpajamas has quit [Quit: Leaving]
<bootstrappm> morning
abuzze has quit [Remote host closed the connection]
fullofcaffeine has joined #ruby
skade has joined #ruby
IceyEC has joined #ruby
<jhass> cschneid_: there are pre and after fork hooks to do you reconnections and such
startupality has joined #ruby
<cschneid_> jhass: right, I'm aware of those. I was hoping for a simple Unicorn::GlobalStatus.running_worker? or running_master? method. A quick skim of the code doesn't turn up anything though
andybernard has joined #ruby
<jhass> I'm saying needing that sounds a bit silly
skade has quit [Client Quit]
snockerton has joined #ruby
andybernard has quit [Client Quit]
andybernard has joined #ruby
chouhoulis has quit [Remote host closed the connection]
TvL2386 has quit [Remote host closed the connection]
chouhoulis has joined #ruby
ReK2 has joined #ruby
ReK2 has joined #ruby
rcvalle has joined #ruby
<Porfa> hello… any suggestion to bypass a thingie I'm having problems with in mechanize?… this ---> .link_with(:text => 'view more →').click
<Porfa> can't i … ".link_with(:text => 'view more ***WHATEVER***').click ?
<Porfa> because I'm having a problem passing the → in ruby
<Porfa> (in rib, works fine, in ruby… it fails)
<[k-> >> '→'
<ruboto> [k- # => "→" (https://eval.in/421460)
dfockler has joined #ruby
but3k4 has quit [Ping timeout: 246 seconds]
<[k-> are you sure it's not the library
<[k-> or your old Ruby
<Porfa> #<Mechanize::Page::Link "view more →" "/administrative_areas/2789/groups">
<Porfa> in rib it works.. my ruby is indeed old, 1.9...
northfurr has quit [Quit: northfurr]
<Porfa> what version should i use in your opinion?
dionysus69 has quit [Ping timeout: 246 seconds]
<jhass> 2.2.3
zenguy_pc has quit [Ping timeout: 244 seconds]
<Porfa> thank you jhass
<[k-> only the latest and greatest
<[k-> , 2.2.3
<dfockler> might as well
but3k4 has joined #ruby
yashinbasement has quit [Quit: Leaving]
paradoja has joined #ruby
rehat has joined #ruby
larissa has quit [Ping timeout: 246 seconds]
bffff_ has joined #ruby
<DiscoM> Hi. Ruby newbie here, can someone tell why in this code http://pastie.org/10372520 , if «puts global_bla
<DiscoM> » , why using «puts @global_local» ?
dagda1 has quit [Quit: Textual IRC Client: www.textualapp.com]
haylon has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
Alayde has joined #ruby
Cache_Money has joined #ruby
[Butch] has joined #ruby
The_Phoenix has joined #ruby
<adaedra> who uses «»
above has joined #ruby
The_Phoenix has quit [Max SendQ exceeded]
yqt has joined #ruby
larissa has joined #ruby
araujo has quit [Ping timeout: 246 seconds]
<DiscoM> me, with my bépo keyboard
<ljarvis> DiscoM: what do you mean why? you didn't write this?
Torrieri has joined #ruby
NeverDie has joined #ruby
<Porfa> arm… i now have 2.2.3 but my gems are gone.. can i use the gems i was using from the 1.9 ruby or it's better for me to change back to 1.9, gem list, get the names, go to 2.2.3 and install said gems again?
sevenseacat has quit [Quit: .]
The_Phoenix has joined #ruby
<ljarvis> Porfa: the latter
<Porfa> ty
<Porfa> :)
Exuma has quit []
ytti has joined #ruby
ytti has quit [Ping timeout: 248 seconds]
The_Phoenix has quit [Max SendQ exceeded]
NeverDie has quit [Max SendQ exceeded]
devoldmx has joined #ruby
khebbie has joined #ruby
ta has quit [Remote host closed the connection]
khebbie has quit [Remote host closed the connection]
The_Phoenix has joined #ruby
araujo has joined #ruby
<adaedra> DiscoM: 1) salut 2) what are you trying to achieve 3) you know the difference between variables and @variables?
<DiscoM> i mean, in «def affiche» , «puts global_bla» is working, but in every tutorial, they tell to use «puts @global_local» , i don't know why they ask to put the «@». Ok it's a local variable, but it's working without «@» so why wondering about it.
<ljarvis> @foo is not a local variable
NeverDie has joined #ruby
phutchins has quit [Ping timeout: 246 seconds]
<ljarvis> I don't understand this "in every tutorial".. this code is quite odd, really
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
benlovell has joined #ruby
<adaedra> “@foo” is not the same as “foo”
<adaedra> (I, too, can use fancy quotation marks)
<ljarvis> so I highly doubt it's "every tutorial". Might be worth sharing your resources
bl4ckpajamas has joined #ruby
fullofcaffeine has quit [Remote host closed the connection]
jtdoncas_ has quit [Ping timeout: 240 seconds]
ta has joined #ruby
<shevy> perhaps ruby the hard way
<DiscoM> ljarvis: like thiis one : http://ruby-doc.org/docs/beginner-fr/xhtml/ch04s02.html (Fra sorry)
<yorickpeterse> Zed might be grumpy, but he's not dumb
dgutierrez1287 has joined #ruby
<[k-> fancy: „“”«»‚‘’‹›
<ljarvis> DiscoM: ok, that's not really the same thing; and I think your variable naming is confusing yourself
IceyEC has quit [Ping timeout: 252 seconds]
devoldmx has quit [Ping timeout: 245 seconds]
<adaedra> « @rue est une variable de classe. »
<adaedra> euh, no
anisha has quit [Quit: Leaving]
NeverDie has quit [Max SendQ exceeded]
<shevy> adaedra beautiful french
<DiscoM> ljarvis: ok, l will read more to understand, thank you.
<adaedra> shevy: the language ok, the tutorial is full of errors
<shevy> adaedra GigiDAgostino - LAmourToujours
<[k-> classe rue de est variable une rue
<DiscoM> too bad for an offical tutorial
<shevy> the language is so beautiful that errors are ok!
<adaedra> official?
<adaedra> ah yes
<shevy> yeah ruby-doc.org
<adaedra> (well, full, I push it a bit far, but there's weird things)
<DiscoM> it's not official ?
<shevy> DiscoM dunno but I would tend to english tutorials, they are often better
araujo_ has joined #ruby
<adaedra> ^
<shevy> or a GERMAN TUTORIAL!
<[k-> ruby-docs.org isnt affiliated with ruby-lang.org
<havenwood> DiscoM: It's only officially official if Matz has direct control of it. :P
big|bad|wolf has joined #ruby
<DiscoM> shevy: ok i will, thanks for the tip
Iskarlar has joined #ruby
<havenwood> DiscoM: So ruby-docs.org, bundler, chruby, rvm etc aren't official.
<shevy> 10 years... most languages change a lot in 10 years...
xhosae has joined #ruby
big|bad|wolf has quit [Remote host closed the connection]
<[k-> i will too
oo_ has quit [Remote host closed the connection]
<shevy> [k- your face!!!
<adaedra> 2003
<shevy> wow
<shevy> the french tutorial is from 2003?
<adaedra> This guide is © 2003
dc has quit [Remote host closed the connection]
<shevy> cool
araujo_ has quit [Max SendQ exceeded]
stan has quit [Ping timeout: 246 seconds]
djbkd_ has joined #ruby
<[k-> shevy: your face will be too old to recognise in 10 years!!!
<[k-> hahahahahahha
<adaedra> [k-: do you have a face fetish or something?
<adaedra> DiscoM: this guide looks really old too
<[k-> i already explained this some time ago
araujo_ has joined #ruby
<[k-> either you werent here or you have a memory loss
araujo has quit [Ping timeout: 246 seconds]
<DiscoM> adaedra: ok :( , i wil try to look for newers
jtdoncas_ has joined #ruby
iamninja has quit [Read error: Connection reset by peer]
<adaedra> « A l'heure ou nous écrivons ces lignes, la dernière version disponible de Ruby pour Microsoft Windows est 1.6.8. » (“As we writes these lines, last available version of Ruby for Ms Windows is 1.6.8”
<adaedra> )
<DiscoM> adaedra: indeed
<[k-> sooooo ooooooooold
bruno- has joined #ruby
bMalum has joined #ruby
araujo_ has quit [Max SendQ exceeded]
<adaedra> DiscoM: If you're fluent enough in English, look for documentation in English. You'll find way better resources than keeping to your native language, even if it would be easier.
duggiefresh has quit [Remote host closed the connection]
phutchins has joined #ruby
jeadre has quit [Remote host closed the connection]
Guest63096 has quit [Quit: Leaving]
<[k-> i think Ox0dea has 1.6.8 archived somewhere
<DiscoM> adaedra: ok, i will stick to english docs. thanks.
dopie has joined #ruby
araujo_ has joined #ruby
<adaedra> De rien
djbkd_ has quit [Ping timeout: 260 seconds]
araujo_ has quit [Max SendQ exceeded]
jeadre has joined #ruby
xhosae has quit [Remote host closed the connection]
Valeness_ is now known as Valeness
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
khebbie has joined #ruby
ytti has joined #ruby
ytti has quit [Ping timeout: 248 seconds]
ngscheurich has quit [Quit: WeeChat 1.2]
araujo_ has joined #ruby
<shevy> la baguette
<DiscoM> ^^'
Lucky__ has joined #ruby
<shevy> adaedra why are there not more games written in ruby :(
araujo_ has quit [Read error: Connection reset by peer]
<shevy> this guy used to use ruby https://github.com/godrin/antargis but he no longer does as far as I know
NeverDie has joined #ruby
<[k-> just like me
<shevy> hmm
<shevy> or perhaps he still does
<shevy> but he wrote a javascript version lately
<dfockler> you could probably use crystal for a game, not sure if there are good bindings yet
<adaedra> shevy why do you ask me
phutchins has quit [Ping timeout: 246 seconds]
oo_ has joined #ruby
ngscheurich has joined #ruby
atomical has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<shevy> adaedra you look wise
<shevy> and competent
<[k-> why adaedra why
<nerdoncall> Noobie here. First Ruby web scraping program and getting an error trying to write a hash to a csv file. Getting an error "undefined local variable or method `csv'" . Code is at https://gist.github.com/0aaffb6f0076b1d0c630.git
<shevy> page not found
<adaedra> 404
christiandsg has joined #ruby
<[k-> remove the .git
atomical has joined #ruby
pragmatism has joined #ruby
<adaedra> rm -rf .git
banister has joined #ruby
<[k-> he used gist and you dont know how to use it?!!?!?
dr3w has joined #ruby
<jhass> nerdoncall: is this the game where you guess the error output?
<jhass> nerdoncall: does it contain an e?
joonty has quit [Quit: joonty]
ngscheurich has quit [Client Quit]
<adaedra> yeah, a complete error with line could be nice.
<nerdoncall> error caused by line 110.
<adaedra> 110G
ngscheurich has joined #ruby
<[k-> your code is not idiomatic
rideh has quit [Quit: zap]
<[k-> and you abuse constants
<nerdoncall> search1.rb:110:in `block (2 levels) in find_att_value': undefined local variable or method `csv' for main:Object (NameError) from search1.rb:83:in `each' from search1.rb:83:in `block in find_att_value' from search1.rb:75:in `each' from search1.rb:75:in `find_att_value' from search1.rb:124:in `block in <main>' from /home/bob/.rvm/rubies/ruby-2.2.1/lib/ruby/2.2.0/csv.rb:1273:in `open' from search1.rb:17:in `<main>'
<jhass> [k-: so helpful
<adaedra> indent is weird
einarj has quit [Remote host closed the connection]
<[k-> line 49 ended csv scope
rodfersou has quit [Ping timeout: 246 seconds]
<jhass> nerdoncall: can you tell me what a local variable is?
<[k-> wait it didnt
rodfersou has joined #ruby
hanmac has quit [Ping timeout: 244 seconds]
new2rails has quit []
mleung has joined #ruby
<ljarvis> [k-: please take a minute to review/think about the code before blurting stuff out
<nerdoncall> a local variable is local to that method or class
<nerdoncall> sorry I am new at this
JoshGlzBrk has joined #ruby
<jhass> nerdoncall: exactly. So you define a bunch of methods. methods introduce a new scope and don't inherit the outer one
JoshGlzBrk has quit [Client Quit]
christiandsg has quit [Ping timeout: 265 seconds]
SCHAAP137 has joined #ruby
<jhass> well, actually a local variable is only local to a method
<jhass> or the toplevel
<jhass> but the point that methods don't inherit any scope stands
luksaur has joined #ruby
oo_ has quit [Remote host closed the connection]
ruurd has joined #ruby
dc has joined #ruby
failshell has quit [Remote host closed the connection]
renderful has joined #ruby
<[k-> but he abused constants!
<[k-> that should be corrected before it gets out of hand
<[k-> constants aren't supposed to be modified, nerdoncall
<nerdoncall> so I need to inherit from CSV. I will work on my constant abuse.
rbennacer has quit [Remote host closed the connection]
Zort0n has quit [Ping timeout: 264 seconds]
unver has left #ruby ["ERC (IRC client for Emacs 24.5.1)"]
khebbie has quit [Remote host closed the connection]
above has quit [Ping timeout: 244 seconds]
renderful has quit [Ping timeout: 265 seconds]
JimmyNeutron has quit [Quit: Leaving]
<jhass> ugh, no
<jhass> you should make a normal class
above has joined #ruby
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
<jhass> and use a instance variables for all your constants as well as the CSV writer instance
<shevy> nerdoncall you need to write clear and concise code; look at what you do, you define a method inside the do |csv| block
fullofcaffeine has joined #ruby
finisherr has joined #ruby
bl4ckpajamas has quit [Quit: Leaving]
khebbie has joined #ruby
rbennacer has joined #ruby
Novice201y has joined #ruby
rbennacer has quit [Remote host closed the connection]
<Novice201y> Hello. Are there interesing open source projects in Ruby on Cloud9 IDE?
whooza_ has quit [Quit: Ex-Chat]
hanmac has joined #ruby
senayar has quit []
<nerdoncall> thank you -jhass -shevy -k-
riotjones has joined #ruby
phutchins has joined #ruby
yardenbar has quit [Quit: Leaving]
pranny has quit [Remote host closed the connection]
fibbel has quit [Quit: fibbel]
bricker has joined #ruby
sudiptamondal has quit [Ping timeout: 245 seconds]
pandaant has quit [Remote host closed the connection]
pietr0 has joined #ruby
jtdoncas_ has quit [Ping timeout: 246 seconds]
RobertBirnie has joined #ruby
riotjones has quit [Ping timeout: 244 seconds]
<shevy> the simplest way towards a cleanup is to use small methods that do only fairly little
<shevy> dunno about cloud
Spami has joined #ruby
skade has joined #ruby
towski_ has joined #ruby
jtdoncas_ has joined #ruby
renderful has joined #ruby
skade has quit [Client Quit]
lkba_ has joined #ruby
<banister> yorickpeterse i wsa in arnhem over the weekend
<banister> yorickpeterse it's the ONLY place i've been to in NL that has hills, are there any other places like that?
<banister> it was awesome, finally...a landscape!
RobertBirnie has quit [Ping timeout: 240 seconds]
lkba has quit [Ping timeout: 252 seconds]
youngbaks has joined #ruby
<adaedra> hills? in NL?
workmad3 has quit [Ping timeout: 240 seconds]
khebbie has quit [Remote host closed the connection]
<anker> adaedra: they have 1/3 of a hill
jgt has quit [Ping timeout: 252 seconds]
<anker> near the border with belgium and germany
<adaedra> At the German border?
rideh has joined #ruby
<adaedra> ninja'd
<anker> the highest spot of the netherlands
<adaedra> "The highest spot of the netherlands – Germany."
<adaedra> :p
hs366 has quit [Ping timeout: 272 seconds]
RobertBirnie has joined #ruby
The_Phoenix has quit [Read error: Connection reset by peer]
Hounddog has quit [Remote host closed the connection]
<shevy> lol
Spami has quit [Ping timeout: 272 seconds]
skade has joined #ruby
fantazo has joined #ruby
yqt has quit [Ping timeout: 260 seconds]
bMalum has quit [Remote host closed the connection]
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
araujo has joined #ruby
araujo has quit [Max SendQ exceeded]
yqt has joined #ruby
<Porfa> ok, now that i have change to ruby 2.2 i can't install most of the gems i was using… lots of compiling errors, rvm requirements was done of course :'/ goddamit.. can't i really stay on 1.9 ?;'(
sudiptamondal has joined #ruby
sudiptamondal has quit [Max SendQ exceeded]
<shevy> come to 2.2.3
dr3w has quit [Quit: WeeChat 1.2]
<shevy> wget ftp://ftp.ruby-lang.org/pub/ruby/ruby-2.2.3.tar.xz
<shevy> if you stay on 1.9 you will have to do more and more work on your own, like fixing incompatibilities
sudiptamondal has joined #ruby
Spami has joined #ruby
Eiam has joined #ruby
Eiam has quit [Client Quit]
c0m0 has quit [Ping timeout: 250 seconds]
<shevy> less heroic than if you were on 1.8.x though
socialjackie has joined #ruby
Spami_ has joined #ruby
sevvie has quit [Ping timeout: 256 seconds]
tkuchiki has quit [Read error: Connection reset by peer]
rubie has joined #ruby
tkuchiki has joined #ruby
sevvie has joined #ruby
<Bish> i want to start a thread with an exchangeable block, is that possible?
zenguy_pc has joined #ruby
maletor has joined #ruby
Spami has quit [Ping timeout: 265 seconds]
DoubleMalt has joined #ruby
araujo has joined #ruby
araujo has quit [Max SendQ exceeded]
<Bish> meaning i want a block in a variable, sort-of
troyready has joined #ruby
sankaber has quit [Read error: Connection reset by peer]
dagda1 has joined #ruby
kies^ has quit [Ping timeout: 250 seconds]
<bricker> Bish: yes, that's what Procs are for
sankaber has joined #ruby
<Porfa> shevy: i want 2.2.3 but I'm using RVM… should i drop it? it's already installed.. but every time i try to install nokogiri or mechanize it starts complaining about lstdc++ and I'm pretty sure its installed..i mean, it installed nokogiri and mechanize in 1.9...
<Bish> bricker, that's what i thought, but how do i start a proc in a thread?
paradoja has quit [Ping timeout: 260 seconds]
sanguisdex has left #ruby [#ruby]
<shevy> Porfa dunno, I can't give advice on rvm as I don't use it; it may help to show the specific error you get
tkuchiki has quit [Ping timeout: 240 seconds]
wprice has joined #ruby
* Bish loves rvm
<Porfa> ruby -v = ruby 2.2.3p173 (2015-08-18 revision 51636) [x86_64-linux]
<bricker> Bish: yourProc = proc { "hello" }; yourProc.call()
<Porfa> ok, i will paste the error in gist and post it, maybe i can get some help, thanks for the hint shevy
<Bish> bricker, Procs aren't threads, or am i wrong?
<bricker> Bish: Procs and Threads are different things
<Bish> their execution blocks when called, that's what i mean
<bricker> Bish: yes
<Bish> yeah so.. how does this help me
roolo has joined #ruby
<bricker> Bish: I guess I misunderstood your question
saddad has joined #ruby
Iskarlar has joined #ruby
<Bish> well, i want to do stuff like "Thread.new block1 if cond1 else Thread.new block2"
cornerma1 has joined #ruby
<bricker> Bish: Thread.new(&yourProc)
<bricker> like that?
<Bish> oehh, i don't know exactly, but might be
araujo has joined #ruby
araujo has quit [Changing host]
araujo has joined #ruby
<Bish> *tries*
einarj has joined #ruby
rbennacer has joined #ruby
araujo has quit [Max SendQ exceeded]
cornerman has quit [Ping timeout: 264 seconds]
roolo has quit [Ping timeout: 246 seconds]
cornerma1 is now known as cornerman
<Bish> bricker, thank you, looks good, but i don't know how to make sure the threads will not get the same variables
<bricker> Bish: I'm not sure what you're concerned about
jpfuentes2 has joined #ruby
codecop has joined #ruby
<livcd> what non rails project are you working on guys ?
<ruboto> Bish, we in #ruby do not like pastebin.com, I reposted your paste to gist for you: https://gist.github.com/4b037e733eab09cef016
<ruboto> pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
Novice201y has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
yatish27 has joined #ruby
Soda has quit [Remote host closed the connection]
duggiefresh has joined #ruby
youngbaks has quit [Ping timeout: 260 seconds]
<clarkenciel> anyone familiar with the Selenium bindings for Ruby?
gizmore has joined #ruby
bap1313 has joined #ruby
fuzzyhorns has joined #ruby
<Bish> #1) why does Proc have "job", if there comes another thread along, will "job" get overwritten? it might be not the case, because i would create a new proc everytime handle_job is called, but what if i store the proc outside of the method
<bricker> Bish: has keys are unique so you don't need that check. Is that what you're talking about?
AlphaAtom has joined #ruby
<Bish> pretty hard to put into words, sorry
<shevy> Porfa that is also the ruby version I use; perhaps your gcc is too old or lstdc++ is missing some -dev package or something like that
AlphaAtom has quit [Max SendQ exceeded]
renanoronfle has quit [Ping timeout: 246 seconds]
<Bish> bricker, most importantly can i give multiple threads the very same proc, or will they end up using the same references?
grotewold has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
AlphaAtom has joined #ruby
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<bricker> Bish: you can define the proc anywhere, you can pass the proc into any number of threads (just be sure the proc isn't changing any state)
efox has left #ruby ["WeeChat 1.2"]
araujo has joined #ruby
araujo has joined #ruby
<havenwood> Porfa: Is that OS X or another BSD?
<Bish> bricker, i will try ;) last question: when doing Thread.new &proc, can i also pass variables to proc?
pawnbox has quit [Remote host closed the connection]
jaycee has joined #ruby
pawnbox has joined #ruby
darkf has quit [Quit: Leaving]
m3ow1504_x has quit [Remote host closed the connection]
roolo has joined #ruby
mary5030 has quit [Remote host closed the connection]
<lagweezle> Erm, anyone know how to set pty true for a single Capistrano task? I'm failing to figure that out, currently. :/
<Bish> bricker, yep i can, found it, thank you
<Bish> let's see if those threads fuck each other up ;)
<havenwood> Porfa: gcc -v
greymeister has joined #ruby
kies^ has joined #ruby
pawnbox has quit [Ping timeout: 250 seconds]
benlovell has quit [Ping timeout: 272 seconds]
stamina has quit [Quit: WeeChat 1.3]
IrishGringo has joined #ruby
TomyLobo has joined #ruby
bruno- has quit [Ping timeout: 265 seconds]
symm- has joined #ruby
<shevy> hmm I have a XP -> level table, in hash form right now ... {400=>1, 900=>2 }
<shevy> now I need to query "if I have 555 xp, what level would I be?" - would a range be better to have?
Timba-as has quit [Quit: Be back later ...]
renanoronfle has joined #ruby
benlovell has joined #ruby
krz has joined #ruby
einarj has quit [Ping timeout: 245 seconds]
m3ow1504_x has joined #ruby
<shevy> I guess I'll just iterate through until I find the exact elements that are smaller, and the next one that is bigger
dumdedum has quit [Quit: foo]
yqt has quit [Ping timeout: 240 seconds]
diegoviola has joined #ruby
banjara has joined #ruby
pawnbox has joined #ruby
leat has quit [Remote host closed the connection]
casadei has joined #ruby
leat has joined #ruby
_djbkd has joined #ruby
_djbkd has quit [Remote host closed the connection]
_djbkd has joined #ruby
Zai00 has quit [Quit: Zai00]
einarj has joined #ruby
Rickmasta has joined #ruby
eminencehc has quit [Ping timeout: 246 seconds]
kies^ has quit [Ping timeout: 260 seconds]
big|bad|wolf has joined #ruby
<Mon_Ouie> You could just have an Array and use #bsearch to find the right index
riotjones has joined #ruby
<shevy> hmm
<Mon_Ouie> (or even linear search since it's probably not a very large array anyway)
tonios57 has quit [Quit: Textual IRC Client: www.textualapp.com]
Musashi007 has joined #ruby
NeverDie has joined #ruby
freezevee has joined #ruby
<freezevee> how do I write an array into a file ?
<freezevee> I am trying with File.open("todo.items", "w") { |f| f.write(@items)} and I see an Array object
<shevy> freezevee File.open; apply .join on it
<freezevee> I am trying with File.open("todo.items", "w") { |f| f.write(@items.to_json)} and I don't see a JSON
baweaver has joined #ruby
<shevy> I assume .to_json turns it into a string?
<freezevee> shevy: just join with "," ?
<shevy> yes if it is an Array, not if it is a String
<freezevee> shevy: json turns into that ["#<Item:0x007f93d39149e8>"]
Jackneill has joined #ruby
spider-mario has joined #ruby
<shevy> no
juanpaucar has quit [Remote host closed the connection]
<shevy> hash.to_json.class
<shevy> # => String
j_mcnally has joined #ruby
<livcd> what do you think about ruby codewars taksks ?
<shevy> I don't believe you freezevee :)
<shevy> freezevee what is @items? perhaps it has a to_json method
<freezevee> shevy: it's an array
<shevy> nope
riotjones has quit [Ping timeout: 255 seconds]
<shevy> array.to_json # => "["1","2","3","4","5","6","7","8","9","0","a","b","c","d","e","abc","cat","dog","a","a","b",null,null]"
<freezevee> shevy: I initialize it with @items = []
<shevy> I also get a String, sorry freezevee, what you say is not correct
<shevy> nope
<shevy> I just tested in irb
<freezevee> shevy: you are right
<freezevee> shevy: you are so right
blueOxigen has quit [Ping timeout: 250 seconds]
juanpaucar has joined #ruby
<shevy> anyway, once you have the string you can store via File.open
<shevy> it may be best to store in a variable, before sending to f.write()
dstarh has quit [Ping timeout: 252 seconds]
<freezevee> I entered an "Item" object into the array
j_mcnally has quit [Client Quit]
<shevy> \o/
bluOxigen has joined #ruby
<freezevee> shevy: I did @items << Item.new(item)
<freezevee> shevy: thank you
<freezevee> I did it
<shevy> \o/
j_mcnally has joined #ruby
failshell has joined #ruby
jschmid has joined #ruby
arup_r has joined #ruby
jschmid has quit [Remote host closed the connection]
snockerton1 has joined #ruby
dagda1 has quit [Ping timeout: 252 seconds]
juanpaucar has quit [Ping timeout: 252 seconds]
snockerton has quit [Ping timeout: 265 seconds]
Shizus has joined #ruby
davedev24 has quit [Ping timeout: 246 seconds]
Motoservo has joined #ruby
davedev24 has joined #ruby
hooper1 has joined #ruby
<Shizus> Hello! I have file with the following structure "001000150001" where the first 3 chars have a meaning, the following 5 chars have another... I have to read each line by char position. Is there a way to define the structure and match it with the string in one step?
dagda1 has joined #ruby
dgutierrez1287 has quit [Remote host closed the connection]
whiteline has quit [Quit: Leaving]
whiteline has joined #ruby
djbkd_ has joined #ruby
dimasg has joined #ruby
<havenwood> >> /(?<three>.{3})(?<five>.{5})/ =~ "001000150001"; [first_three: three, next_five: five]
<ruboto> havenwood # => [{:first_three=>"001", :next_five=>"00015"}] (https://eval.in/421527)
<havenwood> Shizus: Say more about what you're doing?
<havenwood> Shizus: Have an example of the expected output and what you're doing with it? What are you using now?
powersurge has joined #ruby
<powersurge> when using savon, is there any way to see the outgoing headers?
Akkad has quit [Excess Flood]
djbkd_ has quit [Ping timeout: 264 seconds]
<Porfa> hmmm can anyone help me out? (already on ruby 2.2 !! :D :D ) on IRB ir plays fine…. --> error -- kinsters.rb:18:in `<main>': undefined method `click' for nil:NilClass (NoMethodError) -- Gist -- https://gist.github.com/anonymous/123137386b9fce2a64cd
weemsledeux has joined #ruby
devoldmx has joined #ruby
<shevy> 'view more ?' must return nil in your example
Akkad has joined #ruby
<shevy> what is the -> anyway
<Shizus> havenwood: The file lines are too long to paste them. I have file describing by position each line of the file, for example "Char 0 to 3: ID of the element, char 4 to 10: description, char 10 to 15: cost of the element". The idea is to generate a json given an input line
big|bad|wolf has quit [Ping timeout: 245 seconds]
<Porfa> shevy: it's the name of the link on the page I'm trying to get into
kies^ has joined #ruby
whiteline has quit [Remote host closed the connection]
dimasg has quit [Ping timeout: 250 seconds]
einarj has quit [Ping timeout: 272 seconds]
dimasg has joined #ruby
ruurd has quit [Read error: Connection reset by peer]
freerobby has quit [Quit: Leaving.]
<shevy> never seen something like that before
einarj has joined #ruby
<shevy> are you absolutely sure that the '?' is part of the name?
<Shizus> havenwood: I just read about the "unpack" methods used in String, I think that's exactly what I need
devoldmx has quit [Ping timeout: 256 seconds]
choke has joined #ruby
catoblepa has joined #ruby
Cust0sLim3n has quit [Ping timeout: 240 seconds]
dc has quit [Ping timeout: 240 seconds]
iamninja has joined #ruby
yardenbar has joined #ruby
dchait-lt has joined #ruby
catoblepa has quit [Ping timeout: 240 seconds]
jerius has quit [Quit: /part]
ex0ns has quit [Ping timeout: 260 seconds]
kr3ssh has quit [Ping timeout: 252 seconds]
<dchait-lt> Hello all, does Ruby have an internal timeout of sorts? I'm only getting partial results from an OOP query, though it works fine if I remove some secondary processing requirements from the process.
havenwood has quit [Quit: Textual IRC Client: www.textualapp.com]
towski__ has joined #ruby
<eam> dchait-lt: "ruby" doesn't, but whatever gems and frameworks you're using might
<dchait-lt> essentially I am running amatch to do contextual matching (source/destination) via a function, then adding the result to an object
<dchait-lt> good point, amatch might be the problem
mary5030 has joined #ruby
C1V0 has joined #ruby
<eam> dchait-lt: what is the query that's timing out? What protocol? what gem powering the query? etc
iamninja has quit [Ping timeout: 245 seconds]
mary5030 has quit [Remote host closed the connection]
stef204 has joined #ruby
<eam> if you're doing a query, processing, then querying again -- sometimes the server may time you out too
<dchait-lt> I am iterating over a directory, loading a number of YAML files
<dchait-lt> then from each I generate objects (hosts, subnets, etc)
towski_ has quit [Ping timeout: 246 seconds]
mary5030 has joined #ruby
<dchait-lt> and then for each host I run them through amatch to determine role
<dchait-lt> and finally apply that role to the host object
<eam> what's the query you're performing?
<Porfa> shevy: #<Mechanize::Page::Link "view more →" "/administrative_areas/2789/kinksters">
stef204 has quit [Client Quit]
<dchait-lt> def findrole(hostname)
<dchait-lt> m = LongestSubstring.new(hostname)
<dchait-lt> count = 0
<dchait-lt> $rolematch.keys.each do |x|
<dchait-lt> role = 'none'
<dchait-lt> match = m.match(x)
<dchait-lt> if match > count
<dchait-lt> count = match
<dchait-lt> role = $rolematch[x]
<dchait-lt> end
<dchait-lt> end
<dchait-lt> return role
<dchait-lt> end
<dchait-lt> Where rolematch is a hash array with valid roles/patterns
Spleeze has left #ruby [#ruby]
stef204 has joined #ruby
phutchins has quit [Ping timeout: 246 seconds]
<dchait-lt> It looks like I get about 74 results when I pipe the hosts through that function, and all of the results when I don't
einarj has quit [Ping timeout: 246 seconds]
baweaver has quit [Remote host closed the connection]
freerobby has joined #ruby
catoblepa has joined #ruby
catoblepa has quit [Changing host]
catoblepa has joined #ruby
einarj has joined #ruby
malconis_ has joined #ruby
michaeldeol has joined #ruby
malconis_ has quit [Remote host closed the connection]
paulcsmith has joined #ruby
phutchins has joined #ruby
malconis_ has joined #ruby
malconis has quit [Ping timeout: 246 seconds]
_djbkd has quit [Remote host closed the connection]
<Porfa> can i pass it as an HTML code? &#8594;
postmodern has quit [Quit: Leaving]
<shevy> not sure... all I know is that this is the first time I saw '?' used as part of a method call in ruby
<shevy> I guess I could not even use it because I store in an ISO encoding format :)
ych_ has joined #ruby
_djbkd has joined #ruby
<Porfa> can't i escape it using HEX notation?
d5sx43 has joined #ruby
gizmore has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
Spami_ has quit [Ping timeout: 260 seconds]
Spami_ has joined #ruby
yatish27 has quit [Remote host closed the connection]
<Porfa> (where can i host a screenshot where YOU would feel safe opening it?)
<shevy> I don't know how mechanize internally finds a match
d5sx43 has quit [Client Quit]
christiandsg has joined #ruby
<darix> Porfa: given it says /administrative_area/ you might have control over the app and just add an api instead of using html parsing
<darix> just a though
<darix> thought
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Cust0sLim3n has joined #ruby
freerobby has quit [Quit: Leaving.]
<Porfa> thanks for the tip, but unfortunately it's not as it seems… that administrative area is just the standard user logen in URL
<Porfa> logged in*
tmtwd has quit [Ping timeout: 255 seconds]
bruno- has joined #ruby
whiteline has joined #ruby
<Porfa> this is what i need to escape https://codepoints.net/U+21C4
christiandsg has quit [Ping timeout: 265 seconds]
<apeiros> Porfa: your question is how to escape characters in urls?
sudiptamondal has quit [Ping timeout: 260 seconds]
<Porfa> no, i need to tell mechanize to click 'that link' and that link name contains a rightwards arrow
<apeiros> Porfa: then look at the source and see how it's written
lkba_ has quit [Ping timeout: 264 seconds]
dagda1 has quit [Read error: Connection reset by peer]
<Porfa> it's just there, an arrow icon.
<shevy> hehe
IceyEC has joined #ruby
<apeiros> then write it just like that
chinmay_dd has joined #ruby
bin7me has joined #ruby
<Porfa> ruby fails, but rib doesn't.. that's what i am missing...
skade has quit [Read error: Connection reset by peer]
<Porfa> agent.page.link_with(:text => 'view more →').click
<shevy> yeah he applies a .click on nil there
dfockler has quit [Remote host closed the connection]
<Porfa> that on IRB goes into the page "view more ->" but the .rb won't get in
_djbkd has quit [Remote host closed the connection]
<Porfa> but how come it's not nil for IRB but is for ruby?
JoshL has quit [Read error: Connection reset by peer]
<shevy> well
JoshL has joined #ruby
doug_f1 has joined #ruby
<shevy> you pasted the -> differently now
DLSteve has joined #ruby
<shevy> <Porfa> agent.page.link_with(:text => 'view more →').click
<shevy> <Porfa> that on IRB goes into the page "view more ->"
bruno- has quit [Ping timeout: 250 seconds]
<shevy> my client tells me that... so whatever you do, you don't use the same arrow
m3ow1504_x_io has joined #ruby
<doug_f1> Is there a way to make http://ruby-doc.org/core-1.9.3/File.html#method-c-fnmatch-3F ignore symlinks?
EllisTAA has joined #ruby
<Porfa> shevy: sorry, i just can't write it on my keyboard, so i did a minus + plus math sign, srry about that
nux443 has joined #ruby
Zai00 has joined #ruby
<shevy> I can't write it either, I just copy paste your one above
<shevy> '?'
<Porfa> this is getting so confusing, I'm so sorry
<shevy> haha
<Porfa> yes you're right
<shevy> can you not avoid it?
<shevy> by using a regex to the earlier part
<shevy> like /view more/
<shevy> I don't know enough about mechanize to know whether it allows that
juanpaucar has joined #ruby
skade has joined #ruby
A124 has quit [Quit: Luke's IRC Client v0.94 build 682]
momomomomo has joined #ruby
m3ow1504_x has quit [Ping timeout: 260 seconds]
skade has quit [Read error: Connection reset by peer]
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
mhib has quit [Remote host closed the connection]
skade has joined #ruby
pranny has joined #ruby
revoohc has quit [Quit: revoohc]
amclain has joined #ruby
_djbkd has joined #ruby
_djbkd has quit [Read error: Connection reset by peer]
weemsledeux has joined #ruby
_djbkd has joined #ruby
skade has quit [Read error: Connection reset by peer]
araujo has quit [Ping timeout: 265 seconds]
pawnbox has quit [Remote host closed the connection]
snockerton1 has quit [Quit: Leaving.]
ex0ns has joined #ruby
rakm has joined #ruby
snockerton has joined #ruby
ych_ has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Soda has joined #ruby
m3ow1504_xx has joined #ruby
barhum2013 has joined #ruby
nofxx has joined #ruby
grotewold has joined #ruby
clarkenciel has quit [Quit: Leaving]
riotjones has joined #ruby
choke has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
m3ow1504_x_io has quit [Ping timeout: 240 seconds]
einarj has quit [Ping timeout: 246 seconds]
Timba-as has joined #ruby
Spami_ has quit [Ping timeout: 244 seconds]
einarj has joined #ruby
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Porfa> shevy: thank you SO much for the hint… if i do.. irb(main):032:0> agent.page.link_with(:text => /(view more).+/)
<Porfa> it will fetch me the goddamed arrow ;)
riotjones has quit [Ping timeout: 246 seconds]
sevvie has quit [Quit: leaving]
dan123b has joined #ruby
pawnbox has joined #ruby
sarkyniin has quit [Read error: Connection reset by peer]
<Porfa> but now the rest of my ruby 1.9 code is not working… arghwghj
dchait-lt has quit [Ping timeout: 246 seconds]
dagda1 has joined #ruby
<Porfa> why doesn't this work on ruby 2.2 ? .at_css('.clearfix .user_in_list')
<shevy> \o/
<shevy> hmm
<Porfa> unless they changed the site since this morning… O_o
barhum2013 has quit [Quit: barhum2013]
alejo has joined #ruby
Spami_ has joined #ruby
barhum2013 has joined #ruby
<freezevee> Can someone explain to me what am I doing wrong ? https://gist.github.com/chrisvel/6a9d79fa0a8cb345445d
<BraddPitt> what is the issue, freezevee ?
_djbkd has quit [Remote host closed the connection]
<freezevee> I am adding a new task e.g. ruby todo.rb add Clean house
<BraddPitt> what is the error you are getting
<Porfa> *going back to ruby 1.9*
<freezevee> when creating a new object, the file data get loaded, then an item is added to the array and then saved
<apeiros> freezevee: you don't properly indent. do I win?
<freezevee> apeiros: sure
<freezevee> it's pretty simple, I am trying to see how things work
<apeiros> you don't deserialize the json when reading. do I win again?
<freezevee> aha
<BraddPitt> you still haven't described an issue
dagda1 has quit [Ping timeout: 244 seconds]
<eam> freezevee: what BraddPitt is looking for is "when I run the program I see X but I expect Y"
<freezevee> apeiros: the data inside the file saved is a bit of mixed things
<apeiros> oh, and you don't use the easier File.write instead of File.open + #write
<apeiros> freezevee: your save method says otherwise
<eam> freezevee: it'll save a lot of text/time if you explain the issue as well as sharing code
<apeiros> freezevee: and if you used fake code, then: you used fake code to illustrate your problem. do I win again?
<freezevee> apeiros: what ??
<apeiros> freezevee: your save method says your todo.items is only @items.to_json. not a mix.
jackjackdripper has joined #ruby
<apeiros> so if you now claim it's a mix, either you or your code is wrong. what is it?
<freezevee> apeiros: the first add is "Clean windows"
<freezevee> apeiros: the second add is "\"Clean windows\"Wash car"
powersurge has left #ruby ["WeeChat 0.4.3"]
dagda1 has joined #ruby
<freezevee> apeiros: third "\"\\\"Clean windows\\\"Wash car\"Buy a tv cable"
yqt has joined #ruby
Zai00 has quit [Quit: Zai00]
<freezevee> apeiros: I knew that json format is like that { data: "blabla" }
tmtwd has joined #ruby
jackjackdripper has quit [Client Quit]
<apeiros> when you say `the second add is "\"Clean windows\"Wash car"`, do you mean you do `item.add "\"Clean windows\"Wash car"` ?
<freezevee> apeiros: you didn't win yet
kadoppe has quit [Ping timeout: 250 seconds]
jackjackdripper has joined #ruby
dfockler has joined #ruby
<freezevee> apeiros: sorry
<apeiros> oh, I won 4 times. all I said is spot on :-p
<freezevee> apeiros: I do add "Clean windows"
araujo has joined #ruby
<freezevee> add "Wash car"
<freezevee> one add at a time
<BraddPitt> freezevee: post your code, post example input, post expected output, post actual output
<craysiii> he wants to add the values only?
<BraddPitt> this is such a roundabout way to describe a problem
<craysiii> lol ^^
<BraddPitt> its driving me crazy, im sorry
<apeiros> freezevee: and why do you say `"\"Clean windows\"Wash car"` then?
<freezevee> BraddPitt: code is already posted
<apeiros> I concur with BraddPitt. you have not posted all code.
<freezevee> BraddPitt: example input is Item.add "Clean windows"
<craysiii> post example into and expected output vs actual output
<apeiros> you only posted your Item class.
patrick_star has joined #ruby
<craysiii> input*
<apeiros> your main issue still is probably the missing deserialization in initialize
<freezevee> I am tryiing to use it as "ruby main.rb add Clean Windows" and then "ruby main.rb add Wash floor"
kadoppe has joined #ruby
<apeiros> your @items will be a String after new. not an array.
JoshL has quit []
<apeiros> neither a Hash
_djbkd has joined #ruby
dan123b has quit [Remote host closed the connection]
<freezevee> a String ?
<apeiros> File.read returns a string.
<freezevee> I was trying to create an array
rbennacer has quit [Remote host closed the connection]
<freezevee> ok
jenrzzz has joined #ruby
baweaver has joined #ruby
<craysiii> why dont you use a database :)
<freezevee> craysiii: just experimenting with text files
<freezevee> learning *
saddad has quit [Ping timeout: 245 seconds]
_blizzy_ has joined #ruby
<freezevee> apeiros: the array will give me the chance to sort items later
<freezevee> apeiros: isn't array <=> json possible ?
<nofxx> freezevee, require 'json' array.to_json
<freezevee> read from json file => save to array => add item => save to file in json
<freezevee> apeiros: this is what I am trying to do
<apeiros> freezevee: again, if you read json, you have to deserialize it
tmtwd has quit [Ping timeout: 260 seconds]
<freezevee> apeiros: like @items = JSON.parse(File.read("todo.items")) ?
<apeiros> JSON.load(json_string) # => object structure in the json
<apeiros> oh, right, parse, not load
<apeiros> actually, both exist :D
hinbody has quit [Read error: No route to host]
<apeiros> freezevee: yes
Cache_Money has left #ruby [#ruby]
<apeiros> freezevee: you want to make sure you start with a correct value when the todo.items does not exist yet.
<freezevee> ....`initialize': A JSON text must at least contain two octets! (JSON::ParserError)
<shevy> !
<apeiros> ^ because that :-p
<apeiros> so: when todo.items does not exist yet +or is empty
<freezevee> should I open it in "a" mode ?
Iskarlar has joined #ruby
<apeiros> only if you want to end up with broken json.
rbennacer has joined #ruby
Iskarlar has quit [Remote host closed the connection]
<freezevee> apeiros: what do you suggest ?
<apeiros> I think I just said what I suggest?
Iskarlar has joined #ruby
howdoicomputer has joined #ruby
<apeiros> add code to initialize to deal with non-existing/empty todo.items
hinbody has joined #ruby
CorySimmons has joined #ruby
iateadonut has quit [Quit: Leaving.]
dimasg has quit [Ping timeout: 240 seconds]
victortyau has quit [Ping timeout: 244 seconds]
banghouse2 has joined #ruby
symm- has quit [Quit: Leaving...]
Iskarlar has quit [Remote host closed the connection]
<apeiros> freezevee: File.read will never return nil
<freezevee> .empty
banghouse2 has quit [Remote host closed the connection]
<freezevee> ok
<freezevee> apeiros: I believe it worked, I am getting ["Wash car","Buy a tv cable"]
<apeiros> .empty?, ? is part of the name
<freezevee> yes I missed that
<freezevee> but is this JSON format ?
<apeiros> now move the require to the top and use File.write, and then you have almost decent code ;-p
Porfa has quit [Ping timeout: 240 seconds]
<freezevee> you mean outside the class ?
<apeiros> "I am getting" = "my file contains"?
<apeiros> yes. top of the file. (the require)
_aeris_ has quit [Remote host closed the connection]
<freezevee> yeah it's a way to say that my file contains :P
lkba has joined #ruby
davedev2_ has joined #ruby
<apeiros> not really. it can mean a plethora of things.
_aeris_ has joined #ruby
<freezevee> apeiros: why use File.write?
<apeiros> because File.write(path, data.to_json) is 2 lines shorter?
<apeiros> easier to read?
<freezevee> all right
<freezevee> makes sense
momomomomo has quit [Quit: momomomomo]
davedev24 has quit [Ping timeout: 246 seconds]
victortyau has joined #ruby
<freezevee> do you think I can correct something else ? https://gist.github.com/chrisvel/6a9d79fa0a8cb345445d
greencoder has joined #ruby
<apeiros> you could deal with todo.items not existing.
<apeiros> also if your todo is json, I'd use the proper file extension (.json)
<shevy> apeirosn wouldn't like .jsn!!!
<freezevee> all right
<shevy> damn, I mistyped :(
<freezevee> thanks !
Motoservo has quit [Quit: Shhh. I'm trying to get some sleep here.]
<freezevee> valueable chat (for me)
Zai00 has joined #ruby
roadpanda_ has joined #ruby
<apeiros> freezevee: note that require_relative 'lib/item/item' is bad style which may/can/will break once you make this thing a gem
<apeiros> (rubygems is not required to put the lib dir relative to the bin dir the same way it is in your gem)
dtzitz has joined #ruby
<greencoder> Is this the right place to ask questions for ruby help or is there a different channel for beginners?
<freezevee> thank you but require didn't work
<freezevee> that's why I used relative
khebbie has joined #ruby
<nofxx> greencoder, just shoot to thrill
roadpanda_ has quit [Quit: Leaving]
<apeiros> freezevee: require works. but you have to use it properly.
<greencoder> I'm basically trying to write a script that creates a bunch of different folders and files based a name it gets from user input
<greencoder> based on a name*
<apeiros> the way you do it: `require 'item/item'` in your code, and `ruby -I path/to/lib main.rb`
rdark has quit [Ping timeout: 256 seconds]
<apeiros> the -I is not necessary once you made it a gem and installed it. rubygems then handles that. what it does is add "path/to/lib" to $LOAD_PATH (which is what require searches for your file)
clarkenciel has joined #ruby
<apeiros> greencoder: this channel is fine. there's also ##new2ruby if you prefer a smaller channel.
millerti has joined #ruby
<dtzitz> you could also try ##webdevvit if you're looking for people to be activly hostile toward you
<greencoder> cool thanks apeiros
<shevy> greencoder you require 'fileutils', and then you can do so - create a file FileUtils.touch() (or perhaps File.touch, not sure); a directory FileUtils.mkdir_p() etc..
<shevy> and user input is: user_input = gets.chomp
Musashi007 has quit [Quit: Musashi007]
<greencoder> shevy: I'm not too concerned about making the actual directory or file, the problem I'm having is figuring out what to do after I create the file
<shevy> delete it again
<greencoder> I want to insert a bunch of XML code inside it, and only change a certain value in every place
<shevy> :)
<shevy> yah you can write anything into your string; http://stackoverflow.com/questions/2777802/how-to-write-to-file-in-ruby
sarkyniin has joined #ruby
<greencoder> cool, I'll look into it thanks shevy
<apeiros> dtzitz: hm, raytheon, where do I know them from?
jtdoncas_ has quit [Ping timeout: 240 seconds]
khebbie has quit [Ping timeout: 244 seconds]
<shevy> perhaps your dirty php past
<shevy> with your 100.000 lines of code php webframework
jtdoncas_ has joined #ruby
nertzy has joined #ruby
Cust0sLim3n has quit [Ping timeout: 260 seconds]
<dfockler> 1000 lines of php, copied 10 times
<dfockler> then those copies copied 10 times
<shevy> I can see you do know how php works
<nofxx> I remember my first rails project, 100k php files were rewritten to 5k. With lots of extr features.
JoshL has joined #ruby
christiandsg has joined #ruby
<dtzitz> apeiros: never heard of em
dagda1 has quit [Ping timeout: 272 seconds]
<dtzitz> =)
<dfockler> rails just hides the 100k of files in the background
<shevy> nofxx hmm
<nofxx> greencoder, if you're changing a lot this xml you might give ERB a try
<shevy> lol
<nofxx> heheh... what the current rails LOC?
Diabolik has quit [Ping timeout: 246 seconds]
<nofxx> w/o activerecord pls =D
<greencoder> nofxx: It's basically a Sublime Text color scheme file. I basically want to change every instance of a certain hexadecimal color value based on whatever the user inputs
pocketprotector has joined #ruby
Torrieri has quit [Quit: Be back later ...]
<nofxx> greencoder, and the file already exists or are you creating it?
<nofxx> and if you're creating it's cool to overwrite it later?
peterhu has joined #ruby
<greencoder> nofxx: I'm creating it
<greencoder> and what exactly do you mean? Once the color value has been switched, I wouldn't really need to make any other changes to it
choke has joined #ruby
dagda1 has joined #ruby
tmtwd has joined #ruby
greymeister has quit [Quit: greymeister]
rbennacer has quit [Remote host closed the connection]
Timba-as has quit [Quit: Be back later ...]
christiandsg has quit [Ping timeout: 265 seconds]
<nofxx> greencoder, the simplest way I can think: inside a def get_the_xml(value) do a <<EOC paste the xml here and interpolate #{value}
ex0ns has quit [Ping timeout: 252 seconds]
bruno- has joined #ruby
<nofxx> the good way: put the xml a part in a file.xml.erb use the erb <% interpolation that I forgot, and do ERB.render or something that I forgot too
Diabolik has joined #ruby
apt-get_ has joined #ruby
<Darkwater> anyone here got experience with ZeroC ICE?
<Darkwater> trying to use callbacks with murmur
<Darkwater> but I can find like zero documentation on how to do that in ruby
<greencoder> nofxx: that seems like a cleaner way to do it, I may try that
Motoservo has joined #ruby
<nofxx> greencoder, it's very easy actually. erb is also stdlib, so just require and have fun
Cust0sLim3n has joined #ruby
<greencoder> cool thanks
sarkyniin has quit [Disconnected by services]
apt-get_ is now known as sarkyniin
[k- has quit [Ping timeout: 240 seconds]
<nofxx> greencoder, last tip: There;s -p for mkdir too, so you can create nested folders
<nofxx> FileUtils.mkdir_p iirc
michael_mbp has quit [Excess Flood]
<greencoder> so like FileUtils.mkdir_p 'folder/nested_folder' ?
Musashi007 has joined #ruby
<nofxx> greencoder, let me know ;)
<Darkwater> yeah
<greencoder> lol thanks a lot
michael_mbp has joined #ruby
michael_mbp has quit [Excess Flood]
<greencoder> ill start making it
jalljo has joined #ruby
alejo has quit [Quit: Leaving]
djbkd_ has joined #ruby
dc has joined #ruby
pawnbox has quit [Remote host closed the connection]
SCHAAP137 has quit [Quit: Leaving]
michael_mbp has joined #ruby
rbennacer has joined #ruby
SCHAAP137 has joined #ruby
einarj has quit [Read error: Connection reset by peer]
djbkd_ has quit [Ping timeout: 246 seconds]
riotjones has joined #ruby
skade has joined #ruby
einarj has joined #ruby
RazorX has quit [Remote host closed the connection]
Motoservo has quit [Quit: Shhh. I'm trying to get some sleep here.]
greymeister has joined #ruby
<shevy> semi off topic - I am looking at ruby-gnome bindings in github right now. Is there a simple way to propose an updated version of a .rb file, in the browser ideally?
RazorX has joined #ruby
jgt has joined #ruby
<Darkwater> should be an edit button somewhere near the top
baweaver has quit [Remote host closed the connection]
jgpawletko has quit [Quit: jgpawletko]
Shizus has quit [Ping timeout: 246 seconds]
pranny has quit [Read error: Connection reset by peer]
<shevy> oh you are right, now I see it, thanks!
IrishGringo has quit [Ping timeout: 246 seconds]
pranny has joined #ruby
Blaguvest has joined #ruby
Timba-as has joined #ruby
fantazo has quit [Quit: Verlassend]
<shevy> "The Travis CI build is in progress"
<shevy> excitement
greencoder has quit [Remote host closed the connection]
riotjones has quit [Ping timeout: 250 seconds]
<shevy> well this would be pretty cool if this could be a browser in the editor, perhaps one day I can ditch bluefish altogether
<shevy> erm... *editor in the browser
jpfuentes2 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
CorySimmons has quit [Quit: Bye!]
dagda1 has quit [Ping timeout: 256 seconds]
havenwood has joined #ruby
choke has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
IrishGringo has joined #ruby
m3ow1504_xx has quit [Read error: Connection reset by peer]
m3ow1504_x has joined #ruby
bruno- has quit [Ping timeout: 240 seconds]
dagda1 has joined #ruby
nofxx has quit [Ping timeout: 264 seconds]
nertzy has quit [Quit: This computer has gone to sleep]
kr3ssh has joined #ruby
dgutierrez1287 has joined #ruby
barhum2013 has quit [Quit: barhum2013]
barhum2013 has joined #ruby
Nahra has joined #ruby
Nahra has quit [Remote host closed the connection]
baweaver has joined #ruby
Nahra has joined #ruby
dagda1 has quit [Ping timeout: 245 seconds]
cmckee has joined #ruby
<sarkyniin> I have a little ruby script and I want to cache a small file
<nahtnam> > "2015"[-3..-1]
<sarkyniin> what's the preferred folder for that? XDG_CACHE or XDG_CONFIG_HOME? how do I save to those folders?
<nahtnam> >> "2015"[-3..-1]
<ruboto> nahtnam # => "015" (https://eval.in/421613)
shinnya has joined #ruby
devoldmx has joined #ruby
greencoder has joined #ruby
howdoicomputer has quit [Ping timeout: 272 seconds]
toretore has joined #ruby
decaff has joined #ruby
<havenwood> nahtnam: Hem?
<nahtnam> havenwood: ?
<greencoder> is there a good way to check if a hex string is valid?
<havenwood> nahtnam: Oh, you showed example code without context.
<greencoder> like if I wanted to make ` def valid_hex?(hex)`
dagda1 has joined #ruby
<nahtnam> havenwood: Sorry was just running something from #RubyOnRails
jgpawletko has joined #ruby
devoldmx has quit [Ping timeout: 255 seconds]
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
axsuul has joined #ruby
Porfa has joined #ruby
momomomomo has joined #ruby
nonnatus has joined #ruby
jgpawletko has quit [Client Quit]
<havenwood> greencoder: Make sense how to take it from `\h` to your goal?
iamninja has joined #ruby
<Bish> how do i escape #{} correctly?
<Bish> \#{} ?
<havenwood> Bish: That'd do it.
jgpawletko has joined #ruby
jgpawletko has quit [Client Quit]
dc has quit [Read error: Connection reset by peer]
<Bish> will it do it, or is it correct?
skade has quit [Quit: Computer has gone to sleep.]
<Bish> i mean #{ is a two-letter thing, isn't it?
dc has joined #ruby
<havenwood> Bish: If the first is escaped the second is irrelevant.
<greencoder> havenwood: I tried doing something like this: https://gist.github.com/anonymous/f6a38245a82342b5f25c
<Bish> but why is \# == #
<greencoder> but that doesn't seem right
<havenwood> Bish: Without magic that needs escaping there's no need for an escape.
<havenwood> greencoder: You want it to be all valid hex xdigits and also size of 7?
<greencoder> does '#' count as a valid hex digit?
<greencoder> i guess not lol
nonnatus has left #ruby ["WeeChat 0.4.2"]
machinewar has joined #ruby
bumbar_ has quit [Ping timeout: 250 seconds]
dtzitz has left #ruby [#ruby]
<havenwood> greencoder: Is it between 0-9, a-f or A-F?
<baweaver> >> "#\{}" # Keep your eye on the birdie
<ruboto> baweaver # => "\#{}" (https://eval.in/421617)
<greencoder> yeah got it lol
<baweaver> You so silly Ruby
<havenwood> >> 'nope' =~ /\h{7}/
<ruboto> havenwood # => nil (https://eval.in/421618)
<havenwood> greencoder: ^
_djbkd has quit [Remote host closed the connection]
<havenwood> greencoder: That would be any 7 xdigits in a row.
skade has joined #ruby
iamninja has quit [Ping timeout: 240 seconds]
<havenwood> greencoder: Say more about what you want?
barhum2013 has quit [Quit: barhum2013]
<havenwood> greencoder: Or better yet, show examples of real input and desired output.
<baweaver> http://rubular.com/ # greencoder
m3ow1504_x_io has joined #ruby
<greencoder> thanks baweaver that looks cool
<baweaver> should help to experiment
<havenwood> greencoder: On Rubular try: /\A\h{7}\z/
ekleog has quit [Remote host closed the connection]
<greencoder> havenwood: I basically am just verifying that a hexadecimal color should work
<baweaver> allows you to put in psuedo-input to test for matches.
<greencoder> So `#123456` should return true
barhum2013 has joined #ruby
ekleog has joined #ruby
<greencoder> `#h12345` should return false
dagda1 has quit [Ping timeout: 272 seconds]
<havenwood> greencoder /\A#\h{6}\z/
<baweaver> How about FFF?
<Bish> bleh when using .gsub with blocks, can i get the groups somehow?
beef-wellington has quit [Ping timeout: 244 seconds]
<greencoder> baweaver: I'm telling the user to input it in `#XXXXXX` format, but maybe I should account for that too lol
tens0r has joined #ruby
<baweaver> /\A#\h{3,6}\z/
<greencoder> Thanks a lot havenwood and baweaver
frem has joined #ruby
<shevy> the beaver!
<baweaver> it says bits on that
<shevy> that dam bits
AlexRussia_ has quit [Ping timeout: 240 seconds]
<baweaver> >> 'foobar'.gsub(/oo/) { |match| "oo#{match}" }
<ruboto> baweaver # => "foooobar" (https://eval.in/421619)
<baweaver> Bish: ^
howdoi has quit [Quit: Connection closed for inactivity]
Norrin has left #ruby ["Dueces"]
<Bish> 'whoop #{test}'.gsub(/\#{[^}]}/)
<Bish> arghs, sorry
<Bish> 'whoop #{test}'.gsub(/\#{[^}]}/)
<Bish> -_-
ponga has quit [Quit: Connection closed for inactivity]
<Bish> >> 'whoop #{test}'.gsub(/\#{([^}]+)}/) { |m| p m }
<ruboto> Bish # => "\#{test}" ...check link for more (https://eval.in/421620)
freerobby has joined #ruby
<Bish> i just want "test"
nonnatus has joined #ruby
decaff has left #ruby ["Leaving..."]
zxvcd has joined #ruby
z1haze has joined #ruby
<Bish> >> 'whoop #{test}'.gsub(/\#{([^}]+)}/) { |m| m = "that's what i want, just generic" + m[2...-1] }
<ruboto> Bish # => "whoop that's what i want, just generictest" (https://eval.in/421621)
<baweaver> >> 'whoop #{test}'.gsub(/\#\{([^}]+)\}/) { |m| Regexp.last_match[1] }
<ruboto> baweaver # => "whoop test" (https://eval.in/421622)
allcentury has quit [Ping timeout: 265 seconds]
<Bish> kinda dirty, is regexp thread safe?
<z1haze> Hi I know nothing about ruby or anything like that, it is just a requirement for a application I'm using.. But it required me to install mysql2 which I attempted to do.. but its been sitting at Building native extensions. This could take a while... for close for 45 minutes or more now
<z1haze> Is this a problem?
<Bish> z1haze, is it mechanize, yeah leave it hanging for 3 days
<baweaver> Run just the gsub: 'whoop #{test}'.gsub(/\#\{([^}]+)\}/) - then inspect Regexp.last_match
<Bish> baweaver, yeah i understand, but is Regexp unique per thread?
barhum2013 has quit [Quit: barhum2013]
<z1haze> What?
<baweaver> Bish: If you're using threads in ruby you're going to have a bad time.
<z1haze> I dont have 3 days..
<Bish> z1haze, im just fucking with yeah, no that's not normal, atleast if your machine is not from 1998
nonnatus has left #ruby [#ruby]
<z1haze> no its a decent machine
<Bish> baweaver, until know i love threads in ruby
<z1haze> its a dedicated server
<z1haze> what should I do?
Nahra has quit [Remote host closed the connection]
barhum2013 has joined #ruby
<Bish> z1haze, have you tried turning it off and on again?
<baweaver> install just that gem
<z1haze> turning it off?
nonnatus has joined #ruby
<baweaver> ignore them
<Bish> baweaver, what's so bad about threads in ruby?
<z1haze> turning what off?
<Bish> z1haze, another joke.. but i was serious, have you tried restarting the installation of the gem?
<z1haze> I didnt cancel it i didnt wantto mess anything up
sarkyniin has quit [Ping timeout: 246 seconds]
rocx has joined #ruby
<Bish> z1haze, you cannot mess up, in the worst case it doesn't get installed
dagda1 has joined #ruby
<z1haze> well in that case.. i dont think restarting is going to magically fix it. what could I check ?
<baweaver> "These global variables are thread-local and method-local variables."
ngscheur1 has joined #ruby
<baweaver> looks like it
machinewar has quit []
<rocx> Is it true that Ruby contains a JavaScript engine embedded in it?
catoblepa has quit [Ping timeout: 264 seconds]
<z1haze> what ports does it need to connect out on?
Coldblackice_ has joined #ruby
<baweaver> rocx no
<Bish> z1haze, are you using ubuntu? i had problems with it to, it took some time, installed some dev libs, let me check my browser history
<z1haze> I dont have ubuntu, this machine runs centos
<baweaver> There's therubyracer which can do parts of it, but that's a technicality.
<rocx> baweaver: Then the execjs page confused me when it said that there's "V8 embedded in Ruby".
<yorickpeterse> rocx: No, we do have an embedded COBOL engine though
<yorickpeterse> ᕕ(ᐛ)ᕗ
<baweaver> z1haze: yum install mysql
ngscheurich has quit [Read error: Connection reset by peer]
<baweaver> or equivalent
<rocx> Or am I just reading something wrong on the GitHub page for execjs?
<Bish> ^
socialjackie has quit [Quit: Leaving]
<Bish> baweaver, why do you think rubythreads are a bad idea?
Timba-as has quit [Quit: Be back later ...]
<baweaver> rocx: probably, never heard of that myself.
<baweaver> green threads, they block.
<Bish> yeah ofcourse i know about that, but i don't care, i don't have performance issues, also i am using rubinius
<Bish> im just using them, so i don't have to write complicated algorhitms to do the same fu* thing
<baweaver> The more potential global state in a language, the more annoyance they can yield.
<havenwood> rocx: Any reason not to install node if you need it? Or just curious?
<yorickpeterse> suggesting the use of threads is a bad idea is flat out dumb
diegoviola has quit [Quit: WeeChat 1.3]
<yorickpeterse> Anybody telling you that has no idea what they're talking about
<rocx> I'd really really like to not use Node or anything JS-related on my system. That's why I was asking.
<Bish> let the war begin
<yorickpeterse> rocx: No, Ruby has no embbed JS anything
<yorickpeterse> rocx: there are libraries that let you communicate with JS from within Ruby though
<yorickpeterse> but Ruby itself, as in the language and the implementions, is completely unrelated to JS
<baweaver> yorickpeterse: have fun with mutex
<rocx> Alright. Thanks. Guess I read it wrong since I think I see CPP sources for V8 in the execjs repo.
codecop has quit [Remote host closed the connection]
<yorickpeterse> baweaver: I suggest learning about multi-threading before spewing nonsense
<yorickpeterse> Also, you can do lock free operations just fine in Ruby
dstarh has joined #ruby
<yorickpeterse> That is, you don't always need a mutex
<baweaver> You're making an awful lot of assumptions here.
einarj_ has joined #ruby
<yorickpeterse> The only assumption that can be possibly false is my suggestion of you learning about multi-threading
jpfuentes2 has joined #ruby
<dstarh> I need to SHA256 about 6 million email addresses, is there any reason that I should do a Digest::SHA2.new vs passing an instnace of digest and doing a reset before using it?
symm- has joined #ruby
<yorickpeterse> Ruby does not provide decent primitives out of the box, correct
einarj has quit [Ping timeout: 260 seconds]
<yorickpeterse> MRI doesn't do multi-threading properly, correct
<yorickpeterse> But claiming threads are bad is plain dumb
<havenwood> rocx: An understandable position. ;)
<yorickpeterse> dstarh: Digest::SHA2.hexdigest basically does the latter under the hoods
<yorickpeterse> dstarh: it just saves you code
<yorickpeterse> * hood
<baweaver> You're entitled to your opinion, but being an ass about it is another matter entirely.
<greencoder> well now I realize what my problem has been. I was assuming that str.slice(1) would give me the substring from index 1 all the way to the end
<yorickpeterse> baweaver: boo fucking hoo
<havenwood> Do please be nice all!
<bricker> :( why the name calling, we're all on the same team
<dstarh> yorickpeterse so you don't pay the initialzation cost?
<yorickpeterse> baweaver: if you suggest something as silly as you did you should be prepared to be told you're wrong
<yorickpeterse> dstarh: it's there always
<yorickpeterse> dstarh: but it's unlikely to be your bottleneck
<baweaver> Welcome to the mute list then
<dstarh> roger thanks
<yorickpeterse> baweaver: lol
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<z1haze> i have mysql.
barhum2013 has quit [Quit: barhum2013]
<z1haze> lmao
<yorickpeterse> Bish: re regexp, what did you mean about it being thread-safe?
<yorickpeterse> Bish: the magic variables such as $1, $2, etc are supposed to be frame local IIRC
choke has joined #ruby
<yorickpeterse> err, thread local frame local
<yorickpeterse> whatever you'
<yorickpeterse> * you'd call it
<z1haze> i am trying to import a xenforo database into discourse.. when i ran the script and i get load error cannot load such file -- mysql2
<z1haze> so i do gem install mysql2 ... it fetched 100% then building native extensions blah blah.. and just sits there.. 2 times in a row now
<yorickpeterse> z1haze: gem install mysql2 --verbose
<yorickpeterse> might give more insight
<z1haze> oh alright
<z1haze> ah
<z1haze> its just spamming something over and over
TheMoonMaster is now known as blake
<z1haze> checking for mysql_query() in -lmysqlclient... no
<yorickpeterse> make sure you have development headers for mysql installed
<yorickpeterse> usually the package is called something like "mysql-dev" or "mysql-devel"
dagda1 has quit [Ping timeout: 250 seconds]
<baweaver> Now then, to clarify without commentary... Most people abuse threads and metaprogramming earlier on, most of the time not even really needing them.
<z1haze> with yum or gem?
<yorickpeterse> baweaver: that's a massive difference from saying "Ruby threads are bad"
<baweaver> Now when you happened to mention Rubinius and other such things, you probably have knowledge to avoid those issues.
<yorickpeterse> z1haze: yum
rikkipitt has joined #ruby
<havenwood> Bish: JRuby has some reasonable guildlines to follow: https://github.com/jruby/jruby/wiki/Concurrency-in-jruby#concurrency-basics
<Bish> yorickpeterse, well, i was thinking about 2 threads using regexp at the "same time" and overwriting each other
<havenwood> guidelines*
<z1haze> i have mysql installed though, well mariadb..
<z1haze> i use mysql all the time..
<yorickpeterse> Bish: are you specifically referring to the magic variables?
m3ow1504_x_io has quit [Read error: Connection reset by peer]
<Bish> yorickpeterse, yes
<yorickpeterse> Bish: those are fine
<Bish> or Regexp.last_match
m3ow1504_x_io has joined #ruby
<yorickpeterse> That's fine too
<baweaver> MariaDB probably won't work with that gem, but not sure.
<z1haze> Package 1:mariadb-5.5.41-2.el7_0.x86_64 already installed and latest version
<z1haze> thats what mysql installs..
IceyEC has quit [Quit: iceyec]
<baweaver> even if they're forks technically.
<yorickpeterse> z1haze: make sure you also have mariadb-dev or w/e it is
<z1haze> yum install mysql installs mariadb by default
<baweaver> huh, interesting
<yorickpeterse> z1haze: yum search mariadb | grep '\-dev'
<baweaver> I'll have to read into that later.
<Bish> first_body = template[:content].gsub(/\#{([^}]+)}/) { |s| s = data_fields[$1] } <= but this seems to work just fine :3
<z1haze> yea theres a devel
<z1haze> you think thats it?
<yorickpeterse> Yup
<baweaver> might be, but not entirely sure
opensource_ninja has joined #ruby
<baweaver> I just know adapters can be touchy.
failshell has quit [Remote host closed the connection]
<z1haze> that did it
<z1haze> thank you
<yorickpeterse> np
<baweaver> not a problem
<banister> yorickpeterse arnhem is the only place i've been to in NL that has hills, are there any other places like that?
ex0ns has joined #ruby
<yorickpeterse> banister: haha, this country has no proper hills
<baweaver> I'll have to read up on the MariaDB split later though, I only know it by name honestly.
<yorickpeterse> There are bumps, that's it
zendrix has joined #ruby
catoblepa has joined #ruby
<banister> yorickpeterse arnhem was relatively impressive though
<yorickpeterse> There are some in Limburg, and around the Veluwe
<banister> you been there? it felt like a real city
dgutierrez1287 has quit [Remote host closed the connection]
<banister> (cos of the hills, i'm used to hills back in nz)
<yorickpeterse> Not that I can remember
blue_deref has joined #ruby
riotjones has joined #ruby
<banister> ah ok, cool zoo there btw
Iskarlar has joined #ruby
sacarlson has joined #ruby
rocx has left #ruby [#ruby]
<yorickpeterse> baweaver: MariaDB supposedly has an ABI compatible with MySQL
<sacarlson> any idea why I get these https://gist.github.com/sacarlson/bae9ce656325acc99b31 /home/sacarlson/.bundle/gems/json-1.8.3/lib/json/common.rb:67: [BUG] Segmentation fault at 0x00000000000018
<yorickpeterse> Though I don't know if they intend to keep that around forever
senayar has joined #ruby
senayar has joined #ruby
<yorickpeterse> sacarlson: not without any code and a full stack trace
<yorickpeterse> ?gist
<ruboto> https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
<sacarlson> just by runing rake -v
<sacarlson> /home/sacarlson/.rbenv/versions/2.2.0/lib/ruby/gems/2.2.0/gems/rake-10.4.2
riotjones has quit [Ping timeout: 244 seconds]
<sacarlson> yorickpeterse: I think the stack trace is in the included gist above
grotewold has quit [Quit: Textual IRC Client: www.textualapp.com]
bruno- has joined #ruby
_djbkd has joined #ruby
<yorickpeterse> There's no Gist link anywhere to be found
<yorickpeterse> oh wait
<yorickpeterse> heh, I'm dumb
<yorickpeterse> sorry
<sacarlson> np
juanpaucar has quit [Remote host closed the connection]
<yorickpeterse> Hm, maybe the Gem is botched?
pdoherty has joined #ruby
<sacarlson> I've had this error in serveral other gems not sure what it comes from. how do you reinstall the gem? just delete and reinstall it?
sshuff|gone is now known as sshuff
juanpaucar has joined #ruby
<yorickpeterse> Just gem install json
<yorickpeterse> it overwrites it
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<sacarlson> ok but it's with bundler and I'm new to this bunder thing
<yorickpeterse> That should be fine, bundler doesn't matter in this case
<greencoder> Is there a way to join strings with a comma seperator? They are not in an array, so I don't think I can use join(',')
<greencoder> basically 3 different string values
Ox0dea has joined #ruby
yfeldblum has quit [Ping timeout: 244 seconds]
<Ox0dea> greencoder: Just put them in a temporary array?
Iskarlar has joined #ruby
<sacarlson> looks to be the same error after gem install json
<sacarlson> maybe gem install rake?
havenwood has quit [Ping timeout: 240 seconds]
<yorickpeterse> maybe there's some invalid input being passed to the JSON gem?
<sacarlson> this is just from rake -v
Limix has joined #ruby
m3ow1504_x_io has quit [Quit: Leaving]
<yorickpeterse> hmmm
<sacarlson> so with bundler I can still try gem install rake than?
<greencoder> Ox0dea: I basically went with something like this, does that look alright to you? https://gist.github.com/anonymous/7ff0074175d48cb6acd7
<Ox0dea> sacarlson's error is occurring here: http://git.io/vsDC6
<Ox0dea> It looks a little scary, but it should work just fine. :/
radgeRayden has quit [Ping timeout: 260 seconds]
<sacarlson> I'll take a look Ox0dea
<Ox0dea> greencoder: That's fine, I suppose, but there are better ways.
<greencoder> would you mind telling me some? :p
<Ox0dea> >> ['ddeeaa'].pack('H*').bytes * ', ' # greencoder
<ruboto> Ox0dea # => "221, 238, 170" (https://eval.in/421628)
jeadre has quit [Remote host closed the connection]
<greencoder> O.O
<Ox0dea> It'll fail with a leading '#', though. :/
renderful has quit [Remote host closed the connection]
rubie has quit [Remote host closed the connection]
jeadre has joined #ruby
dagda1 has joined #ruby
yardenbar has quit [Quit: Leaving]
yatish27 has joined #ruby
Jackneill has quit [Ping timeout: 240 seconds]
<sacarlson> Ox0dea: I'm not sure what to read into that something to do with # Set the module _generator_ to be used by JSON. ?
renderful has joined #ruby
einarj has joined #ruby
dstarh has quit [Ping timeout: 240 seconds]
einarj_ has quit [Ping timeout: 260 seconds]
Blaguvest has quit []
chipotle has quit [Quit: cheerio]
<Ox0dea> sacarlson: JSON's state generator is written in C; that you're getting a segfault is indicative of something having gone wrong at that level.
sargas has joined #ruby
radgeRayden has joined #ruby
<sacarlson> Ox0dea: what might I reinstall or change version to correct it?
<Ox0dea> Try nuking the entire thing from orbit?
bin7me has quit [Read error: Connection reset by peer]
<sacarlson> the entire thing being all the gems? I've already tried that a few times in the past
<sacarlson> but I'm willing to give it another try
kfpratt has quit []
cmckee has quit [Quit: cmckee]
<Porfa> hehe
jeadre has quit [Remote host closed the connection]
<Ox0dea> sacarlson: No, I was only ribbing.
<Porfa> so I'm really excited because I'm ding my first project where i use mechanize and nokogiri and omg.. it's so beautiful how it works ;_;
<Ox0dea> sacarlson: Have you ensured that the JSON standard library works in isolation?
<sacarlson> Ox0dea: dam and I just reformated my hard disk ha ha
<Ox0dea> Problem solved.
<sacarlson> just kiding
chinmay_dd has quit [Quit: See ya!]
Mon_Ouie has quit [Quit: WeeChat 1.3]
umgrosscol has quit [Quit: Quit]
Nahra has joined #ruby
rubie has joined #ruby
<sacarlson> how would I verify json standard lib?
jeadre has joined #ruby
benlovell has quit [Ping timeout: 246 seconds]
<sacarlson> some irb test I can do?
zenguy_pc has quit [Ping timeout: 265 seconds]
<Porfa> I'm just running into a problem, a programmers logic problem :X so.. i get mechanize no login and do it's stuff, then i jump to the user list, but the user list only contains 40 users on each page… after my parsing loop to get the users names and sex, then after this "for each" is done how do i make it jump to the next page and repeat the previous loop? do i need to put a loop inside a loop?
<Ox0dea> sacarlson: Well, `ruby -rjson -e ""` would let you know that the library is being loaded properly.
IrishGringo has quit [Ping timeout: 244 seconds]
<Ox0dea> But you'll probably need to "exercise" it a bit to hit the bug.
renderful has quit []
renderful has joined #ruby
<maletor> is there a shorter form of foo.inject(0) { |a, e| a + e }
<sacarlson> ruby: no code specified for -e (RuntimeError)
<Ox0dea> >> [1, 2, 3].reduce(:+) # maletor
<ruboto> Ox0dea # => 6 (https://eval.in/421631)
<maletor> Ox0dea: you are fast
<Ox0dea> sacarlson: You need the empty string at the end.
<sacarlson> oh ok
<Ox0dea> maletor: Note well that you can still supply an initial value with this form.
<sacarlson> I get no return so I assume that's good?
<maletor> Ox0dea: but otherwise it's 0?
<Ox0dea> It's good in that the library loads fine, bad in that it doesn't get us any closer to finding the bug.
wprice has quit [Quit: wprice]
<Ox0dea> maletor: Sort of. It just uses the collection's first element as the initial value.
<maletor> sweet
kfpratt has joined #ruby
<shevy> Porfa show the code?
<Ox0dea> In any case, Porfa does in fact need an inner loop.
<shevy> Porfa in general, if you can split up tasks into smaller chunks, it will usually be the best approach; a loop in a loop sounds odd in ruby, normally you could do a .select
<shevy> really?
<Porfa> whats a .select? whoaaa thats to much for me, never heard of that drug mate. ( send hub for you to github)
baweaver has quit [Remote host closed the connection]
jeadre has quit [Remote host closed the connection]
<Ox0dea> shevy: Well, I suppose it's dependent upon what Porfa is doing in their "parsing loop", but if it really does need to be a loop, and they want to do it multiple times, well...
atomical has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
michaeldeol has joined #ruby
<shevy> >> %w( 2 3 4 ).select { |i| i.to_i % 2 == 0 }
<ruboto> shevy # => ["2", "4"] (https://eval.in/421633)
<shevy> Porfa you formulate your query condition within the select {} block and it'll yield you the matches
rodfersou has quit [Quit: leaving]
<Porfa> ignore line 14 plz
jeadre has joined #ruby
vF3hNGxc47h8 has joined #ruby
TomyLobo has quit [Ping timeout: 250 seconds]
<shevy> lots of dependencies
<shevy> are all of these needed for that snippet?
<shevy> I don't have mysql installed here right now for instance
arup_r has quit [Quit: Leaving]
<Porfa> ok, remaking the gist, sorry shevy
<shevy> Porfa cheap man's debug tool is: require 'pp' on top, then do a: pp parsu
<shevy> I don't know what parsu holds for instance
dagda1 has quit [Ping timeout: 264 seconds]
troyready has quit [Read error: Connection reset by peer]
troyready has joined #ruby
einarj has quit [Read error: Connection reset by peer]
einarj has joined #ruby
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
cmckee has joined #ruby
baweaver has joined #ruby
yeticry has quit [Ping timeout: 265 seconds]
<Ox0dea> shevy: "%w( 2 3 4 )"; what is this silliness?
<Porfa> what i really need is that, when the loop ends, i need it to click "next" and do the loop again
dagda1 has joined #ruby
<Ox0dea> Porfa: Do you know how to loop indefinitely?
<shevy> Ox0dea this is called an Array
<Ox0dea> shevy: But it's an array of "words" that contains only numbers.
<Porfa> Ox0dea: nope
<shevy> and?
<Ox0dea> It looks GitHub.
howdoicomputer has joined #ruby
<shevy> Porfa I can't seem to use your code, I get lots of .click on nil objects
<Ox0dea> Porfa: You can say `loop do ... end` to just keep running the loop over and over.
fuzzyhorns has quit [Quit: later nerds]
<Ox0dea> Of course, you'll want to use `break` to exit the loop when you meet some termination condition.
<Porfa> because the user/pass is not real, sorry shevy . i will create a user name / pass for testing purposes, sorry about that, i'll be creating an account now on the site
zenguy_pc has joined #ruby
<Porfa> Ox0dea: the terminal condition would be a nil on the "click next"
<Porfa> if nil*
rbowlby has joined #ruby
northfurr has joined #ruby
<Ox0dea> Probably better to check for its existence, but I suppose that would do.
malconis has joined #ruby
yeticry has joined #ruby
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dagda1 has quit [Read error: Connection reset by peer]
malconis_ has quit [Ping timeout: 240 seconds]
<shevy> Porfa hmm it may be best if you change your code to check for nil objects prior to call a method, there may be other failures like a connection that is down
Asher has quit [Quit: Leaving.]
<shevy> these were the old school usage examples I used to use http://mechanize.rubyforge.org/EXAMPLES_rdoc.html
<shevy> well except for the "end.something" stuff
ex0ns has quit [Remote host closed the connection]
jeadre has quit [Remote host closed the connection]
fmcgeough has quit [Quit: fmcgeough]
stevednd has quit [Read error: Connection reset by peer]
northfurr has quit [Ping timeout: 272 seconds]
<Porfa> :) there, that one works as it as correct user/pass
<sacarlson> is there a command that will just recompile all extensions? assuming those are all the C code that is compiled for each gem?
jeadre has joined #ruby
dblessing has quit [Quit: Textual IRC Client: www.textualapp.com]
christiandsg has joined #ruby
baweaver has quit [Remote host closed the connection]
<shevy> ok I get result this time
<Porfa> *happy because he made something work*
einarj has quit [Ping timeout: 260 seconds]
<shevy> what was the information you wanted to extract from that Porfa?
<Porfa> wife's calling me for dinner, srry i better go.. (lol "i better go…" )
<adaedra> ahah
<Porfa> the user/name/sex/pref/link/pic profile
<Porfa> and then, jump into the next page, and do it all over again
<shevy> well go to dinner then
einarj has joined #ruby
<Porfa> brb so sorry!!
cek has joined #ruby
<Porfa> but ur helping me arghhh shiat,, here's comes the dough roller
<Porfa> brb
<cek> Unfortunately MRI does not have good profile tooling.
kirun has quit [Quit: Client exiting]
<sacarlson> maybe this command will recompile all? gem pristine --all
<shevy> sacarlson I think this may not be available... you could try to ask on #rubygems to make sure, or file an issue request for that
ldnunes has quit [Quit: Leaving]
<sacarlson> ok good idea shevy
<shevy> gem pristine: "restores installed gems to pristine condition from files located in the gem cache"
allcentury has joined #ruby
<shevy> don't think it will recompile
<shevy> although
<shevy> perhaps it may copy back an old compilation
<shevy> -?-[no-]extensions - Restore gems with extensions in addition to regular gems
<shevy> hmm
<sacarlson> well it won't break anything so might be worth a try then
<Ox0dea> cek: How do you mean?
<cek> jruby has it, mri doesn't.
<Ox0dea> cek: There's ruby-prof, the TracePoint API, and a few others.
rideh has quit [Quit: zap]
<cek> > Sidekiq stays fast by using the JProfiler java profiler to find and fix performance problems on JRuby. Unfortunately MRI does not have good profile tooling.
christiandsg has quit [Ping timeout: 265 seconds]
gamename has quit [Remote host closed the connection]
<sacarlson> well gem pristine --all did nothing
<sacarlson> still fails
gamename has joined #ruby
Wolland has joined #ruby
gamename has quit [Remote host closed the connection]
<sacarlson> I'll check in at #rubygems
above has quit [Ping timeout: 260 seconds]
rikkipitt has quit [Quit: Leaving...]
momomomomo_ has joined #ruby
momomomomo has quit [Ping timeout: 260 seconds]
momomomomo_ is now known as momomomomo
Iskarlar has joined #ruby
sgambino has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<shevy> `gsub': incompatible encoding regexp match (ISO-8859-1 regexp with ASCII-8BIT string) (Encoding::CompatibilityError)
nofxx has joined #ruby
nofxx has joined #ruby
<shevy> cool... never had this error before
leafybasil has quit [Remote host closed the connection]
leafybasil has joined #ruby
sarkyniin has joined #ruby
mary5030 has quit [Remote host closed the connection]
mary5030 has joined #ruby
cek has left #ruby [#ruby]
<sarkyniin> is File.write(filename, content) an acceptable way of writing to a file?
<sarkyniin> what are its limitations?
<drbrain> sarkyniin: it doesn't work on ruby 1.8
leafybasil has quit [Ping timeout: 246 seconds]
<drbrain> if you have lots of data (> 100MB) you probably want to use the instance method unless it is already all in memory
<sarkyniin> drbrain: it's just at short json file
DoubleMalt has quit [Remote host closed the connection]
<drbrain> I would use File.write then
rideh has joined #ruby
riotjones has joined #ruby
<Porfa> I'm back!
<greencoder> I'm trying to create a file and fill it with contents from a template file
<greencoder> Is this a bad way of doing it? File.new('newfile.txt', 'w+').write(File.read('template.txt'))
zendrix has left #ruby [#ruby]
<Porfa> ( i said i'd wash the dishes and clean the kitchen if i could be excused…)
duggiefresh has quit [Remote host closed the connection]
chouhoul_ has joined #ruby
<Ox0dea> greencoder: Yes.
mary5030 has quit [Ping timeout: 244 seconds]
<greencoder> I figured :/
<lagweezle> greencoder: You are just copying the file, it looks like, without modifying it...?
<Ox0dea> greencoder: require 'fileutils'; FileUtils.cp 'foo', 'bar'
<greencoder> Yeah I plan on modifying it after I've copied that stuff first
<Ox0dea> You should almost certainly do your modifications before writing.
<greencoder> oh i see
<adaedra> greencoder: never do that (.new.write), as you have no close and let a resource be wasted.
EllisTAA has quit [Quit: EllisTAA]
baweaver has joined #ruby
tmtwd has quit [Ping timeout: 250 seconds]
<Ox0dea> &ri cp
<`derpy> No results
<Ox0dea> adaedra: :(
pdoherty has quit [Quit: Leaving]
yfeldblum has joined #ruby
dc has quit [Remote host closed the connection]
chouhoulis has quit [Ping timeout: 265 seconds]
riotjones has quit [Ping timeout: 260 seconds]
<adaedra> Ox0dea: I don't know about this
<Ox0dea> It's okay for the machines to be better than us at some things.
yatish27 has quit [Remote host closed the connection]
<lagweezle> 0x0dea: ri FileUtils.cp
skade has quit [Quit: Computer has gone to sleep.]
<adaedra> lagweezle: 1) it's a O (letter), not 0, at first place 2) Ox0dea uses `derpy like ri, which find something for `cp`, but `derpy doesn't
einarj has quit [Ping timeout: 250 seconds]
einarj has joined #ruby
FernandoBasso has joined #ruby
barhum2013 has joined #ruby
banjara has quit [Read error: Connection reset by peer]
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Ox0dea> `derpy should show us his guts so we can make him behave more like `ri`.
banjara has joined #ruby
dagda1 has joined #ruby
Rutix has quit []
DroidBurgundy has quit []
<adaedra> Again, the code for the rubydoc plugin is available at GitHub
rbennacer has quit [Ping timeout: 260 seconds]
rhg135 has quit [Ping timeout: 255 seconds]
einarj has quit [Read error: Connection reset by peer]
<lagweezle> That'd explain why it didn't autocomplete for me, when I typed it, adaedra.
einarj_ has joined #ruby
<Ox0dea> Oh, right. I see now that it essentially just formats a URL.
hinbody has quit [Quit: leaving]
baweaver has quit [Remote host closed the connection]
einarj_ has quit [Remote host closed the connection]
<adaedra> What would you want it to do else? :)
<Ox0dea> Well, it could be made cleverer by giving it a list of all the standard library methods.
<Ox0dea> I don't think disambiguation would be too much of a problem.
<adaedra> It has them, through yard
<adaedra> but yard lookup is different from ri's one
m8 has quit [Quit: Sto andando via]
<adaedra> I tried to use rdoc directly, but didn't do well with their library :s
pranny has quit [Remote host closed the connection]
skade has joined #ruby
WilfredTheGreat has quit [Quit: leaving]
rideh has quit [Quit: zap]
bstrarm has quit [Ping timeout: 272 seconds]
Limix has quit [Quit: Limix]
nerdoncall has quit [Ping timeout: 246 seconds]
<sacarlson> my method to fix my seg fault problem was to rm -r ~/.bundle ; bundle install ; seems to have fixed the seg fault
senayar has quit [Remote host closed the connection]
rideh has joined #ruby
phutchins has quit [Ping timeout: 255 seconds]
<nofxx> sacarlson, rm -r , solving bugs since 1971. What it doesn't solve -f does.
<sacarlson> I think the problem comes from when I bundle install ; the first time it hit a problem with some missing system dep that needed apt-get install some-dev
<adaedra> and if nothing works, just `reboot`
<shevy> then he won't be able to bring his computer up anymore!
northfurr has joined #ruby
<nofxx> sacarlson, might be... file a bug if the gem is kinda false installing
<nofxx> but just reinstalling it, with the depedencies, should fix it sacarlson
<Ox0dea> $ while :; eject -T; done
devoldmx has joined #ruby
<sacarlson> well the developer of the app didn't say it was required so
<Ox0dea> I missed a `do` in there.
stef204 has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
<sacarlson> but I'm happy thanks guys
last_staff has quit [Ping timeout: 244 seconds]
<Ox0dea> sacarlson: Perhaps you ended up with some sort of "partial compile".
<Porfa> dammit ;_; i lost my help, damn wife and the dinner
<Porfa> (i love her tho :3 )
<adaedra> heh
<sacarlson> Ox0dea: yes seems so
<sacarlson> if ever I have this problem again first try will be rm -r
leafybasil has joined #ruby
phutchins has joined #ruby
zendrix has joined #ruby
<Ox0dea> >> 'landline'.tr 'denial', '-/ fmr'
<ruboto> Ox0dea # => "rm -rf /" (https://eval.in/421639)
arescorpio has joined #ruby
<shevy> now you only need to hide a system() call there
Guest24 has quit [Ping timeout: 240 seconds]
<Ox0dea> Backticks are particularly inconspicuous in some fonts.
devoldmx has quit [Ping timeout: 260 seconds]
matcouto has joined #ruby
lele has joined #ruby
<Ox0dea> In any case, --preserve-root has been the default on modern systems for, like, a decade.
iamninja has joined #ruby
EllisTAA has joined #ruby
Musashi007 has quit [Quit: Musashi007]
_blizzy_ has quit [Ping timeout: 244 seconds]
Voker57 has quit [Remote host closed the connection]
rideh has quit [Quit: zap]
<Porfa> shevy: hello?
<jhass> easy to workaround, just rm -rf .*
choke has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
freezevee has quit [Remote host closed the connection]
<Porfa> i guess shevy's gone.. hmm well, can anyone help me accomplishing the fine task of making a loop inside a loop? it's my first time.. *wink wink*
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<jhass> loop do; loop do; puts "loop in a loop, forever"; end; end; # solved! next!
<Porfa> https://gist.github.com/anonymous/304c264127ec9185d02c here's the git, i just need to repeat the loop after it clicks "next" (last line)
<sarkyniin> uhh apparently the optionparser module
<sarkyniin> allows me to use autocompletion in shells like zsh
<sarkyniin> however, when pressing tab, nothing happens
<Porfa> yeah, but I'm missing the programers logic, so i think the problem is actually between the monitor and the chair :(
<sarkyniin> do I need to restart my shell first or something
freerobby has quit [Quit: Leaving.]
iamninja has quit [Ping timeout: 240 seconds]
<Ox0dea> sarkyniin: Erm, how do you mean?
<jhass> Porfa: what's your loop condition? when do you want to stop?
workmad3 has joined #ruby
choke has joined #ruby
<sarkyniin> Ox0dea: in the optionparser doc, they mention this: "For modern shells (e.g. bash, zsh, etc.), you can use shell completion for command line options."
<sarkyniin> However, I can't actually use shell completion with my ruby script
paulcsmith has quit [Quit: Be back later ...]
victortyau has quit [Quit: Leaving]
<Porfa> jhass: if "click next" is nil, abort?
<Porfa> (the last page has no "next ->" to click on
<Ox0dea> sarkyniin: I think that must be some sort of mistake.
<Ox0dea> OptionParser doesn't make any mention or use of readline.
<sarkyniin> oh
<sarkyniin> error on optionparser's side
<jhass> Porfa: loop do; parse_page; next_link = ...; break unless next_link; next_link.click; end;
decoponio has quit [Read error: Connection reset by peer]
<Ox0dea> sarkyniin: Well, whoever slipped that into the documentation anyhow.
sacarlson has left #ruby [#ruby]
decoponio has joined #ruby
<Ox0dea> It's true that many shells support Tab completion for arguments, but that's nothing to do with OptionParser.
<Ox0dea> Perhaps they meant to hint at the fact that you can get your script registered for completions through the appropriate channels.
<Ox0dea> I don't see why that advice should go in OptionParser's documentation, though.
valeri_uF0 has joined #ruby
momomomomo has quit [Quit: momomomomo]
Iskarlar has joined #ruby
jaycee has quit [Read error: Connection reset by peer]
jenrzzz has quit [Ping timeout: 256 seconds]
valeri_ufo has quit [Read error: Connection reset by peer]
valeri_uF0 is now known as valeri_ufo
ujjain has quit [Ping timeout: 250 seconds]
JoshGlzBrk has joined #ruby
decoponio has quit [Client Quit]
bhorn1 is now known as bhorn1|away
but3k4 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ckinniburgh_ has quit [Read error: Connection reset by peer]
_ht has quit [Quit: Konversation terminated!]
dan4352 has joined #ruby
Xiti` has joined #ruby
kies^ has quit [Ping timeout: 244 seconds]
ckinniburgh__ has joined #ruby
tubulife| has joined #ruby
zxvcd_ has joined #ruby
JoshL has quit []
ujjain has joined #ruby
ujjain has quit [Changing host]
ujjain has joined #ruby
dseitz has quit [Quit: Textual IRC Client: www.textualapp.com]
tubuliferous_ has quit [Read error: Connection reset by peer]
kidoz has quit [Quit: Ухожу я от вас]
oiwjda has joined #ruby
DLSteve has quit [Ping timeout: 255 seconds]
ckinniburgh__ has quit [Client Quit]
finisherr has quit [Quit: finisherr]
MikeKuntz has joined #ruby
<MikeKuntz> hi
anon has joined #ruby
oiwjda has left #ruby [#ruby]
<jhass> hi
anon has quit [Client Quit]
<MikeKuntz> what are good free resources to build Ruby projects with?
senayar has joined #ruby
<MikeKuntz> I'd like to learn for free while building a portfolio
zxvcd has quit [Ping timeout: 250 seconds]
Xiti has quit [Ping timeout: 250 seconds]
senayar has quit [Remote host closed the connection]
<jhass> ugh, never saw anything just Ruby that would build a project
dan4352 has quit [Remote host closed the connection]
<jhass> little OT if you don't mind, what client are you using?
<MikeKuntz> I have no clue
<jhass> how did you connect here ;)
tmtwd has joined #ruby
Spami_ has quit [Quit: This computer has gone to sleep]
anon_ has quit [Ping timeout: 245 seconds]
<MikeKuntz> via an app
<jhass> which?
<MikeKuntz> irc phone app
<jhass> name?
<MikeKuntz> turbo
dojobo has quit [Quit: Leaving]
<adaedra> TurboIRC for iOS
einarj has joined #ruby
<jhass> interesting, thanks
<jhass> always wondered where those usernames would come from
<MikeKuntz> this is my real name
<MikeKuntz> should I change to a username?
<Ox0dea> jhass: http://git.io/vsD54
<jhass> nah, not the nickname ;)
<Ox0dea> For what it's worth.
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
davedev2_ has quit []
barhum2013 has quit [Quit: barhum2013]
<shevy> jhass I wonder about your username too!
<jhass> Ox0dea: yeah, they don't appear to be unique :/
<Ox0dea> jhass: I expect they're the same person.
<jhass> shevy: I'm sure you can figure it out if you spend any effort on it
<bradland> well, that pretty much counts shevy out
<jhass> Ox0dea: nah, I've run through tons of logs, pretty sure that client's RNG just sucks
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
pen has joined #ruby
<adaedra> jhass: little ot, do you prononce it (jhass) with a german j or an english one?
<jhass> adaedra: I think I never pronounced it actually :D
cmckee has quit [Quit: cmckee]
whippythellama has quit [Quit: WeeChat 1.3]
<jhass> my real name has the german one, even though being of scandinavian origin
failshell has joined #ruby
<adaedra> Well, scandinavian j should be the same I guess
<toretore> its pronounced jazz
doug_f1 has left #ruby [#ruby]
Zai00 has quit [Quit: Zai00]
roolo has quit [Remote host closed the connection]
freerobby has joined #ruby
einarj has quit [Remote host closed the connection]
vF3hNGxc47h8 has quit [Quit: AndroIRC - Android IRC Client ( http://www.androirc.com )]
baweaver has joined #ruby
workmad3 has quit [Ping timeout: 255 seconds]
rbirch_ has joined #ruby
rbirch_ has quit [Remote host closed the connection]
duggiefresh has joined #ruby
workmad3 has joined #ruby
davedev24 has joined #ruby
rbirch has joined #ruby
<jhass> hehe
senayar has joined #ruby
<sarkyniin> is this behaviour normal?
petersaints has quit [Quit: ZNC - http://znc.in]
<jhass> sarkyniin: yes, String#delete has String#count semantics
failshell has quit [Remote host closed the connection]
araujo_ has joined #ruby
cmckee has joined #ruby
riotjones has joined #ruby
phutchins has quit [Ping timeout: 240 seconds]
Gribo has quit [Read error: Connection reset by peer]
matcouto has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
araujo_ has quit [Max SendQ exceeded]
<sarkyniin> jhass: how would I go about achieving what I want in a single command?
<sarkyniin> preferably without using regex
<jhass> you didn't specify what you want
Limix has joined #ruby
araujo has quit [Ping timeout: 246 seconds]
whiteline has quit [Remote host closed the connection]
<sarkyniin> deleting two separate substrings from a string
arooni-mobile has joined #ruby
<jhass> use a regex
_djbkd has quit [Remote host closed the connection]
rbirch has quit [Quit: rbirch]
ishahnaz has joined #ruby
whiteline has joined #ruby
juanpaucar has quit []
<jhass> >> "hello".gsub(Regexp.union("he", "lo"), "")
<ruboto> jhass # => "l" (https://eval.in/421642)
<Ox0dea> sarkyniin: Do you need to actually remove substrings, or just characters?
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<sarkyniin> just characters, Ox0dea
<Ox0dea> >> 'hello'.delete 'el'
<sarkyniin> jhass: I guess I'll do that
<ruboto> Ox0dea # => "ho" (https://eval.in/421643)
riotjones has quit [Ping timeout: 244 seconds]
<jhass> sarkyniin: nah, check Ox0dea's reply. I assumed you checked what String#count semantic actually means and know what you're talking about when saying substring
[Butch] has quit [Quit: Linkinus - http://linkinus.com]
<sarkyniin> jhass: sorry
<sarkyniin> yeah Ox0dea that works
<Ox0dea> jhass: Precious few people actually use "substring" correctly.
<Ox0dea> Alas, it's easier to just pretend I don't know the technically correct definition. :/
nonnatus has quit [Ping timeout: 260 seconds]
<jhass> Ox0dea: well, I assumed in this context the difference between character and substring would be obvious
<jhass> but my bad, yeah
j_mcnally has joined #ruby
veduardo has joined #ruby
<shevy> bradland haha yeah
_djbkd has joined #ruby
duggiefresh has quit [Read error: Connection reset by peer]
DifferentLambda has joined #ruby
havenwood has joined #ruby
duggiefresh has joined #ruby
dgutierrez1287 has joined #ruby
Limix has quit [Ping timeout: 264 seconds]
phutchins has joined #ruby
j_mcnally has quit [Client Quit]
MikeKuntz has quit [Remote host closed the connection]
bruno- has quit [Ping timeout: 260 seconds]
JoshGlzBrk has quit [Quit: Textual IRC Client: www.textualapp.com]
Limix has joined #ruby
veduardo has quit [Ping timeout: 240 seconds]
dgutierrez1287 has quit [Ping timeout: 245 seconds]
devdazed has quit [Ping timeout: 244 seconds]
sshuff is now known as sshuff|gone
christiandsg has joined #ruby
mkopriva has quit []
DifferentLambda is now known as rhg135
Torrieri has joined #ruby
Torrieri has joined #ruby
milesforrest has quit [Quit: Textual IRC Client: www.textualapp.com]
<EllisTAA> i don’t get how a server can handle thousands of users @ once … can someone explain how companies handle such large traffic? do they create multiple servers?
finisherr has joined #ruby
<eam> EllisTAA: generally yes
<EllisTAA> Ox0dea: thanks
<eam> a single server can serve between 1 and 100_000 clients at once depending on the kind of server
<eam> most scalable services run across many, many machines
<baweaver> and most of the time they're behind what's called a load balancer
<EllisTAA> eam: so if me and 99,999 other people update our status, we should get a response from the server in less than a second
<baweaver> that intelligently forwards traffic to servers based on load
<EllisTAA> baweaver: thanks
<baweaver> Typically some form of proxy combination of NginX, squid, or other such tools depending on stack,
christiandsg has quit [Ping timeout: 265 seconds]
<EllisTAA> what is this field or area of programming called?
Dzejmskrokan has joined #ruby
<baweaver> DevOps
<eam> EllisTAA: sure. If you're talking about something like facebook, what you'll have is a large number of frontend systems doing the page rendering and some kind of sharded datastore on the backend
<havenwood> EllisTAA: There are many ways. Here's an Erlang example that might be fun to look at: http://www.erlang-factory.com/upload/presentations/558/efsf2012-whatsapp-scaling.pdf
<baweaver> or Infrastructure Engineering.
<havenwood> EllisTAA: Or do you mean Ruby specifically?
<baweaver> I happen to work in an odd intersection between DevOps, Infrastructure, and straight Web Dev
<eam> havenwood: is that the rick reed presentation?
dagda1 has quit [Ping timeout: 255 seconds]
<havenwood> eam: ayup
<eam> he's fantastic
<EllisTAA> interesting. i guess i’m trying to get a job in web dev, but i’m interested in devops
<baweaver> I once got nailed in College for referring to Erlang and FP as a solution to mutex issues.
zenguy_pc has quit [Ping timeout: 245 seconds]
<baweaver> DevOps can be brutal
<eam> EllisTAA: many smaller companies can go for quite some time before they need to scale certain components
<eam> a single database is a very very common architecture
dagda1 has joined #ruby
<havenwood> Hundreds of connections per hour! ;)
<baweaver> source: I've been in DevOps for 4 years, and am not exactly fond of it.
<EllisTAA> eam: gotcha. thanks
<havenwood> *day
<EllisTAA> baweaver: why not
<baweaver> I'd be lucky to see 100 a second
<EllisTAA> baweaver: sounds bad ass
<baweaver> Chef, for one
veduardo has joined #ruby
charliesome has joined #ruby
* baweaver chuckles at badass reference
<eam> hah
<havenwood> hehe
millerti has quit [Read error: Connection reset by peer]
<baweaver> fine fine, clarification
<EllisTAA> lol
<baweaver> My team name is BaDASS -> Build and Deployment Automation Support System.
<baweaver> So I can legitimately say I'm a badass developer on my resume if I want to.
<EllisTAA> lol
<bootstrappm> hahah thats great
cmckee has quit [Quit: cmckee]
cschneid_ has quit [Remote host closed the connection]
<eam> speaking of load balancers - there's also a point where you have more traffic than can be pushed through one
<eam> this is a much, much higher bar; most companies probably don't reach this point
<baweaver> eam: shhh, you'll scare them
<baweaver> that stuff is the stuff of nightmares.
<EllisTAA> eam: so i dont need to start worrying about having multiple servers until i get a couple thousand users?
<havenwood> it's much easier without users
<eam> EllisTAA: it entirely depends on what kind of server you have and how expensive it is to serve a query
<shevy> the world would be easier without users!
<EllisTAA> eam: gotcha
<eam> working out capacity models and growth plans is all part of the game
<Aeyrix> baweaver: I didn't realise Sony ever named anything that edgy.
<eam> "we'll just put the database on a fusionio"
jtdoncas_ has quit [Ping timeout: 265 seconds]
<baweaver> internal tools
charliesome has quit [Client Quit]
<EllisTAA> eam: what do i search to learn more about this stuff
<Aeyrix> Ah.
<eam> EllisTAA: honestly best way is to get a job and get paid to learn it :)
<bootstrappm> EllisTAA what kind of app are you talking about / building?
C1V0 has quit []
_djbkd has quit [Remote host closed the connection]
<eam> EllisTAA: ##infra-talk is a pretty good channel on freenode for this stuff
charliesome has joined #ruby
<bootstrappm> or you want to learn about the devops part of it?
<EllisTAA> eam: do you know anyone in sf that’s hiring?
<eam> EllisTAA: indeed - perhaps a better question is who isn't ;-)
<bootstrappm> hahahaha that's a good joke
sargas has quit [Quit: This computer has gone to sleep]
<bootstrappm> exactly
<EllisTAA> eam: lol well who’s hiring jr devs!
<bootstrappm> skill level is high though
<bootstrappm> yes, better question
dfockler has quit [Remote host closed the connection]
<eam> EllisTAA: intern programs are a great place to start
<eam> SF interns earn 70-90k so
<EllisTAA> eam: ahh yes i applied to 1. any suggestions on where to apply?
<BraddPitt> EllisTAA take a look at HN "Who's Hiring" threads, angel.co and various ruby job boards
<BraddPitt> i think rubyweekly has a pretty good job board for that
<BraddPitt> otherwise, just search indeed.com with 'ruby' and 'intern' or 'junior dev' keywords
_djbkd has joined #ruby
<eam> well, you could send me your resume if you want. I'd be happy to drop you in our system. try also hn "who's hiring" threads, craigslist
veduardo has quit [Ping timeout: 245 seconds]
<BraddPitt> PLENTY of positions in the bay area
<BraddPitt> where are you located, EllisTAA ?
<EllisTAA> BraddPitt: san fran
<BraddPitt> perfect!
<EllisTAA> thanks ill check out all of those
<BraddPitt> also, you can join the Ruby/RoR Hiring meetups
<EllisTAA> BraddPitt: i missed the last one, ill check em out on meetup.com
<nickjj> are any of you ops knowledge seekers interested in learning more about docker?
_djbkd has quit [Remote host closed the connection]
<EllisTAA> eam: how can i send you my resume?
<eam> messaged you my email
<bootstrappm> me nickjj! I use it in development
<nickjj> bootstrappm, <shameless plug> i recently published a book on using docker for development and production
<bootstrappm> I figured it would be ;) send the link anyways, never know who might find it useful
_blizzy_ has joined #ruby
<nickjj> the cool thing to me is that it's very decoupled from whatever language your web app is written in. you can apply it to anything
zendrix has quit []
_djbkd has joined #ruby
dc has joined #ruby
System42 has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
gregf has quit [Quit: WeeChat 1.1.1]
kies has quit [Ping timeout: 255 seconds]
kies has joined #ruby
_djbkd has quit [Remote host closed the connection]
zenguy_pc has joined #ruby
System42 has quit [Client Quit]
NeverDie has joined #ruby
krz has quit [Quit: WeeChat 1.2]
BTRE has quit [Remote host closed the connection]
_djbkd has joined #ruby
michaeldeol has joined #ruby
BTRE has joined #ruby
_blizzy_ has quit [Read error: Connection reset by peer]
sarkyniin has quit [Ping timeout: 272 seconds]
Limix has quit [Quit: Limix]
BTRE has quit [Remote host closed the connection]
j_mcnally has joined #ruby
DLSteve has joined #ruby
_djbkd has quit [Remote host closed the connection]
sarkyniin has joined #ruby
sgambino has joined #ruby
_blizzy_ has joined #ruby
BTRE has joined #ruby
JimmyNeutron has joined #ruby
blackmesa has joined #ruby
finisherr has quit [Quit: finisherr]
snockerton has quit [Quit: Leaving.]
<craysiii> nickjj what was it like publishing a book?
<nickjj> craysiii, a lot less tedious than screencasts. that's for sure
fumihiro has joined #ruby
sgambino has quit [Ping timeout: 272 seconds]
tjohnson has quit [Quit: Connection closed for inactivity]
<nickjj> overall not too bad, it's only in digital form at the moment
<craysiii> self published?
whiteline has quit [Remote host closed the connection]
workmad3 has quit [Ping timeout: 245 seconds]
<nickjj> yeah
kr3ssh has quit [Ping timeout: 264 seconds]
tkuchiki has joined #ruby
<craysiii> congratulations with that, seems like a good accomplishment to make
whiteline has joined #ruby
Ropeney has joined #ruby
_djbkd has joined #ruby
_djbkd has quit [Remote host closed the connection]
<nickjj> craysiii, thanks. were you interested in publishing one yourself?
phutchins has quit [Ping timeout: 252 seconds]
<craysiii> i am nowhere near proficient enough in anything to write a book about it. When i was tutoring comsci / C++ I had thought about making a short pamphlet for my students, but never got really far.
blue_deref has quit [Quit: bbn]
<shevy> the laziness factor
SCHAAP137 has quit [Quit: Leaving]
tkuchiki has quit [Remote host closed the connection]
_djbkd has joined #ruby
<craysiii> that more than anything.
_djbkd has quit [Remote host closed the connection]
<bricker> Can someone do me a favor and copy this into a gist? I want to share it with coworkers but pastebin is blacklisted http://pastebin.com/BjD84BQ3
<ruboto> bricker, we in #ruby do not like pastebin.com, it loads slowly for most, has ads which are distracting and has terrible formatting. Please use https://gist.github.com
_djbkd has joined #ruby
chipotle has joined #ruby
<nickjj> it does take a bit of effort, but if you keep it under 100 pages or so it doesn't have a chance to get really hand out of hand
<shevy> lol
<bricker> It's the "Amazon Programmer's Perspective" article
<shevy> ruboto for the auto-win
<bricker> :P
<shevy> oh wait
<shevy> why does it not turn it into a gist?
<bricker> shevy: dunno, maybe it's too big?
<bricker> it's not *that* big
<craysiii> thats what ruboto said /s
tkuchiki has joined #ruby
<shevy> well that was strange... ruboto normally auto-gists upon pastebin
<bricker> shevy: thanks!
<craysiii> ruboto no feel well today.
<shevy> >> [].all? {|number| number =~ /\d+/ }
<ruboto> shevy # => true (https://eval.in/421653)
<shevy> can someone explain this to me?
jgt has quit [Ping timeout: 260 seconds]
chipotle has quit [Max SendQ exceeded]
fumihiro has quit [Quit: leaving]
<shevy> hmm
gambl0re has joined #ruby
yfeldblu_ has joined #ruby
<Radar> shevy: All the elements in the array match the block.
[H]unt3r has joined #ruby
<Radar> >> [].all? { }
<ruboto> Radar # => true (https://eval.in/421654)
<pipework> shevy: All the ^
<Aeyrix> >> [1,2,3,4,5].all? {|number| number =~ /\d+/ }
<craysiii> makes sense semantically
<ruboto> Aeyrix # => false (https://eval.in/421655)
<Aeyrix> >> ['1', '2', '3'].all? {|number| number =~ /\d+/ }
<ruboto> Aeyrix # => true (https://eval.in/421656)
<Aeyrix> wew
<shevy> damn
tkuchiki has quit [Remote host closed the connection]
<shevy> thanks
<Radar> np
<Aeyrix> >> ['1', '2', '3', 'tbh'].all? {|number| number =~ /\d+/ }
<ruboto> Aeyrix # => false (https://eval.in/421657)
hooper1 has left #ruby [#ruby]
<pipework> %w my friend
riotjones has joined #ruby
<Aeyrix> \d on fixnum tbh
<pipework> >> %w|1 2 3 woot|
<ruboto> pipework # => ["1", "2", "3", "woot"] (https://eval.in/421658)
yashinbasement has joined #ruby
<Ox0dea> shevy: #all? optimistically starts the search with the result set to `true` and only changes it to `false` if an element doesn't match.
roolo has joined #ruby
yfeldblum has quit [Ping timeout: 244 seconds]
<shevy> ok
petersaints has joined #ruby
<Ox0dea> Aeyrix: %w[1 2 3].all?(/\d+/), amirite?
Liam` has quit [Ping timeout: 244 seconds]
<Aeyrix> ugh
<pipework> Ox0dea: you certainly aint left!
<Ox0dea> Aeyrix: Really?
<Aeyrix> Ox0dea: My problem is more to do with the data type issue.
<Aeyrix> Not really an "issue" given regex's purpose
<Aeyrix> but I've run into it a few times.
<Ox0dea> I don't follow.
<Aeyrix> >> 5.class
<ruboto> Aeyrix # => Fixnum (https://eval.in/421659)
<Aeyrix> >> "5".class
<ruboto> Aeyrix # => String (https://eval.in/421660)
<Ox0dea> I meant that it would be nice if #all? and friends used case equality?
<Aeyrix> You can perform a regex substitution that will work correctly on only one of those.
riotjones has quit [Ping timeout: 250 seconds]
Swappticon has joined #ruby
roolo has quit [Ping timeout: 245 seconds]
<Aeyrix> Now I think about it I forget what the hell I must've been doing to have encountered a Fixnum while performing a regex operation.
<Aeyrix> I must've been seriously breaking something.
<Ox0dea> >> '' =~ //
<ruboto> Ox0dea # => 0 (https://eval.in/421661)
<Aeyrix> >> "535353535" =~ /\d+/
_aeris_ has quit [Ping timeout: 244 seconds]
<ruboto> Aeyrix # => 0 (https://eval.in/421662)
loop3r has quit [Ping timeout: 246 seconds]
<Aeyrix> thanks fam
<Ox0dea> For real, though: https://bugs.ruby-lang.org/issues/11286
jaycee has joined #ruby
loop3r has joined #ruby
<eam> why does fixnum have a =~ method anyway, if it doesn't stringify self?
Liam` has joined #ruby
<shevy> hmm
<eam> what the heck does it do
ledestin has joined #ruby
<drbrain> Object has #=~
_aeris_ has joined #ruby
<eam> that's weird
<drbrain> generically, =~ is "match"
<eam> is it valid for anything other than String?
<Aeyrix> Not really.
chipotle has joined #ruby
<Aeyrix> Not anything that isn't stringified.
<drbrain> I've implemented it on objects before
Meow-J has quit [Ping timeout: 250 seconds]
bove has quit [Ping timeout: 250 seconds]
bjmllr has quit [Read error: Connection reset by peer]
calleerlandsson has quit [Read error: Connection reset by peer]
nahtnam has quit [Read error: Connection reset by peer]
<eam> >> class Fixnum; def =~(x); self.to_s =~ x; end; end; 1234 =~ /23/
<ruboto> eam # => 1 (https://eval.in/421663)
nyandoge has quit [Read error: Connection reset by peer]
ggherdov has quit [Read error: Connection reset by peer]
ELCALOR has quit [Read error: Connection reset by peer]
spider-mario has quit [Remote host closed the connection]
<drbrain> by default it returns nil
bjmllr has joined #ruby
<eam> seems like it oughta be defined on String since it's meaningless for other classes
nux443 has quit [Ping timeout: 260 seconds]
DLSteve has quit [Quit: Leaving]
nahtnam has joined #ruby
kr3ssh has joined #ruby
nyandoge has joined #ruby
calleerlandsson has joined #ruby
dagda1 has quit [Ping timeout: 264 seconds]
ngscheurich has joined #ruby
<Ox0dea> It's also defined on Regexp.
bove has joined #ruby
nux443 has joined #ruby
ELCALOR has joined #ruby
<eam> Ox0dea: yeaaaaah
<Ox0dea> Qua?
<drbrain> you can use it any time you have pattern
<drbrain> pattern =~ object or object =~ pattern
barajasfab has joined #ruby
<eam> not a fan of that behavior :)
AlphaAtom has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ngscheur1 has quit [Ping timeout: 256 seconds]
<drbrain> Regexp#=~ already works with everything implementing #to_str
<eam> drbrain: really? I get a TypeError
Wolland has quit []
<craysiii> >> [false, false].all? { |f| f =~ /true/ }
<ruboto> craysiii # => false (https://eval.in/421668)
kr3ssh has quit [Ping timeout: 246 seconds]
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
greencoder has quit [Remote host closed the connection]
Dzejmskrokan has quit []
Meow-J has joined #ruby
<drbrain> >> o = Object.new; def o.to_str; "dog"; end; p /dog/ =~ o
<ruboto> drbrain # => 0 ...check link for more (https://eval.in/421669)
<eam> oh, to_str not to_s
<drbrain> yeah
ggherdov has joined #ruby
yashinbasement has quit [Quit: Leaving]
<eam> yeah ok :)
<drbrain> with #to_s would be a bizarro-world
maletor has quit [Read error: Connection reset by peer]
devoldmx has joined #ruby
<eam> I see, if it's keyed off to_str that makes sense
barajasfab has left #ruby [#ruby]
workmad3 has joined #ruby
ishahnaz has quit []
devoldmx has quit [Ping timeout: 244 seconds]
d10n-work has quit [Quit: Connection closed for inactivity]
gregf has joined #ruby
chipotle has quit [Max SendQ exceeded]
Feyn has joined #ruby
rcvalle has quit [Quit: rcvalle]
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
iamninja has joined #ruby
jiada has joined #ruby
chipotle has joined #ruby
rehat has quit [Remote host closed the connection]
cyberarm has joined #ruby
iamninja has quit [Ping timeout: 255 seconds]
JoshuaPaling has joined #ruby