apeiros changed the topic of #ruby to: Ruby 1.9.3-p374: http://ruby-lang.org (ruby-2.0.0-rc1) || Paste >3 lines of text on http://gist.github.com
sullenel has quit [Quit: leaving]
jfl0wers has joined #ruby
matchaw_ has quit [Quit: No Ping reply in 180 seconds.]
jackyalcine has quit [Ping timeout: 252 seconds]
matchaw has joined #ruby
jduan1981 has quit [Ping timeout: 248 seconds]
<kenneth> although shouldn't this work?
<kenneth> item.tap(&:finalize_logic).to_hash
<yfeldblum> why?
mengu_ has joined #ruby
<Eiam> kenneth: if you have finalize_logic defined as a proc symbol sure?
<Eiam> kenneth: maybe you mean .tap(&finalize)
<Eiam> err .tap(&finalize_logic
<Eiam> )
Nisstyre-laptop has quit [Quit: Leaving]
mengu__ has joined #ruby
kristofers has quit []
<yfeldblum> kenneth, wouldn't `item.finalize_logic ; item.to_hash` be clearer in most cases?
<kenneth> Eiam: finalize_logic is a method on item
<Eiam> (I was reading about tap two days ago and so far I'm not very impressed, it seems like being clever at the cost of clarity, plenty of other ways to handle debugging too)
<Eiam> ah
<kenneth> yfeldblum: the reason is that it's all in an inline if statement, item.tap(&:finalize_logic).sanitized_hash if item.should_render?
<kenneth> the one liner makes sense to me, not unclear, versus the 4 lines it'd take otherwise
<yfeldblum> kenneth, "for the purpose of one-lining it" :D
mengu has quit [Ping timeout: 248 seconds]
<kenneth> if item.should_render?; item.finalize_logic; item.sanitized_hash; end
<workmad3> kenneth: the one thing that doesn't make sense to me there is the disconnect between the action and the guard :)
blaines has quit [Ping timeout: 256 seconds]
h4mz1d has joined #ruby
samuel02 has joined #ruby
horofox has quit [Quit: horofox]
blaines has joined #ruby
aaronmcadam has quit [Quit: aaronmcadam]
radic has quit [Ping timeout: 245 seconds]
jackyalcine has joined #ruby
dankest has quit [Quit: Leaving...]
slyv has joined #ruby
kpwz has quit [Ping timeout: 252 seconds]
kpwz has joined #ruby
<kenneth> oh i figured it out, silly me
<kenneth> contagious private statement, damnit
Kuifje has quit [Ping timeout: 248 seconds]
<kenneth> i really hate that when private/public/etc applies to everything below it
va_guy has joined #ruby
<yfeldblum> kenneth, why not just mark an individual method private then?
CLUSTERfoo has quit [Ping timeout: 246 seconds]
peteyg has quit [Ping timeout: 246 seconds]
<yfeldblum> kenneth, `def my_secret_method ; ... ; end ; private :my_secret_method`
<kenneth> yfeldblum: how do you do that?
chimmy has joined #ruby
<kenneth> oh interesting, did not know you could pass an argument to private
<kenneth> i'll do that from now on
horofox has joined #ruby
brianpWins has quit [Quit: brianpWins]
peteyg has joined #ruby
arya has quit [Ping timeout: 276 seconds]
breakingthings has joined #ruby
va_guy has quit [Remote host closed the connection]
ahokaomaeha has joined #ruby
TheFuzzball has quit [Quit: Computer has gone to sleep.]
Ergo^ has quit [Remote host closed the connection]
jduan1981 has joined #ruby
Stilo has quit [Quit: Textual IRC Client: www.textualapp.com]
va_guy has joined #ruby
ninp0 has joined #ruby
mikepack has joined #ruby
juarlex has quit [Remote host closed the connection]
arya has joined #ruby
va_guy has quit [Client Quit]
mikepack has quit [Remote host closed the connection]
chimmy has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
Giorgio has quit [Ping timeout: 264 seconds]
carloslopes has quit [Remote host closed the connection]
cakehero has joined #ruby
jduan1981 has quit [Ping timeout: 244 seconds]
horofox has quit [Quit: horofox]
fgro has joined #ruby
ner0x has joined #ruby
carloslopes has joined #ruby
v0n has joined #ruby
va_guy has joined #ruby
mikepack has joined #ruby
elaptics is now known as elaptics`away
arya has quit [Ping timeout: 260 seconds]
seren has joined #ruby
<seren> hi, i have been using vim as a ruby ide for long time.. I wonder if their are some custom light ide's for ruby to play with.. any suggestions?
Beoran_ has joined #ruby
blaines has quit [Quit: Computer has gone to sleep.]
mephux has quit [Excess Flood]
baordog has joined #ruby
<Spitfire> seren, you're hardcore.
<baordog> Hey all! I'm having trouble getting some libraries going. My system can't seem to find wxruby even though I installed it via rubygems
<seren> Spitfire: mmm thanks i guess :)
abcdefg_ has quit [Quit: ChatZilla 0.9.89 [Firefox 17.0.1/20121128204232]]
mephux has joined #ruby
Beoran__ has quit [Ping timeout: 240 seconds]
michaelmartinez has quit [Quit: Check it, Wreck it http://www.caffeineindustries.com/blog]
arya has joined #ruby
rmelissari has quit [Ping timeout: 252 seconds]
samlt has quit [Ping timeout: 244 seconds]
apoch632 has joined #ruby
slainer68 has quit [Remote host closed the connection]
va_guy has quit [Quit: Textual IRC Client: www.textualapp.com]
rmelissari has joined #ruby
dmerrick has joined #ruby
<baordog> Is this a known issue?
CLUSTERfoo has joined #ruby
jduan1981 has joined #ruby
statarb3 has quit [Read error: Connection reset by peer]
jaywastaken has quit [Read error: Connection reset by peer]
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
sailias has joined #ruby
jaywastaken has joined #ruby
jaywastaken has quit [Changing host]
jaywastaken has joined #ruby
<baordog> I am requiring ruby gems
SCommette has joined #ruby
jsted has joined #ruby
tommyvyo has joined #ruby
jsted has left #ruby [#ruby]
itsdavem has joined #ruby
alanjc has joined #ruby
benlieb has quit [Quit: benlieb]
arya_ has joined #ruby
jgrevich_ has joined #ruby
michaelmartinez has joined #ruby
ryanh has joined #ruby
radic has joined #ruby
aedorn has quit [Quit: Leaving]
love_color_text has quit [Read error: Connection reset by peer]
<havenn> baordog: Just tried installing wxruby, no problem. What are your Ruby and RubyGems versions?
robotmay has quit [Ping timeout: 248 seconds]
<baordog> Just updated both to the latest
<baordog> did a gem update
jgrevich has quit [Ping timeout: 248 seconds]
jgrevich_ is now known as jgrevich
<havenn> baordog: 1.9.3?
<baordog> yup
arya has quit [Ping timeout: 248 seconds]
<baordog> other libraries seem to work.
<baordog> require rails works, require rubygems works
love_color_text has joined #ruby
yshh has joined #ruby
<havenn> baordog: Just tried installing wxruby from RubyGems on 1.9.3 in OS X and Ubuntu, can't reproduce the problem. Not sure?
x82_nicole has quit [Quit: Computer has gone to sleep.]
<havenn> baordog: OS/distro?
<baordog> Windows 7
_nitti has joined #ruby
<baordog> wxruby installed fine. Updates go off without a hitch.
unsay has joined #ruby
postmodern has joined #ruby
cakehero has quit [Quit: Computer has gone to sleep.]
<havenn> baordog: So `gem install wxruby` works without a hitch, but you get a LoadError when you require it?
jpfuente_ has quit [Quit: Computer has gone to sleep.]
Solnse has joined #ruby
<baordog> Absolutely. require wx fails, require wxruby also fails.
radic has quit [Ping timeout: 248 seconds]
<baordog> wxruby is listed among the gems on the system
jpfuentes2 has joined #ruby
<havenn> baordog: Can you paste a Gist of the LoadError?
piotr_ has quit [Ping timeout: 248 seconds]
_nitti has quit [Ping timeout: 264 seconds]
seren has quit [Quit: Page closed]
recycle has quit [Read error: No route to host]
recycle_ has joined #ruby
Nisstyre has joined #ruby
pskosinski has quit [Quit: Learn Life's Little Lessons]
Takehiro has joined #ruby
Takehiro has quit [Read error: Connection reset by peer]
aytch is now known as DOUCHE
warb0 has quit [Read error: Connection reset by peer]
DOUCHE is now known as DOUCHE_ALONG_THE
DOUCHE_ALONG_THE is now known as aytch
carloslopes has quit [Remote host closed the connection]
greenarrow has quit [Read error: Connection reset by peer]
greenarrow has joined #ruby
uris has quit [Ping timeout: 240 seconds]
marr has quit [Ping timeout: 252 seconds]
yshh_ has joined #ruby
workmad3 has quit [Ping timeout: 264 seconds]
<baordog> Someone said that I needed to obtain the wx bindings
mando_ has quit [Remote host closed the connection]
dankest has joined #ruby
fgro has quit [Quit: leaving]
yshh has quit [Ping timeout: 264 seconds]
internetishard1 has left #ruby [#ruby]
michaelmartinez has quit [Quit: michaelmartinez]
dallasm has joined #ruby
<havenn> baordog: Are you doing something wxruby specific, or just want a gui?
<baordog> I just want a gui, but this is infuriating me to be honest. I tried installing tk and that didn't want to work either (and it reset my path variable)
<havenn> baordog: I was gunno recommend tk >.>
the_mentat has joined #ruby
cpruitt has quit [Quit: cpruitt]
<baordog> I used the automated installer binary for windows
mengu_ has quit [Remote host closed the connection]
<havenn> baordog: From irb do you get any errors with?: require 'tk'
<baordog> cannot load
mengu_ has joined #ruby
CLUSTERfoo has quit [Ping timeout: 264 seconds]
innohero has quit [Quit: Leaving]
punk_ has joined #ruby
punk_ has quit [Client Quit]
mando has joined #ruby
<baordog> Maybe i should find somewhere to download it from?
mengu__ has quit [Quit: This computer has gone to sleep]
mando_ has joined #ruby
dallasm has quit [Ping timeout: 255 seconds]
<havenn> baordog: I wonder if you'd have more luck with a windows port of Gtk+?
niklasb has quit [Ping timeout: 252 seconds]
c0rn has quit [Quit: Computer has gone to sleep.]
daniel_- has quit [Quit: WeeChat 0.3.9.2]
freeayu has joined #ruby
cawaker has quit [Ping timeout: 245 seconds]
<havenn> baordog: I've no experience with compatibility with Windows, but: https://github.com/ruby-gnome2/ruby-gnome2
<havenn> baordog: I'd have thought tk would work, dunno!
<baordog> I don't even know where to get it at this point.
emmanuelux has quit [Remote host closed the connection]
cableray has joined #ruby
mando has quit [Ping timeout: 248 seconds]
dougireton has quit [Quit: Leaving.]
<havenn> baordog: Another one to maybe look at is green_shoes: https://github.com/ashbb/green_shoes
__BigO__ has joined #ruby
mercwithamouth has quit [Ping timeout: 248 seconds]
__BigO__ has quit [Remote host closed the connection]
uris has joined #ruby
SCommette has quit [Quit: SCommette]
taoru has joined #ruby
aib has quit [Ping timeout: 256 seconds]
itsdavem has quit [Remote host closed the connection]
yshh_ has quit [Remote host closed the connection]
ngoldman has quit [Remote host closed the connection]
fyolnish has joined #ruby
dougireton has joined #ruby
jonathanwallace has quit [Quit: WeeChat 0.3.9.2]
jonathanwallace has joined #ruby
sepia has joined #ruby
idkazuma has quit [Remote host closed the connection]
unsay has quit [Ping timeout: 276 seconds]
CLUSTERfoo has joined #ruby
dougireton has quit [Client Quit]
dmerrick has quit [Quit: dmerrick]
Goles_ has quit [Quit: Out.]
s1n4 has quit [Quit: leaving]
meoblast001 has joined #ruby
radic has joined #ruby
unsay has joined #ruby
sepia has left #ruby [#ruby]
innohero has joined #ruby
innohero has left #ruby [#ruby]
brianpWins has joined #ruby
razieliyo has joined #ruby
<razieliyo> hi
AntiTyping has joined #ruby
tcstar has quit [Ping timeout: 248 seconds]
<razieliyo> I want to hold info on a two dimensional array about a table with rows and columns
<razieliyo> is a two dimensional array the best approach for this? I've seen several ways to handle this
<razieliyo> myarray = Array.new(width) {Array.new(height) {0}}
<razieliyo> for example
Drager has quit [Ping timeout: 252 seconds]
mcqueenorama has joined #ruby
<razieliyo> and another one is a two dimensional hash, or a hash with indexes like this [x,y]
Drager has joined #ruby
bradhe has quit [Remote host closed the connection]
jerius has joined #ruby
x82_nicole has joined #ruby
radic has quit [Ping timeout: 244 seconds]
Virunga has joined #ruby
unsay has quit [Ping timeout: 244 seconds]
sn0wb1rd has quit [Quit: sn0wb1rd]
DrShoggoth has joined #ruby
chiel is now known as chiel`afk
arya_ has quit [Ping timeout: 248 seconds]
zeade has quit [Quit: Leaving.]
<breakingthings> How can I parse XML in Ruby?
tomzx_mac has joined #ruby
bradhe has joined #ruby
peteyg has quit [Ping timeout: 256 seconds]
yshh has joined #ruby
<breakingthings> ah, nevermind, found REXML
chimkan___ has joined #ruby
arya has joined #ruby
freakazoid0223 has joined #ruby
gwillickers has joined #ruby
butblack has joined #ruby
radic has joined #ruby
chimkan_ has quit [Ping timeout: 276 seconds]
TDJACR has joined #ruby
unsay has joined #ruby
Konboi has joined #ruby
slainer68 has joined #ruby
Takehiro has joined #ruby
DrShoggoth has quit [Ping timeout: 248 seconds]
mercwithamouth has joined #ruby
baordog has quit [Quit: ChatZilla 0.9.89 [Firefox 18.0.1/20130116073211]]
allaire has joined #ruby
berserkr has quit [Quit: Leaving.]
CLUSTERfoo has quit [Ping timeout: 248 seconds]
radic has quit [Ping timeout: 256 seconds]
F1skr has quit [Quit: WeeChat 0.4.0]
M- has joined #ruby
love_color_text has quit [Remote host closed the connection]
mando_ has quit [Remote host closed the connection]
Virunga has quit [Remote host closed the connection]
slainer68 has quit [Ping timeout: 264 seconds]
love_color_text has joined #ruby
yacks has joined #ruby
rismoney has quit [Remote host closed the connection]
bradhe has quit [Remote host closed the connection]
generalissimo has joined #ruby
havenn has quit [Ping timeout: 248 seconds]
dpbus has joined #ruby
love_color_text has quit [Ping timeout: 256 seconds]
jrajav has joined #ruby
mneorr has quit [Remote host closed the connection]
sn0wb1rd has joined #ruby
dankest has quit [Quit: Leaving...]
DrShoggoth has joined #ruby
mneorr has joined #ruby
unsay has quit [Ping timeout: 255 seconds]
jerius has quit []
alvaro_o has quit [Quit: Ex-Chat]
ThePicard has quit [Quit: WeeChat 0.3.8]
subbyyy has joined #ruby
nari has joined #ruby
havenn has joined #ruby
generalissimo has quit [Read error: Connection reset by peer]
generalissimo has joined #ruby
amoeba has quit [Quit: Leaving]
ThePicard has joined #ruby
plotter has quit [Ping timeout: 264 seconds]
Targen has quit [Quit: No Ping reply in 180 seconds.]
hiroyuki has quit [Read error: Connection reset by peer]
recycle_ has quit [Remote host closed the connection]
generalissimo has quit [Read error: Connection reset by peer]
Kobrakao has quit [Ping timeout: 248 seconds]
hiroyuki has joined #ruby
jesfre has joined #ruby
tlvb has quit [Ping timeout: 246 seconds]
Targen has joined #ruby
generalissimo has joined #ruby
adkron has joined #ruby
radic has joined #ruby
main_ has quit [Ping timeout: 276 seconds]
Danskersen has joined #ruby
DrShoggoth has quit [Ping timeout: 248 seconds]
quest88_ has joined #ruby
tlvb has joined #ruby
adkron_ has joined #ruby
unsay has joined #ruby
ryanh has quit [Quit: Computer has gone to sleep.]
mikepack has quit [Remote host closed the connection]
chussenot has joined #ruby
frem has quit [Quit: Computer has gone to sleep.]
butblack has quit [Quit: butblack]
samphippen has quit [Quit: Computer has gone to sleep.]
Liothen has joined #ruby
chussenot has left #ruby [#ruby]
butblack has joined #ruby
rupee has quit [Quit: Leaving]
sbear has quit [Ping timeout: 260 seconds]
cawaker has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
cheese1756 has quit [Quit: ZNC - http://znc.in]
Skylab has quit [Quit: Skylab]
jerius has joined #ruby
axiak_ has quit [Quit: leaving]
the_mentat has quit [Quit: Computer has gone to sleep.]
axiak has joined #ruby
hackerdude has quit [Remote host closed the connection]
Evixion has joined #ruby
maletor has joined #ruby
cheese1756 has joined #ruby
ffranz has quit [Read error: No route to host]
elico has quit [Ping timeout: 240 seconds]
mockra has quit [Remote host closed the connection]
rakl has quit [Quit: sleeping]
itsdavem has joined #ruby
krawchyk has joined #ruby
statarb3 has quit [Ping timeout: 240 seconds]
NihilistDandy has joined #ruby
DrShoggoth has joined #ruby
axiak has quit [Client Quit]
axiak has joined #ruby
mcqueenorama has quit [Remote host closed the connection]
Danskersen has quit [Remote host closed the connection]
crackfu has joined #ruby
unsay has quit [Ping timeout: 248 seconds]
itsdavem has quit [Ping timeout: 245 seconds]
adeponte has quit [Remote host closed the connection]
jackyalcine has quit [Quit: Quit]
maletor has quit [Quit: Computer has gone to sleep.]
mneorr has quit [Remote host closed the connection]
jduan1981 has quit [Ping timeout: 252 seconds]
<breakingthings> So, I'm writing a little script to create a batch of svg files from a source… I've gotten as far as opening the file, and editing the xml with Nokogiri, but how can I write to a new file? Am I best off with `newfile = File.new; newfile.write(xml);` or something?
mneorr has joined #ruby
<Paradox> yup
<Paradox> but you dont need the file new
<breakingthings> File.write() has an arg for destination?
<breakingthings> or...
<breakingthings> ?
<Paradox> IO.write(filename, string)
cableray_ has joined #ruby
<breakingthings> hmm, alright.
jackyalcine has joined #ruby
markalanevans has quit [Ping timeout: 252 seconds]
jduan1981 has joined #ruby
cableray has quit [Ping timeout: 248 seconds]
cableray_ is now known as cableray
techlife has quit [Ping timeout: 255 seconds]
tommyvyo has quit [Quit: http://twitter.com/tommyvyo]
io_syl has quit [Quit: Computer has gone to sleep.]
jduan1981 has quit [Client Quit]
banjara has quit [Quit: Leaving.]
Hanmac has joined #ruby
miso1337 has joined #ruby
tjbiddle_ has joined #ruby
toekutr has quit [Remote host closed the connection]
mneorr has quit [Remote host closed the connection]
Hanmac1 has quit [Ping timeout: 252 seconds]
mneorr has joined #ruby
eka has quit [Quit: Computer has gone to sleep.]
toekutr has joined #ruby
<breakingthings> Paradox: that did indeed work, thanks
<breakingthings> Now I just need to find a way to mass convert a folder of svgs to pngs.
jaequery has quit [Quit: Computer has gone to sleep.]
techlife has joined #ruby
tjbiddle has quit [Ping timeout: 264 seconds]
tjbiddle_ has quit [Ping timeout: 240 seconds]
seanwash has joined #ruby
Choobie has joined #ruby
asteve has joined #ruby
<RubyPanther> breakingthings: man xargs
adkron_ has quit [Ping timeout: 248 seconds]
cableray_ has joined #ruby
sailias has quit [Quit: Leaving.]
<breakingthings> RubyPanther: huh? what's xargs do?
adkron has quit [Ping timeout: 248 seconds]
love_color_text has joined #ruby
<RubyPanther> reduces the "directory of" part of the problem
<Paradox> So does the Dir module
stormetrooper has quit [Quit: Leaving]
adkron has joined #ruby
<RubyPanther> well, sure
cableray has quit [Ping timeout: 252 seconds]
cableray_ is now known as cableray
adkron_ has joined #ruby
chrishough has quit [Quit: chrishough]
cableray has quit [Client Quit]
<RubyPanther> but if you have to ask how to do stuff, which tools to use might me more useful than which module to use to write the tool
<Paradox> i think imagemagic can convert from svg to pyng
<Paradox> but im not sure
<breakingthings> possibly but in this case I know neither so :d
<breakingthings> anyway, yes, you're right
<breakingthings> needs specific support though
Bosox20051 has quit [Quit: Leaving]
ffranz has joined #ruby
<breakingthings> and X11.
<breakingthings> which is a pain.
tommyvyo has joined #ruby
<breakingthings> (but luckily I have a dummy machine I can dump that task onto!)
seanwash has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
<Paradox> battle tram
jackyalcine has quit [Ping timeout: 252 seconds]
seanstickle has joined #ruby
gavinhug_ has joined #ruby
seanstickle has quit [Client Quit]
seanstickle has joined #ruby
joeycarmello has quit [Remote host closed the connection]
murilo_fs has joined #ruby
pu22l3r has joined #ruby
Emmanuel_Chanel has quit [Remote host closed the connection]
murilo_fs has quit [Quit: Konversation terminated!]
jackyalcine has joined #ruby
lupinstein has joined #ruby
murilo_fs has joined #ruby
<jokke> hey
<jokke> i have some syntax errors here: http://paste.xinu.at/5vFf/rb
<jokke> i'm not sure what i'm doing wrong
seanstickle has quit [Client Quit]
jonahR has joined #ruby
Bosma has quit [Quit: leaving]
Takehiro has quit [Read error: Connection reset by peer]
segv- has quit [Quit: segv-]
<jokke> i know the def is completely unnecessary
jbw has quit [Ping timeout: 248 seconds]
<banisterfiend> jokke: err, u have two 'end' before your final 'when' :)
bigmac has quit [Quit: Leaving]
<breakingthings> pf… imagemagick with rsvg is hefty. brew is still chugging away at it's deps
Michael_ has joined #ruby
Takehiro has joined #ruby
Skylab has joined #ruby
gwillickers has quit [Ping timeout: 252 seconds]
<jokke> banisterfiend: yes, the first closes the case and the second closes the while
jesfre has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
xemu has quit [Quit: Nettalk6 - www.ntalk.de]
zph has joined #ruby
jekotia has quit [Quit: ChatZilla 0.9.89-rdmsoft [XULRunner 1.9.0.17/2009122204]]
arya has quit [Ping timeout: 248 seconds]
ner0x has quit [Quit: Leaving]
hackerdude has joined #ruby
h4mz1d has quit [Ping timeout: 256 seconds]
pu22l3r has quit [Remote host closed the connection]
atno has quit [Quit: Get MacIrssi - http://www.sysctl.co.uk/projects/macirssi/]
Michael_ has quit [Remote host closed the connection]
arya has joined #ruby
S1kx has quit [Quit: Leaving]
<banisterfiend> jokke: 1. that code sample is not complete, you have an unattached 'when' at the start. 2. You didnt even show the specific exception that was raised or give any kind of backtrace 3. Learn how to ask decent questions and provide the appropriate information, and come back again.
gwillickers has joined #ruby
gwillickers has quit [Client Quit]
mercwithamouth has quit [Ping timeout: 256 seconds]
techhelp has joined #ruby
<breakingthings> Oh boy… Pango can't find the font I'm using in the svg… crap.
ner0x has joined #ruby
vinax has quit [Ping timeout: 245 seconds]
gavinhug_ has quit [Remote host closed the connection]
<jokke> banisterfiend: i'm sorry, you're right. Here's the complete code: http://paste.xinu.at/HdO/ I get these errors: http://paste.xinu.at/chekk/
Michael_ has joined #ruby
jduan1981 has joined #ruby
ryanf has quit [Read error: Connection reset by peer]
ryanf has joined #ruby
x82_nicole has quit [Quit: Computer has gone to sleep.]
dallasm has joined #ruby
dareign85 has quit [Ping timeout: 256 seconds]
arya has quit [Ping timeout: 248 seconds]
brianpWins has quit [Quit: brianpWins]
krainboltgreene has joined #ruby
apok has quit [Quit: apok]
recycle has joined #ruby
bricker`1A has joined #ruby
arya has joined #ruby
butblack has quit [Quit: butblack]
bricker`LA has quit [Ping timeout: 255 seconds]
cardoni has joined #ruby
ckrailo has quit [Quit: Computer has gone to sleep.]
davidcel- has joined #ruby
michaelmartinez has joined #ruby
arya has quit [Ping timeout: 248 seconds]
erichmenge_ has joined #ruby
ilyam has quit [Quit: ilyam]
jaequery has joined #ruby
kylescottmcgill has quit [Ping timeout: 276 seconds]
aaronmacy has joined #ruby
davidcelis has quit [Ping timeout: 240 seconds]
davidcel- is now known as davidcelis
davidcelis has quit [Changing host]
davidcelis has joined #ruby
murilo_fs has quit [Quit: Konversation terminated!]
erichmenge has quit [Ping timeout: 240 seconds]
erichmenge_ is now known as erichmenge
TomyLobo has quit [Quit: Standby mode...]
brianpWins has joined #ruby
murz has joined #ruby
arya has joined #ruby
butblack has joined #ruby
miso1337 has quit [Quit: afk]
zph has quit [Quit: Computer has gone to sleep.]
jerius has quit []
cparen has joined #ruby
chrishunt has joined #ruby
zph has joined #ruby
<havenn> jokke: Looks like you forgot to add commas between your arguements.
dpbus has quit [Quit: Computer has gone to sleep.]
<havenn> jokke: e.g.,: :bg, value
murz has quit [Quit: Leaving...]
ryanf has quit [Read error: Connection reset by peer]
ryanf has joined #ruby
<havenn> jokke: lines 151, 153, 155, 157 (couldn't read indentation so repasted it): http://hastebin.com/xemuyakuso.rb
tomzx_mac has quit [Ping timeout: 245 seconds]
joeycarmello has joined #ruby
hadees has joined #ruby
dareign85 has joined #ruby
dpbus has joined #ruby
lusory has quit [Quit: leaving]
kylescottmcgill has joined #ruby
v0n has quit [Ping timeout: 264 seconds]
vincentpaca has joined #ruby
miso1337 has joined #ruby
freeayu__ has joined #ruby
sepp2k has joined #ruby
dv_ has quit [Quit: No Ping reply in 180 seconds.]
cparen has quit [Quit: cparen]
dv_ has joined #ruby
freeayu has quit [Ping timeout: 276 seconds]
ilyam has joined #ruby
slyv has quit [Quit: Computer has gone to sleep.]
ilyam has quit [Remote host closed the connection]
pu22l3r has joined #ruby
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
mcqueenorama has joined #ruby
mercwithamouth has joined #ruby
recycle has quit [Remote host closed the connection]
pu22l3r has quit [Remote host closed the connection]
zph_ has joined #ruby
<razieliyo> is there any way to run this?
<razieliyo> myHash.each { |key, val| val = "foo" }
<razieliyo> I mean, to have the myHash changed using that naming, instead of myHash[key] = "foo"
cparen has joined #ruby
<jokke> havenn: thanks a lot!
nga4 has joined #ruby
zph has quit [Ping timeout: 252 seconds]
recycle has joined #ruby
anderse has quit [Quit: anderse]
butblack has left #ruby [#ruby]
murz has joined #ruby
d2dchat has quit [Remote host closed the connection]
chrishough has joined #ruby
kylescottmcgill has quit [Quit: WeeChat 0.3.8]
Skylab has quit [Quit: Skylab]
recycle has quit [Remote host closed the connection]
radic has quit [Ping timeout: 245 seconds]
<havenn> razieliyo: You don't want to do?: hash.each { |k, v| hash[k] = 'foo' }
phantasm66 has joined #ruby
phantasm66 has quit [Changing host]
phantasm66 has joined #ruby
chimkan_ has joined #ruby
murz has quit [Read error: Connection reset by peer]
samuel02 has quit [Remote host closed the connection]
murz has joined #ruby
<havenn> razieliyo: or rather: hash.each_key { |k| hash[k] = 'bar' }
asteve has quit [Quit: Computer has gone to sleep.]
techhelp has quit [Quit: This computer has gone to sleep]
DarthGandalf has quit [Ping timeout: 245 seconds]
phantasm66 has quit [Client Quit]
alanjc has quit [Quit: alanjc]
dallasm has quit [Remote host closed the connection]
ananthakumaran has joined #ruby
chimkan___ has quit [Ping timeout: 245 seconds]
cardoni has quit [Quit: cardoni]
jonathanwallace has quit [Ping timeout: 246 seconds]
DarthGandalf has joined #ruby
SCommette has joined #ruby
jonathanwallace has joined #ruby
zeade has joined #ruby
pu22l3r has joined #ruby
f0ster has quit [Ping timeout: 256 seconds]
Konboi has quit [Remote host closed the connection]
beneggett has quit [Quit: Computer has gone to sleep.]
ffranz has quit [Quit: Leaving]
yshh has quit [Remote host closed the connection]
krawchyk has quit [Remote host closed the connection]
mockra has joined #ruby
cardoni has joined #ruby
radic has joined #ruby
alanjc has joined #ruby
joofsh has quit [Remote host closed the connection]
the_mentat has joined #ruby
freakazoid0223 has quit [Quit: Leaving]
tcstar has joined #ruby
<xk_id> Is 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8' a typical http accept header? Or does it vary a lot across browsers?
<xk_id> I'm trying to hide my crawler's identity
taoru has quit [Remote host closed the connection]
Umren has joined #ruby
adeponte has joined #ruby
josh_keith has quit [Ping timeout: 240 seconds]
Bosma has joined #ruby
pu22l3r has quit [Remote host closed the connection]
skcin7 has quit [Quit: Computer has gone to sleep.]
skcin7 has joined #ruby
chrishough has quit [Quit: chrishough]
Takehiro has quit [Remote host closed the connection]
ryanf has quit [Quit: leaving]
allaire has quit []
hemanth_ has joined #ruby
<razieliyo> havenn: yes, you're right, it was just matter of curiosity
<razieliyo> havenn: thanks
krz has joined #ruby
Takehiro has joined #ruby
crackfu_ has joined #ruby
<havenn> razieliyo: hmm, yeah would be nice to have a way to reference the hash you're operating on without referring to the variable, dunno how though!
miso1337 has quit [Quit: afk]
subbyyy_ has joined #ruby
<razieliyo> havenn: yes, that would give you pretty more understandable code for example, although that's just my opinion
NobbZ has joined #ruby
jcrawfor- has joined #ruby
beilabs has quit [Ping timeout: 276 seconds]
wookiehangover has quit [Ping timeout: 276 seconds]
justinabrahms has quit [Ping timeout: 276 seconds]
arusso has quit [Ping timeout: 276 seconds]
hashtree has quit [Ping timeout: 276 seconds]
SeanTAllen has quit [Ping timeout: 276 seconds]
Spaceghost|cloud has quit [Ping timeout: 276 seconds]
Guest85414 has quit [Ping timeout: 276 seconds]
kn330 has quit [Excess Flood]
jrajav has quit [Ping timeout: 276 seconds]
crackfu has quit [Ping timeout: 276 seconds]
SeySayux has quit [Ping timeout: 276 seconds]
jcrawford has quit [Quit: Will Be Back]
fasta has quit [Read error: Connection reset by peer]
jbpros has quit [Quit: May the Cuke be with you!]
NobbZ|wech has quit [Read error: Connection reset by peer]
jcrawfor- is now known as jcrawford
jcrawford has quit [Changing host]
jcrawford has joined #ruby
kn330_ has joined #ruby
Takehiro has quit [Remote host closed the connection]
subbyyy has quit [Ping timeout: 276 seconds]
hemanth has quit [Ping timeout: 276 seconds]
<razieliyo> NilClass are the ruby's segfaults
hashtree has joined #ruby
fasta has joined #ruby
jbpros has joined #ruby
arusso has joined #ruby
wookiehangover has joined #ruby
SeySayux has joined #ruby
itsdavem has joined #ruby
krainboltgreene has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
radic has quit [Disconnected by services]
radic_ has joined #ruby
justinlilly has joined #ruby
josh_keith has joined #ruby
miso1337 has joined #ruby
jrajav has joined #ruby
Michael_ has quit [Remote host closed the connection]
<razieliyo> I'm losing myself in the bunch of methods that an array has to find what I want
<razieliyo> is there any way to apply a block to each array element?
itsdavem has quit [Ping timeout: 264 seconds]
ner0x has quit [Quit: Leaving]
beilabs has joined #ruby
<razieliyo> I mean for example, my_array.each_apply { |x| Integer(x) } to return an equivalent Integer array of my_array
<razieliyo> each_apply has been deliberately invented by me, lol
<razieliyo> just to ilustrate what I'm asking
Choobie has quit [Ping timeout: 255 seconds]
mahmoudimus has quit [Quit: Computer has gone to sleep.]
<razieliyo> what I want is the lisp map function
<razieliyo> there must be a way
v0n has joined #ruby
beilabs has quit [Ping timeout: 252 seconds]
<razieliyo> Boohbah: thanks!
<razieliyo> Boohbah: I'm a bit dizzled
<Boohbah> maybe you should get a book about ruby, too
<razieliyo> Boohbah: yes, I'm reading the pickaxe, but I'm over the first 50 pages, I just swam into something
<razieliyo> but you're right
<razieliyo> I should read it before I ask so basic questions here
daslicious has quit [Quit: daslicious]
beneggett has joined #ruby
sepp2k1 has joined #ruby
jfl0wers has quit [Quit: jfl0wers]
sarkis has joined #ruby
sepp2k has quit [Ping timeout: 248 seconds]
slainer68 has joined #ruby
unsay has joined #ruby
<sarkis> hey guys, i am confused how the ./vendor/ directory actually works? i am planning on packaging a ruby library and like the fact that running bundle install --deployment results in a "self-contained package"
<sarkis> it is a rack app, what do i have to do for the app the know to look in ./vendor?
jaywastaken has quit [Ping timeout: 240 seconds]
k3rn3lito has joined #ruby
<Gate> sarkis: that information is stored in .bundle/config
<sarkis> this is the app i am packaging up: https://github.com/ripienaar/gdash i need to come up with a system package out of it
<sarkis> ah hmm
<Gate> sarkis: so simply running that command to install your gems, then bundle will know to look for its config file
<sarkis> Gate: do you know if i can run that on a system and then package it up.. will that cause any issues?
adeponte has quit [Remote host closed the connection]
<Gate> sarkis: I don't know what you mean by "on a system"
Umren has quit [Read error: Connection reset by peer]
cparen has quit [Quit: cparen]
<Gate> sarkis: we do that on our servers all the time
<sarkis> basically it will be https://github.com/ripienaar/gdash + vendor/ folder and then i will create an rpm to distribute
slainer68 has quit [Ping timeout: 248 seconds]
<Gate> sarkis: You can pull it off. Beware of arch dependent gems and compiled C extensions.
adeponte has joined #ruby
ananthakumaran has quit [Quit: Leaving.]
<Gate> sarkis: what you *really* want to do, in my opinion, is use the "cache" option in bundler
cauffe has joined #ruby
<Gate> sarkis: that stores the gem sources in vendor/cache, then on any arbitrary system running bundle install with the proper options will pull the gems from the cache
jaywastaken has joined #ruby
jaywastaken has quit [Changing host]
jaywastaken has joined #ruby
<sarkis> i see and i can still run bundle install --deployment?
beilabs has joined #ruby
<Gate> sarkis: yep. I think there is an --only-cache option to enforce the cache, as well
apoch632 has quit [Quit: Leaving.]
<cauffe> ruby is a sexy language
<cauffe> just syaing
<Gate> sarkis: that option is --local
<Gate> not --only-cache
ablegreen has joined #ruby
ebarendt has joined #ruby
<Gate> cauffe: not only that, but it loves us, too
dareign85 has quit []
oinkon has quit [Ping timeout: 264 seconds]
jfl0wers has joined #ruby
benlieb has joined #ruby
pu22l3r has joined #ruby
razieliyo has quit [Remote host closed the connection]
meoblast001 has quit [Remote host closed the connection]
banisterfiend has quit [Remote host closed the connection]
cparen has joined #ruby
cparen has quit [Client Quit]
techhelp has joined #ruby
heckler has joined #ruby
cparen has joined #ruby
TDJACR has quit [Quit: Restart]
<heckler> how do i convert a datetime of this type "2013-01-31 21:37:07 -0600" to a unix timestamp?
<pietr0> Time.parse("2013-01-31 21:37:07 -0600").to_i
vanstee has quit [Quit: Computer has gone to sleep.]
sayan has joined #ruby
sayan has quit [Changing host]
sayan has joined #ruby
sayan has quit [Read error: Connection reset by peer]
oinkon has joined #ruby
reset has quit [Ping timeout: 244 seconds]
<heckler> pietr0: thanks!
Konboi has joined #ruby
adeponte has quit [Remote host closed the connection]
TDJACR has joined #ruby
CLUSTERfoo has joined #ruby
bricker`1A is now known as bricker`LA
joeycarmello has quit [Remote host closed the connection]
Nanuq has quit [Read error: Operation timed out]
ananthakumaran has joined #ruby
dougireton has joined #ruby
dougireton has left #ruby [#ruby]
unsay has quit [Ping timeout: 252 seconds]
itsdavem has joined #ruby
Nanuq has joined #ruby
CLUSTERfoo has quit [Ping timeout: 248 seconds]
thinkclay has quit [Quit: Leaving.]
techhelp has quit [Quit: This computer has gone to sleep]
Nanuq has quit [Read error: Operation timed out]
jduan1981 has quit [Read error: Connection reset by peer]
zph_ has quit [Quit: Computer has gone to sleep.]
crackfu_ has quit [Remote host closed the connection]
jduan1981 has joined #ruby
crackfu has joined #ruby
ebarendt has quit [Quit: Textual IRC Client: www.textualapp.com]
reset has joined #ruby
brianpWins has quit [Quit: brianpWins]
benlieb has quit [Quit: benlieb]
crackfu has quit [Ping timeout: 240 seconds]
yshh has joined #ruby
benlieb has joined #ruby
Nanuq has joined #ruby
pu22l3r has quit [Remote host closed the connection]
murilo_fs has joined #ruby
banisterfiend has joined #ruby
coder_neo has joined #ruby
dpbus has quit [Quit: Computer has gone to sleep.]
haridas has joined #ruby
haridas has left #ruby [#ruby]
dormiens has quit [Read error: Connection reset by peer]
murilo_fs is now known as Murilo_FS
Murilo_FS is now known as murilo_fs
jpfuentes2 has joined #ruby
pu22l3r has joined #ruby
end_guy has quit [Remote host closed the connection]
banisterfiend has quit [Ping timeout: 276 seconds]
end_guy has joined #ruby
itsdavem has quit [Remote host closed the connection]
nomenkun has joined #ruby
techlife has quit [Ping timeout: 272 seconds]
itsdavem has joined #ruby
alanjc has quit [Quit: alanjc]
gosshedd has joined #ruby
unsay has joined #ruby
browndawg has joined #ruby
yshh has quit [Remote host closed the connection]
kn330_ has quit [Quit: Ex-Chat]
slainer68 has joined #ruby
joeycarmello has joined #ruby
kn330 has joined #ruby
breakingthings has quit []
joeycarmello has quit [Remote host closed the connection]
joeycarmello has joined #ruby
techlife has joined #ruby
mibitzi has joined #ruby
tommyvyo has quit [Quit: http://twitter.com/tommyvyo]
slainer68 has quit [Ping timeout: 245 seconds]
tjbiddle has joined #ruby
tjbiddle_ has joined #ruby
murilo_fs has left #ruby ["Konversation terminated!"]
shammancer has quit [Quit: Leaving.]
unsay has quit [Ping timeout: 248 seconds]
shammancer has joined #ruby
tjbiddle has quit [Ping timeout: 248 seconds]
tjbiddle_ is now known as tjbiddle
SCommette has quit [Quit: SCommette]
uris has quit [Quit: Leaving]
a_a_g has joined #ruby
sarkis has quit [Ping timeout: 246 seconds]
jaywastaken has quit [Read error: Connection reset by peer]
jaywastaken has joined #ruby
jaywastaken has quit [Changing host]
jaywastaken has joined #ruby
rippa has joined #ruby
cha1tanya has joined #ruby
cparen has quit [Quit: cparen]
mikepack has joined #ruby
tommyvyo has joined #ruby
dhruvasagar has joined #ruby
ossareh has quit [Ping timeout: 276 seconds]
the_mentat has quit [Quit: Computer has gone to sleep.]
noop has joined #ruby
arya has quit [Ping timeout: 248 seconds]
ryanf has joined #ruby
v0n has quit [Quit: WeeChat 0.4.0]
lusory has joined #ruby
arya has joined #ruby
JohnBat26 has joined #ruby
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
mahmoudimus has joined #ruby
bradleyprice has joined #ruby
kenneth has quit [Quit: kenneth]
<shevy> making games is not easy
<ddilinger> any good methods for lint checking your recipes? for example i tried "foo = data_bag('some_bag')<return> .map {|id| ... }<return> .select {|item| ... } i thought i was supposed to use ruby -c <filename> for lint check, but that things the preceding is 'Syntax OK' even though running it fails with 'unexpected '.', expecting $end'
carlzulauf has quit [Ping timeout: 240 seconds]
<ddilinger> s/things/thinks
jackyalcine has quit [Quit: Quit]
<ddilinger> i know i can escape the <return>, just wondering how i can get faster feedback from the interpreter without having to fire up a new instance
thinkclay has joined #ruby
statarb3 has quit [Ping timeout: 264 seconds]
maletor has joined #ruby
sayan has joined #ruby
sayan has quit [Changing host]
sayan has joined #ruby
abionic has joined #ruby
Spaceghost|cloud has joined #ruby
SeanTAllen has joined #ruby
Guest85414 has joined #ruby
pu22l3r has quit [Remote host closed the connection]
cableray has joined #ruby
ossareh has joined #ruby
robbyoconnor has joined #ruby
guns has joined #ruby
banisterfiend has joined #ruby
unsay has joined #ruby
dhruvasagar has quit [Ping timeout: 246 seconds]
ABK has quit [Ping timeout: 255 seconds]
wmoxam has joined #ruby
dhruvasagar has joined #ruby
subbyyy_ has quit [Ping timeout: 248 seconds]
itsdavem has quit [Remote host closed the connection]
decoponio has joined #ruby
banisterfiend has quit [Ping timeout: 248 seconds]
recycle has joined #ruby
Myconix has quit [Ping timeout: 248 seconds]
girija_ has joined #ruby
tommyvyo has quit [Quit: http://twitter.com/tommyvyo]
unsay has quit [Ping timeout: 260 seconds]
blacktulip has joined #ruby
ossareh has quit [Ping timeout: 246 seconds]
carlzulauf has joined #ruby
recycle has quit [Ping timeout: 248 seconds]
dhruvasagar has quit [Ping timeout: 276 seconds]
rippa has quit [Ping timeout: 240 seconds]
dhruvasagar has joined #ruby
michaelmartinez has quit [Quit: michaelmartinez]
ossareh has joined #ruby
jaywastaken has quit [Read error: Connection reset by peer]
jaywastaken has joined #ruby
jaywastaken has quit [Changing host]
jaywastaken has joined #ruby
blacktulip has quit [Ping timeout: 245 seconds]
girija_ has quit [Ping timeout: 248 seconds]
blacktulip has joined #ruby
quest88_ has quit [Quit: quest88_]
sayan has quit [Read error: Connection reset by peer]
bandu has quit [Quit: Leaving]
guns has quit [Quit: guns]
jonathanwallace has quit [Ping timeout: 252 seconds]
dhruvasa1ar has joined #ruby
ABK_ has joined #ruby
aryatosh has joined #ruby
freezway has quit [Ping timeout: 264 seconds]
abionic has quit [Ping timeout: 252 seconds]
Myconix has joined #ruby
joeycarmello has quit [Remote host closed the connection]
Retistic has joined #ruby
joeycarmello has joined #ruby
shock_one has joined #ruby
nomenkun has quit [Remote host closed the connection]
xandy is now known as xAndy
<Retistic> is there a way to do some_long_var = some_long_var.to_i without writing some_long_var twice?
lolmaus has joined #ruby
nomenkun has joined #ruby
Takehiro has joined #ruby
jamescarr_ has joined #ruby
<jamescarr_> shouldn't methods ending in ? return true or false???
<shevy> Retistic hmm dont think so
<jamescarr_> yeah
<jamescarr_> dude's shit is broke
<shevy> jamescarr_ ruby does not enforce any particular style. a method "foo" is valid, a method "foo?" is equally valid. you can use those methods to return whatever you like
<Retistic> shevy: :-( should be a to_i! method
josh_keith has quit [Quit: Leaving]
<shevy> Retistic hmm... I think there may be a reason why there is no .to_i!
<jamescarr_> reokay
<Retistic> shevy: yeah, i'm sure there is… its just unfortunate
<shevy> yeah I agree... in many of these situations though, there were reasons... like why there is no ++ operator in ruby
<shevy> I just could not tell you what the reason for no .to_i! is :\
aganov has joined #ruby
tfittsy has joined #ruby
joeycarmello has quit [Ping timeout: 260 seconds]
Bry8Star has joined #ruby
<shevy> hmm
<shevy> .to_i
<shevy> "Returns the result of interpreting leading characters in str as a decimal integer."
nomenkun has quit [Ping timeout: 246 seconds]
<shevy> "Extraneous characters past the end of a valid number are ignored."
<shevy> "If there is not a valid number at the start of str, 0 is returned."
<shevy> "The method never raises an exception."
<shevy> aha
<shevy> there is a .to_a method but no .to_a! method for strings
<shevy> Retistic it could be that self might change and this may not be allowed
thinkclay has quit [Quit: Leaving.]
ryanf has quit [Ping timeout: 264 seconds]
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
n1x has joined #ruby
<Retistic> shevy: ah that could be
<Retistic> shevy: yeah there are a bunch of to_x methods and none with bangs
himsin has quit [Remote host closed the connection]
<shevy> I think there is no implicit conversion via any ! method that changes the class of an object... the only time where I saw this happen was with a file called evil.rb -> http://www.oreillynet.com/ruby/blog/2007/04/ruby_code_that_will_swallow_yo.html
<shevy> dog = Dog.new
<shevy> dog.class = Cat
<shevy> p dog.class # => Cat
<shevy> :)
unsay has joined #ruby
<shevy> but to be honest... less metamagic is often more...
girija_ has joined #ruby
icole has quit [Remote host closed the connection]
<tfittsy> I'm trying to get a number value from a string that I then want to % 6. It doesn't really matter what the string number adds up to as long as it is random across different strings and always the same for the same string. Is there a better way than just adding up the ascii value of each character?
n1x has quit [Max SendQ exceeded]
<shevy> dunno... md5sum could be used on it or?
<shevy> require 'digest/md5'; Digest::MD5.hexdigest 'cat' # => "d077f244def8a70e5ea758bd8352fcd8"
x82_nicole has joined #ruby
xbayrockx has joined #ruby
<shevy> dunno what that gives when you do % 6 on it :P
xbayrockx is now known as wf2f
n1x has joined #ruby
bricker is now known as bricker`work
bricker`LA is now known as bricker
answer_42 has joined #ruby
<jamescarr_> what is self.instances?
<jamescarr_> as def self.instances
<shevy> that one seems odd
<jamescarr_> doesn't it
<jamescarr_> and yet, it remails
<shevy> who defined that method?
<shevy> and on what class
<shevy> I'd assume from the name alone that it attempts to give back an array of all instances of any given class
beneggett has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
gosshedd has quit [Ping timeout: 248 seconds]
<shevy> I'd expect all object_ids :P
<tfittsy> I guess .hash will work
elkclone has joined #ruby
whowantstolivefo has joined #ruby
havenn has quit [Remote host closed the connection]
ngoldman has joined #ruby
havenn has joined #ruby
havenn has quit [Read error: Connection reset by peer]
ryanf has joined #ruby
Konboi has quit [Remote host closed the connection]
tagrudev has joined #ruby
hackerdude has quit [Remote host closed the connection]
unsay has quit [Ping timeout: 248 seconds]
banjara has joined #ruby
kenneth has joined #ruby
Takehiro has quit [Remote host closed the connection]
tfittsy has quit [Ping timeout: 264 seconds]
tfittsy has joined #ruby
sayan has joined #ruby
love_color_text has quit [Remote host closed the connection]
Takehiro has joined #ruby
love_color_text has joined #ruby
benlieb has quit [Quit: benlieb]
bradleyprice has quit [Ping timeout: 240 seconds]
mahmoudimus has quit [Quit: Computer has gone to sleep.]
cableray has quit [Ping timeout: 276 seconds]
sayan has quit [Ping timeout: 245 seconds]
reset has quit [Ping timeout: 244 seconds]
oblio is now known as tc
AntiTyping has quit [Quit: AntiTyping]
cableray has joined #ruby
robustus has quit [Ping timeout: 248 seconds]
cableray has quit [Client Quit]
tcstar has quit [Ping timeout: 276 seconds]
robustus has joined #ruby
sjk has joined #ruby
rezzack has quit [Quit: Leaving.]
maletor has quit [Quit: Computer has gone to sleep.]
JumpMast3r has quit [Quit: JumpMast3r]
itsdavem has joined #ruby
x82_nicole has quit [Quit: Computer has gone to sleep.]
ngoldman has quit [Remote host closed the connection]
tvw has joined #ruby
murz has quit [Quit: Linkinus - http://linkinus.com]
huoxito has quit [Quit: Leaving]
yshh has joined #ruby
nga4 has quit []
itsdavem has quit [Ping timeout: 256 seconds]
ngoldman has joined #ruby
miso1337 has quit [Quit: afk]
Morkel has joined #ruby
shock_one has quit [Ping timeout: 246 seconds]
unsay has joined #ruby
havenn has joined #ruby
generalissimo has quit [Ping timeout: 245 seconds]
whowantstolivefo has quit [Read error: Connection reset by peer]
Liothen has quit [Read error: Connection reset by peer]
whowantstolivefo has joined #ruby
Liothen has joined #ruby
Liothen has quit [Changing host]
Liothen has joined #ruby
dcwu has quit [Read error: Connection reset by peer]
dcwu has joined #ruby
sayan has joined #ruby
mmitchell has quit [Read error: Connection reset by peer]
mmitchell has joined #ruby
sc_raptor has joined #ruby
james__ has quit [Remote host closed the connection]
chendo_ has quit [Ping timeout: 248 seconds]
chendo_ has joined #ruby
yshh has quit [Remote host closed the connection]
codespectator has quit [Quit: Computer has gone to sleep.]
Morkel_ has joined #ruby
M- has quit [Quit: This computer has gone to sleep]
Morkel has quit [Ping timeout: 264 seconds]
Morkel_ is now known as Morkel
unsay has quit [Ping timeout: 248 seconds]
yshh has joined #ruby
clocKwize has joined #ruby
Raboo has quit [Read error: Connection reset by peer]
Raboo has joined #ruby
pavilionXP has quit [Ping timeout: 248 seconds]
hemanth_ has quit [Read error: Connection reset by peer]
hemanth_ has joined #ruby
itsdavem has joined #ruby
mengu has joined #ruby
dcwu has quit [Read error: Connection reset by peer]
IrishGringo_ has joined #ruby
arya has quit [Ping timeout: 248 seconds]
dcwu has joined #ruby
ferdev has quit [Quit: ferdev]
oerrze has joined #ruby
aryatosh has quit [Ping timeout: 264 seconds]
mockra has quit [Read error: Connection reset by peer]
IrishGringo has quit [Ping timeout: 252 seconds]
gutsiest60 has quit [Ping timeout: 252 seconds]
mockra has joined #ruby
joeycarmello has joined #ruby
heckler has left #ruby ["Leaving"]
itsdavem has quit [Ping timeout: 252 seconds]
slainer68 has joined #ruby
arya has joined #ruby
aryatosh has joined #ruby
jduan1981 has quit [Quit: jduan1981]
gutsiest60 has joined #ruby
timeout has joined #ruby
joeycarmello has quit [Ping timeout: 252 seconds]
samuel02 has joined #ruby
dr_bob has joined #ruby
mengu has quit [Quit: Leaving]
mafolz has joined #ruby
anderse has joined #ruby
robbyoconnor has quit [Ping timeout: 245 seconds]
mockra has quit [Remote host closed the connection]
sayan has quit [Ping timeout: 248 seconds]
Solnse has quit [Ping timeout: 244 seconds]
cha1tanya has quit [Remote host closed the connection]
aryatosh_ has joined #ruby
arya_ has joined #ruby
noxoc has joined #ruby
mahmoudimus has joined #ruby
hyperboreean has quit [Ping timeout: 245 seconds]
bartj3 has joined #ruby
Hypn has joined #ruby
samlt has joined #ruby
markalanevans has joined #ruby
arya has quit [Ping timeout: 248 seconds]
aryatosh has quit [Ping timeout: 245 seconds]
jprovazn has joined #ruby
markalanevans has quit [Client Quit]
zommi has joined #ruby
zigomir has joined #ruby
codespectator has joined #ruby
stormetrooper has joined #ruby
dr_bob has quit [Quit: Leaving.]
hyperboreean has joined #ruby
chussenot has joined #ruby
buscon has joined #ruby
aryatosh_ has quit [Ping timeout: 264 seconds]
workmad3 has joined #ruby
unsay has joined #ruby
eldariof has joined #ruby
dmerrick has joined #ruby
<shevy> guys
mikepack has quit [Remote host closed the connection]
<shevy> def foo; return [1,2] end
<shevy> is the same as:
<shevy> def foo; return 1,2 end
<shevy> (I forgot a ; but nevermind, it is spaced on 3 lines anyway)
<shevy> which one of the two do you prefer, and why?
aryatosh has joined #ruby
altamic has joined #ruby
altamic has quit [Changing host]
altamic has joined #ruby
<havenn> shevy: I'd prefer: def foo; [1, 2] end
<shevy> hehe
<shevy> ok
osaut has joined #ruby
<havenn> shevy: 1, 2 seems overly clever, possibly. not sure implicit arrays are easy to grok
noxoc has quit [Quit: noxoc]
dmerrick has quit [Client Quit]
perun_ has quit [Ping timeout: 256 seconds]
roadt_ has quit [Ping timeout: 248 seconds]
noxoc has joined #ruby
roadt_ has joined #ruby
lkba has quit [Ping timeout: 264 seconds]
Elhu has joined #ruby
rburton- has joined #ruby
zeade has quit [Quit: Leaving.]
gosshedd has joined #ruby
tfittsy has quit [Ping timeout: 264 seconds]
razibog has joined #ruby
goraxe has quit [Ping timeout: 276 seconds]
ngoldman has quit [Remote host closed the connection]
<shevy> I concur
Vainoharhainen has joined #ruby
unsay has quit [Ping timeout: 276 seconds]
wchun has joined #ruby
recycle has joined #ruby
arya_ has quit [Ping timeout: 248 seconds]
noxoc has quit [Quit: noxoc]
workmad3 has quit [Ping timeout: 245 seconds]
ferdev has joined #ruby
Giorgio has joined #ruby
dhruvasa1ar has quit [Ping timeout: 245 seconds]
dhruvasagar has quit [Ping timeout: 255 seconds]
miso1337 has joined #ruby
jonahR has quit [Quit: jonahR]
nipara is now known as nipar
bluOxigen has joined #ruby
dhruvasagar has joined #ruby
mockra has joined #ruby
arya has joined #ruby
dhruvasa1ar has joined #ruby
chussenot has quit [Quit: chussenot]
beliveyourdream has joined #ruby
lkba has joined #ruby
hoelzro|away is now known as hoelzro
yshh has quit [Remote host closed the connection]
timeout has quit [Quit: "I'll be back..."]
ryanf has quit [Quit: leaving]
mockra has quit [Ping timeout: 244 seconds]
timeout has joined #ruby
eka has joined #ruby
mneorr has quit [Remote host closed the connection]
dcwu has quit [Quit: Leaving.]
freeayu__ has quit [Ping timeout: 255 seconds]
yshh has joined #ruby
beilabs has quit [Ping timeout: 252 seconds]
chussenot has joined #ruby
nomenkun has joined #ruby
chimkan__ has joined #ruby
skcin7 has quit [Quit: Computer has gone to sleep.]
acriax has joined #ruby
jaywastaken has quit [Read error: Connection reset by peer]
arya has quit [Ping timeout: 248 seconds]
jaywastaken has joined #ruby
jaywastaken has quit [Changing host]
jaywastaken has joined #ruby
afd___ has quit [Quit: No Ping reply in 180 seconds.]
maxmanders has joined #ruby
afd__ has joined #ruby
skcin7 has joined #ruby
miso1337 has quit [Quit: afk]
kristofers has joined #ruby
chimkan_ has quit [Ping timeout: 244 seconds]
poga has joined #ruby
<acriax> Hi, I'm attempting to learn Ruby, and it's going well, but I have trouble with expecting when to use symbols and when to use symbols, and when to use other variables. Is there some kind of logical system I'm not seeing?
tfittsy has joined #ruby
<acriax> Like here, why is :name in the attr_accessor a symbol when it isn't anywhere else in the class?: https://gist.github.com/4690158
arya has joined #ruby
<hoelzro> acriax: symbols tend to be used in metaprogramming (like attr_accessor)
<hoelzro> they are also commonly used as hash keys
<acriax> but like, strings CAN be used in attr_accessor (but with worse performance)?
pavilionXP has joined #ruby
<hoelzro> honestly, I've not tried strings with attr_accessor
zeade has joined #ruby
<hoelzro> and they probably wouldn't be slower
aryatosh has quit [Ping timeout: 244 seconds]
<hoelzro> well, the call to attr_accessor might
<hoelzro> but the difference would be negligible
<acriax> Ok
unsay has joined #ruby
w3pm has quit []
buibex has joined #ruby
buibex has quit [Client Quit]
ngoldman has joined #ruby
<acriax> The part in that code which has me confused is really why it isn't @name = :name instead of @name = name
main_ has joined #ruby
jbw has joined #ruby
itsdavem has joined #ruby
<acriax> Or rather, how ruby manages to couple :name with name
beilabs has joined #ruby
lormn has joined #ruby
<acriax> I guess it's something happening behind the curtains of attr_accessor
<hoelzro> acriax: name is a variable
<hoelzro> :name is a value
<hoelzro> attr_accessor isn't actually that complex; you could implement it yourself
aryatosh has joined #ruby
<lormn> hi, i tried gem install arcadia on my fedora laptop and keep getting this error: "Arcadia require ruby-tk extension and tcl/tk run-time you must install before run .." I tried to install all tk packages I found in the repos but still same error.. please advice
<hoelzro> oh, another use for symbols is as flags for methods
Dreamer3 has joined #ruby
<tobiasvl> acriax: check out #7 for example
<acriax> Alright, thanks you two!
imami|afk is now known as banseljaj
miso1337 has joined #ruby
soc42 has joined #ruby
beilabs has quit [Ping timeout: 246 seconds]
jimeh has joined #ruby
itsdavem has quit [Ping timeout: 264 seconds]
skcin7 has quit [Quit: Computer has gone to sleep.]
mercwithamouth has quit [Ping timeout: 248 seconds]
freeayu has joined #ruby
tjbiddle_ has joined #ruby
tjbiddle_ has quit [Client Quit]
marr has joined #ruby
charliesome has joined #ruby
hakunin_ has joined #ruby
hakunin has quit [Read error: Connection reset by peer]
ferdev_ has joined #ruby
ngoldman has quit [Ping timeout: 260 seconds]
zeade has quit [Quit: Leaving.]
mcqueenorama has quit [Remote host closed the connection]
bartj3 has quit []
hikariHe has joined #ruby
ferdev_ has quit [Client Quit]
chimkan__ has quit [Ping timeout: 240 seconds]
mneorr has joined #ruby
tjbiddle has quit [Ping timeout: 248 seconds]
recycle has quit [Remote host closed the connection]
rburton- has quit [Quit: Linkinus - http://linkinus.com]
unsay has quit [Ping timeout: 256 seconds]
chussenot has quit [Quit: chussenot]
reinaldob has joined #ruby
aryatosh has quit [Ping timeout: 248 seconds]
pavilionXP has quit [Read error: Connection timed out]
adeponte has joined #ruby
noxoc has joined #ruby
willbradley has joined #ruby
clooth has joined #ruby
wallerdev has quit [Quit: wallerdev]
shock_one has joined #ruby
adeponte has quit [Client Quit]
Konboi has joined #ruby
itsdavem has joined #ruby
robotmay has joined #ruby
love_color_text has quit [Remote host closed the connection]
<lormn> i tried gem install arcadia on my fedora laptop and keep getting this error: "Arcadia require ruby-tk extension and tcl/tk run-time you must install before run .." I tried to install all tk packages I found in the repos but still same error.. please advice
grzywacz has joined #ruby
<shevy> lormn you must have tcl and tk installed, and the ruby bindings to these
<shevy> since you use fedora, you need to ask fedora how they packaged up those things
yshh has quit [Remote host closed the connection]
<shevy> otherwise, if you would have compiled from source, in the ruby ext/ directory should be the tcl/ or tk/ directory, which you could go into, and run extconf.rb there. this would give you the specific error
love_color_text has joined #ruby
beilabs has joined #ruby
yshh has joined #ruby
<lormn> shevy: i installed tcl and tk already. and ran gem search tk and installed everything i found there.. not sure if its a fedora issue
aryatosh has joined #ruby
adeponte has joined #ruby
<shevy> acriax usually when you need flexibility, you use strings, but when you need unique identifiers, that are fast and always the same, you use symbols
<shevy> what is your ruby version 'ruby -v'
<lormn> ruby 1.9.3p362 (2012-12-25 revision 38607) [x86_64-linux]
<shevy> I am in this directory right now/Depot/Temp/ruby-1.9.3p374/ext/tk/
<shevy> this is where the tk bindings are
<shevy> now I run "ruby extconf.rb"
blaxter has joined #ruby
<shevy> and I get an error
<shevy> Search tcl.h.checking for tcl.h... no
itsdavem has quit [Ping timeout: 255 seconds]
<shevy> Search tk.h.checking for tk.h... no
<willbradley> heya, i've got a array of hashes like [{:name => "John", :id => 1},{:name => "John", :id => 2}]
<shevy> ok, I have to compile tcl and tk first
<willbradley> i'm trying to end up with just a single instance of "John"
<shevy> and what would the :id be
<willbradley> any ideas? ruby 1.8.7
<willbradley> doesn't matter
<shevy> ok
<willbradley> as long as it exists
<willbradley> i try examples found online but i get "symbol used as index" errors
poseid has joined #ruby
<poseid> when I do: B = Class.new A
beilabs has quit [Ping timeout: 252 seconds]
<shevy> array.find {|e| e[:name] == 'John' } # => {:name=>"John", :id=>1}
<poseid> How would i overwrite instance methods from A ?
<poseid> e.g. A has def foo; end;
<shevy> poseid what is that
<poseid> and I want to overwrite this for B
toekutr has quit [Read error: Connection reset by peer]
<shevy> what is A
tvw has quit [Remote host closed the connection]
<willbradley> shevy: what about deduping an array of ~100?
<poseid> it's the superclass
aryatosh has quit [Ping timeout: 248 seconds]
<willbradley> not just finding a single known one
<poseid> some class
<willbradley> thanks btw
oerrze has quit [Quit: Leaving...]
<shevy> willbradley deduping? I dont even know what that word means
<willbradley> de-duplicating, getting rid of duplicate entries
<willbradley> by :name
<poseid> e.g. B= Class.new Struct.new(:foo)
<shevy> hmmm so you now have another question? you want to get rid of duplicates?
nfk has joined #ruby
<willbradley> yes that's what i meant by the original question
<shevy> ok, I thought you want to find something :D
slainer68 has quit [Ping timeout: 276 seconds]
<willbradley> sorry :P
<poseid> When I do B.new --> I want to overwrite foo from A
<shevy> willbradley this may be trickier
<willbradley> yeah
<shevy> if it would be a simple array, you could run .uniq on it
<willbradley> i'm about to give up and dump names to an array and forget about trying to sort
<shevy> but as it is an array with different hashes, you need to somehow make a selection
poga has quit [Remote host closed the connection]
arya has quit [Ping timeout: 248 seconds]
yshh has quit [Remote host closed the connection]
<shevy> you could perhaps try to make a .select statement to return all unique entries, and ignore the others
adeponte has quit [Remote host closed the connection]
<shevy> or you could construct a new hash or array and add only unique elements to it
<willbradley> hmm maybe i should mess around in rails some more
berkes has joined #ruby
berkes has quit [Remote host closed the connection]
Takehiro has quit [Read error: Connection reset by peer]
<shevy> usually when things seem complicated, there is an easy way
<willbradley> cool thanks
<willbradley> the problem is it's based on a relationship; classes.user.name
<shevy> I myself am usually too lazy to find the easy way, I simplify the data structures I use ;)
<willbradley> and when it hits a nil user, it freaks out
<shevy> poseid can't you use real classes instead? in your child method you could either redefine "def foo", or call super() from within foo
aryatosh has joined #ruby
kpshek has joined #ruby
Giorgio has quit [Read error: Connection reset by peer]
browndawg1 has joined #ruby
<shevy> willbradley well you can split it up into chunks, and check for nil before
<poseid> hmm.. yes.. it's just that I am experimenting with some methods in IRB
<shevy> get_element = bla.select
<shevy> unless get_element.nil?
<shevy> do_something_here
<poseid> I though that quickly overriding a method would help me
<shevy> you can always override a method on any object
perun_ has joined #ruby
rdark has joined #ruby
rezzack has joined #ruby
codecop has joined #ruby
tfittsy has quit [Ping timeout: 244 seconds]
browndawg has quit [Ping timeout: 276 seconds]
<willbradley> shevy: problem is i have to sort with nils included
<shevy> poseid class Foo; def test; puts 'test'; end; end; foo = Foo.new; foo.test # => "test"; class Foo; def test; puts 'ok'; end; end; foo.test # => "ok"
<shevy> def foo.test # would also work
<willbradley> if rails didn't freak out about nils it'd be fine (just display nothing there, treat it as -1 < nil > 1
<shevy> willbradley how do you want to sort nil?
<shevy> it has no real characteristic to be sorted
<shevy> you could run a .sort_by and inside that define the logic how to treat when nil happens
lormn has quit [Quit: Page closed]
<shevy> rails uses ruby so any problem can be solved in ruby
<willbradley> i was thinking about that; how would you write that?
cdt has joined #ruby
<shevy> dunno
<willbradley> i'm unfamiliar with complicated logic inside a sort_by
<shevy> I'd sanitize my datastructure before, and I don't use rails :\
<shevy> willbradley, I usually play in irb until things work
kpshek has quit [Ping timeout: 276 seconds]
codecop has quit [Client Quit]
nomenkun has quit [Read error: Connection reset by peer]
aryatosh has quit [Ping timeout: 245 seconds]
codecop has joined #ruby
nomenkun has joined #ruby
<shevy> %w{ apple pear fig }.sort_by {|word| word.length}
juco has joined #ruby
<reactormonk> shevy, and post the resulting code on instacode?
adeponte has joined #ruby
<shevy> hey where is willbradley
<shevy> oh here he is ... willbradley ['apple',nil,'pear','fig'].sort_by {|word| word.to_s.length} # => [nil, "fig", "pear", "apple"]
beilabs has joined #ruby
<shevy> reactormonk, what is instacode?
love_color_text has quit [Remote host closed the connection]
<shevy> I am the classical guy, I have irb running in one tab of my terminal all the time. I even use yakuake :D
<shevy> I'd wish they would make a desktop environment based on advanced keybindings and advanced terminals with tabs alone
<shevy> cool
unsay has joined #ruby
<shevy> how does that work? does this make a screenshot?
<reactormonk> shevy, nah, you upload code and apply filters
<shevy> hmm lemme try
<hoelzro> shevy: like Awesome? ;)
<shevy> ack
<shevy> "Please paste at least 10 lines of code"
ahokaomaeha has quit [Ping timeout: 252 seconds]
<reactormonk> shevy, yeah, you need something to fill the image
<shevy> they want me to write 9 newlines for every 1 line of code :(
<shevy> cool... you can zoom into this hahaha
<shevy> reactormonk, sorry, this is over my head...
itsdavem has joined #ruby
<shevy> but it looks very cool
<reactormonk> shevy, yeah, I preferred the previous interface
<shevy> hehe
beilabs has quit [Ping timeout: 245 seconds]
mockra has joined #ruby
hakunin_ has quit [Remote host closed the connection]
<shevy> hoelzro I am not sure... whenever I tried to use those kind of WMs, I felt as if they were getting into my way more than i.e. fluxbox, and they seemed super minimalistic rather than integrative
<shevy> but I shall give awesomeWM another try!
aryatosh has joined #ruby
arya has joined #ruby
recycle has joined #ruby
<shevy> the thing is, I love tabs, but not in the same window
<hoelzro> well, it's a lot of work to set up, I'm not going to lie
<hoelzro> but to me, it's worth it
hakunin has joined #ruby
<shevy> ok
<hoelzro> shevy: what do you mean by "tabs, but not in the same window"?
<reactormonk> shevy, currently trying to hack some tiling into kwin ;-)
<shevy> I'll give it a try again... I think the last try was like... 4 years ago or something like that...
<shevy> hoelzro well, this modal interface, it splits up the current window into sub-parts, right? I can't work with something like that
<hoelzro> well, in Awesome, the entire screen is split up into tiles
<shevy> I think for my editor and my browser I need a 100% view
<hoelzro> each window is given a tile
<hoelzro> you can do that
<hoelzro> my browser is always full screened
<shevy> aha, ok
banjara has quit [Quit: Leaving.]
<hoelzro> there's also a WM called subtle
<hoelzro> which, as I understand it, is AwesomeWM =~ s/Lua/Ruby/
JonnieCache has quit [Quit: leaving]
itsdavem has quit [Ping timeout: 264 seconds]
Ralt has quit [Remote host closed the connection]
mockra has quit [Ping timeout: 260 seconds]
greenarrow has quit [Ping timeout: 255 seconds]
greenarrow has joined #ruby
recycle has quit [Ping timeout: 264 seconds]
aryatosh has quit [Ping timeout: 256 seconds]
unsay has quit [Ping timeout: 264 seconds]
yshh has joined #ruby
cha1tanya has joined #ruby
<poseid> shevy: Ok, now I have it: it's C.class_eval("def bar; 1; end")
ablegreen has quit [Quit: Page closed]
beilabs has joined #ruby
chussenot has joined #ruby
aryatosh has joined #ruby
itsdavem has joined #ruby
elaptics`away is now known as elaptics
<shevy> aaaah the good old eval way
fyolnish has quit [Remote host closed the connection]
mahmoudimus has quit [Quit: Computer has gone to sleep.]
dekronin1 has quit [Quit: leaving]
<poseid> yes... it's rather new to me ;-)
nari has quit [Ping timeout: 245 seconds]
anderse has quit [Quit: anderse]
aryatosh has quit [Client Quit]
<poseid> looks like meta-programming, which shouldn't be good for maintainable code
vinax has joined #ruby
horofox has joined #ruby
<poseid> but maybe for quick-and-dirty experiments it's nice
rezzack has quit [Quit: Leaving.]
M-- has joined #ruby
liquid-silence has quit [Ping timeout: 260 seconds]
itsdavem has quit [Ping timeout: 264 seconds]
shock_one has quit [Ping timeout: 255 seconds]
beilabs has quit [Ping timeout: 276 seconds]
buibex has joined #ruby
Elhu_ has joined #ruby
browndawg1 has left #ruby [#ruby]
browndawg has joined #ruby
fflush has quit [Ping timeout: 240 seconds]
mahmoudimus has joined #ruby
guns has joined #ruby
fflush has joined #ruby
mneorr has quit [Remote host closed the connection]
reinaldob has quit [Remote host closed the connection]
JohnBat26 has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
sayan has joined #ruby
workmad3 has joined #ruby
rotor has joined #ruby
seich has quit [Ping timeout: 245 seconds]
sulaco_ has quit [Read error: Connection reset by peer]
sulaco has joined #ruby
chiel`afk is now known as chiel
JohnBat26 has joined #ruby
beilabs has joined #ruby
Konboi has quit [Ping timeout: 276 seconds]
yshh has quit [Remote host closed the connection]
poikon has joined #ruby
cardoni has quit [Quit: cardoni]
aaronmacy has quit [Quit: Leaving.]
<shevy> dunno
<shevy> I hate every line that has eval in it
<shevy> when I came to a project weeks lateron and I saw an eval, it took me longer than other parts of the code to understand what and why I did it that way
beilabs has quit [Ping timeout: 248 seconds]
mahmoudimus has quit [Quit: Computer has gone to sleep.]
unsay has joined #ruby
<shevy> hey guys
<shevy> if you have a class in a module
arya has quit [Ping timeout: 256 seconds]
ossareh has quit [Ping timeout: 276 seconds]
<shevy> would you rather do this:
<shevy> module Foo
<shevy> class Bar
<shevy> def test
<shevy> or rather
<shevy> module Foo
<shevy> class Bar
<shevy> def test
angusigu1ss has joined #ruby
<shevy> IF it is the only class in the .rb file in question?
<havenn> indentation only difference?
<shevy> in the first example, I feel I need so much indent
<shevy> yeah havenn
<havenn> the former
<shevy> ok
poikon has quit [*.net *.split]
adeponte has quit [*.net *.split]
dhruvasagar has quit [*.net *.split]
whowantstolivefo has quit [*.net *.split]
jamescarr_ has quit [*.net *.split]
wookiehangover has quit [*.net *.split]
Eiam has quit [*.net *.split]
[Neurotic] has quit [*.net *.split]
angusiguess has quit [*.net *.split]
CorpusCallosum has quit [*.net *.split]
x0F has quit [*.net *.split]
billy_ran_away has quit [*.net *.split]
robert_ has quit [*.net *.split]
yeltzooo has quit [*.net *.split]
Skelz0r has quit [*.net *.split]
coaster has quit [*.net *.split]
earthquake has quit [*.net *.split]
thomasfedb has quit [*.net *.split]
pcboy_ has quit [*.net *.split]
darkc0met has quit [*.net *.split]
kanzure has quit [*.net *.split]
mtfk has quit [*.net *.split]
bier has quit [*.net *.split]
pietr0 has quit [*.net *.split]
scrr has quit [*.net *.split]
Sp4rKy has quit [*.net *.split]
mnemon has quit [*.net *.split]
michele has quit [*.net *.split]
rcsheets has quit [*.net *.split]
jhowarth has quit [*.net *.split]
timmow has joined #ruby
hikariHe has quit [Read error: Connection reset by peer]
reinaldob has joined #ruby
reinaldob has quit [Read error: Connection reset by peer]
<havenn> then if you end up adding other classes, already g2g, and just 'looks right' i think
hikariHe has joined #ruby
jamescarr has joined #ruby
aaronmcadam has joined #ruby
<workmad3> shevy: I'm with havenn... however, if you can ensure that module Foo will already exist, I'm also perfectly happing with 'class Foo::Bar'
poikon has joined #ruby
adeponte has joined #ruby
dhruvasagar has joined #ruby
whowantstolivefo has joined #ruby
wookiehangover has joined #ruby
[Neurotic] has joined #ruby
Eiam has joined #ruby
CorpusCallosum has joined #ruby
billy_ran_away has joined #ruby
x0F has joined #ruby
yeltzooo has joined #ruby
Skelz0r has joined #ruby
robert_ has joined #ruby
pietr0 has joined #ruby
coaster has joined #ruby
earthquake has joined #ruby
thomasfedb has joined #ruby
bier has joined #ruby
pcboy_ has joined #ruby
darkc0met has joined #ruby
mtfk has joined #ruby
mnemon has joined #ruby
Sp4rKy has joined #ruby
michele has joined #ruby
rcsheets has joined #ruby
jhowarth has joined #ruby
scrr has joined #ruby
aef has quit [Excess Flood]
[Neurotic] has quit [Excess Flood]
whowantstolivefo has quit [Max SendQ exceeded]
kanzure has joined #ruby
whowantstolivefo has joined #ruby
aef has joined #ruby
ossareh has joined #ruby
jamescarr has quit [Quit: jamescarr]
[Neurotic] has joined #ruby
lkba has quit [Ping timeout: 256 seconds]
KillerFox has quit [Ping timeout: 248 seconds]
horofox has quit [Quit: horofox]
KillerFox has joined #ruby
itsdavem has joined #ruby
blueOxigen has joined #ruby
dr_bob has joined #ruby
beliveyourdream_ has joined #ruby
beliveyourdream has quit [Ping timeout: 255 seconds]
JohnBat26 has quit [Ping timeout: 276 seconds]
havenn has quit [Remote host closed the connection]
bluOxigen has quit [Ping timeout: 260 seconds]
seich- has joined #ruby
itsdavem has quit [Ping timeout: 252 seconds]
beilabs has joined #ruby
unsay has quit [Ping timeout: 276 seconds]
JohnBat26 has joined #ruby
Elhu_ has quit [Read error: Connection reset by peer]
arkiver has joined #ruby
horofox has joined #ruby
beliveyourdream_ has quit [Read error: Connection reset by peer]
JumpMast3r has joined #ruby
beliveyourdream has joined #ruby
traph has quit [Quit: Lost terminal]
arya has joined #ruby
arturaz has joined #ruby
anderse has joined #ruby
TomJ_ has joined #ruby
beilabs has quit [Ping timeout: 255 seconds]
<shevy> hmm
browndawg has quit [Quit: Leaving.]
<shevy> how would you arrange on the latter?
<shevy> class Foo::Bar
<shevy> def test
<shevy> or?
<shevy> I dunno, the :: disturbs me somewhat :\
TomJ has quit [Ping timeout: 248 seconds]
TomJ_ is now known as TomJ
<shevy> I am going to look at some popular gems to see what the people do there
browndawg has joined #ruby
arya has quit [Ping timeout: 264 seconds]
dhruvasa1ar has quit [Read error: Connection reset by peer]
dhruvasagar has quit [Ping timeout: 244 seconds]
dhruvasagar has joined #ruby
dhruvasa1ar has joined #ruby
Xeago has joined #ruby
mockra has joined #ruby
horofox has quit [Quit: horofox]
banjara has joined #ruby
yacks has quit [Ping timeout: 248 seconds]
Retistic has quit [Quit: Retistic]
dekroning has joined #ruby
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
mockra has quit [Ping timeout: 248 seconds]
mklappstuhl has joined #ruby
jprovazn has quit [Quit: Leaving]
banisterfiend has joined #ruby
arya has joined #ruby
wargasm1 has quit [Ping timeout: 248 seconds]
statarb3 has quit [Client Quit]
robotmay_ has joined #ruby
hikariHe has quit [Ping timeout: 255 seconds]
TheFuzzball has joined #ruby
robotmay has quit [Ping timeout: 264 seconds]
banjara has quit [Ping timeout: 256 seconds]
suf has quit [Read error: Connection reset by peer]
johndouthat has quit [Quit: johndouthat]
unsay has joined #ruby
apoch632 has joined #ruby
renanoronfle has joined #ruby
tvw has joined #ruby
browndawg has quit [Quit: Leaving.]
renanoronfle has quit [Client Quit]
nanothief has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
matti has quit [Changing host]
matti has joined #ruby
greenarrow has quit [Read error: Connection reset by peer]
plotter has joined #ruby
greenarrow has joined #ruby
browndawg has joined #ruby
arietis has joined #ruby
itsdavem has joined #ruby
Hanmac_ has joined #ruby
renanoronfle has joined #ruby
jgrevich has quit [Remote host closed the connection]
ngoldman has joined #ruby
arya has quit [Ping timeout: 256 seconds]
cardoni has joined #ruby
itsdavem has quit [Ping timeout: 255 seconds]
ngoldman has quit [Ping timeout: 246 seconds]
unsay has quit [Ping timeout: 244 seconds]
vinax has quit [Ping timeout: 264 seconds]
Elhu has quit [Quit: Computer has gone to sleep.]
niklasb has joined #ruby
arya has joined #ruby
apoch632 has quit [Quit: Leaving.]
itsdavem has joined #ruby
apoch632 has joined #ruby
shock_one has joined #ruby
arya has quit [Ping timeout: 248 seconds]
Michael_ has joined #ruby
bluOxigen has joined #ruby
Targen has quit [Ping timeout: 245 seconds]
cardoni has quit [Ping timeout: 252 seconds]
apoch632 has quit [Client Quit]
blueOxigen has quit [Ping timeout: 252 seconds]
matti has quit [Changing host]
matti has joined #ruby
arya has joined #ruby
itsdavem has quit [Ping timeout: 245 seconds]
banjara has joined #ruby
jaywastaken has quit [Read error: Connection reset by peer]
jaequery has quit [Quit: Computer has gone to sleep.]
samphippen has joined #ruby
jaywastaken has joined #ruby
jaywastaken has quit [Changing host]
jaywastaken has joined #ruby
reinaldob has joined #ruby
emanon_ has joined #ruby
arietis has quit [Quit: Computer has gone to sleep.]
Elhu has joined #ruby
<timmow> I might e missing something here, but I can't seem to find a gem that provides a rake task to generate a file from erb
shtirlic has joined #ruby
<timmow> its simple enough to do as your own task, but seems like the sort of thing that would be nice to have as a shared dependency
yacks has joined #ruby
sayan has quit [Ping timeout: 248 seconds]
yeban has joined #ruby
cha1tanya has quit [Ping timeout: 248 seconds]
soc42 has quit [Remote host closed the connection]
TotalEvil has joined #ruby
<TotalEvil> hi2all
<TotalEvil> can anyone help fix script?
<jokke> hi!
<jokke> me, probably not :/
<TotalEvil> i'm newbie to ruby(
<jokke> i'm a n00b myself
<TotalEvil> xDD
<TotalEvil> 2 noobs)
<tobiasvl> TotalEvil: you still haven't fixed the script from yesterday?
fermion has joined #ruby
<TotalEvil> yeap tobias
<TotalEvil> work day was off
<TotalEvil> but
<TotalEvil> have progress
<tobiasvl> what have you done since yesterday, and where's the problem?
<jokke> i need help too :) my script tries to execute following:
<jokke> echo "bli
<jokke> blub
<jokke> " | dmenu -b -l 20 -nf "#FFFFFF" -nb "#000000" -sf "#555555" -sb "#BBBBBB" -p "bla"
<TotalEvil> problem left only with send variables
banjara has quit [Ping timeout: 255 seconds]
<TotalEvil> puts show all correct
<jokke> and i get this error:
<jokke> dmenu-edit.rb:115:in ``': No such file or directory - command (Errno::ENOENT)
<TotalEvil> but sending to host incorrect
<jokke> from dmenu-edit.rb:115:in `execute'
<jokke> from dmenu-edit.rb:196:in `<main>'
<tobiasvl> TotalEvil: i don't understand what that means. please give an example on gist.
arietis has joined #ruby
clooth has quit [Read error: Connection reset by peer]
<tobiasvl> jokke: that's likewise impossible to debug without the code. please gist
<jokke> ok
adeponte has quit [Remote host closed the connection]
<jokke> tobiasvl: http://paste.xinu.at/n6E9/
clooth has joined #ruby
<TotalEvil> line 69
<TotalEvil> i debug it with puts
<TotalEvil> and get all correct params
apoch632 has joined #ruby
<TotalEvil> but at action at line 72-73
<tobiasvl> TotalEvil: do you realize that you never close the string on line 69?
<TotalEvil> sends wrong
<TotalEvil> why
recycle has joined #ruby
unsay has joined #ruby
<TotalEvil> before problem was with output) problem was newlines at output
apoch632 has quit [Remote host closed the connection]
IdlePhD has joined #ruby
<tobiasvl> TotalEvil: you never close the string
<tobiasvl> there's no " on the end of line 69
<TotalEvil> nlah
<TotalEvil> blah i see)
tagrudev has quit [Remote host closed the connection]
<TotalEvil> mb removed when editing
<TotalEvil> oh no
<TotalEvil> it's just bad gist
<TotalEvil> copy
<tobiasvl> jokke: you try to run the command called 'command'
<TotalEvil> i will recopy now
tagrudev has joined #ruby
<jokke> face -> desk
<tobiasvl> jokke: selection = `#{command}`
<tobiasvl> jokke: if you read the error message you got, that's exactly what it tells you ;)
<TotalEvil> now correct https://gist.github.com/4690789
Spooner has joined #ruby
<tobiasvl> TotalEvil: ok, so what's the problem exactly
p2w has joined #ruby
<IdlePhD> sorry to intrude, but I had a quick question, anyone install gltail on ubuntu12.04?
carloslopes has joined #ruby
<TotalEvil> 69 line parameters gets wrong at remote host
<shevy> TotalEvil will you or will you not learn ruby
<TotalEvil> seems problems still with commands
<TotalEvil> but puts show all correct
<tobiasvl> TotalEvil: but what does that MEAN? can you show me output? ANYTHING?
<TotalEvil> yeap
<tobiasvl> well please do then
<tobiasvl> i got nothing to go on
<shevy> he does not like to show the errors he gets :>
sayan has joined #ruby
<TotalEvil> Error performing action:
<TotalEvil> unknown option -I:3306
<TotalEvil> Error performing action: Using config file: /etc/haproxy/haproxy.cfg, listener: mysql
<TotalEvil> it's error
<jokke> tobiasvl: yes sure.. i got that :)
<shevy> what is the FULL command you try there TotalEvil
<TotalEvil> -a add -w -l mysql -s NewAntares -t "192.168.7.101":3306 -e "inter 3000 rise 2 fall 3 maxconn 1"
<shevy> and are you sure that on bash "-I:3306" works
<TotalEvil> correct output
<TotalEvil> same Hostname -I
<shevy> where is the leading command before -a ?
<TotalEvil> but at remote it get -I
<TotalEvil> see gist
poga has joined #ruby
<TotalEvil> -I:3306 must be not a command
<shevy> yes, where in the gist is the full command?
mockra has joined #ruby
<TotalEvil> just output
<shevy> what does that even mean
<TotalEvil> 62-63 line
<tobiasvl> TotalEvil: english isn't your first language, is it
<TotalEvil> yeap(
<shevy> hehehe
robbyoconnor has joined #ruby
<TotalEvil> Ukrainian native
<shevy> yeah
h8R has quit [Read error: Connection reset by peer]
itsdavem has joined #ruby
JarJar has joined #ruby
<TotalEvil> at line 62 command get ip address of server
reinaldob has quit [Remote host closed the connection]
<shevy> We always seem to miss information when we write to each other, TotalEvil
<TotalEvil> so to remote server must send just that ip adress not a command
<TotalEvil> ( yeap
samphippen has quit [Quit: Computer has gone to sleep.]
h8R has joined #ruby
<shevy> TotalEvil, the code you have there is no good
<TotalEvil> but as i see( it try send a not full command but need send just ouput from command
<shevy> for instance, look at this:
<shevy> sess_sticky = "#{ENV['OPT_SESSION_STICKINESS']}".downcase
<shevy> why is there a #{}
<TotalEvil> that not using
<shevy> no no that is not the point... code you have should be short and useful
<TotalEvil> wait i will remove unused stuffs
<shevy> I not trust the person who wrote this script
<shevy> *I do not
Dreamer3 has quit [Quit: Computer has gone to sleep.]
<shevy> TotalEvil can't we just start from zero?
mockra has quit [Ping timeout: 248 seconds]
recycle has quit [Remote host closed the connection]
p2w has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
itsdavem has quit [Ping timeout: 264 seconds]
<TotalEvil> sure
<shevy> TotalEvil ok then:
<shevy> can you give me the command you would use in bash?
unsay has quit [Ping timeout: 244 seconds]
<TotalEvil> i trought it would be easilly modify that
<shevy> the FULL command
<shevy> perhaps for tobiasvl
<shevy> but I find this to be a complete mess
<jokke> TotalEvil: hm okay, i just got it to work kind of.. my problem: my command defined in a Command instance won't be executed. or maybe it is, but not as intended. I tried defining a Command with the command urxvt -e Bla but nothing happened when i selected it.
<TotalEvil> ))
<TotalEvil> mb better i start with explain what it must to do
<shevy> TotalEvil please please please do not
<shevy> when you try to explain, you only confuse
<jokke> tobiasvl: here's the updated code http://paste.xinu.at/NrGhYW/
<shevy> TotalEvil, I generate this string right now:
<shevy> -a add -w -l mysql -s computer -t "10.0.0.1":3306 -e "inter 3000 rise 2 fall 3 maxconn 1"
<shevy> TotalEvil, please correct this string ^^^
Michael_ has quit [Remote host closed the connection]
<shevy> tell me what is wrong, so I can correct it
<TotalEvil> this script must run after backend server boot and add it into loadbalancer (haproxy) via ssh access run command on LoadBalancer server with options from BackEnd
<shevy> ...
<TotalEvil> competely at remote
rakuN has joined #ruby
<TotalEvil> it must be haproxy_config_server.rb -a add -w -l mysql -s computer -t "10.0.0.1":3306 -e "inter 3000 rise 2 fall 3 maxconn 1"
<TotalEvil> in current script problem is
liquid-silence has joined #ruby
liquid-silence has quit [Max SendQ exceeded]
<TotalEvil> i get not 10.0.0.1:3306 just part from command hostname -I so i get -I:3306 which is incorrect
liquid-silence has joined #ruby
rakuN has quit [Client Quit]
Dreamer3 has joined #ruby
<shevy> TotalEvil, why
<shevy> why must it include haproxy_config_server.rb
horofox has joined #ruby
<TotalEvil> haproxy_config_server.rb it's run on remote
<shevy> TotalEvil ok the solution is
<TotalEvil> from backend we run that script with own parameters
<shevy> -t \"#{server_ip}\":#{port}
itsdavem_ has joined #ruby
<shevy> ^^^ server_ip is not added
<shevy> you must find out why it is not added
<shevy> no wait
<shevy> where from does the -I come?
<shevy> oh yeah
<TotalEvil> server_ip=`hostname -I`
<shevy> server_ip=`hostname -I`
<TotalEvil> from this must
<TotalEvil> but 1 more thing
<shevy> this returns a wrong result
<TotalEvil> i tried server_ip="1.1.1.1"
<TotalEvil> and get same
<shevy> not possible
<TotalEvil> how it can be possible>
atno has joined #ruby
<shevy> you must have done something wrong
<shevy> no, not possible
<shevy> you made something else in addition to that
<tobiasvl> jokke: i don't understand what your current problem is. "nothing happened" is not a good error report. what do you mean you "selected" it?
<shevy> TotalEvil try it now. set server_ip="1.1.1.1" again.
<TotalEvil> same
<TotalEvil> hmm
<TotalEvil> how it can be
<shevy> TotalEvil no, not possible. you lie. show the code.
banjara has joined #ruby
<jokke> tobiasvl: are you on a linux system?
<tobiasvl> jokke: yes
<jokke> if you have dmenu installed, you can test it
<jokke> it's a wrapper for dmenu
<tobiasvl> i have no idea what dmenu is
<shevy> TotalEvil, yes, this will have a string with "-t 1.1.1.1" in it
<TotalEvil> but i get same error(
<tobiasvl> jokke: i'd rather be able to understand your problem without having to install and run your stuff
<TotalEvil> with -I
<shevy> TotalEvil does args contain 1.1.1.1 ?
Konboi has joined #ruby
<shevy> jokke you always mix up tobiasvl with TotalEvil ;)
<jokke> ah
<jokke> sorry
<TotalEvil> DD
<tobiasvl> please don't
<tobiasvl> we're pretty different people i think
<jokke> tab completion
<tobiasvl> hehe
<shevy> TotalEvil, does args include the '1.1.1.1'
haxrbyte has joined #ruby
Hypn has quit [Remote host closed the connection]
<tobiasvl> jokke: okay, now i know roughly what dmenu is. now what? i still don't know what your problem is :P
<shevy> hehehe
<tobiasvl> this is a ruby support channel, not dmenu support. what doesn't work in your code?
haxrbyte_ has quit [Ping timeout: 248 seconds]
<shevy> tobiasvl my cat is choking on something. can you help?
adambeynon has joined #ruby
sayan has quit [Read error: Connection reset by peer]
haxrbyte_ has joined #ruby
shtirlic has quit [Remote host closed the connection]
adeponte has joined #ruby
samphippen has joined #ruby
<tobiasvl> put your fist inside its throat and pull out the object
<shevy> hehe
* whitequark wonders if he should read the backlog
<tobiasvl> DON'T TRUST ME, I'M NOT A DOCTOR
<tobiasvl> i mean veterinarian
<tobiasvl> so anyway, jokke: I know ruby, I don't know heimlich maneuvres for cats or X menu programming
emanon_ has quit [Read error: Connection reset by peer]
<shevy> lol
<jokke> tobiasvl: i think the problem is with how `` is executed..
emanon_ has joined #ruby
<jokke> maybe it can't attach to an x server
tagrudev has quit [Remote host closed the connection]
<TotalEvil> nope
haxrbyte has quit [Ping timeout: 240 seconds]
TomyLobo has joined #ruby
<shevy> TotalEvil no, you lie
<tobiasvl> jokke: okay. that might very well be. what makes you think that? on what line is the `` command that leads you to believe this?
<tobiasvl> i still don't know what i'm looking for here
abionic has joined #ruby
banisterfiend has quit [Remote host closed the connection]
tagrudev has joined #ruby
sepp2k1 has quit [Remote host closed the connection]
M-- has quit [Quit: Leaving]
oinkon has quit [Ping timeout: 256 seconds]
banjara has quit [Ping timeout: 245 seconds]
<shevy> TotalEvil, look: https://gist.github.com/4690932
nari has joined #ruby
<tobiasvl> jokke: help me help you! explain your problem as shortly and succintly as possible. be to the point and specific. i don't have the time to troubleshoot a lot of stuff for you (and i don't want to either). when you hit a specific and concrete problem, please let us know so we can assist with our knowledge of ruby, but don't make us learn new knowledge about something totally unrelated to be able to help you
<shevy> hehehe
<TotalEvil> bro
<shevy> I think newbies often need short sentences
<TotalEvil> it's show correct only at puts
<shevy> TotalEvil what do you mean "only at puts". do not lie. if you run system(_) it will run the command as shown.
ABK_ has quit [Ping timeout: 264 seconds]
Takehiro has joined #ruby
<TotalEvil> yeap system return ok
<shevy> perfect
<TotalEvil> and if i run puts args
<TotalEvil> also ok
<shevy> if you need the return value, do:
decoponio is now known as decoponio_
<shevy> result = `#{_}`
ABK_ has joined #ruby
adeponte has quit [Ping timeout: 276 seconds]
<shevy> rather than system(_)
decoponio_ is now known as decoponio
<TotalEvil> but when 74-75 line runs
<shevy> understand?
<TotalEvil> it bad
<shevy> no line 74 no line 75
<TotalEvil> ohh
<shevy> this script is fucking shit
IdlePhD has quit [Ping timeout: 276 seconds]
zigomir has quit [Quit: zigomir]
<shevy> kill it. throw it away. start from zero. kill the guy who wrote it.
<TotalEvil> #{_hostname -I}
<TotalEvil> ?
<shevy> what the fuck are you doing here
a_a_g has quit [Quit: Leaving.]
<shevy> throw the script away
<TotalEvil> it's not related to script
reinaldob has joined #ruby
<shevy> yes it is
<shevy> all your problems are because of that fucking script
<TotalEvil> hostname -I
<shevy> empty your brain. remove that script.
carloslopes has quit [Remote host closed the connection]
<TotalEvil> it;s just command which i need
<shevy> TotalEvil, listen. Start irb
<shevy> have you started irb?
<TotalEvil> irb?
<shevy> why do you not know what irb is
hybris has joined #ruby
<shevy> come back when you do.
unsay has joined #ruby
shtirlic has joined #ruby
<TotalEvil> i haven't it
<shevy> then install it
Kuifje has joined #ruby
<TotalEvil> i have only clean console
<shevy> that is sad. in the ukraine people have no irb :(
<TotalEvil> okay looking
<TotalEvil> )) bcz not many people work with ruby)
<TotalEvil> before this only bash))
<shevy> so what
<shevy> and?
<shevy> I use bash all the time too
<shevy> so what?
<TotalEvil> so it wasn't needed
abionic has quit [Ping timeout: 252 seconds]
<shevy> good. you dont need ruby :)
<shevy> write shell scripts
<shevy> they are MUCH better than ruby
<TotalEvil> must be a ruby(
<TotalEvil> bcz of that .... company
RonScagz has joined #ruby
<TotalEvil> which write that script)
<shevy> do you use linux
<shevy> do you know how I start irb in bash?
<shevy> I type:
<shevy> irb
<shevy> then I hit enter
<shevy> then I am in irb.
<shevy> awesome, isn't it?
<shevy> anyway, install irb, start it, then do this:
<shevy> x = `hostname -I`
horofox has quit [Quit: horofox]
<shevy> and tell me what x has
<shevy> irb will give you the output, which you can copy paste to irc
elico has joined #ruby
renanoronfle has quit [Quit: This computer has gone to sleep]
<TotalEvil> i get irb
<shevy> GOOD
<TotalEvil> yeap sure)
<shevy> THERE IS HOPE FOR YOU MAN
<TotalEvil> i just haven't irb package)) before
<shevy> yeah, distributions suck
<TotalEvil> => "192.168.7.101 \n"
<shevy> ok good
<shevy> now you know that it will try to insert this string
<shevy> if you look at it, you see it has a newline
<shevy> the \n
<shevy> you can get this away via .chomp or .strip
<TotalEvil> yeap i see
felipecvo has joined #ruby
<shevy> "192.168.7.101 \n".strip # => "192.168.7.101"
warb0 has joined #ruby
<shevy> if you use .strip, you know that your string no longer has the \n
<shevy> then you can include it into args variable
miso1337 has quit [Quit: afk]
<shevy> but you must be sure that you need this "192.168.7.101"
<shevy> if it is used on the remote server, it will probably be another return value
<shevy> perhaps it returns "" there
buscon has quit [Quit: Leaving]
<shevy> in which case you must use a conditional
<shevy> if blabla
<TotalEvil> i not need "" there
<shevy> do this
<shevy> yes I know that you do not need this, that is why you need to use conditional checks!
<Xeago> btw, hostname -I errors on my system
<shevy> hehe
<TotalEvil> it's not working at all system
<TotalEvil> redhat based
<shevy> as long as it works on your machine ...
<TotalEvil> all machines have 1 os
<shevy> good
<TotalEvil> so ) it works on all
<shevy> so why does it still not work :P
<whitequark> TotalEvil: offtopic, but I'm curious: are you russian?
<TotalEvil> nope)
<TotalEvil> Ukrainian
<whitequark> almost
<TotalEvil> not almost))
<tobiasvl> lol
<tobiasvl> not exactly almost
<whitequark> these ")" betray you
<TotalEvil> we hate russians))
<TotalEvil> xDD
<whitequark> yes, "xD" too
<TotalEvil> nope) it's just my personal habbit)
<TotalEvil> and xDD too
<shevy> why
<shevy> is ) a problem with their keyboard?
<TotalEvil> nope))
<whitequark> I never seen this habit on anyone non-Slavic
<shevy> whitequark, how comes you know this?
<TotalEvil> mb))
<TotalEvil> didn't saw that
<jokke> tobiasvl: okay, i'll be back later and be more specific. Thanks!
<TotalEvil> almost all our people not use this
<whitequark> shevy: I am russian, and (I hope) somewhat observant
<shevy> TotalEvil those ) remind me of lisp
<TotalEvil> people which talking with me in chat from my county and russians not use this
<Mon_Ouie> /xD+/ is (or used to be) popular in French too
<shevy> whitequark cool, I would have never noticed based on the ) alone :)
dhruvasagar has quit [Ping timeout: 248 seconds]
dhruvasa1ar has quit [Ping timeout: 240 seconds]
<TotalEvil> %))
krz has quit [Quit: krz]
<whitequark> Mon_Ouie: but I still have to see ")" anywhere else
<shevy> I was constantly thinking "what is wrong with his keyboard..."
<TotalEvil> it's not specific to country
<TotalEvil> it's depend on human brain))
<shevy> there! the ) again ...
<TotalEvil> ))
<whitequark> TotalEvil: that's why I've said "Slavic"
<TotalEvil> always)
<TotalEvil> anyone can use this habbit)
<TotalEvil> not only slavic))
<shevy> yeah but whitequark was right
<whitequark> meh.
<shevy> :)
<TotalEvil> nope))
<TotalEvil> as i say
<TotalEvil> lot of people
<TotalEvil> not use this
a_a_g has joined #ruby
<shevy> in your case he was right ;)
<TotalEvil> just in my case))
<shevy> I can recognize people from singapore
dhruvasagar has joined #ruby
<shevy> they will almost always have the last word "siao" or "lah" or "wah"
dhruvasa1ar has joined #ruby
unsay has quit [Ping timeout: 245 seconds]
<TotalEvil> better write smile="xDD" ?))
<TotalEvil> what is that))
<TotalEvil> siao lah wah)
nari has quit [Ping timeout: 248 seconds]
<whitequark> shevy: there are also some people who say "ok" after each your phrase
<whitequark> like the TCP stack replies with ACK
<TotalEvil> xDD
<TotalEvil> i;m using not ok)
<TotalEvil> kk ))
arietis has quit [Quit: Computer has gone to sleep.]
<whitequark> shevy: but grepping logs by "ok\W+ack" will take a very long time
<whitequark> or rather, interpreting the results
ryanh has joined #ruby
ryanh has quit [Max SendQ exceeded]
shtirlic has quit [Read error: Connection reset by peer]
shtirlic_ has joined #ruby
<shevy> TotalEvil "siao" means already in chinese, and "wa liao" or "lah" is a casual remark... like nonchalanty speaking to a good friend in a pub
<TotalEvil> xDD)
ffranz has joined #ruby
<whitequark> sigh
cousine has joined #ruby
buibex has quit [Remote host closed the connection]
ryanh has joined #ruby
unsay has joined #ruby
lupinstein has quit [Remote host closed the connection]
emanon_ has quit [Ping timeout: 260 seconds]
ryanh has quit [Client Quit]
dhruvasagar has quit [Ping timeout: 240 seconds]
dhruvasa1ar has quit [Ping timeout: 255 seconds]
dhruvasagar has joined #ruby
chussenot has quit [Quit: chussenot]
dhruvasa1ar has joined #ruby
atmosx has joined #ruby
haxrbyte_ has quit [Remote host closed the connection]
haxrbyte has joined #ruby
<whitequark> as you can see he's somewhere from latin america. torture my search box further if you're that interested.
chiel has quit [Quit: leaving]
banjara has joined #ruby
AndChat| has joined #ruby
itsdavem_ has quit [Remote host closed the connection]
chiel has joined #ruby
malkomalko has joined #ruby
Banistergalaxy has quit [Ping timeout: 264 seconds]
<shevy> hehe
<shevy> that's quite excessive
<atmosx> shevy: can you help me?
<atmosx> shevy: query
<shevy> I use "ok" rather often though, it gives the other person the notice that I have "acknowledged" or "read" something
<shevy> atmosx sure
<whitequark> shevy: where are you from?
Squarepy has joined #ruby
<shevy> whitequark Europe, Austria, Vienna
Squarepy has quit [Changing host]
Squarepy has joined #ruby
buibex has joined #ruby
<whitequark> hm. well, you also don't use "ok" that much
<whitequark> no data points compromised!
<jokke> okay, so. Here's my problem: i use my script to build a menu based on dmenu. When i select a menu item that's an instance of Comand (a class i've declarated) it doesn't seem to execute the command. I get no errors or anything.
<shevy> whitequark yeah, it depends on the setup. when I ask a question and someone else is trying to help, I try to use "ok" more often... but that guy is quite insane, like every 2nd sentence is "ok" hehe
<shevy> jokke whatever dmenu is, it sounds awful
<whitequark> shevy: there was a second one from the same (iirc) country, with the same habit
<jokke> again, my script is here http://paste.xinu.at/n6E9/
<shevy> and is your class really called "Comand"
<jokke> no Command
<shevy> good
<jokke> shevy: it's not awful
<jokke> at all
<shevy> jokke and where do you invoke this class?
chussenot has joined #ruby
<jokke> when i create the menu
<shevy> are you sure
<shevy> is the line:
<shevy> puts "Ready. Test menu now? (y/n)"
<shevy> displayed?
<jokke> linel 181
<jokke> yes
<shevy> ok what is menu.class saying
arkiver has quit [Quit: Leaving]
a_a_g has quit [Ping timeout: 252 seconds]
<shevy> make a puts menu.class after menu = add_menu
RurouniJones has joined #ruby
guns has quit [Quit: guns]
mockra has joined #ruby
<jokke> you mean mean this line? menu.add_item(Command.new name, gets)
<jokke> the menu is displayed correctly
<jokke> the problem is with the Command
<jokke> also sub menues are executed correctly (they open themselves up)
banjara has quit [Ping timeout: 246 seconds]
<jokke> hm i added a puts before the `` in Commands execute method. it outputs the correct string
unsay has quit [Ping timeout: 248 seconds]
zeade has joined #ruby
mockra has quit [Ping timeout: 245 seconds]
pavilionXP has joined #ruby
arya has quit [Ping timeout: 276 seconds]
yshh has joined #ruby
shtirlic_ has quit [Remote host closed the connection]
dhruvasagar has quit [Ping timeout: 252 seconds]
a_a_g has joined #ruby
dhruvasa1ar has quit [Ping timeout: 252 seconds]
arya has joined #ruby
dhruvasagar has joined #ruby
dhruvasa1ar has joined #ruby
girija_ has quit [Ping timeout: 248 seconds]
samphippen has quit [Quit: Computer has gone to sleep.]
ananthakumaran has quit [Quit: Leaving.]
ananthakumaran has joined #ruby
pskosinski has joined #ruby
carloslopes has joined #ruby
jrajav has quit [Quit: phunq, sandwich store loop, WHAT NO UNIVERSE]
ananthakumaran has quit [Ping timeout: 264 seconds]
nyuszika7h has quit [Remote host closed the connection]
adambeynon has quit [Quit: Computer has gone to sleep.]
noop has quit [Remote host closed the connection]
zeade has quit [Quit: Leaving.]
oreo has joined #ruby
razieliyo has joined #ruby
<razieliyo> hi
Drager has quit [Changing host]
Drager has joined #ruby
arya_ has joined #ruby
<tobiasvl> hi
<oreo> Hello. I am wondering how I can ad parameters to a Proc that I am giving as a callback parameter. For example: ssh.process(0.1, &condition), how could I specify parameters to "condition"?
nyuszika7h has joined #ruby
Udom0 has joined #ruby
<heftig> ssh.process(0.1) { condition.(3,4,5) }
vlad_starkov has joined #ruby
<Xeago> heftig: with the dot?
<oreo> heftig, could you explain the role of the dot?
<Xeago> never seen that syntax before
arya has quit [Ping timeout: 246 seconds]
<heftig> it's a short form of condition.call(3,4,5)
arya has joined #ruby
<Xeago> ah, thanks!
<oreo> heftig, thanks. so if process yields with parameters, they would be added after mine?
haxrbyte has quit [Remote host closed the connection]
haxrbyte has joined #ruby
<heftig> no, if you want to do that:
<heftig> ssh.process(0.1) { |*args| condition.(3,4,5,*args) }
arya_ has quit [Ping timeout: 248 seconds]
stetho has quit [Quit: stetho]
<oreo> ah so I have to create a proxy Proc/lambda then
<heftig> yes
<oreo> never thought of that possibility, thanks a lot :)
girija_ has joined #ruby
Emmanuel_Chanel has joined #ruby
chiel is now known as chiel`afk
ffranz has quit [Quit: Leaving]
chiel`afk is now known as chiel
adkron_ has quit [Ping timeout: 248 seconds]
atmosx has quit [Quit: And so the story goes…]
adkron has quit [Ping timeout: 256 seconds]
[Neurotic] has quit [Remote host closed the connection]
invisime has joined #ruby
banjara has joined #ruby
deavidsedice has quit [Ping timeout: 240 seconds]
xemu has joined #ruby
dekroning has quit [Ping timeout: 246 seconds]
fenak has joined #ruby
mibitzi has quit [Remote host closed the connection]
kristofers has quit [Read error: Connection reset by peer]
niklasb has quit [Ping timeout: 248 seconds]
grendlme has joined #ruby
Kosova has joined #ruby
mmitchell has quit [Remote host closed the connection]
<Kosova> Plz 1 cREDIT cARD
dustint has joined #ruby
dustint has quit [Read error: Connection reset by peer]
<heftig> def foo(&blk) 2.times { |x| blk.call(x) { |&blk| 4.times(&blk) } } end; foo { |x,&blk| 2.times { |y| blk.call { |z| puts "#{x}:#{y}:#{z}" } } }
Kosova has left #ruby [#ruby]
<heftig> mmh, spaghetti code
<tobiasvl> beautiful
miso1337 has joined #ruby
dustint has joined #ruby
chussenot has quit [Quit: chussenot]
fflush has quit [Changing host]
fflush has joined #ruby
zigomir has joined #ruby
xbayrockx has joined #ruby
unsay has joined #ruby
cha1tanya has joined #ruby
wf2f has quit [Ping timeout: 248 seconds]
deavid has joined #ruby
SQLDarkly has joined #ruby
<SQLDarkly> Hey All. I have the following json im writing to mongo, but im not sure how to tackle the classes array I have. http://pastebin.com/2bsrUZQV
<SQLDarkly> classes keeps getting written like "mathscienceenglish"
jonathanwallace has joined #ruby
chussenot has joined #ruby
<SQLDarkly> Any pointers would be appreciated.
banjara has quit [Ping timeout: 260 seconds]
tommyvyo has joined #ruby
mjolk has joined #ruby
x0F has quit [Disconnected by services]
xAndy is now known as xandy
x0F_ has joined #ruby
dawkirst has joined #ruby
x0F_ is now known as x0F
cha1tanya has quit [Quit: Leaving]
shtirlic has joined #ruby
miso1337 has quit [Quit: unplugging]
subbyyy_ has joined #ruby
enroxorz-work has joined #ruby
cohwsw has joined #ruby
cardoni has joined #ruby
AsgardBSD_ has quit [Read error: Connection reset by peer]
Hanmac_ has quit [Quit: Page closed]
yshh has quit [Remote host closed the connection]
yalue has joined #ruby
cardoni has quit [Ping timeout: 248 seconds]
banister_ has joined #ruby
dhruvasagar has quit [Ping timeout: 264 seconds]
dhruvasa1ar has quit [Ping timeout: 260 seconds]
jfl0wers has quit [Quit: jfl0wers]
buibex has quit [Remote host closed the connection]
Stilo has joined #ruby
mockra has joined #ruby
tommyvyo has quit [Quit: http://twitter.com/tommyvyo]
kristofers has joined #ruby
<Spooner> SQLDarkly, You should just include the classes array directly. Not convert to string.
enroxorz-work has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
enroxorz-work has joined #ruby
bigkevmcd has quit [Quit: outta here]
enroxorz-work has quit [Client Quit]
<shevy> SQLDarkly you did not say what is the problem
stopbit has joined #ruby
enroxorz-work has joined #ruby
<Spooner> shevy, The problem is that 1.8.7 to_s writes strings out poorly. But also that SQLDarkly didn't realiuse that Array maps directly to JSON anyway.
<Spooner> shevy, Array#to_s that is.
<shevy> I think he died in front of his computer
<SQLDarkly> yeah im a lowly unix admin not a programmer so im going through some exercises to learn a bit more. I write shell scripts heh
<shevy> SQLDarkly are you still alive
mockra has quit [Ping timeout: 260 seconds]
<SQLDarkly> yeah sorry I was working a change control @ work. Finished now though.
coder_neo has quit [Ping timeout: 248 seconds]
<Spooner> SQLDarkly, You should never need to do "#{var}" either. Either use var directly or use var.to_s.
<shevy> "mathscienceenglish" is cool output. where is the problem
reinaldob has quit [Remote host closed the connection]
moshee has quit [Ping timeout: 240 seconds]
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
<SQLDarkly> Should be "math" \n "science" \n "english"
<Spooner> SQLDarkly, Use #{} when you have more than just a single variable in a string.
<shevy> you can use .join on your array SQLDarkly
<Spooner> SQLDarkly, Are you sure it wouldn't be better as an array?
<Spooner> There isn't any reason to convert it into a single string.
<shevy> SQLDarkly, array = %w( math science english ); array.map(&:capitalize).join("\n") # => "Math\nScience\nEnglish"
<SQLDarkly> ah I was under the impression #{} is used like $var in say "hi my name is $name "
bigkevmcd has joined #ruby
<Spooner> SQLDarkly, It is, but no reason to do "$name" if you can $name (In Perl) ;)
<shevy> $var is a global variable in ruby
<shevy> #{} in a string works on everything
<shevy> "#{foo}"
<shevy> "$#{foo}"
<shevy> hmmmmm
<shevy> haha
<shevy> "#{$foo}"
<shevy> there. but this is awful...
<Spooner> shevy, Yes, but I often see newbies doing "#{var}" when var would do.
<shevy> yeah
<shevy> even I failed with $ just now
<Spooner> And by that I mean just "#{var}" not "#{var} likes pie". The latter makes sense.
<SQLDarkly> im a newb for sure :) Im mean on a unix cli, but programming..... not so much.
Liothen has quit [Remote host closed the connection]
<TotalEvil> xDD
geekbri has joined #ruby
<TotalEvil> i got it work))
<shevy> SQLDarkly, you write shell scripts, you can program.
jonathanwallace has quit [Ping timeout: 252 seconds]
banjara has joined #ruby
<Spooner> Anyway, SQLDarkly You can just do "classes" => classes - the Array will be converted to JSON for you.
<SQLDarkly> trying to bridge that gap shevy :) I understand constructs like for loops while if case etc, but there are a lot of ways to do things in ruby so im finding it difficult to say this is how X is done. Maybe im overthinking
the_mentat has joined #ruby
<Spooner> You only need to know one way.
<shevy> SQLDarkly well you have most of the basics already
<SQLDarkly> i suppose that is true Spooner
<shevy> most of the programming in ruby happens in methods
alanjc has joined #ruby
<shevy> the rest is just storing data somewhere
<shevy> and some way to access or query or modify that
<shevy> SQLDarkly, you can ignore all other ways as long as you have found one way
bean__ has joined #ruby
<Spooner> Yeah, programming is just about moving data around with code. Simple ;)
bean__ is now known as bean|work
<shevy> I ignore lambdas for instance
<shevy> Spooner it is! I once had an awful array residing in a huge hash residing in a fat array
<shevy> I was trying to make it look better
tommyvyo has joined #ruby
<shevy> then I started again, and simply made it just one hash
<shevy> and things worked magically from that point!
sailias has joined #ruby
<shevy> I let the smart folks write smart code
<shevy> I bring everything down to my level
<workmad3> Spooner: code is itself data though :D
<Spooner> shevy, If you'd used lambdas, it would have been better ;)
<workmad3> Spooner: or so lisp would have us believe
<Spooner> workmad3, That is a good point, but since you can't read code in Ruby (only manipulate lambda/methods), that is less true.
<Spooner> Though I suppose there are AST tools that can read Ruby code properly.
yfeldblum has quit [Ping timeout: 256 seconds]
<shevy> Spooner, yeah I heard that about lambdas before. someone on #ruby-lang told me "use them, you can learn something that way and become better", but I never got them. it seems that in all the ruby code I wrote so far, I somehow manage to avoid consciously *needing* them
<Spooner> shevy, I can't imagine there is a Ruby app that actually _needs_ lambdas.
slainer68 has joined #ruby
<Spooner> But then we don't need most things in Ruby. We just like to have stuff in case ;)
jaywastaken has quit [Read error: Connection reset by peer]
jaywastaken has joined #ruby
workmad3_ has joined #ruby
<shevy> hmm
<shevy> I want to have good reasons for using something and not using something else
<shevy> like subclassing, vs. including
fenak has quit [Quit: Page closed]
workmad3 has quit [Ping timeout: 245 seconds]
ngoldman has joined #ruby
xbayrockx has quit []
acrocity has quit [Read error: Connection reset by peer]
horofox has joined #ruby
banjara has quit [Ping timeout: 252 seconds]
acrocity has joined #ruby
n1x has quit [Quit: Ex-Chat]
horofox has quit [Client Quit]
browndawg has quit [Quit: Leaving.]
<SQLDarkly> thanks for the help gentlemen. Going to crack away at this and see if I can get it working.
Skylab has joined #ruby
yshh has joined #ruby
SQLDarkly has quit [Quit: Page closed]
subbyyy_ has quit [Ping timeout: 256 seconds]
jfl0wers has joined #ruby
ngoldman has quit [Ping timeout: 252 seconds]
girija_ has quit [Ping timeout: 245 seconds]
zigomir has quit [Quit: zigomir]
arietis has joined #ruby
samphippen has joined #ruby
renanoronfle has joined #ruby
huoxito has joined #ruby
elico has quit [Quit: elico]
abcdefg_ has joined #ruby
mjolk has quit [Quit: Leaving]
mjolk has joined #ruby
joofsh has joined #ruby
teriyakis has joined #ruby
breakingthings has joined #ruby
buibex has joined #ruby
codecop has quit [Remote host closed the connection]
kn330 has quit [Remote host closed the connection]
luk3 has joined #ruby
afd__ has quit [Quit: No Ping reply in 180 seconds.]
jrajav has joined #ruby
afd__ has joined #ruby
jerius has joined #ruby
TotalEvil has quit [Quit: ChatZilla 0.9.89 [Firefox 18.0.1/20130116073211]]
teriyakis has quit [Remote host closed the connection]
workmad3 has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
binaryplease has joined #ruby
lunarjar has joined #ruby
workmad3_ has quit [Ping timeout: 255 seconds]
yshh has quit [Remote host closed the connection]
zph has joined #ruby
quest88_ has joined #ruby
vlad_starkov has quit [Read error: Connection reset by peer]
ij has quit [Ping timeout: 256 seconds]
buibex has quit [Ping timeout: 276 seconds]
carlyle has joined #ruby
Konboi has quit [Remote host closed the connection]
yshh has joined #ruby
vlad_starkov has joined #ruby
segv- has joined #ruby
jaywastaken has quit [Remote host closed the connection]
tomzx_mac has joined #ruby
tekacs has quit [Quit: Disappearing... *poof*]
rippa has joined #ruby
DrShoggoth has quit [Ping timeout: 248 seconds]
tekacs has joined #ruby
tekacs has quit [Client Quit]
quest88_ has quit [Quit: quest88_]
elico has joined #ruby
xk_id has quit [Remote host closed the connection]
jonathanwallace has joined #ruby
a_a_g has quit [Quit: Leaving.]
Virunga has joined #ruby
ondrejr has joined #ruby
solidoodlesuppor has joined #ruby
zph has quit [Quit: Computer has gone to sleep.]
unsay has quit [Ping timeout: 245 seconds]
banjara has joined #ruby
banseljaj is now known as imami|afk
jtharris has joined #ruby
theRoUS has joined #ruby
theRoUS has joined #ruby
tekacs has joined #ruby
ondrejr has left #ruby ["Leaving"]
DaltonUS has joined #ruby
<Xeago> reused or re-used?
jrist-afk is now known as jrist
browndawg has joined #ruby
<Xeago> The existing instance has been re-used to put the system in a mode of reduced redundancy but fully operational.
jpfuentes2 has joined #ruby
cardoni has joined #ruby
tekacs has quit [Read error: Connection reset by peer]
tekmaster has joined #ruby
tekmaster is now known as tekacs
binarypl1 has joined #ruby
kold has joined #ruby
yfeldblum has joined #ruby
jaywastaken has joined #ruby
jaywastaken has joined #ruby
jaywastaken has quit [Changing host]
dpbus has joined #ruby
elico has quit [Remote host closed the connection]
pu22l3r has joined #ruby
huoxito has quit [Quit: Leaving]
renanoronfle has quit [Quit: This computer has gone to sleep]
binaryplease has quit [Ping timeout: 245 seconds]
s1n4 has joined #ruby
freeayu has quit [Remote host closed the connection]
generalissimo has joined #ruby
cardoni has quit [Ping timeout: 264 seconds]
mmitchell has joined #ruby
s1n4 has quit [Client Quit]
stormetrooper has quit [Ping timeout: 246 seconds]
banjara has quit [Ping timeout: 248 seconds]
unsay has joined #ruby
jgarvey has joined #ruby
workmad3_ has joined #ruby
mockra has joined #ruby
tomzx_mac has quit [Ping timeout: 256 seconds]
nkr has joined #ruby
samphippen has joined #ruby
buibex has joined #ruby
segv-_ has joined #ruby
rismoney has joined #ruby
segv- has quit [Ping timeout: 245 seconds]
shtirlic has quit [Read error: Connection reset by peer]
segv-_ is now known as segv-
kold has quit [Remote host closed the connection]
shtirlic has joined #ruby
workmad3 has quit [Ping timeout: 260 seconds]
unsay has quit [Ping timeout: 276 seconds]
jgarvey has quit [Ping timeout: 245 seconds]
mockra has quit [Ping timeout: 260 seconds]
osaut has quit [Read error: Operation timed out]
blaxter has quit [Quit: foo]
Beoran__ has joined #ruby
buibex has quit [Ping timeout: 276 seconds]
generalissimo has quit [Remote host closed the connection]
timeout has quit [Quit: leaving]
Beoran_ has quit [Ping timeout: 264 seconds]
stormetrooper has joined #ruby
browndawg1 has joined #ruby
maycon has joined #ruby
maycon has quit [Changing host]
maycon has joined #ruby
acies has joined #ruby
browndawg has quit [Ping timeout: 245 seconds]
<acies> Is there an Array method for doing '.pop!' ?
<acies> That is, returning the array instead of the popped item
<banister_> acies: array.tap(&:pop)
<heftig> ew
buibex has joined #ruby
<acies> Poor question, sorry. Thanks
samuel02 has quit [Remote host closed the connection]
clocKwize has quit [Quit: clocKwize]
jonathanwallace has quit [Ping timeout: 264 seconds]
dpbus has quit []
workmad3_ has quit [Ping timeout: 276 seconds]
shock_one has quit [Read error: Connection reset by peer]
frem has joined #ruby
v0n has joined #ruby
workmad3 has joined #ruby
chimkan has joined #ruby
atno has quit [Quit: Get MacIrssi - http://www.sysctl.co.uk/projects/macirssi/]
clocKwize has joined #ruby
jonathanwallace has joined #ruby
osaut has joined #ruby
x82_nicole has joined #ruby
lunarjar has quit [Quit: Leaving.]
lunarjar has joined #ruby
cousine has quit [Remote host closed the connection]
bdnelson has joined #ruby
lunarjar has quit [Client Quit]
atno has joined #ruby
theRoUS has quit [Ping timeout: 260 seconds]
mmitchel_ has joined #ruby
nimred has quit [Quit: leaving]
jesfre has joined #ruby
mando has joined #ruby
jesfre has quit [Client Quit]
banjara has joined #ruby
__BigO__ has joined #ruby
mmitchell has quit [Ping timeout: 252 seconds]
cousine has joined #ruby
segv- has quit [Read error: Connection reset by peer]
segv-_ has joined #ruby
reinaldob has joined #ruby
flyinprogramer has joined #ruby
pu22l3r has quit [Remote host closed the connection]
punkrawkR has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
_nitti has joined #ruby
joofsh has quit [Remote host closed the connection]
IrishGringo_ has quit [Quit: ChatZilla 0.9.89 [Firefox 18.0.1/20130116073211]]
ferdev_ has joined #ruby
cpruitt has joined #ruby
fmcgeough has joined #ruby
IrishGringo has joined #ruby
blazes816 has quit [Quit: blazes816]
michaelmartinez has joined #ruby
DrShoggoth has joined #ruby
Elhu has quit [Quit: Computer has gone to sleep.]
atno has quit [Quit: Leaving]
aedornm has quit [Quit: Leaving]
niklasb has joined #ruby
vlad_starkov has quit [Read error: Connection reset by peer]
<flyinprogramer> has anyone done any performance testing on the difference between directly using/calling an instance variable in code vs using the class' reader method to access it ? ex. using @variable instead of a call to a method like: def variable @variable; end
asteve has joined #ruby
vlad_starkov has joined #ruby
atno has joined #ruby
ferdev_ has quit [Client Quit]
bradleyprice has joined #ruby
unsay has joined #ruby
elkclone has quit [Ping timeout: 248 seconds]
ferdev_ has joined #ruby
elkclone has joined #ruby
zph has joined #ruby
banjara has quit [Ping timeout: 255 seconds]
Aenigma has joined #ruby
ferdev_ has quit [Client Quit]
daniel_- has joined #ruby
daniel_- has quit [Changing host]
daniel_- has joined #ruby
nateberkopec has joined #ruby
<bean|work> flyinprogramer: I'd imagine the performance differences would be negligible.
theRoUS has joined #ruby
theRoUS has joined #ruby
theRoUS has quit [Changing host]
<hoelzro> I would favor the accessor methods
alanjc has quit [Quit: alanjc]
<hoelzro> no need to prematurely optimize
clocKwize has quit [Quit: clocKwize]
cousine has quit [Remote host closed the connection]
<flyinprogramer> i would completely agree, but for giggles i did the swap and i swear things are running faster...
eldariof has quit [Ping timeout: 248 seconds]
<flyinprogramer> if we could just fit Gigs of L2 cache on our procs it wouldn't matter for sure :P
jrajav has quit [Quit: I tend to be neutral about apples]
<bean|work> I like attr_accessor
<bean|work> personally
<Aenigma> i have a bit of a newbie question. if i wanted to make a class that extends Array but add a definition for an extra data type for the already existing methods, how should I do it since ruby doesn't have method overloading?
<tobiasvl> Aenigma: ruby doesn't have method overloading?
JarJar has quit [Quit: Leaving]
<tobiasvl> oh yeah like that
<tobiasvl> nvm
<Aenigma> tobiasvl: like object.doStuff(int) and object.doStuff(String)
zph has quit []
<flyinprogramer> oh i do too - especially if you're going to reach for things inside the object from the outside, but when you're inside, i would think it would be terribly inefficient -- unless some how the interpreter is like a compiler, and that it was smarter than mere mortals
<heftig> flyinprogramer: for MRI, the method calls make it more than twice as slow
nomenkun has quit [Remote host closed the connection]
<heftig> in RBX, the method call version is actually faster
x82_nicole has quit [Quit: Textual IRC Client: www.textualapp.com]
<hoelzro> flyinprogramer: let the interpreter worry about optimization; if your code is fast enough with method calls, stick with method calls
beliveyourdream has quit [Read error: Connection reset by peer]
<flyinprogramer> heftig: i need the maths and science
<flyinprogramer> heftig: i.e. do you have links to the data to support that
michaelmartinez has quit [Quit: Check it, Wreck it http://www.caffeineindustries.com/blog]
<flyinprogramer> hoelzro: you're absolutely correct, i just have some what of a systems background, i'm type A, it's a friday, so why not go on a quest for knowledge
<lectrick> Anyone from rubygems.org on here?
pavilionXP has quit [Read error: Connection reset by peer]
<hoelzro> oh, fair enough. I'm all for curiosity =)
<heftig> flyinprogramer: https://gist.github.com/4691957
<waxjar> flyinprogramer: https://gist.github.com/4691954
<tobiasvl> Aenigma: i don't know exactly what you're trying, but check the type of the variable and call the super method if applicable?
nobuoka has joined #ruby
jlast has joined #ruby
techhelp has joined #ruby
poikon_work has joined #ruby
<jokke> hey! How do i use YAML::dump ? I can't find docs for it
SCommette has joined #ruby
<jokke> i also need YAML::load
ABK_ has quit [Read error: Operation timed out]
<heftig> you just call it with an object and it gives you a string
<heftig> other way around for load
<jokke> heftig: ah it gives me a string
poikon has quit [Ping timeout: 244 seconds]
<jokke> cool
cardoni has joined #ruby
tagrudev has quit [Quit: Y]
grendlme has quit [Quit: grendlme]
<jokke> so i write that to a file for example
<jokke> to save objects
<tobiasvl> google
<jokke> honestly i coudn't find it
<jaywastaken> It's been a while since I've upgraded ruby... does 37 minutes stuck on the "Making gemset *** pristine" sound right?
<heftig> jokke: you can also give it an IO object (e.g. a file or a socket) as the second argument, and it will write to it instead of returning
<heftig> jokke: it mirrors Marshal.dump and Marshal.load
<jokke> heftig: ah perfect
<jokke> and it's human readable?
grendlme has joined #ruby
BadLarry has quit [Ping timeout: 248 seconds]
BadLarry has joined #ruby
<heftig> eh, mostly
mrmist has quit [Quit: restart]
<heftig> not as readable as JSON, imo, but it's okay
<jokke> assuming, i take care of the to_s methods
<heftig> huh, to_s?
<jokke> to string?
<heftig> YAML doesn't use to_s
<jokke> oh
<jokke> ok :P
<jokke> all for nothing then :D
techhelp has quit [Quit: This computer has gone to sleep]
alex__c2022 has joined #ruby
cardoni has quit [Ping timeout: 245 seconds]
elux has joined #ruby
aganov has quit [Remote host closed the connection]
dougireton1 has joined #ruby
MissionCritical has quit [Ping timeout: 252 seconds]
banister_ has quit [Remote host closed the connection]
fasta has quit [Ping timeout: 245 seconds]
dougireton1 has quit [Client Quit]
Morkel has quit [Quit: Morkel]
carloslopes has quit [Remote host closed the connection]
mrmist has joined #ruby
Stilo has quit [Quit: Textual IRC Client: www.textualapp.com]
axl_ has joined #ruby
girija_ has joined #ruby
hashtree has quit []
postmodern has quit [Quit: Leaving]
<Aenigma> tobiasvl: yeah, i think that works. i was trying to see if i can create a class that can generate cartesian products
x82_nicole has joined #ruby
carloslopes has joined #ruby
<tobiasvl> why do you want to extend Array to make that?
recycle has joined #ruby
dougireton has joined #ruby
mockra has joined #ruby
philcrissman has joined #ruby
davidcelis has quit [Quit: K-Lined.]
erichmenge has quit [Quit: Arrivederci!]
<Aenigma> tobiasvl: i guess it would make it easier for me to manipulate it? Is that bad practice?
<tobiasvl> no, just curious
davidcelis has joined #ruby
pu22l3r has joined #ruby
<tobiasvl> don't really understand what functionality you need from Array
<tobiasvl> Array#product?
jamescarr has joined #ruby
erichmenge has joined #ruby
dougireton has quit [Client Quit]
adkron_ has joined #ruby
dougireton has joined #ruby
Mission-Critical has joined #ruby
thatRD has joined #ruby
banjara has joined #ruby
joofsh has joined #ruby
recycle has quit [Ping timeout: 276 seconds]
joshman_ has joined #ruby
dougireton has quit [Client Quit]
<Aenigma> tobiasvl: ..oh. Array#product is a cartesian product
mockra has quit [Ping timeout: 260 seconds]
<tobiasvl> yeah
<tobiasvl> it's not lazy though
chussenot has quit [Quit: chussenot]
punkrawkR has joined #ruby
charliesome has quit [Quit: Textual IRC Client: www.textualapp.com]
ner0x has joined #ruby
chussenot has joined #ruby
vlad_starkov has quit [Read error: Connection reset by peer]
jerikl has joined #ruby
vlad_starkov has joined #ruby
michaelmartinez has joined #ruby
t0rc has joined #ruby
Mission-Critical is now known as MissionCritical
noxoc has quit [Quit: noxoc]
Virunga has quit [Remote host closed the connection]
banisterfiend has joined #ruby
clooth has quit [Quit: clooth]
decoponi_ has joined #ruby
stopbit has quit [Quit: Leaving]
joofsh has quit [Remote host closed the connection]
decoponio has quit [Ping timeout: 260 seconds]
lunarjar has joined #ruby
jaequery has joined #ruby
lunarjar has quit [Client Quit]
maxmanders has quit [Quit: Computer has gone to sleep.]
generalissimo has joined #ruby
<breakingthings> How can I convert a string date in the format "%Y-%m-%d" into a Date object?
elico has joined #ruby
banjara has quit [Ping timeout: 255 seconds]
decoponi_ is now known as decoponio
miskander has joined #ruby
maxmanders has joined #ruby
maz-dev has quit [Read error: Connection reset by peer]
supergiantrobot_ has joined #ruby
tvw has quit [Remote host closed the connection]
maxmanders has quit [Client Quit]
jrafanie has joined #ruby
dougireton has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
decoponio is now known as decoponi_
maxmanders has joined #ruby
theRoUS has quit [Ping timeout: 272 seconds]
d2dchat has joined #ruby
<breakingthings> nevermind, got it.
chussenot has quit [Quit: chussenot]
decoponi_ is now known as decoponyo
ananthakumaran has joined #ruby
decoponyo is now known as decoponio
elico has quit [Remote host closed the connection]
elico has joined #ruby
chussenot has joined #ruby
dmiller has joined #ruby
dhruvasagar has joined #ruby
dhruvasa1ar has joined #ruby
poikon has joined #ruby
axl_ has quit [Read error: Connection reset by peer]
poikon_work has quit [Ping timeout: 245 seconds]
noxoc has joined #ruby
techhelp has joined #ruby
murilo_fs has joined #ruby
jonahR has joined #ruby
jfl0wers has quit [Read error: Connection reset by peer]
ckrailo has joined #ruby
jfl0wers has joined #ruby
axl_ has joined #ruby
michaelmartinez_ has joined #ruby
mneorr has joined #ruby
apenneba has joined #ruby
michaelmartinez has quit [Ping timeout: 245 seconds]
michaelmartinez_ is now known as michaelmartinez
<apenneba> Where can I find a gem for printing diff-format differences between two arrays? Diffy doesn't work on Windows without manual installation of the Unix diff tool :(
Umren has joined #ruby
<bean|work> in general windows sucks for ruby work, apenneba
mklappstuhl has quit [Ping timeout: 248 seconds]
cy43 has joined #ruby
chrishunt has quit [Quit: Leaving...]
recycle has joined #ruby
flyinprogramer has quit [Quit: flyinprogramer]
cy43 has left #ruby ["Ex-Chat"]
the_mentat has quit [Quit: Computer has gone to sleep.]
BizarreCake has joined #ruby
alanjc has joined #ruby
joofsh has joined #ruby
mklappstuhl has joined #ruby
elico has quit [Quit: elico]
elico has joined #ruby
AndChat| has quit [Ping timeout: 245 seconds]
poseid has quit [Quit: Page closed]
banjara has joined #ruby
inokenty has joined #ruby
reinaldob has quit [Remote host closed the connection]
sayan has joined #ruby
gosshedd has quit [Ping timeout: 246 seconds]
hoelzro is now known as hoelzro|away
elico has quit [Client Quit]
elico has joined #ruby
albakry has joined #ruby
albakry has joined #ruby
browndawg1 has quit [Ping timeout: 245 seconds]
elico has quit [Client Quit]
elico has joined #ruby
elico has quit [Client Quit]
elico has joined #ruby
miskander has quit [Quit: miskander]
sc_raptor has quit [Quit: Leaving]
chrishough has joined #ruby
shashin has joined #ruby
miskander has joined #ruby
Vainoharhainen has quit [Quit: Leaving...]
miskander has quit [Client Quit]
alanjc has quit [Ping timeout: 245 seconds]
Xeago has quit [Remote host closed the connection]
girija_ has quit [Ping timeout: 255 seconds]
pu22l3r has quit [Ping timeout: 252 seconds]
apenneba has quit [Quit: Page closed]
alanjc has joined #ruby
ogamita has joined #ruby
Vainoharhainen has joined #ruby
brimil01 has joined #ruby
slainer68 has quit [Remote host closed the connection]
Takehiro has quit [Remote host closed the connection]
michaelmartinez_ has joined #ruby
renanoronfle has joined #ruby
buibex has quit [Remote host closed the connection]
miskander has joined #ruby
<ogamita> Hi! I'm trying to load cucumber and frank-cucumber on 1.8.7-p370 (version is imposed). Unfortunately, frank-cucumber requires sim_launcher (0.4.6 installed), which requires cgi.rb from ruby 1.8, and it breaks on line 781 because of DelegateClass(Array) which raises: ~/.rvm/rubies/ruby-1.8.7-p370/lib/ruby/1.8/cgi.rb:781: undefined method `Class' for CGI:Class (NoMethodError)
<ogamita> What can I do to resolve this problem?
hybris has quit [Read error: Connection reset by peer]
tjbiddle has joined #ruby
michaelmartinez has quit [Read error: Connection reset by peer]
<ogamita> Sorry, it wasn't the right error message. Here is the right message: ~/.rvm/rubies/ruby-1.8.7-p370/lib/ruby/1.8/cgi.rb:781: invalid identifier 만약 (NameError)
<ogamita> Notice the Korean characters. There's no non-ascii character in cgi.rb.
michaelmartinez_ has quit [Ping timeout: 264 seconds]
mengu_ has quit [Quit: Konversation terminated!]
banjara has quit [Ping timeout: 246 seconds]
angusigu1ss has quit [Ping timeout: 260 seconds]
nazty has quit [Ping timeout: 248 seconds]
theRoUS has joined #ruby
<jerikl> ogamita: I think you're gonna have to dig into the libraries to figure out what's really going on
dougireton has quit [Quit: Leaving.]
<ogamita> Even in the implementation I'm afraid.
<jerikl> Have you done a diff on the two cgi libraries?
<ogamita> which other?
<jerikl> Oh I thought it was expecting cgi.rb from another version of ruby
<ogamita> I have one installed by the system yes.
<ogamita> No diff.
<ogamita> System ruby is: ruby 1.8.7 (2012-02-08 patchlevel 358) [universal-darwin12.0]
<ogamita> rvm ruby is ruby 1.8.7 (2012-06-29 patchlevel 370) [i686-darwin12.2.0]
Banistergalaxy has joined #ruby
mockra has joined #ruby
<ogamita> With system ruby, the error message is: /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/cgi.rb:774: invalid identifier Eğerki (NameError)
uris has joined #ruby
<ogamita> It loads the same rvm-installed gems.
carloslopes has quit [Remote host closed the connection]
odyssey4me has joined #ruby
<jerikl> Yeah it's hard to say without debugging / I don't have any experience with those gems in 1.8.7
murilo_fs has left #ruby ["Konversation terminated!"]
<ogamita> To me it looks like a bug in ruby 1.8 that existed at least [1.8-358 .. 1.8-370]
jgrevich has joined #ruby
<ogamita> 1.8.7 yes.
<ogamita> ok, let's try to debug that …
girija_ has joined #ruby
andrewh has quit [Quit: leaving]
<ogamita> at work, 15 min before the start of the week end…
<jerikl> Is there a diff in cgi.rb between 1.8 and 1.9?
dougireton has joined #ruby
andrewh has joined #ruby
<ogamita> Well, I'd diff Delegate.rb rather, the problem must be there I think. it's the call to DelegateClass(Array) that raise the error.
browndawg has joined #ruby
mklappstuhl has quit [Ping timeout: 264 seconds]
sn0wb1rd has quit [Quit: sn0wb1rd]
mockra has quit [Ping timeout: 252 seconds]
razibog has quit [Ping timeout: 252 seconds]
<jerikl> Ah okay. I wonder if it has something to do with the way 1.9 handles Unicode over 1.8 .... Maybe one of the gems is doing something 1.8 doesn't support
Vainoharhainen has quit [Quit: Leaving...]
kpshek has joined #ruby
<ogamita> Well, so far I didn't install other ruby version here, so normally everything's matching.
banisterfiend has quit [Remote host closed the connection]
noxoc has quit [Quit: noxoc]
<ogamita> The fact is that cucumber and frank-cucumber load correctly when running tests. I'm trying to load them with irb to connect to the application from irb.
mklappstuhl has joined #ruby
dmiller has quit [Ping timeout: 255 seconds]
<jerikl> Ooh okay. I thought the gems weren't working in 1.8.7
<ogamita> Well, rvm doesn't seem to have any problem. :-)
oreo has quit []
<ogamita> Probably it uses old gems.
Takehiro has joined #ruby
tcstar has joined #ruby
carlyle has quit [Remote host closed the connection]
dr_bob has quit [Read error: Connection reset by peer]
<jerikl> So you want to run this from system ruby irb?
mahmoudimus has joined #ruby
<ogamita> no, just with the rvm ruby. I wrote a script concatenating chunks from cucumber and irb scripts and frank-cucumber.rb.
mercwithamouth has joined #ruby
<ogamita> It fails on require 'frank-cucumber' because of this DelegateClass(Array) call in cgi.rb.
* ogamita brew installing ruby 1.9.3
mephux has quit [Excess Flood]
Stilo has joined #ruby
osaut has quit [Read error: Operation timed out]
grendlme has quit [Quit: grendlme]
chimkan___ has joined #ruby
mephux has joined #ruby
<jerikl> So it works on system ruby 1.8.7 but not rvm ruby 1.8.7?
alvaro_o has joined #ruby
<ogamita> No, it doesn't work on neither. Just a small variation in the error message (the garbage characters are not the same).
otters has quit [Ping timeout: 252 seconds]
<ogamita> delegate.rb didn't change between the two 1.8.7; it change in 1.9.3
rakm has joined #ruby
mklappstuhl has quit [Ping timeout: 264 seconds]
<jerikl> But they are both loaded successfully in both when running tests?
chimkan has quit [Ping timeout: 260 seconds]
<ogamita> Yes.
chimkan___ is now known as chimkan
Elhu has joined #ruby
tommyvyo has quit [Quit: http://twitter.com/tommyvyo]
otters has joined #ruby
otters has quit [Changing host]
otters has joined #ruby
<jerikl> And you are requiring the gems in the same fashion as the tests do and it fails?
DarthGandalf has quit [Ping timeout: 245 seconds]
_nitti has quit [Remote host closed the connection]
<ogamita> Yep, DelegateClass changed a lot in 1.9.3, the creation of methods doesn't goes thru module_eval anymore. It's module_eval that raise the SyntaxError at the origin of the NameError.
<ogamita> jerikl: Well, I hoped to do the necessary require, that's probably the problem. On the other hand, I want to avoid requiring the files that will run the tests non-interactively.
<ogamita> Anyways, work time ends, week end starts, we'll see that later. Thanks for the help. (I'll probably patch DelegateClass to make it like in 1.9).
<ogamita> Bye.
tvw has joined #ruby
<jerikl> Sorry I wasn't much of it /enjoy the weekend!
carloslopes has joined #ruby
_nitti has joined #ruby
mikeycgto has joined #ruby
DarthGandalf has joined #ruby
binarypl1 has quit [Quit: WeeChat 0.4.0]
chimkan has quit [Ping timeout: 244 seconds]
binaryplease has joined #ruby
timmow has quit [Remote host closed the connection]
codespectator has quit [Ping timeout: 252 seconds]
renanoronfle has quit [Ping timeout: 244 seconds]
timmow has joined #ruby
banjara has joined #ruby
snorb has joined #ruby
banisterfiend has joined #ruby
swex_ has quit [Ping timeout: 255 seconds]
girija_ has quit [Ping timeout: 256 seconds]
goraxe has joined #ruby
nazty has joined #ruby
dmiller has joined #ruby
sn0wb1rd has joined #ruby
dmiller has quit [Client Quit]
acriax has quit [Remote host closed the connection]
davidcel- has joined #ruby
erichmenge_ has joined #ruby
mythical has joined #ruby
workmad3 has quit [Ping timeout: 246 seconds]
davidcelis has quit [Ping timeout: 252 seconds]
davidcel- is now known as davidcelis
davidcelis has quit [Changing host]
davidcelis has joined #ruby
rakl has joined #ruby
nga4 has joined #ruby
mythical has quit [Client Quit]
erichmenge has quit [Ping timeout: 245 seconds]
erichmenge_ is now known as erichmenge
mythical has joined #ruby
codespectator has joined #ruby
snorb has left #ruby [#ruby]
snorb has joined #ruby
snorb has left #ruby [#ruby]
tjbiddle has quit [Quit: tjbiddle]
aaronmacy has joined #ruby
zommi has quit [Quit: Leaving.]
skcin7 has joined #ruby
DarthGandalf has quit [Ping timeout: 245 seconds]
ffranz has joined #ruby
joofsh has quit [Remote host closed the connection]
shashin has quit [Quit: shashin]
mythical has quit [Quit: mythical]
dmiller has joined #ruby
chrishunt has joined #ruby
ahokaomaeha has joined #ruby
mythical has joined #ruby
DarthGandalf has joined #ruby
Malgorath has joined #ruby
mythical has quit [Remote host closed the connection]
zastern has joined #ruby
<Malgorath> Is this a place I can ask questions about Ruby on Rails?
dustint has quit [Remote host closed the connection]
jgrevich has quit [Quit: jgrevich]
pavilionXP has joined #ruby
JohnBat26 has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
banjara has quit [Ping timeout: 246 seconds]
<shevy> Malgorath there is channel #rubyonrails
girija_ has joined #ruby
<Malgorath> ah thanks
<shevy> here, on #ruby, people know more about general ruby
jfelchner has joined #ruby
<shevy> rails is very specialized
<Malgorath> I'm just learning something as an alternative to php
mythical has joined #ruby
gosshedd has joined #ruby
jgrevich has joined #ruby
zeade has joined #ruby
<Hanmac> everything is an alternate to php :D
mythical has quit [Client Quit]
miskander has quit [Quit: miskander]
blazes816 has joined #ruby
s__dana has joined #ruby
sailias has quit [Ping timeout: 245 seconds]
jaequery has quit [Ping timeout: 246 seconds]
<deed02392> what does %w{ } do?
<deed02392> split the wrapped on white space into an array/hash?
<GeekOnCoffee> array, yeah
mikepack has joined #ruby
<GeekOnCoffee> at least is my understanding of it
Squarepy has quit [Ping timeout: 276 seconds]
mengu has joined #ruby
stkowski has joined #ruby
jerikl has quit [Quit: Colloquy for iPad - http://colloquy.mobi]
dougireton has quit [Quit: Leaving.]
joeycarmello has joined #ruby
jaequery has joined #ruby
ngoldman has joined #ruby
miskander has joined #ruby
odyssey4me has left #ruby [#ruby]
jaequery has quit [Client Quit]
RurouniJones has quit [Remote host closed the connection]
s__dana_ has joined #ruby
mmitchel_ has quit [Remote host closed the connection]
altamic has quit [Quit: altamic]
maz-dev has joined #ruby
gosshedd has quit [Ping timeout: 245 seconds]
<deed02392> cool thanks GeekOnCoffee
squidBits has joined #ruby
gosshedd has joined #ruby
razibog has joined #ruby
geggam has joined #ruby
jduan1981 has joined #ruby
MissionCritical has quit [Ping timeout: 245 seconds]
chussenot has quit [Quit: chussenot]
<shevy> deed02392 yeah, you could also use %w() ... array = %w( cat dog horse ) # => ["cat", "dog", "horse"]
<shevy> you could also use %
radic_ has quit [Read error: Connection reset by peer]
<shevy> %w% cat dog horse % # => ["cat", "dog", "horse"]
<deed02392> ah gotcha shevy
osaut has joined #ruby
aaronmcadam has quit [Quit: aaronmcadam]
skcin7 has quit [Quit: Computer has gone to sleep.]
s__dana has quit [Ping timeout: 264 seconds]
s__dana_ is now known as s__dana
vlad_starkov has joined #ruby
miskander has quit [Quit: miskander]
girija_ has quit [Ping timeout: 276 seconds]
<tuxillo> hi
spider-mario has joined #ruby
miskander has joined #ruby
<tuxillo> is it possible to redirect stdout, stderr to /dev/null after a popen4 call?
CLUSTERfoo has joined #ruby
Squarepy has joined #ruby
whowantstolivef1 has joined #ruby
maletor has joined #ruby
maletor has quit [Remote host closed the connection]
<otters> you can use any character actually
dougireton has joined #ruby
chrishunt has quit [Quit: Leaving...]
shaman42 has quit [Ping timeout: 245 seconds]
cousine has joined #ruby
mockra_ has joined #ruby
dmiller has quit [Ping timeout: 248 seconds]
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
AxisOfEval has joined #ruby
sailias has joined #ruby
maletor has joined #ruby
maletor has quit [Remote host closed the connection]
tcstar has quit [Read error: Connection reset by peer]
miskander has quit [Quit: miskander]
reinaldob has joined #ruby
cdt has quit [Quit: Ex-Chat]
adeponte has joined #ruby
nw_ has quit [Ping timeout: 260 seconds]
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
nw has joined #ruby
chrishunt has joined #ruby
beaky has joined #ruby
<beaky> hello
Mission-Critical has joined #ruby
<beaky> can "foo" => "bar" be replaced by foo: "bar"?
jonathanwallace has quit [Ping timeout: 248 seconds]
<beaky> or only if "foo" was :foo ?
peteyg has joined #ruby
dmerrick has joined #ruby
<Hanmac> otters no you cant :P only special chars like ( [ { "
<Hanmac> beaky: no, only symbols
<Gate> beaky: only if it was :foo
<beaky> ah
jamescarr has quit [Quit: jamescarr]
havenn has joined #ruby
banjara has joined #ruby
Virunga has joined #ruby
mythical has joined #ruby
shaman42 has joined #ruby
clooth has joined #ruby
banjara has quit [Read error: Connection reset by peer]
<otters> Hanmac: no you can use symbols
<otters> special characters I mean
reinaldob has quit [Remote host closed the connection]
<otters> %w#foo# #=> ["foo"]
tjbiddle has joined #ruby
adeponte has quit [Ping timeout: 256 seconds]
cantonic_ has joined #ruby
thinkclay has joined #ruby
s__dana_ has joined #ruby
girija_ has joined #ruby
s__dana__ has joined #ruby
oinkon has joined #ruby
bigkevmcd has quit [Quit: outta here]
skcin7 has joined #ruby
Skaag has joined #ruby
lkba has joined #ruby
albakry has quit [Quit: Leaving]
poga has quit [Remote host closed the connection]
cantonic has quit [Ping timeout: 264 seconds]
cantonic_ is now known as cantonic
<Skaag> is this format only recognized in a certain higher version of gem/bundler? gem "mysql2", group: :mysql
s__dana has quit [Ping timeout: 256 seconds]
s__dana__ is now known as s__dana
benlieb has joined #ruby
jaywastaken has quit [Read error: Connection reset by peer]
Elhu has quit [Quit: Computer has gone to sleep.]
jaywastaken has joined #ruby
jaywastaken has quit [Changing host]
jaywastaken has joined #ruby
s__dana_ has quit [Ping timeout: 252 seconds]
Mission-Critical is now known as MissionCritical
carlyle has joined #ruby
t0rc has quit [Quit: WeeChat 0.4.0]
jaequery has joined #ruby
RagingDave has joined #ruby
mythical has quit [Quit: mythical]
jacktrick has joined #ruby
Aenigma has left #ruby [#ruby]
hekin has joined #ruby
mafolz has quit [Remote host closed the connection]
<havenn> Skaag: Using 1.9 hash-syntax, so 1.9+ only. Could ask in #bundler. What problem you having?
maxmanders has quit [Quit: Computer has gone to sleep.]
qleelulu has joined #ruby
tcstar has joined #ruby
qleelulu has left #ruby [#ruby]
tommyvyo has joined #ruby
dustint has joined #ruby
Takehiro has quit [Remote host closed the connection]
banjara has joined #ruby
anderse has quit [Quit: anderse]
chimkan_ has joined #ruby
backjlack has quit [Read error: Connection reset by peer]
mmitchell has joined #ruby
grn has joined #ruby
dougireton has quit [Quit: Leaving.]
c0rn has joined #ruby
timmow has quit [Quit: timmow]
cardoni has joined #ruby
fourq has quit [Read error: Operation timed out]
kenneth has quit [Quit: kenneth]
elico has quit [Quit: elico]
elico has joined #ruby
<shevy> Skaag you stuck on a specific version?
<shevy> cuddly otters!!!
<otters> hi
mythical has joined #ruby
carlyle has quit [Ping timeout: 245 seconds]
michaelmartinez has joined #ruby
adkron_ has quit [Ping timeout: 276 seconds]
fourq has joined #ruby
rupee has joined #ruby
samphippen has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
jacktrick has quit [Quit: Leaving]
samphippen has joined #ruby
shashin has joined #ruby
zeade has quit [Quit: Leaving.]
zeade has joined #ruby
dougireton has joined #ruby
spinagon has joined #ruby
arya_ has joined #ruby
rippa has quit [Read error: Connection reset by peer]
bricker is now known as bricker`LA
dmiller has joined #ruby
rdark has quit [Ping timeout: 260 seconds]
slainer68 has joined #ruby
elaptics is now known as elaptics`away
arya has quit [Ping timeout: 248 seconds]
breakingthings has quit []
poikon has quit [Remote host closed the connection]
aaronmacy has quit [Quit: Leaving.]
michaelmartinez has quit [Quit: Check it, Wreck it http://www.caffeineindustries.com/blog]
lolmaus has quit []
jaywastaken has quit [Remote host closed the connection]
hekin has quit [Quit: hekin]
bluenemo has joined #ruby
bluenemo has quit [Changing host]
bluenemo has joined #ruby
tvw has quit [Read error: Connection reset by peer]
Squarepy has quit [Quit: Leaving]
tvw has joined #ruby
renanoronfle has joined #ruby
the_mentat has joined #ruby
bdnelson has quit [Quit: Textual IRC Client: www.textualapp.com]
Mon_Ouie has quit [Ping timeout: 256 seconds]
robotmay_ has quit [Remote host closed the connection]
eldariof has joined #ruby
adeponte has joined #ruby
pu22l3r has joined #ruby
jduan1981_ has joined #ruby
shtirlic has quit [Remote host closed the connection]
forced_request has joined #ruby
techlife has quit [Ping timeout: 272 seconds]
DrShoggoth has quit [Quit: Leaving]
jduan1981 has quit [Ping timeout: 255 seconds]
_nitti has quit [Remote host closed the connection]
jduan1981_ has quit [Ping timeout: 260 seconds]
cohwsw has quit [Remote host closed the connection]
kpshek has quit []
reinaldob has joined #ruby
DrShoggoth has joined #ruby
benlieb has quit [Quit: benlieb]
altamic has joined #ruby
altamic has quit [Changing host]
altamic has joined #ruby
slainer68 has quit [Remote host closed the connection]
wyhaines has quit [Remote host closed the connection]
AxisOfEval has quit [Quit: Leaving...]
wildcard0 has quit [Remote host closed the connection]
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
wildcard0 has joined #ruby
dhruvasa1ar has quit [Ping timeout: 245 seconds]
kenneth has joined #ruby
ferdev_ has joined #ruby
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
fumbe has quit [Ping timeout: 248 seconds]
dhruvasagar has quit [Ping timeout: 252 seconds]
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
benlieb has joined #ruby
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
Markvilla has joined #ruby
reinaldob has quit [Remote host closed the connection]
frem has quit [Quit: Computer has gone to sleep.]
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
jduan1981 has joined #ruby
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
chussenot has joined #ruby
altamic has quit [Ping timeout: 245 seconds]
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
mrsolo has joined #ruby
stkowski has quit [Quit: stkowski]
dmiller has quit [Ping timeout: 256 seconds]
fermion has quit [Quit: P]
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
dougireton has quit [Quit: Leaving.]
techlife has joined #ruby
Catbuntu has joined #ruby
<Catbuntu> Hi
cousine has quit [Remote host closed the connection]
thatRD has quit [Quit: thatRD]
girija_ has quit [Ping timeout: 245 seconds]
i_s has joined #ruby
Takehiro has joined #ruby
buibex has joined #ruby
asobrasil has left #ruby [#ruby]
dougireton has joined #ruby
chussenot has quit [Quit: chussenot]
alanp has quit [Read error: Connection reset by peer]
joofsh has joined #ruby
alanp has joined #ruby
<i_s> does ruby have something like this coffescript? lottery.drawWinner?().address?.zipcode
miskander has joined #ruby
<i_s> the "?." operator, or whatever you'd call it
<i_s> to soak up null references in a chain
Markvilla has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
chussenot has joined #ruby
chussenot has quit [Client Quit]
shashin has quit [Quit: shashin]
bluenemo has quit [Quit: Verlassend]
kpshek has joined #ruby
dougireton has quit [Client Quit]
nate_h_ has joined #ruby
<nate_h_> are there any ruby modules/gems that are good for grabbing info from /proc?
<nate_h_> I want to get information on the bonding status of an interface /proc/net/bonding/bond0
thibauts has quit [Ping timeout: 264 seconds]
mjolk is now known as spacemilk
<bean|work> i_s: the ? would just be part of the function.
<nate_h_> Other than just reading that file and parsing it into a hash, is there something that already exists for this?
Catbuntu has quit [Ping timeout: 248 seconds]
<bean|work> i_s: and ? functions usually return a true or false
Catbuntu has joined #ruby
dougireton has joined #ruby
yshh_ has joined #ruby
decoponio has quit [Quit: my sleeper was come]
<i_s> so no :(
woolite64 has joined #ruby
va_guy_ has joined #ruby
<wmoxam> Is there anything available that's more readable than $1, $2, etc for regexp matches?
kirun has joined #ruby
pu22l3r has quit [Remote host closed the connection]
grendlme has joined #ruby
<bean|work> i_s: I guess i dont understand what ?. is coffeescript accomplishes
<bean|work> in*
spider-mario has quit [Quit: No Ping reply in 180 seconds.]
woolite64_ has quit [Ping timeout: 252 seconds]
Takehiro has quit [Ping timeout: 256 seconds]
<pietr0> wmoxam: `match = string.match(regexp); match[1] ; match[2]`
<i_s> if you have a long chain of properties you want to access, it will just break out early and return null
griffindy has joined #ruby
yshh has quit [Ping timeout: 255 seconds]
<wmoxam> pietr0: yeah, but I mean via a global
spacemilk is now known as spacedog
<wmoxam> pietr0: I thought there was a Regexp class method
spacedog is now known as spacemilk
<i_s> bean|work the result is the same as Hash.new[:bogus1][:bogus2] rescue nil
<wmoxam> but can't seem to find reference to it
<bean|work> ah ok
sullenel has joined #ruby
<i_s> but no rescue
thibauts has joined #ruby
dougireton has quit [Client Quit]
girija_ has joined #ruby
stkowski has joined #ruby
<pietr0> i_s: ActiveSupport in Rails adds a method called 'try' do Object that does that.
sullenel has quit [Client Quit]
<pietr0> s/do/to
miskander has quit [Quit: miskander]
freezway has joined #ruby
otters has quit [Ping timeout: 252 seconds]
<pietr0> i_s: you can simply copy the implementation
kirun has quit [Quit: Client exiting]
workmad3 has joined #ruby
va_guy_ has quit [Quit: Textual IRC Client: www.textualapp.com]
<Hanmac> pietr0 so in rails you can do "try & fail"? :D
_nitti has joined #ruby
chrishough has quit [Quit: chrishough]
<i_s> pietr0: hm just tried it. looks like it needs: Hash.new.try(:[],:bogus1).try(:[],:bogus2)
dougireton has joined #ruby
io_syl has joined #ruby
<pietr0> Hanmac: certainly :P
<pietr0> i_s: it's not exactly the same thing because '?' is valid on ethod names in ruby
woolite64 has quit [Ping timeout: 264 seconds]
Stilo has quit [Quit: Textual IRC Client: www.textualapp.com]
pu22l3r has joined #ruby
<pietr0> i_s: and by convention methodas ending in '?' return booleans
<i_s> right, but it could have just been replaced with another char
statarb3 has joined #ruby
statarb3 has joined #ruby
MissionCritical has quit [Read error: Connection reset by peer]
KevinSjoberg has joined #ruby
woolite64 has joined #ruby
KevinSjoberg has quit [Max SendQ exceeded]
KevinSjoberg has joined #ruby
chiel is now known as chiel`afk
<pietr0> i_s: ruby is open source :)
BizarreCake has quit [Remote host closed the connection]
generalissimo has quit [Remote host closed the connection]
<Hanmac> wmoxan there is an secret regexp technique ...
<Hanmac> >> /(?<word>[[:alpha:]]+)/ =~ "123abc" ? p(word) : nil
<eval-in> Hanmac: Output: "\"abc\"\n" (http://eval.in/8179)
Elhu has joined #ruby
<Hanmac> i mean wmoxam
<i_s> pietr0: good point
angusiguess has joined #ruby
<wmoxam> Hanmac: that's not much nicer
c0rn has quit [Quit: Computer has gone to sleep.]
nimred has joined #ruby
nimred has quit [Changing host]
nimred has joined #ruby
_nitti has quit [Ping timeout: 260 seconds]
wallerdev has joined #ruby
jtharris has quit [Quit: WeeChat 0.3.9.2]
<KevinSjoberg> Hi, guys. I've got this idea of a project I want to create. It's open source. Mostly to improve in programming and learn something along the way. I'm looking for someone that want to help me build this, so we can share ideas and work on it together. The project is a simple markup language (similar to Markdown).
jrist is now known as jrist-afk
<Hanmac> i_s only one of ? and ! is supported and only at the end ... so abc! and abc? is valid, abc?! is not (but you can still define it with define_method)
mythical has quit [Quit: mythical]
dougireton has quit [Remote host closed the connection]
s1n4 has joined #ruby
yacks has quit [Quit: Leaving]
chimkan_ has quit [Quit: chimkan_]
mneorr has quit [Remote host closed the connection]
grendlme has quit [Quit: grendlme]
girija_ has quit [Ping timeout: 264 seconds]
spacemilk is now known as spacekitten
woolite64_ has joined #ruby
spacekitten is now known as Spacehost
woolite64 has quit [Ping timeout: 276 seconds]
Spacehost is now known as Space6host|cloud
buibex has quit [Remote host closed the connection]
sayan has quit [Quit: Leaving]
Space6host|cloud is now known as spacemjolk
dougireton has joined #ruby
green_leaf has quit [Quit: Leaving]
dmiller has joined #ruby
mcqueenorama has joined #ruby
mneorr has joined #ruby
cakehero has joined #ruby
chrishough has joined #ruby
woolite64_ has quit [Ping timeout: 256 seconds]
apok has joined #ruby
Mission-Critical has joined #ruby
otters has joined #ruby
carloslopes has quit [Remote host closed the connection]
otters has quit [Client Quit]
jgrevich_ has joined #ruby
cantonic has quit [Ping timeout: 245 seconds]
<nate_h_> how come I can't add stuff to a hash at two levels at once?
dmiller has quit [Ping timeout: 255 seconds]
<nate_h_> i want to do myhash[var1][var2] = var3
jgrevich has quit [Ping timeout: 252 seconds]
jgrevich_ is now known as jgrevich
mneorr has quit [Remote host closed the connection]
otters has joined #ruby
<nate_h_> but its complaining that bonding.rb:21: undefined method `[]=' for nil:NilClass (NoMethodError)
fasta has joined #ruby
<nate_h_> i can see with puts that all keys and values exist
<nate_h_> see my pastie
spacemjolk is now known as mjolk
shevy has quit [Ping timeout: 264 seconds]
woolite64 has joined #ruby
filipe has quit [Remote host closed the connection]
filipe_ has quit [Remote host closed the connection]
jpfuentes2 has joined #ruby
maletor has joined #ruby
beardyjay has joined #ruby
Mon_Ouie has joined #ruby
<Hanmac> nate_h_ you cant do that like that ...
Mission-Critical is now known as MissionCritical
binaryplease has quit [Quit: WeeChat 0.4.0]
<Hanmac> (bonding[interface] ||= {})[key] = value
Virunga has quit [Remote host closed the connection]
arietis has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
otherj has joined #ruby
workmad3 has quit [Ping timeout: 248 seconds]
dustint has quit [Remote host closed the connection]
<i_s> pietr0: ooh thats better, nice
dustint has joined #ruby
Axsuul has joined #ruby
clocKwize has joined #ruby
<nate_h_> Hanmac: is that because ru by doesn' tknow if the second hash key is an array or a hash?
oposomme has joined #ruby
jgarvey has joined #ruby
luckyruby has joined #ruby
maxmanders has joined #ruby
nimred has quit [Quit: leaving]
<pietr0> i_s: i haven't tested it
codecop has joined #ruby
<Hanmac> nate_h_ yeah
<nate_h_> do I have to say myhash[var1] = Hash.new(...)
<i_s> tested {}[:bogus1].i_s(:bogus2) #=> nil
dbck has joined #ruby
nimred has joined #ruby
<pietr0> i_s: the idea is that if add _i_s to the end of a method name it will it call try passing the original method name as arg
staafl has joined #ruby
staafl has quit [Max SendQ exceeded]
hackerdude has joined #ruby
nimred has quit [Client Quit]
swex has joined #ruby
staafl has joined #ruby
frankkany has joined #ruby
shevy has joined #ruby
jtharris has joined #ruby
<i_s> pietr0: hm, how to use that with the :[] method?
shtirlic has joined #ruby
jfelchner has quit [Ping timeout: 256 seconds]
nomenkun has joined #ruby
Neomex has joined #ruby
<pietr0> i_s: hmm, i don't think it's possible
_nitti has joined #ruby
Neomex has quit [Client Quit]
Neomex has joined #ruby
Neomex has quit [Client Quit]
<pietr0> i_s: it works with #fetch and a default value: {}.fetch_i_s(:bogus1, nil).fetch_i_s(:bogus2, nil)
tenmilestereo has joined #ruby
<i_s> hm, there is no alias for :[] then
mythical has joined #ruby
KevinSjoberg has quit [Quit: Computer has gone to sleep.]
<pietr0> class Hash ; alias :get :[] ; end
<pietr0> {}.get_i_s(:bogus1).get_i_s(:bogus2)
<pietr0> i_s: ^^^
<pietr0> i feel dirty after writing those lines
dyrot has joined #ruby
<katherinem13> What's '$?' mean in Ruby? Googling punctuation is hard
otherj has quit [Quit: otherj]
toekutr has joined #ruby
<i_s> haha cool that works
<pietr0> katherinem13: same thing as in bash. return value of a process
<pietr0> s/a/last
albakry has joined #ruby
albakry has quit [Changing host]
albakry has joined #ruby
alanjc has quit [Ping timeout: 255 seconds]
<katherinem13> pietr0, Hanmac: thanks!
warb0 has quit [Quit: Textual IRC Client: www.textualapp.com]
felipecvo has left #ruby [#ruby]
<Hanmac> hm this list is better: http://ruby.runpaint.org/globals
alanjc has joined #ruby
hemanth_ has quit [Read error: Connection reset by peer]
<kenneth> hey all
hemanth_ has joined #ruby
Raboo has quit [Read error: Connection reset by peer]
radic has joined #ruby
Raboo has joined #ruby
dyrot has quit [Ping timeout: 252 seconds]
oposomme has quit [Ping timeout: 245 seconds]
<kenneth> imagine i have a class which wraps around a connection object. the class has a bunch of methods that use this connection. any of the methods on that connection can throw a "socket exception" exception, which i'd like to catch and use to trigger a reconnect
benlieb has quit [Quit: benlieb]
s1n4 has quit [Quit: leaving]
<kenneth> how would you do this? i'm thinking of doing it this way:
klip has quit [Ping timeout: 255 seconds]
soulcake has quit [Quit: ZNC - http://znc.in]
chiel`afk is now known as chiel
<pietr0> kenneth: when you wrap the connection object rescue the class of the socket exception and retry
klip has joined #ruby
hadees has quit [Read error: Connection reset by peer]
hadees has joined #ruby
soulcake has joined #ruby
<kenneth> creating a proxy object for the connection intercepts every method call and forwards to the connection, catching the exception and re-constructing it
sullenel has joined #ruby
<kenneth> pietr0: well no, i want to avoid having to catch the same exception everywhere i use the connection
<kenneth> because there's like dozens of places
<graft> hey is there a shorthand way to link an instance method to a class method?
<kenneth> graft: you mean the equivalent of doing def method; self.class.method; end
<graft> kenneth: exactly
grzywacz has quit [Quit: :wq]
moos3 has quit [Ping timeout: 245 seconds]
adkron has joined #ruby
chrishunt has quit [Ping timeout: 260 seconds]
pu22l3r has quit [Remote host closed the connection]
<kenneth> graft: it's not that long to type out :) but there isn't a way that i know of, though it'd be easy to build one
<graft> yeah, i guess i can just build one, that's probably easiest in the end
jduan1981 has quit [Ping timeout: 264 seconds]
b1rkh0ff has joined #ruby
Banistergalaxy has quit [Ping timeout: 245 seconds]
freakazoid0223 has joined #ruby
atmosx has joined #ruby
sullenel has quit [Quit: WeeChat 0.4.0]
arturas_ has quit [Ping timeout: 252 seconds]
Banistergalaxy has joined #ruby
<atmosx> hello
johndouthat has joined #ruby
<Hanmac> "Canada joined the map »Pirates of Mali« and is searching for Gold"
NihilistDandy has quit [Quit: Textual IRC Client: www.textualapp.com]
dougireton has left #ruby [#ruby]
RonScagz has quit [Quit: Linkinus - http://linkinus.com]
<pietr0> kenneth: how are you wrappinf the connection?
adkron has quit [Ping timeout: 245 seconds]
haxrbyte has quit [Ping timeout: 248 seconds]
<atmosx> Hanmac, what's that ? game?
kn330 has joined #ruby
clocKwize has quit [Quit: clocKwize]
<Hanmac> atmosx: if yes, an very realistic one: http://www.cbc.ca/news/politics/story/2013/01/28/pol-mali-monday.html
alex__c2022_ has joined #ruby
<tetsus> falcon patch for the win
<tetsus> wow!
mythical has quit [Quit: mythical]
ereslibre_ is now known as ereslibre
mahmoudimus has quit [Read error: Connection reset by peer]
alex__c2022 has quit [Ping timeout: 245 seconds]
alex__c2022_ is now known as alex__c2022
haxrbyte has joined #ruby
CaptainKnots has quit [Ping timeout: 260 seconds]
moos3 has joined #ruby
CaptainKnots has joined #ruby
CaptainKnots has quit [Changing host]
CaptainKnots has joined #ruby
sharpobject has quit [Ping timeout: 260 seconds]
sharpobject has joined #ruby
nimred has joined #ruby
nimred has quit [Changing host]
nimred has joined #ruby
dpn` has quit [Ping timeout: 260 seconds]
benlieb has joined #ruby
breakingthings has joined #ruby
Goles has joined #ruby
mahmoudimus has joined #ruby
Skaag has left #ruby [#ruby]
<benlieb> something has happened to my gem command. I can use it to uninstall, and I can run bundle install, but `gem install x` fails => 'Could not find rubygems-bundler' https://gist.github.com/4693695 help?
chrishough has quit [Quit: chrishough]
faulkner has quit [Read error: Connection reset by peer]
frem has joined #ruby
<atmosx> Hanmac, oh the words kind
_JamieD_ has joined #ruby
moos3 has quit [Ping timeout: 248 seconds]
theoros has quit [Ping timeout: 260 seconds]
<atmosx> s/words/worst
theoros has joined #ruby
pu22l3r has joined #ruby
faulkner has joined #ruby
dpn` has joined #ruby
stkowski has quit [Quit: stkowski]
moshef has joined #ruby
_JamieD_ has quit [Client Quit]
moos3 has joined #ruby
dallasm has joined #ruby
joshcheek has joined #ruby
nate_h_ has quit [Ping timeout: 245 seconds]
TDJACR has quit [Remote host closed the connection]
ananthakumaran has quit [Quit: Leaving.]
codecop has quit [Remote host closed the connection]
skcin7 has quit []
Virunga has joined #ruby
codecop has joined #ruby
Takehiro has joined #ruby
<joshcheek> Hi, I want to invoke a program and give it a stream for its stdin. But reading the docs isn't making it clear to me how to hook the streams together. http://pastie.org/6020628
dmiller has joined #ruby
bigkevmcd has joined #ruby
bigkevmcd_ has joined #ruby
carlzulauf has quit [Read error: Connection reset by peer]
bigkevmcd_ has quit [Read error: Connection reset by peer]
io_syl has quit [Ping timeout: 276 seconds]
workmad3 has joined #ruby
moos3_ has joined #ruby
moos3 has quit [Ping timeout: 264 seconds]
jduan1981 has joined #ruby
io_syl has joined #ruby
jakecamara has joined #ruby
moshef has quit [Quit: moshef]
Takehiro has quit [Ping timeout: 248 seconds]
johnpcamara has joined #ruby
dmiller has quit [Ping timeout: 264 seconds]
eldariof has quit []
chrishough has joined #ruby
jduan1981 has quit [Ping timeout: 246 seconds]
generalissimo has joined #ruby
pu22l3r has quit [Ping timeout: 264 seconds]
<waxjar> joshcheek, i'm guessing puts :)
workmad3 has quit [Read error: Operation timed out]
mneorr has joined #ruby
johnpcamara has left #ruby [#ruby]
banisterfiend has quit [Remote host closed the connection]
jduan1981 has joined #ruby
Catbuntu has quit [Quit: Auf wiedersehen]
<joshcheek> waxjar: I want to connect the streams together, puts writes to the stream.
jamescarr has joined #ruby
michaelmartinez has joined #ruby
<Hanmac> joshcheek .reopen ?
moos3_ is now known as moos3
clooth has quit [Remote host closed the connection]
enroxorz-work has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
c0rn has joined #ruby
cousine has joined #ruby
banisterfiend has joined #ruby
DrShoggoth has quit [Quit: Leaving]
renanoronfle has quit [Quit: This computer has gone to sleep]
<mehwork> where can i find a list of all the one letter shortcuts? like what what 'p' does
<Mon_Ouie> p is just a short method name
phantasm66 has joined #ruby
<Mon_Ouie> So in the documentation of Kernel
<Hanmac> mehwork, there is no list
<Hanmac> http://www.ruby-doc.org/core-1.9.3/Kernel.html << you could look at this
<jokke> wasn't there a neat way to output multiple lines of code?
<mehwork> thx
<jokke> not code
<jokke> text
<jokke> as in usage
<Hanmac> >> p Symbol.all_symbols.select {|s|s.to_s.size == 1 } # this is a list of all symbol (method names with size == 1)
<eval-in> Hanmac: Output: "[:_, :!, :&, :|, :^, :<, :>, :+, :*, :%, :i, :-, :/, :~, :`, :p, :E, :I, :h, :n, :k, :v, :f, :s, :r, :e]\n" (http://eval.in/8181)
<mehwork> a SO answer said to do: y $LOAD_PATH
<mehwork> but y is not a method in irb
<jokke> or do i have to stack up those puts or \n's
mando has quit [Remote host closed the connection]
<Hanmac> mehwork link us this freaky SO answer
spider-mario has joined #ruby
<Hanmac> jokke: look at print vs puts
xandy is now known as xAndy
dougireton has joined #ruby
elkclone has quit [Changing host]
elkclone has joined #ruby
Goles has quit [Quit: Computer has gone to sleep.]
jonahR has quit [Remote host closed the connection]
<theoros> method(:p).owner #=> Kernel
jfelchner has joined #ruby
jonahR has joined #ruby
<Hanmac> mehwork it maybe means pint it with a method of your choice
dallasm has quit []
Monie has joined #ruby
jrist-afk is now known as jrist
<mehwork> when you make a public ruby gem does it have to work on windows? I really don't wanna spend the time to make it work on that crap
<Mon_Ouie> y comes from require 'yaml'
<mehwork> ah thanks Mon
<mehwork> though in this case puts $LOAD_PATH would be easier and more readable
i_s has quit [Quit: i_s]
<jokke> Hanmac: not sure.. You know i just want to print out a long multiline static string.
sullenel has joined #ruby
tspike has joined #ruby
<theoros> jokke: heredocs? %Q{}?
<theoros> jokke: or are you talking about printing a string you already have?
sullenel has quit [Client Quit]
bigkevmcd has quit [Quit: Ex-Chat]
<jokke> i already have it
<theoros> and what's wrong with puts
<jokke> its just a short license declaration
<Hanmac> mehwork you you could say in the gem description that you only support unixoid systems, like i says in the description that only 1.9.* is supported
<mehwork> cool
<jokke> theoros: well, all the \n's or puts are kinda annoying
Takehiro has joined #ruby
<theoros> jokke: if you have a multiline string, why is there not just one puts?
<theoros> puts my_string
<jokke> theoros: yes well, but then i have to add all the \n's in there
<theoros> jokke: maybe you should stop trying to describe code and just paste some example code
<jokke> i thought there was some way to make part of the file just output as is.
jakecamara has quit [Quit: jakecamara]
phantasm66 has quit [Quit: *poof*]
havenn is now known as havenwood
sullenel has joined #ruby
<jokke> i don't know what's so hard to understand.. :/ I just want to output a license declaration. I also want my code to look neat, so i'd like to have the declaration in the file the way it's gonna output. not with \n's or puts
pewter_tao has joined #ruby
<theoros> okay, so you want to make a multiline string easily
<theoros> you don't want to print a multiline string
<pewter_tao> ok, I install a bunch of gems by doing "gem install .../*.gem"
<jokke> yes i wan't to print it
<jokke> too
<pewter_tao> The problem is I get: ERROR: While executing gem... (ArgumentError) invalid byte sequence in US-ASCII
Takehiro has quit [Ping timeout: 264 seconds]
<jokke> i think in python or so you can just make some weird TEXT>>> write your long ass text here <<<TEXT or something
<pewter_tao> at random times during the install of all of the gems... How do I make them install one after the other so it is always the same one causing the error?
<theoros> the weird <<< you're talking about are called heredocs http://en.wikipedia.org/wiki/Here_document
<mehwork> try googling for heredoc in ruby
<jokke> ah see just what i was looking for
<jokke> thanks!
<theoros> heredocs were mentioned more than once, by the way
<mehwork> i'm rarely a fan of those bcause they require no indentation
angusiguess has quit [Ping timeout: 255 seconds]
<mehwork> oh ruby does have a way to indent themm it looks like
dougireton has quit [Quit: Leaving.]
osaut has quit [Quit: osaut]
<theoros> jokke: you may find this useful https://github.com/ruby/ruby/blob/trunk/doc/syntax/literals.rdoc#strings as well as the other parts of this document
stkowski has joined #ruby
nimred has quit [Quit: leaving]
<Hanmac> jokke & theoros:
<Hanmac> >> p "this" "does" "also" "work" # :D
<eval-in> Hanmac: Output: "\"thisdoesalsowork\"\n" (http://eval.in/8182)
<theoros> except why would you do that in this case
shashin has joined #ruby
cousine has quit [Remote host closed the connection]
rakl has quit [Quit: sleeping]
<Hanmac> because iCan? :D
dallasm has joined #ruby
nimred has joined #ruby
nimred has quit [Changing host]
nimred has joined #ruby
mercwithamouth has quit [Ping timeout: 244 seconds]
dougireton has joined #ruby
arturaz has quit [Remote host closed the connection]
mephux has quit [Excess Flood]
dougireton has left #ruby [#ruby]
chrishunt has joined #ruby
freakazoid0223 has quit [Quit: Leaving]
mephux has joined #ruby
<mehwork> i like %Q() more
Goles has joined #ruby
tspike has quit [Ping timeout: 255 seconds]
jfl0wers has quit [Quit: jfl0wers]
kpshek has quit []
cakehero has quit [Quit: Computer has gone to sleep.]
<mehwork> though youd have to end it with a regex to format it how you want it
squidBits has quit [Quit: whoops]
sailias has quit [Ping timeout: 264 seconds]
ryanf has joined #ruby
nomenkun has quit [Remote host closed the connection]
tspike has joined #ruby
dallasm has quit [Remote host closed the connection]
Elhu has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
mneorr has quit [Remote host closed the connection]
Skylab has quit [Quit: Skylab]
Elhu has joined #ruby
blaines has joined #ruby
wargasm has joined #ruby
arya_ has quit [Ping timeout: 248 seconds]
Mchl has quit [Quit: ZNC - http://znc.sourceforge.net]
Kuifje has quit [Read error: Connection reset by peer]
dmerrick_ has joined #ruby
kpshek has joined #ruby
Mchl has joined #ruby
mneorr_ has joined #ruby
havenwood has quit [Remote host closed the connection]
Kuifje has joined #ruby
havenwood has joined #ruby
iambic has joined #ruby
mando has joined #ruby
chiel is now known as chiel`afk
chiel`afk is now known as chiel
arya has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
dmerrick has quit [Ping timeout: 245 seconds]
dmerrick_ is now known as dmerrick
<ericwood> wtf, if you do a Marshal.load on a ruby object that contains unicode it barfs
Guest39686 has quit [Ping timeout: 255 seconds]
<ericwood> anyone have any idea what's up with that?
stkowski has quit [Read error: Connection reset by peer]
nimred has quit [Read error: Connection reset by peer]
nimred has joined #ruby
nimred has quit [Changing host]
nimred has joined #ruby
tspike has quit [Ping timeout: 256 seconds]
atmosx has quit [Quit: Leaving]
havenwood has quit [Ping timeout: 264 seconds]
Retistic has joined #ruby
graft_ has joined #ruby
workmad3 has joined #ruby
moos3 has quit [Quit: Computer has gone to sleep.]
aquaranto has quit [Read error: Connection reset by peer]
aquaranto has joined #ruby
sailias has joined #ruby
c0rn has quit [Quit: Computer has gone to sleep.]
grendlme has joined #ruby
mattso has joined #ruby
<mattso> Hi guys, this is a Rails question but #rails seems dead
mythical has joined #ruby
asteve has quit [Quit: Computer has gone to sleep.]
<mattso> I don't understand why there's an error here,
<workmad3> mattso: #rubyonrails
dallasm has joined #ruby
__BigO__ has quit [Remote host closed the connection]
<mattso> there is a well defined expireTime, in the model and saved to the db
<mattso> ahh, ok. Thanks workmad3
geekbri has quit [Remote host closed the connection]
Monie has quit [Read error: Connection reset by peer]
dougireton has joined #ruby
Monie has joined #ruby
shashin has quit [Quit: shashin]
dougireton has quit [Read error: Connection reset by peer]
Elhu has quit [Quit: Computer has gone to sleep.]
n1x has joined #ruby
dougireton has joined #ruby
joshcheek has quit [Read error: Connection reset by peer]
joshcheek has joined #ruby
kirun has joined #ruby
shtirlic has quit [Remote host closed the connection]
dougireton has quit [Client Quit]
backjlack has joined #ruby
elvikingo has joined #ruby
Monie has quit [Read error: Connection reset by peer]
Monie has joined #ruby
browndawg has left #ruby [#ruby]
mneorr_ has quit [Remote host closed the connection]
aaronmcadam has joined #ruby
jfl0wers has joined #ruby
mneorr has joined #ruby
m8 has joined #ruby
<elvikingo> in a slim template how do you do a link inside a paragraph. e.g. <p>Hello <a href="#url">here's a link</a> that you should follow</p> ?
<elvikingo> https://github.com/slim-template/slim just tried it today. not sure if like it ^^
c0rn has joined #ruby
tspike has joined #ruby
dougireton has joined #ruby
Villadelfia has quit [Read error: Operation timed out]
poikon has joined #ruby
mercwithamouth has joined #ruby
Elhu has joined #ruby
__BigO__ has joined #ruby
SeySayux has quit [Ping timeout: 240 seconds]
<lectrick> What does anyone think of this idea? https://gist.github.com/4694272
SeySayux has joined #ruby
angusiguess has joined #ruby
freakazoid0223 has joined #ruby
fmcgeough has quit [Quit: fmcgeough]
albakry has quit [Quit: Leaving]
Villadelfia has joined #ruby
chiel is now known as chiel`afk
JumpMast3r has quit [Quit: JumpMast3r]
elventails has joined #ruby
elventails has left #ruby [#ruby]
bawigga has joined #ruby
<swarley> I'm trying to decide on whether to use Treetop or parslet
elaptics`away is now known as elaptics
<bawigga> I'm writing a gem to consume content from an API. Should that gem return objects or hashes? What's best practice?
<bawigga> hashes seem more generic, but with objects i could add business logic
bawigga has left #ruby [#ruby]
bawigga has joined #ruby
<bawigga> back sorry
<bawigga> accidentally quit the room
chiel`afk is now known as chiel
cmyers has joined #ruby
colonolGron has joined #ruby
<swarley> bawigga, it depends on what you will be doing with the content
<bawigga> well it's a gem, so hopefully it could be used by any project depending on our api
<swarley> If you know the keys and you will be accessing it independantly, then you may want to use an object. However if you are going to iterate you may want a hash
Nisstyre has quit [Ping timeout: 255 seconds]
frankkany has quit [Remote host closed the connection]
<swarley> >> Struct.new(:foo, :bar).new(%w{hello world}).tap {|me| puts me.foo }.tap {|me| puts me.bar }
<eval-in> swarley: Output: "hello\nworld\n\n" (http://eval.in/8183)
<bawigga> sounds like a class is the way to go, both for encapsultation and robustness
moshee has quit [Ping timeout: 245 seconds]
emmanuelux has joined #ruby
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
soulisson has joined #ruby
<swarley> >> {foo: "hello",bar: "world"}.each {|key,val| puts val }
<eval-in> swarley: Output: "hello\nworld\n" (http://eval.in/8184)
ryanh has joined #ruby
abcdefg_ has quit [Quit: ChatZilla 0.9.89 [Firefox 17.0.1/20121128204232]]
chrishunt has quit [Quit: Leaving...]
<soulisson> Hi, i would like to learn about distributed programming concepts while using the ruby, can you guys give some advice on where to begin (books, videos, ...)
<soulisson> ?
ryanjh has joined #ruby
alex__c2022 has quit [Remote host closed the connection]
ryanh has quit [Read error: Connection reset by peer]
ryanjh is now known as ryanh
Retistic has quit [Quit: Retistic]
carloslopes has joined #ruby
alex__c2022 has joined #ruby
mengu_ has joined #ruby
sailias has quit [Ping timeout: 245 seconds]
rezzack has joined #ruby
dmerrick has quit [Remote host closed the connection]
icole has joined #ruby
dmerrick has joined #ruby
__BigO__ has quit [Remote host closed the connection]
dbck has quit [Quit: Be back later]
grendlme has quit [Remote host closed the connection]
nkr has quit [Quit: Linkinus - http://linkinus.com]
chrishunt has joined #ruby
mengu has quit [Ping timeout: 256 seconds]
emmanuelux has quit [Ping timeout: 245 seconds]
<cmyers> I am trying to shim into an activerecord mysql adapter. Sometimes it is defined, and sometimes it isn't. How do I adjust this code to work all the time? https://gist.github.com/4694419
the_mentat has quit [Quit: Computer has gone to sleep.]
sn0wb1rd has quit [Quit: sn0wb1rd]
<cmyers> I feel like I need to do an `if responds_to?(...)` or something like that but I can't find an example or anything that works
thone has joined #ruby
blacktulip has quit [Remote host closed the connection]
asteve has joined #ruby
jduan1981 has quit [Ping timeout: 240 seconds]
havenwood has joined #ruby
thone_ has quit [Ping timeout: 264 seconds]
dyrot has joined #ruby
yalue has quit [Quit: Leaving]
tommyvyo has quit [Quit: http://twitter.com/tommyvyo]
sn0wb1rd has joined #ruby
alanjc has quit [Ping timeout: 252 seconds]
dyrot is now known as alanjc
icole has quit [Remote host closed the connection]
carloslopes has quit [Remote host closed the connection]
Monie has quit [Quit: Quit]
invisime has quit [Quit: Leaving.]
griffindy has quit [Quit: Computer has gone to sleep.]
nobuoka has quit [Read error: Operation timed out]
elvikingo has quit [Ping timeout: 255 seconds]
backjlack has quit [Remote host closed the connection]
mengu__ has joined #ruby
Udom0 has quit [Quit: Leaving.]
emmanuelux has joined #ruby
maletor has joined #ruby
<Hanmac> cmyers: use method_defined?
<workmad3> cmyers: or instance_methods.include?(:connect)
<mehwork> are user defined methods supposed to be snake_case in ruby as a style convention?
<cmyers> So I do ActiveRecord::whatevs::Mysql2Adapter.method_defined?(:connect) ?
nga4 has quit [Ping timeout: 252 seconds]
wyhaines has joined #ruby
mengu_ has quit [Ping timeout: 264 seconds]
<cmyers> ooh, the connect method is private. does alias_method work on private methods?
<banisterfiend> cmyers: yes
Umren has quit [Read error: Connection reset by peer]
Elhu has quit [Quit: Computer has gone to sleep.]
mattso has quit [Quit: Page closed]
<cmyers> hmm, this might work then - testing
<jokke> how can i debug my code again?
razieliyo has quit [Read error: Connection reset by peer]
<jokke> step by step
kpshek has quit []
<jokke> or rather line by line
Mchl has quit [Quit: ZNC - http://znc.sourceforge.net]
roadt_ has quit [Ping timeout: 276 seconds]
razibog has quit [Ping timeout: 245 seconds]
jduan1981 has joined #ruby
luckyruby has quit [Remote host closed the connection]
<cmyers> hmm, now I am getting superclass mismatch. is there a way to reopen a class without knowing what it inherrits?
luckyruby has joined #ruby
Mchl has joined #ruby
jonahR has quit [Ping timeout: 260 seconds]
reinaldob has joined #ruby
<Hanmac> “If you’re out walking, we’re going to stop you, ask why you’re out walking, and check for your ID,” police chief Todd Stovall told a December town hall meeting. <<< wtf?
chrishunt has quit [Quit: Leaving...]
Skylab has joined #ruby
<havenwood> fuck the police?
chrishunt has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
DaltonUS has quit [Quit: DaltonUS]
chrishunt has quit [Client Quit]
maletor has joined #ruby
<lectrick> Is there a way to ask an object whether it extends a module?
<lectrick> similar to ".include?"
<cmyers> http://patmaddox.com/2010/11/16/how-i-reopen-classes-in-ruby/ seems to answer my question, testing...
n1x has quit [Quit: Ex-Chat]
tenmilestereo has quit [Quit: Leaving]
malkomalko has quit [Read error: Connection reset by peer]
malkomalko has joined #ruby
i_s has joined #ruby
<Hanmac> havenwood: it seems that is totally unnatural for americans to walk with their own foot ... it seems that they drive even its only a few meters :P
chrishunt has joined #ruby
reinaldob has quit [Remote host closed the connection]
<lectrick> nevermind it's singleton_class.include?
<havenwood> Hanmac: I do live in LA, so hard to contradict...
colonolGron has quit [Quit: Lost terminal]
bluOxigen has quit [Ping timeout: 264 seconds]
<havenwood> Hanmac: But a growing number of us ride bikes (and get hit by cars regularly!).
jonahR has joined #ruby
JJMalina has joined #ruby
<JJMalina> is it safe to install gems from rubygems?
ham1 has joined #ruby
<Hanmac> JJMalina: it was :D
<JJMalina> ….at this point in time?
Micha____ has joined #ruby
<Hanmac> i think they may have restored the packs ... (does rubygems has its own channel too?)
theoros is now known as lrnt
Goles has quit [Quit: Out.]
lrnt is now known as theoros
mmitchell has quit [Read error: Connection reset by peer]
hackeron has quit [Ping timeout: 255 seconds]
foohey has quit [Remote host closed the connection]
shashin has joined #ruby
mmitchell has joined #ruby
keymone has joined #ruby
hackeron has joined #ruby
foohey has joined #ruby
<nateberkopec> JJMalina: Rubygems.org has said they're good http://blog.rubygems.org/2013/01/31/data-verification.html
alanjc has quit [Read error: Operation timed out]
benlieb has quit [Quit: benlieb]
dyrot has joined #ruby
_nitti has quit [Remote host closed the connection]
<JJMalina> nateberkopec: thanks
keymone has quit [Client Quit]
<workmad3> Hanmac: #rubygems
<workmad3> Hanmac: there's also a few others at the moment... #rubygems-aws for people working on the aws infrastructure rebuild
<havenwood> #rubygems for general matters, #rubygems-verification (kinda moot since verified but still active), #rubygems-trust for future looking validations, #rubygems-aws for new platform
maletor has quit [Quit: Computer has gone to sleep.]
<workmad3> havenwood: what about #rubygems-exploit ?
* workmad3 just checked the #rubygems topic, they're all there
bricker`work is now known as bricker
rakl has joined #ruby
<Hanmac> hm i need to publish and develop more C++ gems :P
breakingthings has quit []
dougireton has quit [Quit: Leaving.]
<havenwood> If you've got expertise in X509 or GPG join #rubygems-trust and chime in!
oy has joined #ruby
CLUSTERfoo has quit [Quit: Leaving]
<Hanmac> havenwood ... hm not yet, but i am good in studing C(++) code ...
jaygen has quit [Remote host closed the connection]
<oy> TEST
samuel02 has joined #ruby
nateberkopec has quit [Quit: Leaving...]
ferdev has quit [Disconnected by services]
ferdev_ is now known as ferdev
<jokke> here's my code: http://paste.xinu.at/A3n9X4/
<jokke> i get the error dynmenu.rb:120:in `to_s': undefined method `keys' for nil:NilClass (NoMethodError)
<Hanmac> the only code i am not willed to understand is php code ... specially when its ecommerce shit
jrist is now known as jrist-afk
MrPunkin has joined #ruby
<jokke> so this is something like a null pointer exception
<jokke> it seems that the object i'm trying to call keys on is nil
<MrPunkin> Okay folks, I'm looking at trying to do some sorting / grouping in my app that can't be done at the DB level. What would be the most efficient method to sort an array of hashes by one of the hash values for ~100k objects?
<MrPunkin> Trying to just get some benchmarks to know if it's even doable routinely
<jokke> i just don't understand, why to_s is called at all. I didn't call the function anywhere
<jokke> Can anyone help?
elvikingo has joined #ruby
aquaranto has quit [Remote host closed the connection]
jrafanie has quit [Quit: jrafanie]
joshcheek_ has joined #ruby
<poikon> jokke: you're creating a string
moshee has quit [Ping timeout: 255 seconds]
joshcheek has quit [Ping timeout: 240 seconds]
joshcheek_ is now known as joshcheek
<poikon> .join does that
<Hanmac> jokke you miss a super
moshee has joined #ruby
ham1 has quit [Ping timeout: 252 seconds]
chussenot has joined #ruby
rudiX has joined #ruby
<havenwood> Too bad HN etc get no attention for: "TL;DR: We were able to verify that all gems served by rubygems.org are tamper-free."
angusiguess has quit [Ping timeout: 248 seconds]
<jokke> poikon: ah ok
statarb3 has quit [Ping timeout: 245 seconds]
<jokke> havenwood: what do you mean?
<workmad3> jokke: also string interpolation
RagingDave has quit [Quit: Ex-Chat]
<jokke> where do i miss one?
<workmad3> jokke: this - '" #{@colors}" ' calls .to_s on @colors
<poikon> you could try a .reject(:nil?) before the join
oy has left #ruby [#ruby]
<workmad3> jokke: and inserts the result into the string
<havenwood> Maybe postmortems will get more attention.
havenwood has quit [Remote host closed the connection]
<workmad3> poikon: .compact ;)
ffranz has quit [Ping timeout: 245 seconds]
<poikon> workmad3: thanks :)
whowantstolivef1 has quit [Ping timeout: 245 seconds]
<Hanmac> jokke: Editor::initialize does NOT call Menu::initialize, so @items is NOT set
reinaldob has joined #ruby
<jokke> ah
<jokke> i get it ok
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
<jokke> makes sense
ner0x has quit [Quit: Leaving]
<Hanmac> jokke: YAML::load File.open(file) is wrong: YAML::load File.read(file) is better, or File.open(file) {|f| YAML::load f}
<jokke> Hanmac: thanks again :P
kn330 has quit [Ping timeout: 260 seconds]
jtharris has quit [Quit: WeeChat 0.3.9.2]
<jokke> Hanmac: where do i need @items in Editor?
benlieb has joined #ruby
<jokke> i don't need it
<jokke> at least not knowingly :D
<Hanmac> does your error has a backtrace too?
xbayrockx has joined #ruby
xbayrockx is now known as wf2f
<jokke> yes
<jokke> one moment
tspike has quit [Ping timeout: 245 seconds]
<jokke> 4 lines paste here okay?
yfeldblum has quit [Ping timeout: 245 seconds]
<Hanmac> i dont think so :P
katzekintosh has quit [Quit: Leaving]
browndawg has joined #ruby
mmitchell has quit [Remote host closed the connection]
IRC-bot has joined #ruby
reinaldob has quit [Remote host closed the connection]
<Hanmac> jokke. show_menu returns the menu as a string, that calls to_s, that needs this items
bjeanes has quit [Ping timeout: 248 seconds]
ngoldman has quit [Remote host closed the connection]
maletor has joined #ruby
jerius has quit []
elux has quit [Quit: Bye!]
Skylab has quit [Quit: Skylab]
_nitti has joined #ruby
<jokke> Hanmac: which part of the line calls to_s of Menu?
<jokke> entries.join?
<Hanmac> yeah
<jokke> but entries shouldn't be @items in Editor
willob has quit [Quit: Leaving.]
luk3 has quit [Quit: luk3]
ham1 has joined #ruby
IRC-bot has quit [Read error: Connection reset by peer]
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
chrishough has quit [Quit: chrishough]
<jokke> i don't get what the problem is.. :/
Morkel has joined #ruby
samlt has quit [Ping timeout: 240 seconds]
sullenel has quit [Quit: WeeChat 0.4.0]
jonathanwallace has joined #ruby
techhelp has quit [Quit: This computer has gone to sleep]
ebobby has joined #ruby
mythical has quit [Ping timeout: 260 seconds]
michaelmartinez has quit [Quit: Check it, Wreck it http://www.caffeineindustries.com/blog]
Retistic has joined #ruby
iambic has quit [Quit: leaving]
stkowski has joined #ruby
dougireton has joined #ruby
<Hanmac> jokke: "echo \"#{entries.join "\n"}\" this part ... join uses to_s to concat the elements together and Menu#to_s is broken
stormetrooper has quit [Quit: I found the droids I was looking for]
generalissimo has quit [Remote host closed the connection]
niklasb has quit [Ping timeout: 245 seconds]
bradleyprice has quit [Remote host closed the connection]
spider-mario has quit [Remote host closed the connection]
grn has quit [Read error: Connection reset by peer]
icole has joined #ruby
asteve has quit [Quit: Computer has gone to sleep.]
axl_ has quit [Quit: axl_]
tspike has joined #ruby
graeme has joined #ruby
SCommette has quit [Quit: SCommette]
jlast has quit [Remote host closed the connection]
dougireton has quit [Remote host closed the connection]
kenneth has quit [Quit: kenneth]
Spooner has quit [Remote host closed the connection]
jonahR has quit [Quit: jonahR]
chussenot has quit [Quit: chussenot]
nga4 has joined #ruby
Spooner has joined #ruby
chiel is now known as chiel`afk
otherj has joined #ruby
chiel`afk is now known as chiel
jduan1981 has quit [Read error: Connection reset by peer]
jduan1981_ has joined #ruby
Morkel has quit [Quit: Morkel]
theRoUS has quit [Ping timeout: 272 seconds]
Takehiro has joined #ruby
mythical has joined #ruby
JMcAfreak has joined #ruby
carloslopes has joined #ruby
cardoni is now known as greg
otherj has quit [Client Quit]
jaequery has quit [Quit: Textual IRC Client: www.textualapp.com]
<MrPunkin> are ordered hashes more efficient than trying to find data in nested arrays?
solidoodlesuppor has quit [Remote host closed the connection]
chiel is now known as chiel`afk
jaequery has joined #ruby
pu22l3r has joined #ruby
mythical has quit [Client Quit]
pu22l3r has quit [Remote host closed the connection]
kirun has quit [Quit: Client exiting]
pu22l3r has joined #ruby
v0n has quit [Ping timeout: 245 seconds]
Takehiro has quit [Ping timeout: 246 seconds]
kenneth has joined #ruby
rudiX has quit [Quit: rudiX]
gosshedd has quit [Ping timeout: 256 seconds]
<Hanmac> MrPunkin: hashs are not not orderd by default
greg is now known as cardoni
Asher has quit [Read error: No route to host]
<MrPunkin> I understand that
bjeanes has joined #ruby
<MrPunkin> but 1.9 introduced ordered hashes
Asher has joined #ruby
carloslopes has quit [Ping timeout: 264 seconds]
c0rn has quit [Ping timeout: 252 seconds]
huoxito has joined #ruby
drockna has joined #ruby
jamescarr has quit [Quit: jamescarr]
TheFuzzball has quit [Ping timeout: 256 seconds]
michaelmartinez has joined #ruby
jduan1981_ has quit [Read error: Connection reset by peer]
jduan1981 has joined #ruby
yfeldblum has joined #ruby
jgarvey has quit [Quit: Leaving]
browndawg has quit [Read error: Operation timed out]
<jokke> Hanmac: i'm sorry to be such a pain, but what exactly is broken? And why does join try to call to_s on Menu? Makes no sense to me :/
pcarrier has joined #ruby
malkomalko has quit [Remote host closed the connection]
<jokke> i'd understand if it tried to call to_s on entries..
philcrissman has quit [Remote host closed the connection]
c0rn has joined #ruby
_nitti has quit [Remote host closed the connection]
chimkan_ has joined #ruby
<Hanmac> jokke:
<Hanmac> >> p [1,2,3,4,5,6].join
<eval-in> Hanmac: Output: "\"123456\"\n" (http://eval.in/8185)
warb0 has joined #ruby
<jokke> yes
<Hanmac> join calls to_s on entry objects in entries
<jokke> no
<Hanmac> wrong it does
<jokke> i pass entry.keys
<jokke> i mean @items.keys
mikepack has quit [Remote host closed the connection]
<jokke> which are simple strings
chrishough has joined #ruby
arya has quit [Ping timeout: 248 seconds]
<Hanmac> jokke wrong line, i mean entries.join on Line 133
<Hanmac> its an Array of Editor objects
bean|work has quit [Quit: Computer has gone to sleep.]
<jokke> AH!
<jokke> finally!
<Hanmac> THIS join calls to_s on the Editor objects ... which is the Menu#to_s
<jokke> yes, all makes sense now. thanks for working with this shit brain of mine :D
<TomJ> I'm using Pry as an IRB replacement and it's lovely. But one annoying issue - I can't do Control-Left / C-Right to go back/forward a work. This works in my shell and every other readline app I have, e.g. mysql client. The only reference to a similar issue I can find via Google is someone who had the issue only when running Pry in a particular Rails project, and that was caused by a conflicted readline Gem. But for me it happens in all Pry sessions, and I h
<TomJ> no rb-readline or similar gems
<TomJ> I need to search a hash many tens of thousands of times in a method: what is the most performant way to do so? I just need to know if a key exists, I dont need to know the value. Currently I'm doing: unless myhash[integer_key].nil? … - is there any faster method, like a search or anything?
_nitti has joined #ruby
<TomJ> in fact it will be searched close to a million times
TheFuzzball has joined #ruby
pu22l3r_ has joined #ruby
LKiS has left #ruby ["Leaving"]
stkowski has quit [Quit: stkowski]
mando has quit [Remote host closed the connection]
cauffe has quit [Read error: Connection reset by peer]
codecop has quit [Quit: Išeinu]
JJMalina has quit [Quit: JJMalina]
supergiantrobot_ has quit [Quit: supergiantrobot_]
michaelmartinez has quit [Quit: Check it, Wreck it http://www.caffeineindustries.com/blog]
arya has joined #ruby
pu22l3r has quit [Ping timeout: 252 seconds]
freakazoid0223 has quit [Quit: Leaving]
generalissimo has joined #ruby
soulisson has quit [Quit: Leaving]
<Spooner> TomJ Hash.has_key?
anderse has joined #ruby
<Spooner> But I don't expect it is any faster.
answer_42 has quit [Ping timeout: 276 seconds]
chimkan_ has quit [Ping timeout: 255 seconds]
<Spooner> TomJ : And you don't need to search in a Hash. It is super-fast lookup.
<lectrick> who is searching in a hash?
SCommette has joined #ruby
<lectrick> TomJ: and what they said, it's Hash#has_key? or just hash_var[:keyname] not being nil
chimkan_ has joined #ruby
<TomJ> I need to check a hash to see if a key exists in it, about a million times. so I wanted to know what was the absolutely fastest way - like whether anything would be faster than my current unless myhash[key].nil?
<TomJ> ok thanks guys, I might benchmark to see if there's a difference between those two but guess there won't be
<lectrick> i would guess has_key? might be fractionally faster than just trying to index by the key
pu22l3r_ has quit [Remote host closed the connection]
<lectrick> TomJ: You can also just do hash.key? ... I think they're aliased
<TomJ> and if I do: if ( hash.key?(key) || other_exp … ) - it doesn't evaluate other_exp unless hash.key? is true, correct?
<TomJ> no that's not right
dougireton has joined #ruby
<jokke> next problem... updated code: http://paste.xinu.at/yc2sJ/
drockna has left #ruby [#ruby]
<jokke> on line 150 the while loop is just skipped
<jokke> i tried the expression in irb and for some reason it returns nil
thufir_ has joined #ruby
<jokke> not true or false
frem has quit [Ping timeout: 245 seconds]
kristofers has quit []
mneorr has quit [Remote host closed the connection]
joofsh has quit [Remote host closed the connection]
arya has quit [Ping timeout: 248 seconds]
JumpMast3r has joined #ruby
mmitchell has joined #ruby
<jokke> >> entries = []; selection = nil; entries.index selection != entries.length - 1
<eval-in> jokke: Output: "" (http://eval.in/8186)
unsay has quit [Ping timeout: 252 seconds]
chimkan_ has quit [Read error: Connection reset by peer]
<jokke> huh..
<jokke> no output
<jokke> wtf
apok has quit [Quit: apok]
Takehiro has joined #ruby
ner0x has joined #ruby
<jokke> ah i gotta put the left part in parentheses
banjara has quit [Quit: Leaving.]
Mon_Ouie has quit [Ping timeout: 245 seconds]
arya has joined #ruby
pu22l3r has joined #ruby
pavilionXP has quit [Read error: Connection reset by peer]
maxmanders has quit [Quit: Computer has gone to sleep.]
chimkan has joined #ruby
dougireton has quit [Remote host closed the connection]
Micha____ has quit [Remote host closed the connection]
segv-_ has quit [Ping timeout: 248 seconds]
kaen has quit [Remote host closed the connection]
Michael_ has joined #ruby
jduan1981 has quit [Read error: Connection reset by peer]
jduan1981 has joined #ruby
Takehiro has quit [Ping timeout: 252 seconds]
awarner has quit [Remote host closed the connection]
angusiguess has joined #ruby
nanothief has joined #ruby
banisterfiend has quit [Ping timeout: 276 seconds]
dougireton has joined #ruby
SCommette has quit [Quit: SCommette]
chimkan has quit [Ping timeout: 245 seconds]
vlad_starkov has quit [Remote host closed the connection]
chimkan has joined #ruby
workmad3 has quit [Ping timeout: 244 seconds]
luk3_ has joined #ruby
dougireton has quit [Client Quit]
pyx has joined #ruby
angusiguess has quit [Ping timeout: 244 seconds]
LKiS has joined #ruby
luk3_ has quit [Client Quit]
dougireton has joined #ruby
LKiS has left #ruby [#ruby]
graeme has quit [Quit: graeme]
dallasm has quit []
luk3 has joined #ruby
chiel`afk is now known as chiel
chimkan has quit [Read error: Connection reset by peer]
luk3 has quit [Client Quit]
joshman_ has quit [Ping timeout: 245 seconds]
chimkan has joined #ruby
maj has joined #ruby
jduan1981 has quit [Read error: Connection reset by peer]