lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
sunslide has joined #ruby-lang
<sunslide>
hi guys, is there a way for me to tell ruby to create subkeys in a hash if they don't exist? something like h['key']['subkey'] = value where 'subkey' doesn't exist but I would ruby to create it with the value given
kaczmar has quit [Quit: kaczmar]
jxie_ has joined #ruby-lang
jxie has quit [Ping timeout: 245 seconds]
<ledestin>
sunslide: what prevents you from doing it now?
<sunslide>
a NoMethodError because 'subkey' doesn't exist
michael_mbp has quit [Excess Flood]
<ledestin>
sunslide: it’s more likely, subhash doesn’t exist
<ledestin>
‘subkey’ is not a method
<ledestin>
sunslide: are you coming from JS?
<yorickpeterse>
morning
<sunslide>
not really :) I'll rephrase: I'd like ruby to create all subkeys "on the way" to the value that don't exist
michael_mbp has joined #ruby-lang
<sunslide>
the NoMethodError is because 'key' doesn't exist as well, and I would like ruby to create it
<ruby-lang407>
~/p/milaap-webapp ❯❯❯ which ruby /Users/jitendra/.rbenv/shims/ruby ~/p/milaap-webapp ❯❯❯ which rails /Users/jitendra/.rbenv/shims/rails
tbuehlmann has quit [Remote host closed the connection]
tbuehlmann has joined #ruby-lang
<JodyTheBad>
I'm really really green, but if I google "get_peer_cert" and "can't allocate memory" then I find this site referencing a memory leak in a get_peer_cert call. You aren't really running out of memory, though, are you?
<imperator>
ruby-lang407, how was this ruby built?
tkuchiki has quit [Remote host closed the connection]
tkuchiki has joined #ruby-lang
bradcliffe has quit [Remote host closed the connection]
GBrawl has quit [Ping timeout: 260 seconds]
stamina has joined #ruby-lang
<imperator>
mm, looks like eventmachine, and some posts indicate it's dead
cmhobbs has joined #ruby-lang
<imperator>
can you switch to celluloid?
ruskie has quit [Ping timeout: 250 seconds]
tkuchiki has quit [Ping timeout: 245 seconds]
ruskie has joined #ruby-lang
ruskie has quit [Excess Flood]
ruby-lang407 has quit [Ping timeout: 246 seconds]
whippythellama has joined #ruby-lang
j4cknewt has joined #ruby-lang
gnufied has quit [Ping timeout: 265 seconds]
jgpawletko_mtg is now known as jgpawletko
chris2 has quit [Ping timeout: 272 seconds]
loincloth has joined #ruby-lang
gnufied has joined #ruby-lang
tenderlove has joined #ruby-lang
Squarepy has quit [Quit: Leaving]
enebo has joined #ruby-lang
miqui has quit [Ping timeout: 250 seconds]
Guest7 has joined #ruby-lang
oleo has joined #ruby-lang
j4cknewt has quit [Remote host closed the connection]
joast has quit [Quit: Leaving.]
Austin__ has quit [Quit: Leaving.]
miqui has joined #ruby-lang
tkuchiki has joined #ruby-lang
bradcliffe has joined #ruby-lang
havenwood has joined #ruby-lang
allomov has quit [Remote host closed the connection]
gss has joined #ruby-lang
ruskie has joined #ruby-lang
benlovell has joined #ruby-lang
riffraff has joined #ruby-lang
q_leonetti has joined #ruby-lang
kaczmar has joined #ruby-lang
tkuchiki has quit [Remote host closed the connection]
fragamus has joined #ruby-lang
tkuchiki has joined #ruby-lang
chris2_ has joined #ruby-lang
chris2_ is now known as chris2
skade has quit [Quit: Computer has gone to sleep.]
tkuchiki has quit [Ping timeout: 250 seconds]
SuMo_D has quit [Remote host closed the connection]
[spoiler] has quit [Quit: Leaving]
momomomomo has joined #ruby-lang
joast has joined #ruby-lang
tkuchiki has joined #ruby-lang
shinnya has quit [Ping timeout: 245 seconds]
marr has quit [Ping timeout: 244 seconds]
jarto has joined #ruby-lang
<yorickpeterse>
Today I awared myself the "Dumbest programmer of the year award"
<yorickpeterse>
for disabling code by overwriting a method with a tracer
<yorickpeterse>
and then not calling the original method
cih has joined #ruby-lang
cih has quit [Client Quit]
mistym has joined #ruby-lang
ducklobster has joined #ruby-lang
mikecmpb_ has joined #ruby-lang
<Senjai>
yorickpeterse: Its k, I wrote a method that called itself without realizing it and spent forever trying to understand why I was getting stack level too deep all the time
<yorickpeterse>
well, I had angry customers as a result
<yorickpeterse>
place your bets :P
mikecmpbll has quit [Read error: Connection reset by peer]
<Senjai>
:P
<Senjai>
Yea
<Senjai>
mine didnt make it to prod
<Senjai>
:P
tkuchiki has quit [Remote host closed the connection]
tkuchiki has joined #ruby-lang
tkuchiki has quit [Ping timeout: 240 seconds]
nelsonsar has joined #ruby-lang
nelsonsar has quit [Remote host closed the connection]
nelsonsar has joined #ruby-lang
allomov has joined #ruby-lang
ender|dkm has quit [Ping timeout: 255 seconds]
kiddorails has quit [Remote host closed the connection]
<imperator>
yorickpeterse, isn't that what refinements are for?
nelsonsar has quit [Remote host closed the connection]
q_leonetti has quit [Quit: q_leonetti]
mattyohe has joined #ruby-lang
momomomomo has quit [Ping timeout: 255 seconds]
momomomomo_ has joined #ruby-lang
jarto has quit [Quit: Ухожу я от вас (xchat 2.4.5 или старше)]
<yorickpeterse>
imperator: you watch your mouth
nelsonsar has joined #ruby-lang
<imperator>
sorry man, just trying to be helpful :)
<yorickpeterse>
refinements...pfft
<yorickpeterse>
also no they wouldn't help, since they'd overwrite the method in similar fashion
<imperator>
ah, ok
JohnBat26 has quit [Ping timeout: 265 seconds]
tenderlove has quit [Remote host closed the connection]
tenderlove has joined #ruby-lang
|jemc| has joined #ruby-lang
dagda1 has joined #ruby-lang
<yorickpeterse>
basically I did `def foo; ...; end` instead of `def foo; original_foo; end`
tkuchiki has joined #ruby-lang
dagda1 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
gdave_ has quit [Ping timeout: 245 seconds]
futilegames has quit [Quit: futilegames]
momomomomo_ has quit [Quit: momomomomo_]
enebo has quit [Quit: enebo]
miqui has quit [Ping timeout: 244 seconds]
miqui_ has joined #ruby-lang
michael_mbp has quit [Excess Flood]
enebo has joined #ruby-lang
bradcliffe has quit [Ping timeout: 255 seconds]
* imperator
looks up how super works with refinemenets
nelsonsar has quit [Remote host closed the connection]
michael_mbp has joined #ruby-lang
__butch__ has joined #ruby-lang
whippythellama has quit [Quit: whippythellama]
mistym has quit [Remote host closed the connection]
nelsonsar has joined #ruby-lang
whippythellama has joined #ruby-lang
|jemc| has quit [Quit: WeeChat 1.0.1]
fragamus has quit [Quit: Computer has gone to sleep.]
benlovell has quit [Ping timeout: 255 seconds]
imkmf has joined #ruby-lang
thagomizer has joined #ruby-lang
goodcodeguy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mistym has joined #ruby-lang
tkuchiki has quit [Remote host closed the connection]
tkuchiki has joined #ruby-lang
bradcliffe has joined #ruby-lang
bradcliffe has quit [Remote host closed the connection]
miqui_ has quit [Ping timeout: 244 seconds]
tkuchiki has quit [Ping timeout: 250 seconds]
kaczmar has quit [Quit: kaczmar]
theotherstupidgu has quit [Quit: leaving]
theotherstupidgu has joined #ruby-lang
apeiros has quit [Remote host closed the connection]
apeiros has joined #ruby-lang
ledestin_ has joined #ruby-lang
SuMo_D has joined #ruby-lang
michaeldeol has joined #ruby-lang
pastuxso has joined #ruby-lang
ledestin has quit [Ping timeout: 256 seconds]
ledestin_ is now known as ledestin
apeiros has quit [Ping timeout: 256 seconds]
jimbach has quit [Remote host closed the connection]
benlovell has joined #ruby-lang
benlovell has quit [Ping timeout: 265 seconds]
nofxx_ has joined #ruby-lang
nofxx_ has joined #ruby-lang
djbkd has joined #ruby-lang
jxpx777_ has joined #ruby-lang
nelsonsar has quit [Remote host closed the connection]
koderok has joined #ruby-lang
emmesswhy has joined #ruby-lang
goodcodeguy has joined #ruby-lang
nelsonsar has joined #ruby-lang
mkaesz has quit [Remote host closed the connection]
wallerdev has joined #ruby-lang
hellangel7 has quit [Remote host closed the connection]
danijoo_ has quit [Remote host closed the connection]
danijoo has joined #ruby-lang
parenjitsu has joined #ruby-lang
qba73 has quit [Remote host closed the connection]
kaczmar has joined #ruby-lang
qba73 has joined #ruby-lang
RobertBirnie has joined #ruby-lang
apeiros has joined #ruby-lang
imperator has quit [Quit: Valete!]
RobertBi_ has joined #ruby-lang
qba73 has quit [Ping timeout: 250 seconds]
RobertBirnie has quit [Ping timeout: 272 seconds]
ender|dkm has joined #ruby-lang
David_H_Smith has quit []
GBrawl has joined #ruby-lang
jimbach has joined #ruby-lang
charliesome has joined #ruby-lang
fusillicode has quit [Ping timeout: 264 seconds]
mikecmpb_ is now known as mikecmpbll
danijoo_ has joined #ruby-lang
danijoo has quit [Ping timeout: 250 seconds]
charliesome has quit [Client Quit]
David_H_Smith has joined #ruby-lang
David_H_Smith has quit [Remote host closed the connection]
arBmind1 has joined #ruby-lang
David_H_Smith has joined #ruby-lang
mikecmpbll has quit [Quit: i've nodded off.]
<nofxx_>
Need to trap SIGTERM, and some threads and loop will stop gracefully, always used $terminate, $finish globals... trying to get rubocop friendly, what's the better option in this case?
arBmind has quit [Ping timeout: 265 seconds]
<jhass>
make subclasses of Thread that have such flags as attribute
<nofxx_>
jhass, and how to change that flag on each instance?
<jhass>
depends on how they're created
q_leonetti has joined #ruby-lang
tbuehlmann has quit [Remote host closed the connection]
<nofxx_>
ok, but I'will need to change it one by one .. threads.each(&:terminate!) or something
<nofxx_>
you mean?
<jhass>
could be one example
<jhass>
maybe some thread knows others and passes the message on
<jhass>
maybe some don't even need to be informed but just don't get any new work
<jhass>
and so on
<nofxx_>
jhass, got it, thank you
<jhass>
actually I think Thread even ships such a flag
workmad3 has quit [Ping timeout: 255 seconds]
<nofxx_>
or maybe simplify and just wait in the main loop... my program is just Module.run! will use just a class var on Module
yfeldblum has joined #ruby-lang
yfeldblum has quit [Remote host closed the connection]
yfeldblum has joined #ruby-lang
nysthee has joined #ruby-lang
nysthee has quit [Client Quit]
q_leonetti has quit [Quit: q_leonetti]
nelsonsar has quit [Remote host closed the connection]
solars has joined #ruby-lang
q_leonetti has joined #ruby-lang
carraroj has joined #ruby-lang
marr has joined #ruby-lang
goodcodeguy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
gss has quit [Remote host closed the connection]
danijoo_ has quit [Read error: Connection reset by peer]
bradcliffe has joined #ruby-lang
danijoo has joined #ruby-lang
emmesswhy has quit [Quit: This computer has gone to sleep]
symm- has joined #ruby-lang
benlovell has joined #ruby-lang
jimbach has quit [Remote host closed the connection]
<havenwood>
masterkorp: any particular way you're wanting to compare them?
<apeiros>
masterkorp: you stare at them long and hard
t4nk907 has joined #ruby-lang
<apeiros>
maybe draw them on different papers. put the paper on top of each other. let light shine through.
MichD is now known as michd
<t4nk907>
I've heard that I can create web applications using Ruby on Rails, and that websites like GitHub run them. However, I don't quite get how the actual websites are made? Do I still have to use the good ol' HTML and CSS?
<apeiros>
t4nk907: yes
<apeiros>
all websites in the end are html. and usually css. and very often js.
<apeiros>
there are just a bazillion different ways to create or generate those.
sepp2k has quit [Quit: Konversation terminated!]
<t4nk907>
Do I still have to use JS and PHP, or does RoR replace them?
<apeiros>
PHP is one of the ways to generate html (and sometimes js or css)
<apeiros>
RoR is another way to generate html/css/js
<havenwood>
t4nk907: By default you'd use CoffeeScript instead of JavaScript and Ruby instead of PHP. The Rails channel is #rubyonrails by the way, nick registration required: /msg NickServ HELP REGISTER
<t4nk907>
Really? Doesn't that mean I can make the whole website in RoR?
<t4nk907>
havenwood: Thanks, I'll remember that to when I get started.
mistym has quit [Remote host closed the connection]
GBrawl has quit [Quit: (null)]
<t4nk907>
One final question: Is it fun?
sepp2k has joined #ruby-lang
bradcliffe has quit [Remote host closed the connection]
<apeiros>
can you define "fun" in objective quantities?
<havenwood>
t4nk907: Ruby can be great fun.
<apeiros>
IMO the difference between php and rails is similar as between walking on glass shards vs. on tarmac (both barefoot)
sepp2k has quit [Client Quit]
cmhobbs has quit [Ping timeout: 250 seconds]
nelsonsar has quit [Remote host closed the connection]
nelsonsar has joined #ruby-lang
yfeldblum has joined #ruby-lang
cmhobbs has joined #ruby-lang
cmhobbs has quit [Changing host]
cmhobbs has joined #ruby-lang
cmhobbs has quit [Client Quit]
cmhobbs has joined #ruby-lang
cmhobbs has quit [Changing host]
cmhobbs has joined #ruby-lang
wallerdev_ has joined #ruby-lang
wallerdev has quit [Ping timeout: 250 seconds]
wallerdev_ is now known as wallerdev
<masterkorp>
apeiros: lol
fragamus has joined #ruby-lang
emmesswhy has quit [Quit: This computer has gone to sleep]
emmesswhy has joined #ruby-lang
t4nk907 has quit [Ping timeout: 246 seconds]
__butch__ has quit [Quit: Leaving.]
sepp2k has joined #ruby-lang
goodcodeguy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mistym has joined #ruby-lang
robbyoconnor has joined #ruby-lang
oleo is now known as Guest39128
oleo__ has joined #ruby-lang
allomov has quit [Remote host closed the connection]
oleo__ has quit [Read error: Connection reset by peer]
oleo__ has joined #ruby-lang
Guest39128 has quit [Ping timeout: 260 seconds]
oleo__ is now known as oleo
goodcodeguy has joined #ruby-lang
goodcodeguy has quit [Client Quit]
allomov has joined #ruby-lang
allomov has quit [Ping timeout: 255 seconds]
bradcliffe has joined #ruby-lang
jxpx777_ has quit [Quit: Leaving...]
quimrstorres has quit [Ping timeout: 260 seconds]
tkuchiki has joined #ruby-lang
bradcliffe has quit [Remote host closed the connection]
jgpawletko has quit [Quit: jgpawletko]
michael_mbp has quit [Excess Flood]
nelsonsar has quit [Remote host closed the connection]
existensil has quit [Ping timeout: 258 seconds]
michael_mbp has joined #ruby-lang
malconis_ has joined #ruby-lang
ikrima has joined #ruby-lang
dagda1 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
diegoviola has joined #ruby-lang
malconis has quit [Ping timeout: 258 seconds]
nelsonsar has joined #ruby-lang
cornerma1 has joined #ruby-lang
GBrawl has joined #ruby-lang
mistym has quit [Remote host closed the connection]
benlovell has joined #ruby-lang
cornerman has quit [Ping timeout: 244 seconds]
cornerma1 is now known as cornerman
djbkd has quit [Remote host closed the connection]
bradcliffe has joined #ruby-lang
benlovell has quit [Ping timeout: 256 seconds]
fragamus has quit [Quit: Computer has gone to sleep.]
DEac- has quit [Quit: leaving]
DEac- has joined #ruby-lang
fragamus has joined #ruby-lang
Lewix has quit [Remote host closed the connection]
kaczmar has quit [Quit: kaczmar]
fragamus has quit [Read error: Connection reset by peer]
quimrstorres has joined #ruby-lang
quimrstorres has quit [Read error: Connection reset by peer]
mistym has joined #ruby-lang
djbkd has joined #ruby-lang
emmesswhy has quit [Ping timeout: 256 seconds]
djbkd has quit [Remote host closed the connection]
robbyoconnor has quit [Quit: Konversation terminated!]
r0bby has joined #ruby-lang
GBrawl has quit [Ping timeout: 260 seconds]
shinnya has joined #ruby-lang
cmhobbs has quit [Remote host closed the connection]
r0bby has quit [Quit: Konversation terminated!]
r0bby has joined #ruby-lang
cleopatra has joined #ruby-lang
whippythellama has quit [Quit: whippythellama]
rikkipitt has joined #ruby-lang
CatButts has joined #ruby-lang
quimrstorres has quit [Remote host closed the connection]
<CatButts>
hai guise
<CatButts>
I'm drunk and I'm gonna try to erect a server with ruby
<CatButts>
the server happens to be (sic) winXP and potato hardware
nathanstitt has quit [Quit: I growing sleepy]
<CatButts>
last I checked there are multiple Ruby interpreter in existence
<CatButts>
(probably a year ago)
<CatButts>
one more optimized than the other
joshmun23 has joined #ruby-lang
<CatButts>
I am looking for speed on my potato hardware
fragamus has joined #ruby-lang
<CatButts>
what pick?
quimrstorres has joined #ruby-lang
<bougyman>
what workload?
<bougyman>
jruby or mri latest, one or the other will probably do ya.
<CatButts>
workload being client number, yes?
<CatButts>
minimal
<bougyman>
mri should do fine, then.
<CatButts>
right
<bougyman>
2.1.4
existensil has joined #ruby-lang
kaczmar has joined #ruby-lang
masterkorp has left #ruby-lang ["WeeChat 0.3.8"]
<CatButts>
I wish I had some tomato juice to go with Ruby
fragamus has quit [Client Quit]
joshmun23 has quit []
nelsonsar has quit [Remote host closed the connection]
mark999 has joined #ruby-lang
<CatButts>
I've been told ruby somewhat resembles perl
Asher has joined #ruby-lang
<CatButts>
as in
<CatButts>
"Ruby is perl on training wheels"
<CatButts>
how true is this exactly?
<mark999>
well... you can decypher code written in one of those two languages without getting a splitting headache
<CatButts>
hehe
<mark999>
I hardly use either language, but I think your best bet would be to grab some code written in each and try to understand it
r0bby has quit [Read error: Connection reset by peer]
<CatButts>
I typically write code out of need/craving
<CatButts>
I'm sure I'll get some with ruby
<mark999>
does anyone know of a program that parses the output of 'rake -P'? I'm hoping to use that data as input to an IDE and it would be nice to have something to start with
kaczmar has quit [Quit: kaczmar]
<CatButts>
also, I could be a lazy bastard and look for ready-packaged ruby stacks
<CatButts>
a la WAMP
<CatButts>
>jruby
<CatButts>
yeah, I'm gonna avoid that because Java and lowend hardware
<CatButts>
particularelly memory consumption
skade has joined #ruby-lang
ikrima has quit [Ping timeout: 272 seconds]
<CatButts>
yeah, I better rest and think clearly
CatButts has quit [Quit: Here is my journey's end, here is my butt.]
postmodern has joined #ruby-lang
postmodern has quit [Changing host]
postmodern has joined #ruby-lang
ikrima has joined #ruby-lang
symm- has quit [Ping timeout: 255 seconds]
solars has quit [Quit: WeeChat 0.4.1]
djbkd has quit [Remote host closed the connection]
HoroscopeFlower has joined #ruby-lang
rikkipitt has quit [Remote host closed the connection]
<HoroscopeFlower>
Hey I know this is probably an easy one, but I can't find a way to google it. What does the ||= operator do? The context is Ruby on Rails, and something to do with arrays.
qba73 has quit [Remote host closed the connection]
<ericwood>
HoroscopeFlower: it assigns if whatever is on the right is "falsy"
<ericwood>
as in nil, false, etc.
<HoroscopeFlower>
on the right, or on the left?
<ericwood>
whoops I mean whatever is on the left
<HoroscopeFlower>
cool, thanks
ender|dkm has quit [Ping timeout: 255 seconds]
<HoroscopeFlower>
for future reference is there some sort of symbol search you know about?