apeiros_ changed the topic of #ruby to: Ruby 2.1.2; 2.0.0-p481; 1.9.3-p545: http://ruby-lang.org || Paste >3 lines of text on http://gist.github.com || this channel is logged at http://irclog.whitequark.org, other public logging is prohibited
namxam has quit [Ping timeout: 245 seconds]
jottr has quit [Ping timeout: 255 seconds]
frank__ has joined #ruby
<frank__> hey all, how do you get all the migrate tasks to depend on one of your tasks? Say I need to setup a connection to MongoDB before most migrations run for example
wjimenez_5271_ has joined #ruby
yeticry has quit [Ping timeout: 255 seconds]
Testor has joined #ruby
<Testor> sup
codezomb has joined #ruby
beseku has joined #ruby
mikepack_ has joined #ruby
<ramfjord> frank__: If you make that task a dependency, it will get run first
<ramfjord> that's how rails loads its environment
Martxel has quit [Ping timeout: 272 seconds]
<ramfjord> if you're familiar with task blah: :environment
<frank__> ramfjord, but a dependency on what? theres like 5 tasks under the migrate namespace
<ramfjord> so you would do task blah: [:environment, :mongo_connection]
terrellt has quit [Quit: Leaving...]
fold has joined #ruby
Zebroid has quit [Remote host closed the connection]
wjimenez5271 has quit [Ping timeout: 255 seconds]
<frank__> so I want db:migrate to depend mongo cool. How do I redeclare db:migrate so that it still runs the original but w/ the added dependency?
awc737 has joined #ruby
<ramfjord> namespace db
<frank__> I was thinking of overriding the :environment task to depened on the :mongo task...but then couldn't figure out how to get the original :environment task to still run
<ramfjord> task migrate: :environment
sepp2k1 has joined #ruby
<ramfjord> task mongo_migrate: [:environment, :migrate]
thams has quit [Quit: thams]
<ramfjord> task mongo_migrate: [:environment, :mongo_setup, :migrate]
<ramfjord> actually
mikepack has quit [Ping timeout: 255 seconds]
thams has joined #ruby
<ramfjord> or you can do task mongo_env: environment, like you said...
<frank__> so if I do task migrate: [:environment, :mongo] then nice its setup with the dependencies...but it doesn't actually migrate
<frank__> just runs the empty body of the new migrate task
sepp2k has quit [Ping timeout: 272 seconds]
<frank__> how do I get it to call the 'parent' task?
mikepack_ has quit [Ping timeout: 250 seconds]
beseku has quit [Ping timeout: 272 seconds]
jimbow has quit [Quit: jimbow]
AskSteve1 has joined #ruby
yeticry has joined #ruby
AskSteve1 has left #ruby [#ruby]
<frank__> ramfjord, any ideas?
mostlybadfly has quit [Quit: Connection closed for inactivity]
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
renderful has joined #ruby
Soda has quit [Remote host closed the connection]
codezomb has quit [Quit: Textual IRC Client: www.textualapp.com]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
sunya7a has joined #ruby
jaimef has quit [Excess Flood]
tkuchiki has quit [Remote host closed the connection]
Testor has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
renderfu_ has quit [Ping timeout: 260 seconds]
<frank__> anybody else any ideas? Seems like something that would have been asked a bunch of times by now but I can't find the answer. Being able to run a user task that all the existing migration tasks run first
dapz has joined #ruby
lw has quit [Quit: s]
nanoyak has quit [Quit: Computer has gone to sleep.]
jaimef has joined #ruby
yeticry has quit [Ping timeout: 272 seconds]
Photism has quit [Quit: Leaving]
yeticry has joined #ruby
thams has quit [Quit: thams]
ddv has quit [Ping timeout: 260 seconds]
renderful has quit [Remote host closed the connection]
tobago has quit [Read error: Permission denied]
tobago has joined #ruby
lw has joined #ruby
jay_ has quit [Remote host closed the connection]
<ramfjord> frank__: try rake :mongo_migrate => [:mongo_env, :migrate]
Lewix has joined #ruby
<ramfjord> frank__: err. task :mongo_migrate => [:mongo_env, :migrate]
<Lewix> yolo
<ramfjord> it doesn't run if you redefine migrate
<ramfjord> because you're redefining migrate
danijoo_ has quit [Read error: Connection reset by peer]
mostlybadfly has joined #ruby
larsam has joined #ruby
danijoo has joined #ruby
ddv has joined #ruby
shawnjgoff has joined #ruby
mehlah has quit [Quit: Leaving...]
<frank__> ramfjord, yeah with one task its simple, I just want to avoid wrapping db:migrate, db:migrate:up, db:migrate:down, db:migrate:redo, etc.
yeticry has quit [Ping timeout: 240 seconds]
ghr has joined #ruby
brandonshowers has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
startupality has quit [Quit: startupality]
Alina-malina has quit [Ping timeout: 255 seconds]
thams has joined #ruby
melik has quit [Quit: Computer has gone to sleep.]
yeticry has joined #ruby
melik has joined #ruby
brandonshowers has joined #ruby
oo_ has joined #ruby
zz_karupa is now known as karupa
ghr has quit [Ping timeout: 255 seconds]
mary5030 has joined #ruby
MatthewsFace has joined #ruby
tkuchiki has joined #ruby
Alina-malina has joined #ruby
sunya7a has quit [Ping timeout: 260 seconds]
Rainicorn has quit [Ping timeout: 245 seconds]
oo_ has quit [Remote host closed the connection]
britneywright has joined #ruby
orionstein_away is now known as orionstein
baweaver has joined #ruby
wfw has joined #ruby
arq_ has joined #ruby
melik has quit [Ping timeout: 240 seconds]
wfw has left #ruby [#ruby]
<zenspider> frank__: declaring a new task dependency doesn't overwrite any existing tasks, ever.
<frank__> hm how does a task know which one to use?
<zenspider> a task is just a collection of dependencies to be followed by a collection of procs
startupality has joined #ruby
<zenspider> you're not understanding what rake is. it uses ALL of them
rezzack has quit [Ping timeout: 256 seconds]
CorpusCallosum has quit [Ping timeout: 256 seconds]
deadbolt has left #ruby [#ruby]
MatthewsFace has quit [Client Quit]
mary5030 has quit [Ping timeout: 240 seconds]
danman has joined #ruby
thams has quit [Quit: thams]
Sirupsen has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Sirupsen has joined #ruby
j_mcnally_ has quit [Ping timeout: 260 seconds]
<zenspider> frank__: you have to get down and dirty with rake to actually remove actions
banisterfiend has quit [Quit: Computer has gone to sleep.]
danman has quit [Client Quit]
<zenspider> task :a do ... thing 1 end; task :a do ... thing 2 end; task :a do ... thing 3 end
<zenspider> (whether thing 1-3 are tasks or dependencies) declares 3 things to run for that task
<zenspider> they'll all run, deps first, then bodies
baweaver has quit [Ping timeout: 240 seconds]
blaines has joined #ruby
<frank__> zenspider, I see. So if I declare a hundred tasks w/ the same name in the same namespace rake will run them all?
nanoyak has joined #ruby
mocfive has quit [Remote host closed the connection]
<zenspider> yup
<frank__> because whats happening is that when I define an :environment task I get an ActiveRecord not connected exception. I thought that meant the other environment task that sets it up wasn't running
Sirupsen has quit [Ping timeout: 240 seconds]
mocfive has joined #ruby
awc737 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
proq has joined #ruby
saarinen has quit [Quit: saarinen]
sam113101 is now known as mozzarella
xmad has quit [Ping timeout: 255 seconds]
echooo has joined #ruby
xenomorph is now known as {xenomorph}
seanosaur has quit [Remote host closed the connection]
LadyRainicorn has joined #ruby
codeurge has joined #ruby
Alina-malina has quit [Ping timeout: 272 seconds]
mocfive has quit [Ping timeout: 264 seconds]
Alina-malina has joined #ruby
Aryasam has quit [Ping timeout: 272 seconds]
mocfive has joined #ruby
frank__ has quit [Ping timeout: 255 seconds]
startupality has quit [Quit: startupality]
tobago has quit [Ping timeout: 240 seconds]
oo_ has joined #ruby
nanoyak has quit [Read error: Connection reset by peer]
MatthewsFace has joined #ruby
nanoyak has joined #ruby
Sirupsen has joined #ruby
Akagi201 has joined #ruby
sevenseacat has joined #ruby
LadyRainicorn has quit [Ping timeout: 240 seconds]
nanoyak has quit [Read error: Connection reset by peer]
nanoyak has joined #ruby
jonathanwallace has quit [Quit: ZNC - http://znc.in]
crudson has quit [Ping timeout: 255 seconds]
banjara has quit [Quit: Leaving.]
banjara has joined #ruby
<proq> how does one implement a def foo!(x) method? stackoverflow doesn't seem to know how to change x
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
namxam has joined #ruby
<mozzarella> proq: you need to call methods on it
moritzs has quit [Ping timeout: 260 seconds]
nanoyak has quit [Client Quit]
mattstratton has joined #ruby
<mozzarella> >> def foo!(x); x << 'test'; end; x = 'wut'; foo!(x); x
<Mon_Robot> mozzarella: => "wuttest" (https://eval.in/171532)
lxsameer has quit [Quit: Leaving]
Akagi201 has quit [Ping timeout: 255 seconds]
<mozzarella> see ^, the foo! method modified the external x
<proq> odd, I have a code sample that looks like that from my old ruby days. it doesn't work with numbers though
MatthewsFace has quit [Quit: This computer has gone to sleep]
thams has joined #ruby
<proq> also, how would you clear the string? that sample appends "test" but I'm not sure how to clear it
<proq> >> def foo!(x); x = ''; x << 'test'; end; x = 'wut'; foo!(x); x
<Mon_Robot> proq: => "wut" (https://eval.in/171533)
Hobogrammer has quit [Ping timeout: 264 seconds]
namxam has quit [Ping timeout: 245 seconds]
<mozzarella> the .clear method
jonathanwallace has joined #ruby
<mozzarella> >> 'test'.clear
<Mon_Robot> mozzarella: => "" (https://eval.in/171534)
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
maletor has quit [Quit: Computer has gone to sleep.]
Zenigor has joined #ruby
toastynerd has joined #ruby
nanoyak has joined #ruby
<proq> aha, thank
<proq> thanks
rp__ has quit [Ping timeout: 255 seconds]
beseku has joined #ruby
<Hanmac> proq there is also replace
thams has quit [Quit: thams]
Vivekananda_y510 has quit [Ping timeout: 255 seconds]
absolutezeroff has joined #ruby
britneywright has joined #ruby
thams has joined #ruby
beseku has quit [Ping timeout: 250 seconds]
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
toastynerd has quit [Remote host closed the connection]
Photism has joined #ruby
mattstratton has joined #ruby
jaimef has quit [Excess Flood]
phutchins has joined #ruby
<benlieb> is there a shorter way to write this: additional_attribs = opts[:attribs] ? opts[:attribs] : {}
rebelshrug has joined #ruby
<benlieb> is additional_attribs = opts[:attribs] || {} good practice?
jaimef has joined #ruby
dayepa1 has quit [Quit: dayepa1]
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dayepa1 has joined #ruby
shawnjgoff has quit [Ping timeout: 240 seconds]
IceDragon has quit [Ping timeout: 240 seconds]
larsam has quit [Read error: Connection reset by peer]
ryannielson has joined #ruby
<ryannielson> A few days back I came across a repo on GitHub that contained a .md file with lots of Ruby or Rails resources. It has a lot of stars, so maybe someone here knows what it is?
beauby has joined #ruby
fenicks has quit [Remote host closed the connection]
AlSquire has quit [Quit: This computer has gone to sleep]
justinmcp has quit [Ping timeout: 240 seconds]
<robscormack> rails? :X
<robscormack> haha
<robscormack> not sure, sorry
Hobogrammer has joined #ruby
wjimenez_5271_ has quit [Remote host closed the connection]
wjimenez5271 has joined #ruby
<mozzarella> ryannielson: what kind of resources?
<ryannielson> mozzarella: I actually just found it, https://github.com/Sdogruyol/awesome-ruby
brandonshowers has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
phutchins has quit [Ping timeout: 245 seconds]
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
arya_ has quit [Ping timeout: 264 seconds]
dapz has joined #ruby
mattstratton has joined #ruby
IceDragon has joined #ruby
PanPan has joined #ruby
wjimenez5271 has quit [Ping timeout: 255 seconds]
oo_ has quit [Remote host closed the connection]
robustus has quit [Ping timeout: 250 seconds]
larsam has joined #ruby
ghr has joined #ruby
Zebroid has joined #ruby
djbkd has quit [Remote host closed the connection]
benzrf|offline is now known as benzrf
arya_ has joined #ruby
larsam has quit [Read error: Connection reset by peer]
davedev24_ has quit []
robustus has joined #ruby
ghr has quit [Ping timeout: 255 seconds]
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
benlieb has quit [Quit: benlieb]
s2013 has quit [Ping timeout: 260 seconds]
dapz has joined #ruby
<robscormack> nice catch, ryannielson
<ryannielson> Ya it's pretty nice.
toastynerd has joined #ruby
k0m has joined #ruby
toastynerd has quit [Remote host closed the connection]
k0m has quit [Excess Flood]
dapz has quit [Client Quit]
k0m has joined #ruby
oo_ has joined #ruby
thams has quit [Quit: thams]
mocfive has quit [Ping timeout: 250 seconds]
thams has joined #ruby
BadQuanta has joined #ruby
seanosaur has joined #ruby
seanosaur has quit [Remote host closed the connection]
Zenigor has quit [Remote host closed the connection]
seanosaur has joined #ruby
ryannielson has quit []
mocfive has joined #ruby
dapz has joined #ruby
arya_ has quit [Ping timeout: 240 seconds]
seanosaur has quit [Ping timeout: 240 seconds]
Sigma00 has left #ruby ["Textual IRC Client: http://www.textualapp.com/"]
jamto11 has joined #ruby
baweaver has joined #ruby
k0m has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Pizza has joined #ruby
b00stfr3ak has quit [Ping timeout: 260 seconds]
Pizza has left #ruby [#ruby]
Akagi201 has joined #ruby
wenshan has quit [Read error: Connection reset by peer]
Zebroid has quit [Remote host closed the connection]
Fire-Dragon-DoL has quit [Quit: Leaving.]
rebelshrug has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mocfive has quit [Remote host closed the connection]
mocfive has joined #ruby
Akagi201 has quit [Ping timeout: 240 seconds]
saarinen has joined #ruby
lazarus477 has joined #ruby
nanoyak has quit [Quit: Computer has gone to sleep.]
tokik has joined #ruby
<lazarus477> Question: RubyGems: How can I search for an available package X using the shell command "gem search"? It appears to only work on exsisting/installed packages.
saarinen has quit [Client Quit]
mocfive has quit [Ping timeout: 245 seconds]
nanoyak has joined #ruby
larissa has joined #ruby
jaequery has joined #ruby
CodeLicker has joined #ruby
armyriad has quit [Ping timeout: 255 seconds]
armyriad has joined #ruby
dbasch has joined #ruby
beseku has joined #ruby
seanosaur has joined #ruby
tylersmith has quit [Remote host closed the connection]
banjara has quit [Quit: Leaving.]
wallerdev has quit [Quit: wallerdev]
armyriad has quit [Ping timeout: 250 seconds]
GriffinHeart has joined #ruby
dbasch has quit [Ping timeout: 250 seconds]
beseku has quit [Ping timeout: 240 seconds]
thams has quit [Quit: thams]
fold has quit [Ping timeout: 245 seconds]
northfurr has joined #ruby
elico has quit [Ping timeout: 260 seconds]
locks has joined #ruby
<locks> for anyone still using mustache: http://www.rubyflow.com/items/11334-mustache-0-99-6-released
dvb_ua has quit [Ping timeout: 240 seconds]
bunnicula has joined #ruby
osvimer has joined #ruby
r_rios has joined #ruby
elico has joined #ruby
yetanotherdave has quit [Quit: Lost terminal]
r0ast has joined #ruby
<r0ast> Anyone ever used Wukong? https://github.com/infochimps-labs/wukong
<r0ast> Looks interesting
jrhorn424 is now known as zz_jrhorn424
blackgoat has quit [Quit: reboot]
sunya7a has joined #ruby
Shidash has joined #ruby
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mattstratton has joined #ruby
linojon has joined #ruby
amclain has joined #ruby
Wolland has joined #ruby
bmurt has joined #ruby
Vivekananda_y510 has joined #ruby
ixti has quit [Quit: WeeChat 0.4.3]
wallerdev has joined #ruby
ghr has joined #ruby
locks has left #ruby [#ruby]
lethjakman has joined #ruby
j_mcnally_ has joined #ruby
spyderma_ has quit [Ping timeout: 245 seconds]
seanosaur has quit [Remote host closed the connection]
overmacht has joined #ruby
overmacht has quit [Max SendQ exceeded]
ghr has quit [Ping timeout: 245 seconds]
blaines has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Robbo` has joined #ruby
overmacht has joined #ruby
overmacht has quit [Max SendQ exceeded]
<Robbo`> doing gem install rmagick works, compiles fine
overmacht has joined #ruby
overmacht has quit [Max SendQ exceeded]
<Robbo`> doing bundle install fails with
<Robbo`> *** ERROR: missing required library to compile this module
<Robbo`> *** extconf.rb failed ***
<Robbo`> makes no sense
overmacht has joined #ruby
<sevenseacat> the full error is...?
overmacht has quit [Changing host]
overmacht has joined #ruby
<sevenseacat> !gist it
<helpa> http://gist.github.com - Put your codes online with pretty syntax highlighting and the ability to embed it into other pages.
nanoyak has quit [Quit: Computer has gone to sleep.]
<Robbo`> actually I just realiozed I am a moron
orionstein is now known as orionstein_away
<Robbo`> so thanks :D
<sevenseacat> np :P
hydrozen has quit [Quit: Computer has gone to sleep.]
hydrozen has joined #ruby
hydrozen has quit [Client Quit]
r0ast has quit [Remote host closed the connection]
gr33n7007h has joined #ruby
orionstein_away is now known as orionstein
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Xiti has quit [Ping timeout: 245 seconds]
t_p has joined #ruby
hydrozen has joined #ruby
overmacht has left #ruby [#ruby]
joe_____ has joined #ruby
<joe_____> Why does it keep warning string literal, what does that mean?
Akagi201 has joined #ruby
<j_mcnally> since when does helpa troll #Ruby ?
<sevenseacat> for a while now
<sevenseacat> i try to keep its use to a minimum though
<joe_____> sevenseacat: why does ruby keep telling me string literal?
<joe_____> sevenseacat: what does that mean?
<sevenseacat> joe_____: what?
filipesaraiva has joined #ruby
<sevenseacat> what are you doing?
ebanoid has joined #ruby
<joe_____> sevenseacat: sorry it says warning: string literal in condition
<sevenseacat> !code
<helpa> We cannot help you with your problem if you don't show us your code. Please put it on http://gist.github.com and give us the URL so we can see it.
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
hgl has joined #ruby
<filipesaraiva> Hello, please can anyone help me? I am trying to iterate in a variable from a YAML file but I can not know how to do it. The YAML is in http://paste.kde.org/plhsbth2d and the code to load the YAML is 'proceeding = YAML.load_stream("file")'.
Spami has quit [Quit: This computer has gone to sleep]
sethen has joined #ruby
hectorrr has quit [Read error: Connection timed out]
gbaway has joined #ruby
charliesome has joined #ruby
gbaway has quit [Max SendQ exceeded]
hectorrr has joined #ruby
armyriad has joined #ruby
GriffinHeart has quit [Remote host closed the connection]
<benzrf> >> YAML.load_stream("file")
<Mon_Robot> benzrf: => NameError: uninitialized constant YAML (https://eval.in/171549)
<benzrf> >> require 'yaml'; YAML.load_stream("file")
<Mon_Robot> benzrf: => ["file"] (https://eval.in/171550)
_maes_ has joined #ruby
<benzrf> filipesaraiva: what were you expecting
<joe_____> sevenseacat: http://pastebin.com/5CCDUKT5
<sevenseacat> thats... not quite how conditionals work
<sevenseacat> the if and until will get parsed like (userInput != ("Yes" || "No"))
<sevenseacat> which isnt what you want
<benzrf> joe_____: stop speaking english and translating it word-for-word
<filipesaraiva> thanks benzrf. I would like to iterate in each element from papers variable
<benzrf> and start thinking about the meaning of the code you write
<benzrf> >:[
<filipesaraiva> But I don't know how to access papers variable from proceeding.
<joe_____> benzrf: excuse me,w hat did I do
<benzrf> filipesaraiva: there is no papers in proceeding
<benzrf> filipesaraiva: you parsed "file"
<benzrf> there is nothing called papers in "file"
<joe_____> what the hell are you talking about this is my first time programming
<benzrf> joe_____: i assume you thought in your head "if the user's input isnt yes or no" and then transcribed that to ruby syntax
<filipesaraiva> benzrf, 'file' is the file name of YAML from http://paste.kde.org/plhsbth2d
<benzrf> joe_____: the problem is that ruby syntax doesnt quite mean the same thing as english words
<benzrf> filipesaraiva: what's your code?
<benzrf> joe_____: look carefully at the codeurge
gbaway has joined #ruby
<benzrf> *code
<benzrf> imagine you don't know english
gbaway has quit [Max SendQ exceeded]
<benzrf> how would you parse that statement?
<joe_____> benzrf: what does parse mean
Umang has joined #ruby
<filipesaraiva> benzrf: " I am trying to iterate in a variable from a YAML file but I can not know how to do it. The YAML is in http://paste.kde.org/plhsbth2d and the code to load the YAML is 'proceeding = YAML.load_stream("file")'."
<benzrf> filipesaraiva: ok, so you're parsing the string "file"
<benzrf> there is nothing called papers in that string
<benzrf> joe_____: sorry
<benzrf> joe_____: what i mean is, try looking at that code without reading it as english
<benzrf> pretend it's a mathematical statement or something
<benzrf> what does it mean?
<benzrf> be mechanical
<benzrf> like the ruby interpreter :-)
GriffinHeart has joined #ruby
<filipesaraiva> oh benzrf, please. file is the YAML file content from http://paste.kde.org/plhsbth2d. In my computer file have the content from http://paste.kde.org/plhsbth2d, do you understand?
heftig has quit [Ping timeout: 250 seconds]
<benzrf> filipesaraiva: can i see the actual code then
<filipesaraiva> Putz.
namxam has joined #ruby
<benzrf> filipesaraiva: no need for name calling
<benzrf> joe_____: look at 'userInput != "Yes" || "No"'
<benzrf> joe_____: != and || don't change their meaning by being put next to each other
gbaway has joined #ruby
<benzrf> what is the meaning of !=, and what is the meaning of ||?
gbaway has quit [Max SendQ exceeded]
<joe_____> 1= nt and || is or
<joe_____> !=*
<benzrf> joe_____: ok.
<joe_____> sorry
<benzrf> joe_____: so what does 'userInput != "Yes" || "No"' mean?
<benzrf> don't read it as english
<benzrf> parenthesize it if you need to
<benzrf> evaluate it mathematically, like a computer
<filipesaraiva> I have a file with content is http://paste.kde.org/plhsbth2d/tjlluh/raw. I load this content in an variable. In the content I have a variable named papers (first line). I just want iterate in this variable, but I don't know how access it. The code to load this YAML file is proceeding = YAML.load_stream("file"), where "file" is a file in my computer where the content is http://paste.kde.org/plhsbth2d/tjlluh/raw
gbaway has joined #ruby
gbaway has quit [Max SendQ exceeded]
jaequery has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rimenes has joined #ruby
<benzrf> filipesaraiva: is the code literally `YAML.load_stream("file")'?
<benzrf> like, that's the exact text?
<filipesaraiva> YES
dvb_ua has joined #ruby
<benzrf> ok
bmurt has quit []
<benzrf> so you're parsing the string "file"
<benzrf> the string "file" doesn't contain any data labelled 'papers'
<benzrf> like i said
lethan has quit []
<filipesaraiva> Oh, ok. Thanks, but the code is YAML.load_stream(file).
<filipesaraiva> I am loading the file, it is ok, I can put it in the interpreter.
namxam has quit [Ping timeout: 256 seconds]
thams has joined #ruby
<benzrf> ok
<filipesaraiva> But I don't know how iterate in papers variable from it.
<sevenseacat> lmao
<joe_____> Im confused
<sevenseacat> 'is this the exact code?' 'yes' 'ok heres why it doesnt work' 'ok but thats not what the code is'
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<benzrf> joe_____: depending on order of operations, that could be:
<benzrf> userInput != ("Yes" || "No")
gbaway has joined #ruby
<benzrf> or
<benzrf> (userInput != "Yes") || "No"
gbaway has quit [Max SendQ exceeded]
<sevenseacat> both are wrong
<sevenseacat> well, wrong as in not what he wants
<benzrf> >> "Yes" || "No"
<Mon_Robot> benzrf: => "Yes" (https://eval.in/171567)
djbkd has joined #ruby
<joe_____> so use ()'s?
<sevenseacat> no
britneywright has quit [Quit: Textual IRC Client: www.textualapp.com]
<sevenseacat> get the logic right
<sevenseacat> you want to know if userInput is either yes or no, right?
<joe_____> yes
<sevenseacat> so you need to check if it is yes, or if it is no
<sevenseacat> not if it is (yes or no)
<sevenseacat> because the (yes or no) part will get evaluated first
<joe_____> I get it I think
jaequery has joined #ruby
<joe_____> It's if userInput != "Yes" && "No"?
<sevenseacat> noooooooooo
<robscormack> it's so hard to understand that I want to eat spaghetti
<robscormack> let's see
dapz has joined #ruby
mityaz has quit [Ping timeout: 260 seconds]
hectorrr has quit [Read error: Connection timed out]
mityaz has joined #ruby
iamjarvo has joined #ruby
dapz has quit [Client Quit]
<joe_____> !code
<joe_____> show me some code
beseku has joined #ruby
fgo has joined #ruby
<robscormack> (userInput == "Yes" || userInput == "No") ? "it's a yes or a no, nothing else" : "it's not whatcha want"
braincrash has quit [Quit: bye bye]
dapz has joined #ruby
<robscormack> >> userInput = "Yes" ; (userInput == "Yes" || userInput == "No") ? "it's a yes or a no, nothing else" : "it's not whatcha want"
<Mon_Robot> robscormack: => "it's a yes or a no, nothing else" (https://eval.in/171568)
<robscormack> >> userInput = "nope" ; (userInput == "Yes" || userInput == "No") ? "it's a yes or a no, nothing else" : "it's not whatcha want"
<Mon_Robot> robscormack: => "it's not whatcha want" (https://eval.in/171569)
<robscormack> that?
krz has joined #ruby
Vivekananda_y510 has quit [Ping timeout: 264 seconds]
<benzrf> joe_____: look
<benzrf> userInput != ("Yes" || "No")
<benzrf> joe_____: this means, userInput does not equal the result of "Yes" || "No"
<benzrf> > "Yes" || "No"
<benzrf> >> "Yes" || "No"
<Mon_Robot> benzrf: => "Yes" (https://eval.in/171570)
<benzrf> aka, userInput does not equal Yes
razum2um has joined #ruby
<benzrf> (userInput != "Yes") || "No"
<benzrf> this means, first test "userInput does not equal Yes", then if that's true then true, otherwise "No"
<benzrf> remember, if statements consider "No" to be true
<benzrf> they only judge by if it's nil or false
<benzrf> all strings are true to an if
<joe_____> im reading
beseku has quit [Ping timeout: 240 seconds]
heftig has joined #ruby
benlieb has joined #ruby
<joe_____> little clearer, thanks
braincrash has joined #ruby
<benzrf> np
thams has quit [Quit: thams]
robclancy has joined #ruby
saarinen has joined #ruby
ebanoid has quit [Ping timeout: 240 seconds]
Robbo` has quit [Ping timeout: 264 seconds]
orionstein is now known as orionstein_away
gb_away has joined #ruby
gb_away has quit [Max SendQ exceeded]
orionstein_away is now known as orionstein
gbaway has joined #ruby
gbaway has quit [Max SendQ exceeded]
cocotton has joined #ruby
ebanoid has joined #ruby
gbaway has joined #ruby
gbaway has quit [Max SendQ exceeded]
thams has joined #ruby
arup_r has joined #ruby
joe_____ is now known as madbro
kaspergrubbe has quit [Remote host closed the connection]
sunya7a has quit [Ping timeout: 250 seconds]
cocotton has quit [Remote host closed the connection]
spyderman4g63 has joined #ruby
Lulzon has joined #ruby
<filipesaraiva> Ok, I can access variables using proceeding[0]['papers'][0]
<filipesaraiva> From this I can iterate on proceeding variable.
<filipesaraiva> Thanks.
sepp2k1 has quit [Read error: Connection reset by peer]
ffranz has quit [Quit: Leaving]
Lulzon has quit [K-Lined]
crudson has joined #ruby
ebanoid has quit [Ping timeout: 240 seconds]
saarinen has quit [Quit: saarinen]
MrL0ngbowman has joined #ruby
jelera has joined #ruby
gbaway has joined #ruby
gbaway has quit [Max SendQ exceeded]
ghr has joined #ruby
gbaway has joined #ruby
gbaway has quit [Max SendQ exceeded]
beauby has quit [Ping timeout: 245 seconds]
snath has joined #ruby
ebanoid has joined #ruby
larissa has quit [Quit: Leaving]
little_fu has joined #ruby
inside has joined #ruby
ghr has quit [Ping timeout: 260 seconds]
gbaway has joined #ruby
gbaway has quit [Max SendQ exceeded]
hydrozen has quit [Quit: Textual IRC Client: www.textualapp.com]
troyready has quit [Ping timeout: 255 seconds]
s2013 has joined #ruby
thams has quit [Quit: thams]
rimenes has quit [Quit: Textual IRC Client: www.textualapp.com]
gbaway has joined #ruby
fold has joined #ruby
ebanoid has quit [Ping timeout: 240 seconds]
mr_snowf1ake has quit [Quit: Leaving]
Lewix has quit [Remote host closed the connection]
ebanoid has joined #ruby
sethen has quit [Remote host closed the connection]
filipesaraiva has left #ruby [""Vou por aí a procurar...""]
ARCADIVS has joined #ruby
s2013 has quit [Remote host closed the connection]
milky has joined #ruby
namxam has joined #ruby
ebanoid has quit [Ping timeout: 260 seconds]
arq_ is now known as CorpusCallosum
madbro has quit [Ping timeout: 246 seconds]
lazyguru has joined #ruby
bunnicula has quit []
beef-wellington has quit [Ping timeout: 260 seconds]
ebanoid has joined #ruby
mocfive has joined #ruby
namxam has quit [Ping timeout: 245 seconds]
Sirupsen has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jackjackdrpr has joined #ruby
Sirupsen has joined #ruby
toastynerd has joined #ruby
Kache has quit [Ping timeout: 246 seconds]
nonnatus has joined #ruby
mallu has joined #ruby
arup_r has quit [Quit: Leaving.]
<mallu> hi, I'm studying ruby and I have a doubt. 'Fear is the path to the dark side'.split(' ').each do |a| In this case is 'a' a variable? shouldn't I be able to puts #{a} ?
<sevenseacat> `puts a`, yes
<nonnatus> you mean `puts a`
<sevenseacat> #{} is string interpolation
beseku has joined #ruby
<sevenseacat> so has to be inside a string
<sevenseacat> (double-quoted string)
Skwallinux has joined #ruby
<mallu> ok thanks
s2013 has joined #ruby
njibx has joined #ruby
dbasch has joined #ruby
lw has quit [Quit: s]
beseku has quit [Ping timeout: 260 seconds]
GriffinHeart has quit [Remote host closed the connection]
MatthewsFace has joined #ruby
ebanoid has quit []
Vivekananda_y510 has joined #ruby
TrueJet has joined #ruby
CaptainJet has quit [Ping timeout: 255 seconds]
toastynerd has quit [Remote host closed the connection]
thams has joined #ruby
bridge has quit [Ping timeout: 245 seconds]
orionstein is now known as orionstein_away
nanoyak has joined #ruby
b00stfr3ak has joined #ruby
codeurge has quit [Quit: Sleep.]
jackjackdrpr has quit [Ping timeout: 255 seconds]
wingedsnake has joined #ruby
lethjakman has quit [Ping timeout: 250 seconds]
<wingedsnake> is json a part of stdlib ?
benlieb has quit [Read error: Connection reset by peer]
toastynerd has joined #ruby
tectonic has joined #ruby
phinfonet has quit []
<Hanmac> wingedsnake: check: require "json"; $LOADED_FEATURES.grep(/json.rb/) #=> ["/usr/local/lib/ruby/2.2.0/json.rb"]
ghr has joined #ruby
hgl has quit [Quit: Computer has gone to sleep.]
Vivekananda_y510 has quit [Quit: Leaving]
<wingedsnake> I check the docs and it's a part of stdlib
<wingedsnake> 2.0.0
toretore has quit [Quit: This computer has gone to sleep]
Vivekananda_y510 has joined #ruby
mary5030 has joined #ruby
seanosaur has joined #ruby
codabrink has quit [Ping timeout: 260 seconds]
ghr has quit [Ping timeout: 260 seconds]
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
tylersmith has joined #ruby
Channel6 has quit [Quit: Leaving]
mikepack has joined #ruby
seanosaur has quit [Ping timeout: 272 seconds]
davispuh has quit [Ping timeout: 245 seconds]
spastorino has quit [Quit: Connection closed for inactivity]
dapz has joined #ruby
robscormack has quit [Quit: This computer has gone to sleep]
beneggett has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
heath has left #ruby [#ruby]
heath has joined #ruby
JasmeetQA has joined #ruby
inside has quit [Ping timeout: 240 seconds]
NinoScript has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
Zesty has joined #ruby
t_p has quit [Ping timeout: 245 seconds]
beneggett has joined #ruby
gbaway has quit [Quit: I screamma, you screamma, we all screamma for ice cream!]
heftig has quit [Ping timeout: 255 seconds]
TrueJet has quit []
deavid has quit [Ping timeout: 245 seconds]
r_rios has quit [Ping timeout: 256 seconds]
beneggett has quit [Client Quit]
Sirupsen has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Arkaniad has joined #ruby
arya_ has joined #ruby
baweaver has quit [Ping timeout: 240 seconds]
namxam has joined #ruby
deavid has joined #ruby
mary5030 has quit [Remote host closed the connection]
dbasch has quit [Quit: dbasch]
namxam has quit [Ping timeout: 240 seconds]
DeanH has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
EvanR_ has quit [Read error: Connection reset by peer]
nanoyak has quit [Quit: Computer has gone to sleep.]
heftig has joined #ruby
EvanR_ has joined #ruby
djbkd has quit [Remote host closed the connection]
robscormack has joined #ruby
dawkirst has joined #ruby
thams has quit [Quit: thams]
oo_ has quit [Remote host closed the connection]
bMalum___ has joined #ruby
bMalum__ has quit [Read error: Connection reset by peer]
dbasch has joined #ruby
oo_ has joined #ruby
jack_rabbit has quit [Ping timeout: 250 seconds]
asmodlol has joined #ruby
jack_rabbit has joined #ruby
Zesty has quit [Quit: Linkinus - http://linkinus.com]
beseku has joined #ruby
amclain has quit [Quit: Leaving]
djbkd has joined #ruby
mary5030 has joined #ruby
DeanH has joined #ruby
b00stfr3ak has quit [Ping timeout: 272 seconds]
beseku has quit [Ping timeout: 240 seconds]
JBreit has left #ruby ["Leaving"]
oo_ has quit [Remote host closed the connection]
GriffinHeart has joined #ruby
GriffinHeart has quit [Remote host closed the connection]
GriffinHeart has joined #ruby
Photism has quit [Quit: Leaving]
jmbrown412 has joined #ruby
oo_ has joined #ruby
bMalum___ has quit [Quit: Computer has gone to sleep.]
mary5030 has quit [Remote host closed the connection]
apeiros has quit [Read error: Connection reset by peer]
apeiros_ has joined #ruby
ViperChief has quit [Ping timeout: 255 seconds]
bMalum___ has joined #ruby
nanoyak has joined #ruby
beilabs has joined #ruby
Morkel has joined #ruby
duncannz has joined #ruby
jmbrown412 has quit [Ping timeout: 260 seconds]
justinmcp has joined #ruby
bMalum___ has quit [Ping timeout: 250 seconds]
brandonshowers has joined #ruby
AlexRussia_w has quit [Ping timeout: 240 seconds]
wingedsnake has quit [Quit: This computer has gone to sleep]
mozzarella is now known as sam113101
blackgoat has joined #ruby
DeanH has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
thams has joined #ruby
heftig has quit [Quit: Quitting]
IceDragon has quit [Quit: Space~~~]
whyy has joined #ruby
narcan has joined #ruby
mallu has quit [Ping timeout: 246 seconds]
apeiros_ has quit [Remote host closed the connection]
apeiros has joined #ruby
AlexRussia_w has joined #ruby
mostlybadfly has quit [Quit: Connection closed for inactivity]
nanoyak has quit [Quit: Computer has gone to sleep.]
ghr has joined #ruby
Mooneye has joined #ruby
meinside has joined #ruby
AndChat| has joined #ruby
ryanneufeld has quit [Ping timeout: 272 seconds]
ViperChief has joined #ruby
GriffinHeart has quit [Remote host closed the connection]
lkba has quit [Ping timeout: 250 seconds]
apeiros has quit [Ping timeout: 272 seconds]
AlexRussia_w has quit [Ping timeout: 240 seconds]
ryanneufeld has joined #ruby
oo_ has quit [Remote host closed the connection]
oo_ has joined #ruby
ghr has quit [Ping timeout: 255 seconds]
yfeldblum has quit [Remote host closed the connection]
arup_r has joined #ruby
arya_ has quit [Ping timeout: 240 seconds]
dawkirst has quit [Ping timeout: 260 seconds]
tagrudev has joined #ruby
arup_r_ has joined #ruby
mikepack has quit [Remote host closed the connection]
AlexRussia_w has joined #ruby
djbkd has quit [Remote host closed the connection]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Morkel has quit [Quit: Morkel]
djbkd has joined #ruby
arup_r has quit [Ping timeout: 250 seconds]
dbasch has quit [Read error: Connection reset by peer]
arya_ has joined #ruby
aganov has joined #ruby
Sauvin has joined #ruby
tobago has joined #ruby
AlexRussia_w has quit [Ping timeout: 240 seconds]
proq has quit [Ping timeout: 264 seconds]
duncannz has quit [Remote host closed the connection]
duncannz has joined #ruby
djbkd has quit [Ping timeout: 245 seconds]
thams has quit [Quit: thams]
bMalum_ has joined #ruby
MatthewsFace has quit [Quit: This computer has gone to sleep]
CodeLicker has quit [Ping timeout: 250 seconds]
AlexRussia_w has joined #ruby
mocfive has quit [Remote host closed the connection]
mocfive has joined #ruby
roolo has joined #ruby
jaequery has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
GriffinHeart has joined #ruby
mocfive has quit [Ping timeout: 240 seconds]
jamto11 has quit [Remote host closed the connection]
x1337807x has joined #ruby
arya_ has quit [Ping timeout: 255 seconds]
St_Marx has quit [Ping timeout: 264 seconds]
hamakn has joined #ruby
jamto11 has joined #ruby
jamto11 has quit [Remote host closed the connection]
craigbowen3 has joined #ruby
jdj_dk has joined #ruby
JoshGlzBrk has joined #ruby
ndrei has quit [Ping timeout: 245 seconds]
njibx has quit [Ping timeout: 240 seconds]
Ilyas has joined #ruby
ndrei has joined #ruby
apeiros has joined #ruby
absolutezeroff has quit [Ping timeout: 256 seconds]
proq has joined #ruby
beseku has joined #ruby
melik has joined #ruby
jdj_dk has quit [Remote host closed the connection]
zkay11 has quit [Remote host closed the connection]
proq has quit [Ping timeout: 272 seconds]
asmodlol has quit [Quit: Leaving]
mfcovington has joined #ruby
beseku has quit [Ping timeout: 250 seconds]
charliesome has quit [Ping timeout: 256 seconds]
charliesome_ has joined #ruby
lw has joined #ruby
n_blownapart has joined #ruby
bMalum___ has joined #ruby
mattmcclure has quit [Quit: Connection closed for inactivity]
benzrf is now known as benzrf|offline
bal has joined #ruby
dvb_ua has quit [Ping timeout: 260 seconds]
lkba has joined #ruby
charliesome_ has quit [Client Quit]
whyy has quit [Remote host closed the connection]
pontiki has quit [Quit: "Poets have been mysteriously silent on the subject of cheese." -- G.K.Chesterson]
AndChat| has quit [Ping timeout: 245 seconds]
yfeldblum has joined #ruby
proq has joined #ruby
n_blownapart has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
tectonic has quit []
sputnik13 has joined #ruby
t_p has joined #ruby
St_Marx has joined #ruby
IteratorP has quit [Remote host closed the connection]
IteratorP has joined #ruby
coderhs has joined #ruby
ndrei has quit [Ping timeout: 256 seconds]
dbasch has joined #ruby
lw has quit [Quit: s]
mary5030 has joined #ruby
fatebeats has joined #ruby
whyy has joined #ruby
thams has joined #ruby
njibx has joined #ruby
proq has quit [Ping timeout: 256 seconds]
mary5030 has quit [Ping timeout: 245 seconds]
ghr has joined #ruby
djbkd has joined #ruby
sarkis has joined #ruby
Lewix has joined #ruby
<sarkis> hey all, i contructed a hash that i'd like to email, trying to figure out the best way to send it through.. i am using the mail gem
mocfive has joined #ruby
<sarkis> i tried body #{PP.pp(hash)}
<sarkis> i get an object though :(
mfcovington has quit [Remote host closed the connection]
<Lewix> yo
<sarkis> like this : #<IO:0x007feb918dab88>
jackneill has joined #ruby
NinoScript has joined #ruby
ghr has quit [Ping timeout: 245 seconds]
MrL0ngbowman has quit [Ping timeout: 240 seconds]
jelera has quit [Ping timeout: 260 seconds]
Avahey_ has quit [Quit: Connection closed for inactivity]
relix has joined #ruby
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
panga has joined #ruby
<existensil> sarkis: I prefer to use JSON for that kind of thing. #{JSON.pretty_generate(hash)}
noop has joined #ruby
<sarkis> isn't there any other way i can generate a nice string from the hash
lmickh has quit [Remote host closed the connection]
panga has left #ruby [#ruby]
dapz has joined #ruby
tylersmith has quit [Remote host closed the connection]
anaeem1_ has joined #ruby
ramfjord has quit [Ping timeout: 256 seconds]
_justin has joined #ruby
_justin has left #ruby [#ruby]
NinoScript_ has joined #ruby
_justin has joined #ruby
IteratorP has quit [Remote host closed the connection]
NinoScript_ has quit [Client Quit]
NinoScript_ has joined #ruby
NinoScript_ has quit [Client Quit]
magic has quit [Quit: WeeChat 1.0-dev]
NinoScript_ has joined #ruby
NinoScript_ has quit [Client Quit]
magic_ has joined #ruby
NinoScript_ has joined #ruby
IteratorP has joined #ruby
<existensil> sarkis: yes, but you'd have to use PP.pp(hash, io), where io is maybe a StringIO instance that you rewind after the pp and then read from to build your mail body.
magic_ is now known as magic
IteratorP has quit [Remote host closed the connection]
fabrice31 has joined #ruby
IteratorP has joined #ruby
awc737 has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Alina-malina has quit [Ping timeout: 260 seconds]
srnty has joined #ruby
olivier_bK has joined #ruby
namxam has joined #ruby
srnty has quit [Ping timeout: 250 seconds]
ndrei has joined #ruby
namxam has quit [Ping timeout: 264 seconds]
Alina-malina has joined #ruby
AskSteve has joined #ruby
_tpavel has joined #ruby
s2013 has quit [Ping timeout: 240 seconds]
dbasch has quit [Quit: dbasch]
awc737 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
IteratorP has quit [Remote host closed the connection]
timonv_ has joined #ruby
roolo has quit [Quit: Leaving...]
ephemerian has joined #ruby
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
beseku has joined #ruby
zoosjuice has joined #ruby
TomyWork has joined #ruby
thams has quit [Quit: thams]
alem0lars has joined #ruby
matrixdevuk has quit [Remote host closed the connection]
kmels has quit [Ping timeout: 240 seconds]
IteratorP has joined #ruby
awc737 has joined #ruby
beseku has quit [Ping timeout: 245 seconds]
evansbee has joined #ruby
evansbee has quit [Client Quit]
narcan has quit [Quit: -[AppDelegate installMalware]: unrecognized selector sent to instance 0x156109c0]
IteratorP has quit [Remote host closed the connection]
jmbrown412 has joined #ruby
anarang has joined #ruby
evansbee has joined #ruby
Shidash has quit [Ping timeout: 264 seconds]
<BackEndCoder> is .htm not cool anymore ?
<sevenseacat> its not necessary anymore
<sevenseacat> the name of the format is HTML
bricker`LA has quit [Ping timeout: 240 seconds]
Ilyas_ has joined #ruby
jmbrown412 has quit [Ping timeout: 264 seconds]
Ilyas has quit [Ping timeout: 240 seconds]
<sarkis> can i not navigate in pry without pry-nav gem?
sputnik13 has joined #ruby
NinoScript_ has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
<sevenseacat> correct.
gr33n7007h has quit [Ping timeout: 256 seconds]
michael_lee has joined #ruby
startupality has joined #ruby
<sarkis> bah
<sarkis> pry-nav it is.. why would i even use pry :P
divhok has joined #ruby
proq has joined #ruby
JoshGlzBrk has quit [Quit: Textual IRC Client: www.textualapp.com]
alem0lars has quit [Quit: Going AFK...]
Mooneye has quit [Quit: Leaving]
Starless has joined #ruby
rdark has joined #ruby
anarang has quit [Quit: Leaving]
ghr has joined #ruby
proq has quit [Ping timeout: 260 seconds]
ramfjord has joined #ruby
Starless has quit [Client Quit]
namxam has joined #ruby
ghr has quit [Ping timeout: 250 seconds]
djbkd has quit [Remote host closed the connection]
melik has quit [Quit: Computer has gone to sleep.]
djbkd has joined #ruby
olivier_bK has quit [Ping timeout: 256 seconds]
melik has joined #ruby
freezey has joined #ruby
IteratorP has joined #ruby
sk87 has joined #ruby
magic has quit [Quit: WeeChat 1.0-dev]
magic_ has joined #ruby
blackmes1 has joined #ruby
linojon has quit [Quit: linojon]
jack_rabbit has quit [Ping timeout: 272 seconds]
magic_ is now known as magic
Duckily has quit [Quit: Duckily]
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
Starless has joined #ruby
djbkd has quit [Ping timeout: 250 seconds]
IteratorP has quit [Remote host closed the connection]
andrewlio has joined #ruby
melik has quit [Ping timeout: 260 seconds]
mercwithamouth has quit [Ping timeout: 250 seconds]
s2013 has joined #ruby
Takle has joined #ruby
radic has quit [Disconnected by services]
hgl has joined #ruby
dangerousdave has joined #ruby
radic_ has joined #ruby
hgl has quit [Client Quit]
startupality has quit [Quit: startupality]
alem0lars has joined #ruby
timonv_ has quit [Remote host closed the connection]
arya_ has joined #ruby
dANOKELOFF has joined #ruby
byteddown has quit [Ping timeout: 240 seconds]
namxam_ has joined #ruby
anarang has joined #ruby
northfurr has quit [Quit: northfurr]
jack_rabbit has joined #ruby
<apeiros> sevenseacat: you know, rails always confuses me… uses .yml, but not .htm, .sas, .ham :)
<sevenseacat> because yml is the official suffix for yaml files, no?
namxam has quit [Ping timeout: 245 seconds]
byteddown has joined #ruby
Alina-malina has quit [Read error: Connection reset by peer]
mocfive has quit [Remote host closed the connection]
lsmola has joined #ruby
mocfive has joined #ruby
Alina-malina has joined #ruby
Joulse has joined #ruby
ghr has joined #ruby
tesuji has joined #ruby
alem0lars has quit [Quit: Going AFK...]
sputnik13 has joined #ruby
sarkis has quit [Ping timeout: 264 seconds]
sputnik13 has quit [Client Quit]
mocfive has quit [Ping timeout: 272 seconds]
s2013 has quit [Remote host closed the connection]
IteratorP has joined #ruby
mikecmpbll has joined #ruby
AlSquire has joined #ruby
<sam113101> Filename extension .yaml, .yml
j_mcnally_ has quit [Ping timeout: 240 seconds]
dANOKELO_ has joined #ruby
freezey has quit [Remote host closed the connection]
<sam113101> I hate it to be honest
arup_r_ has quit [Remote host closed the connection]
IteratorP has quit [Remote host closed the connection]
techsethi has joined #ruby
dANOKELO_ has quit [Remote host closed the connection]
dANOKELO_ has joined #ruby
olivier_bK has joined #ruby
AlexRussia_w has quit [Ping timeout: 264 seconds]
dANOKELOFF has quit [Read error: Connection reset by peer]
_justin has quit [Quit: _justin]
whyy has quit [Ping timeout: 240 seconds]
fatebeats has quit [Read error: Connection reset by peer]
beseku has joined #ruby
fatebeats has joined #ruby
toastynerd has quit [Remote host closed the connection]
memph1s has joined #ruby
<apeiros> sevenseacat: no
rylev has joined #ruby
fooziex has joined #ruby
dooz has joined #ruby
<apeiros> but consistency is just such a radical idea ;-p
beseku has quit [Ping timeout: 255 seconds]
dooz has quit [Client Quit]
fatebeats has quit [Ping timeout: 240 seconds]
jmbrown412 has joined #ruby
s2013 has joined #ruby
<robscormack> it's all about usage. The format is jpeg but we use jpg
flughafen has joined #ruby
fooziex has quit [Ping timeout: 240 seconds]
<flughafen> do people recommend the library net::ssh for ssh? or is there a better library
doev has joined #ruby
<flughafen> i see it's maintenance mode
timonv_ has joined #ruby
<robscormack> if you want sth easier, use rye
<robscormack> but it depends on net-ssh anyway
<flughafen> robscormack: thanks
<robscormack> kein Problem
redlegion has quit [Ping timeout: 240 seconds]
jmbrown412 has quit [Ping timeout: 240 seconds]
<apeiros> robscormack: jpeg can at least claim that it exists since 8.3 filename days
<apeiros> robscormack: that's not true for yaml
techsethi has quit [Ping timeout: 250 seconds]
<apeiros> robscormack: same for things like .txt or .doc. not that it's good, but it's acceptable because it's historically established
<apeiros> but using .yml instead of .yaml is just stupid
wallerdev has quit [Quit: wallerdev]
techsethi has joined #ruby
dazm has joined #ruby
<apeiros> there's no history of it, it's just imitating a technical limitation of 2 decades past
sarkis has joined #ruby
goshdarnyou has quit [Quit: Connection closed for inactivity]
doub has quit [Remote host closed the connection]
doub has joined #ruby
<robscormack> afaik it was bc the technical limitation was present on a lot of computers when yaml appeared (2001)
nobodyzzz has joined #ruby
<robscormack> yeah, it's nonsense but nothing I can't live with
ramfjord has quit [Ping timeout: 250 seconds]
redlegion has joined #ruby
timonv_ has quit [Ping timeout: 240 seconds]
hamakn has quit [Read error: Connection reset by peer]
brandonshowers has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sarkis has quit [Ping timeout: 245 seconds]
proq has joined #ruby
hamakn has joined #ruby
lkba has quit [Ping timeout: 240 seconds]
_gunther has joined #ruby
jack_rabbit has quit [Ping timeout: 255 seconds]
dawkirst has joined #ruby
<robscormack> how's life?
Arkaniad|Laptop has joined #ruby
hamakn_ has joined #ruby
hamakn has quit [Read error: Connection reset by peer]
arup_r has joined #ruby
codabrink has joined #ruby
LadyRainicorn has joined #ruby
awc737 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
brianherman has joined #ruby
proq has quit [Ping timeout: 250 seconds]
Guest12899 has quit [Changing host]
Guest12899 has joined #ruby
Guest12899 is now known as deepy
whyy has joined #ruby
IteratorP has joined #ruby
lsmola has quit [Ping timeout: 245 seconds]
IteratorP has quit [Remote host closed the connection]
lyuzashi has quit [Ping timeout: 272 seconds]
whyy has quit [Read error: Connection reset by peer]
Arkaniad|Laptop has quit [Ping timeout: 250 seconds]
IteratorP has joined #ruby
Wolland has quit [Remote host closed the connection]
whyy has joined #ruby
elaptics`away is now known as elaptics
chth0n has joined #ruby
bpgoldsb has quit [Ping timeout: 272 seconds]
why_away has joined #ruby
sevenseacat has quit [Quit: Leaving.]
diegoviola has quit [Remote host closed the connection]
Hobogrammer has quit [Ping timeout: 255 seconds]
timonv_ has joined #ruby
whyy has quit [Ping timeout: 240 seconds]
bpgoldsb has joined #ruby
Poky has joined #ruby
LadyRainicorn has quit [Read error: Connection reset by peer]
LadyRainicorn has joined #ruby
jack_rabbit has joined #ruby
BadQuanta has quit [Ping timeout: 240 seconds]
LadyRainicorn has quit [Read error: Connection reset by peer]
Rainicorn has joined #ruby
moritzs has joined #ruby
Starless has quit [Quit: Leaving]
crudson has quit [Quit: q term]
jack_rabbit has quit [Ping timeout: 245 seconds]
zoosjuice has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
klaut has joined #ruby
sprihodko has joined #ruby
beseku has joined #ruby
brianherman has quit [Quit: Leaving]
timonv_ has quit [Remote host closed the connection]
moritzs has quit [Ping timeout: 260 seconds]
s2013 has quit [Ping timeout: 250 seconds]
jottr has joined #ruby
proq has joined #ruby
toastynerd has joined #ruby
Rainicorn has quit [Read error: Connection reset by peer]
LadyRainicorn has joined #ruby
_gunther has quit [Quit: WeeChat 0.4.3]
_gunther2 has joined #ruby
_gunther2 has quit [Client Quit]
oo_ has quit [Remote host closed the connection]
proq has quit [Ping timeout: 240 seconds]
oo_ has joined #ruby
LadyRainicorn has quit [Read error: Connection reset by peer]
Rainicorn has joined #ruby
oo_ has quit [Remote host closed the connection]
gaurav_ has joined #ruby
gaurav_ has left #ruby [#ruby]
oo_ has joined #ruby
gauravagarwalr has joined #ruby
toastynerd has quit [Ping timeout: 255 seconds]
eeezkil has joined #ruby
fgo has quit [Remote host closed the connection]
SouL has quit [Ping timeout: 260 seconds]
sarkis has joined #ruby
Bumptiou_ has quit [Remote host closed the connection]
Bumptious has joined #ruby
karupa is now known as zz_karupa
marr has joined #ruby
pandaant_ has joined #ruby
blackmes1 has quit [Quit: WeeChat 0.4.3]
Rainicorn has quit [Read error: Connection reset by peer]
LadyRainicorn has joined #ruby
sarkis has quit [Ping timeout: 255 seconds]
arya_ has quit [Ping timeout: 272 seconds]
tkuchiki_ has joined #ruby
AlexRussia_w has joined #ruby
lanox has joined #ruby
timonv_ has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
tkuchiki has quit [Ping timeout: 255 seconds]
Staal has joined #ruby
dangerousdave has joined #ruby
Pharaoh2 has joined #ruby
toretore has joined #ruby
banisterfiend has joined #ruby
timonv_ has quit [Remote host closed the connection]
timonv_ has joined #ruby
lsmola has joined #ruby
dangerousdave has quit []
LadyRainicorn has quit [Read error: Connection reset by peer]
Rainicorn has joined #ruby
pandaant_ has quit [Ping timeout: 240 seconds]
sarkis has joined #ruby
pandaant_ has joined #ruby
mityaz has quit [Ping timeout: 245 seconds]
mityaz has joined #ruby
Rainicorn has quit [Read error: Connection reset by peer]
LadyRainicorn has joined #ruby
dumdedum has joined #ruby
hamakn_ has quit [Remote host closed the connection]
sarkis has quit [Ping timeout: 245 seconds]
thomasxie has joined #ruby
Takle has quit [Remote host closed the connection]
thomasxie has quit [Read error: Connection reset by peer]
hamakn has joined #ruby
Gooder` has joined #ruby
lanox has quit [Remote host closed the connection]
tokik has quit [Ping timeout: 264 seconds]
LadyRainicorn has quit [Read error: Connection reset by peer]
_justin has joined #ruby
LadyRainicorn has joined #ruby
hamakn has quit [Ping timeout: 256 seconds]
Gooder`` has joined #ruby
Gooder` has quit [Ping timeout: 245 seconds]
IteratorP has quit [Remote host closed the connection]
coderhs has quit [Read error: Connection reset by peer]
coderhs has joined #ruby
sprihodko has quit [Quit: Lingo - http://www.lingoirc.com]
decoponio has joined #ruby
oo_ has quit [Remote host closed the connection]
arup_r has quit [Remote host closed the connection]
Staal has quit [Ping timeout: 245 seconds]
echooo has quit [Ping timeout: 264 seconds]
Atttwww has quit [Ping timeout: 255 seconds]
tvw has joined #ruby
oo_ has joined #ruby
proq has joined #ruby
<j416> if someone has been stupid enough to define #name, how can I get the name of the class I'm currently in?
<j416> self.name fails, obviously
{xenomorph} is now known as xenomorph
oo_ has quit [Remote host closed the connection]
oo_ has joined #ruby
toastynerd has joined #ruby
why_away has quit [Remote host closed the connection]
aganov has quit [Ping timeout: 250 seconds]
<j416> ancestors.first worked, but what if some idiot defines #ancestors .. agh
<j416> oh well. :)
tagrudev has quit [Ping timeout: 245 seconds]
proq has quit [Ping timeout: 240 seconds]
<pandaant_> j416: you could try Module#alias_method.
nonnatus has quit [Ping timeout: 264 seconds]
toastynerd has quit [Ping timeout: 250 seconds]
dapz has quit [Quit: Textual IRC Client: www.textualapp.com]
oo_ has quit [Remote host closed the connection]
coderhs has quit [Ping timeout: 272 seconds]
_justin has quit [Quit: _justin]
dapz has joined #ruby
dapz has quit [Client Quit]
jackneill has quit [Read error: Connection reset by peer]
professor_soap has joined #ruby
whyy has joined #ruby
arup_r has joined #ruby
<apeiros> j416: Module.instance_method(:name).bind(klass).call
<apeiros> same works with ancestors
<apeiros> pandaant_: if somebody redefined them already, then aliasing won't help
ctp has joined #ruby
<j416> apeiros: awesome, thanks!
rylev has quit [Remote host closed the connection]
rylev has joined #ruby
hamakn has joined #ruby
oo_ has joined #ruby
hamakn_ has joined #ruby
hamakn has quit [Read error: Connection reset by peer]
moritzs has joined #ruby
little_fu has quit [Remote host closed the connection]
Lewix has quit [Remote host closed the connection]
tagrudev has joined #ruby
gauravagarwalr has quit [Remote host closed the connection]
rylev has quit [Ping timeout: 255 seconds]
banisterfiend has quit [Quit: Computer has gone to sleep.]
coderhs has joined #ruby
phoo1234567 has joined #ruby
PanPan has quit [Quit: ChatZilla 0.9.90.1 [Firefox 31.0/20140716183446]]
<j416> apeiros: how about self.class.name
Arkaniad has quit [Ping timeout: 245 seconds]
phoo1234567 has quit [Max SendQ exceeded]
phoo1234567 has joined #ruby
<j416> the chance of someone having defined a method called 'class' is very small, but I want to safeguard nonetheless
<j416> hey I don't need to chain it, because class is always that of Object
mostlybadfly has joined #ruby
<j416> hah
<j416> Object.instance_method(:class).bind(self).call.name
<j416> yay
<j416> but I don't know if it's an Object, blergh
claymore has joined #ruby
<j416> I'll just use self.class, if someone redefines that they deserve to get an error
<j416> problem solved
little_fu has joined #ruby
osvimer has quit [Read error: Connection reset by peer]
oo_ has quit [Remote host closed the connection]
osvimer has joined #ruby
oo_ has joined #ruby
phutchins has joined #ruby
fgo has joined #ruby
tkuchiki_ has quit [Read error: Connection reset by peer]
tkuchiki has joined #ruby
aganov has joined #ruby
sarkis has joined #ruby
tkuchiki_ has joined #ruby
timonv_ has quit [Remote host closed the connection]
fgo has quit [Ping timeout: 240 seconds]
gauravagarwalr has joined #ruby
tkuchiki has quit [Ping timeout: 240 seconds]
toastynerd has joined #ruby
sarkis has quit [Ping timeout: 260 seconds]
<apeiros> j416: if name is overridden, it doesn't matter how you call it. it's still the overridden method
<apeiros> j416: unless you borked up your initial question and didn't mean Module#name but YourClass#name, in which case you were messing up as those don't collide
professor_soap has quit []
yfeldblum has quit [Remote host closed the connection]
<apeiros> there's no Object#name method
dangerousdave has joined #ruby
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
bMalum_ has quit [Quit: ChatZilla 0.9.90.1 [Firefox 30.0/20140611060104]]
coderhs has quit [Ping timeout: 264 seconds]
sk87 has joined #ruby
<j416> apeiros: what I meant initially was that someone defined: module Foo; class << self; def name; 'foo'; end; end; end
<j416> apeiros: and I wanted 'Foo'
toastynerd has quit [Ping timeout: 264 seconds]
<j416> but your solution seems to work in this case
<j416> use case is I'm building a logger that will use the name of its class by default as a prefi
<j416> x
_justin has joined #ruby
<j416> apeiros: this is what I ended up with, to get an id of the object, class or module: http://dl.dropbox.com/u/3207594/24h/name.rb
tagrudev has quit [Ping timeout: 245 seconds]
shredding has joined #ruby
dANOKELO_ has quit [Remote host closed the connection]
bMalum___ has quit [Quit: Computer has gone to sleep.]
dANOKELOFF has joined #ruby
bMalum___ has joined #ruby
davedev24_ has joined #ruby
kaspergrubbe has joined #ruby
moritzs has quit [Ping timeout: 240 seconds]
kaspergrubbe_ has joined #ruby
dANOKELOFF has quit [Ping timeout: 245 seconds]
bMalum___ has quit [Ping timeout: 250 seconds]
osvimer has quit [Read error: Connection reset by peer]
little_fu has quit [Remote host closed the connection]
Macaveli has joined #ruby
sevenseacat has joined #ruby
osvimer has joined #ruby
kaspergrubbe has quit [Ping timeout: 260 seconds]
LadyRainicorn has quit [Read error: Connection reset by peer]
LadyRainicorn has joined #ruby
<gauravagarwalr> @j416 just joined in.. what are you exactly trying to achieve?
tkuchiki has joined #ruby
jds has quit [Quit: Connection closed for inactivity]
alem0lars has joined #ruby
mostlybadfly has quit [Ping timeout: 256 seconds]
NinoScript has quit [Ping timeout: 256 seconds]
cbetta has quit [Ping timeout: 256 seconds]
dnyy has quit [Read error: Connection reset by peer]
bedouin has quit [Read error: Connection reset by peer]
<j416> gauravagarwalr: I made a logger and I have a Kernel.log method that returns it; now I want to give the logger the name of the class/module/object that invoked it
spyderman4g63 has quit [Remote host closed the connection]
teejar has quit [Ping timeout: 256 seconds]
mostlybadfly has joined #ruby
cbetta has joined #ruby
matchaw_ has quit [Quit: No Ping reply in 180 seconds.]
dnyy has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
tkuchiki_ has quit [Ping timeout: 256 seconds]
neoice has quit [Ping timeout: 256 seconds]
banisterfiend has joined #ruby
neoice has joined #ruby
t_p has quit [Quit: Computer has gone to sleep.]
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
<j416> gauravagarwalr: problem is, one module defines a class method .name on itself, so I can't rely on 'self.name' being what I want
dangerousdave has joined #ruby
bedouin has joined #ruby
pangean has joined #ruby
MindfulMonk has quit [Ping timeout: 256 seconds]
LordXe-gnu has quit [Ping timeout: 256 seconds]
rblackwe has quit [Ping timeout: 256 seconds]
icedp has quit [Ping timeout: 256 seconds]
<j416> gauravagarwalr: I want to use the original implementation of .name but in the context of the current module/class
matchaw has joined #ruby
<j416> I thought this fixed it but there's still something not right, trying to figure it out
rblackwe has joined #ruby
teejar has joined #ruby
shredding has quit [Ping timeout: 264 seconds]
NinoScript has joined #ruby
MindfulMonk has joined #ruby
icedp has joined #ruby
klaut has quit [Remote host closed the connection]
cn28h has joined #ruby
marr has quit [Ping timeout: 245 seconds]
whyy has quit [Remote host closed the connection]
warti has joined #ruby
pangean has quit []
tagrudev has joined #ruby
proq has joined #ruby
marr has joined #ruby
JasmeetQA has quit [Read error: Connection reset by peer]
fold has quit [Ping timeout: 245 seconds]
coderhs has joined #ruby
LadyRainicorn has quit [Read error: Connection reset by peer]
LadyRainicorn has joined #ruby
heftig-z has joined #ruby
shredding has joined #ruby
Martxel has joined #ruby
tkuchiki_ has joined #ruby
proq has quit [Ping timeout: 250 seconds]
<j416> gauravagarwalr: what part of it?
<j416> gauravagarwalr: sorry, not sure what you are referencing exactly
<heftig-z> how do you register GAsyncReadyCallbacks in ruby-gir-ffi?
gr33n7007h has joined #ruby
<warti> Hi all. I am getting this error on running autotest loading autotest/rspec_rspec2 Autotest style autotest/rspec_rspec2 doesn't seem to exist. Aborting; my autotest version is 4.2.1 and version of rails is 3.2.15 Can ayone please tell me what am I doing wrong?
timfoo has joined #ruby
<warti> I think it's problem with ZenTest but I don't know which version of ZenTest to use
Takle has joined #ruby
timonv_ has joined #ruby
tvw has quit []
gr33n7007h has quit [Client Quit]
doub has quit [Ping timeout: 255 seconds]
tkuchiki has quit [Ping timeout: 240 seconds]
doub has joined #ruby
<apeiros> j416: yes, if he does that, then self.class.name still gives you that redefined method
tkuchiki_ has quit [Ping timeout: 256 seconds]
LadyRainicorn has quit [Read error: Connection reset by peer]
MCDev has quit [Ping timeout: 250 seconds]
LadyRainicorn has joined #ruby
jds has joined #ruby
<jds> Hi
LadyRainicorn has quit [Read error: Connection reset by peer]
<jds> What does ruby use to determine equality on hash keys?
alem0lars has quit [Quit: Going AFK...]
LadyRainicorn has joined #ruby
rylev has joined #ruby
moritzs has joined #ruby
alem0lars has joined #ruby
<apeiros> jds: straight from the docs:
<apeiros> Two objects refer to the same hash key when their hash value is identical and
<apeiros> the two objects are eql? to each other.
<apeiros> "the hash value" -> key.hash
<jds> Hmph. So I've got a hash with a number keys that are identical, both from the hash value and if I compare them via eql?
ndrei has quit [Ping timeout: 245 seconds]
amystephen has quit [Read error: Connection reset by peer]
<jds> which seems pretty broken
amystephe has joined #ruby
<heftig-z> jds: huh?
<apeiros> I don't follow
<jds> Yeah, me neither
<apeiros> you have what?
<heftig-z> what is your issue?
<apeiros> and why is it broken?
Takle has quit [Ping timeout: 240 seconds]
timonv_ has quit [Ping timeout: 250 seconds]
<jds> @details_keys is a hash, where the keys are all hashes themselves.
<apeiros> heftig-z: should tell here too that you moved on ;-p
<jds> Note the latter bunch of keys, which are all identical
mr_rich101 has joined #ruby
<heftig-z> soz; moved my question to #r-l
fold has joined #ruby
<jds> different object_ids, but the hash values are the same, and @details_keys.keys[2].eql?(@details_keys.keys[3]) => true
mr_rich101 has quit [K-Lined]
<apeiros> jds: looks like you mutated your keys
<apeiros> which is something you should never ever do
<jds> Hmm, sounds plausible
<apeiros> freeze your keys and see where it explodes
<jds> thanks, will give it a try
<j416> apeiros: I'm already in the class so I wanted self.name to be 'Foo' even if .name is redefined
<apeiros> jds: self.name != self.class.name
<apeiros> so that approach is pointless
whyy has joined #ruby
<apeiros> self and self.class are different objects, so you're asking for the name of two different objects
<j416> apeiros: I know this
<apeiros> then why did you try it? o0
<j416> apeiros: please forget self.class for a moment
<j416> I didn't
<j416> self.name is all I want
<j416> (self.class.name I am using if I'm an object, and I'll assume that self.class is not redefined)
ldnunes has joined #ruby
<j416> but self.name can be redefined because nuts create methods called 'name'
_justin has quit [Quit: _justin]
<apeiros> Object.instance_method(:class).bind(self).call if you don't want to assume
<apeiros> not just nuts. may have a valid reason.
<heftig-z> apeiros: aren't keys automatically frozen these days?
<apeiros> heftig-z: no
<apeiros> heftig-z: string keys are the only special case (sadly)
<apeiros> those are duplicated and then frozen
<apeiros> everything else, ruby won't hold your hand
<j416> apeiros: sure, reason may exist.
<apeiros> and thanks god it won't just go around and freeze your objects :)
Morkel has joined #ruby
<jds> apeiros: thanks for the help, I think I might finally be on my way to fixing this memory leak. It's only taken me about 40 hours so far...
<heftig-z> I guess if you do that you should only stick them into hashes that are set to compare_by_identity
<heftig-z> (as keys)
<apeiros> heftig-z: or you know what you're doing
xenomorph is now known as {xenomorph}
<apeiros> I rarely ever take the precaution of freezing my keys (and even less deep freezing)
<apeiros> only when those objects are exposed to users of my code
jcromartie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<j416> apeiros: this is what I ended up with now http://dl.dropbox.com/u/3207594/24h/name2.rb
jcromartie has joined #ruby
moritzs has quit [Ping timeout: 250 seconds]
mehlah has joined #ruby
<apeiros> j416: case self; when Module; …when Object; …
<apeiros> empty case should IMO only be used with a large list of when's with all inline then's
<j416> apeiros: indeed, I removed one case that made that form not possible, now it is again
<j416> ty
<apeiros> otherwise, use if/elsif
<j416> good point
warti has quit [Quit: Page closed]
lxsameer has joined #ruby
lxsameer has joined #ruby
fgo has joined #ruby
<j416> apeiros: the else is also useless, is it?
<j416> self can ever be anything other than Object, right?
<apeiros> BasicObject
<j416> ooh
<apeiros> with some code of mine I started using `unreachable`
<apeiros> case … else unreachable; end
sarkis has joined #ruby
sarkis has quit [Changing host]
sarkis has joined #ruby
Umang has quit [Read error: Connection reset by peer]
<j416> to create an error on purpose?
dangerousdave has quit [Read error: Connection reset by peer]
<j416> hm
<j416> ah, properly defined
dangerousdave has joined #ruby
<apeiros> you could also leave it undefined. I prefer to have it defined and thus documented
<j416> yeah
drawingthesun has quit [Ping timeout: 260 seconds]
<j416> I think I'll just say nil here though
<j416> it's not up to the logger to catch this
drawingthesun has joined #ruby
timonv_ has joined #ruby
fgo has quit [Ping timeout: 250 seconds]
<j416> but in practice, unless we've done something very wrong, that else will never be triggered, right
Avahey_ has joined #ruby
<apeiros> up to you of course. IMO that just leads to undetected bugs.
<j416> true
qwyeth has joined #ruby
<apeiros> but I'm not yet consistent in doing it myself. mainly because it has that dependency.
<j416> ah, yes..
toastynerd has joined #ruby
sarkis has quit [Ping timeout: 272 seconds]
MCDev has joined #ruby
Umang has joined #ruby
<j416> but it's a nice name
<j416> I'll use that error class but not the convenience method
<j416> else raise Unreachable, 'self is not an Object'
<j416> and do that
jdj_dk has joined #ruby
MartinCleaver has joined #ruby
sk87 has joined #ruby
toastynerd has quit [Ping timeout: 255 seconds]
Martxel has quit [Quit: Leaving]
_justin has joined #ruby
lsmola has quit [Ping timeout: 245 seconds]
Zackio is now known as CaveJohnson
whyy has quit [Remote host closed the connection]
anaeem1_ has quit [Remote host closed the connection]
timonv_ has quit [Remote host closed the connection]
whyy has joined #ruby
anaeem1_ has joined #ruby
GriffinHeart has quit [Remote host closed the connection]
klaut has joined #ruby
anaeem1 has joined #ruby
anaeem1_ has quit [Read error: Connection reset by peer]
LadyRainicorn has quit [Read error: Connection reset by peer]
Rainicorn has joined #ruby
klaut has quit [Ping timeout: 240 seconds]
spastorino has joined #ruby
GriffinHeart has joined #ruby
Scorchin has joined #ruby
Rainicorn has quit [Ping timeout: 240 seconds]
LadyRainicorn has joined #ruby
pandaant_ has quit [Quit: Lost terminal]
dangerousdave has quit [Read error: Connection reset by peer]
jamto11 has joined #ruby
iamjarvo has joined #ruby
dangerou_ has joined #ruby
jdj_dk has quit [Remote host closed the connection]
<Scorchin> What are the options for creating a class that has default attributes (and a similar constructor) as well as having the requisite marshalling methods in place to allow easy serialization to JSON?
cocotton has joined #ruby
cocotton has quit [Remote host closed the connection]
cocotton has joined #ruby
<Scorchin> I'm looking for something similar to https://github.com/tcrayford/Values but where fields can be made optional
banisterfiend has quit [Quit: Computer has gone to sleep.]
anaeem1 has quit [Remote host closed the connection]
proq has joined #ruby
MCDev has quit [Read error: Connection reset by peer]
rylev has quit [Remote host closed the connection]
MCDev has joined #ruby
banisterfiend has joined #ruby
Sgeo has quit [Read error: Connection reset by peer]
dANOKELOFF has joined #ruby
Sirupsen has joined #ruby
Skwallinux has quit [Quit: ChatZilla 0.9.90.1 [Firefox 30.0/20140605174243]]
proq has quit [Ping timeout: 240 seconds]
rylev has joined #ruby
<elaptics> Scorchin: maybe virtus?
MCDev has quit [Read error: Connection reset by peer]
banisterfiend has quit [Ping timeout: 250 seconds]
<j416> Scorchin: I did something similar before
<j416> Scorchin: here, I adapted it a bit a wrote an example for you, not sure if it's what you're after
<j416> Scorchin: it handles datatypes, but if you don't need that it could be made simpler
<Scorchin> thanks both, I'll take a look
MCDev has joined #ruby
amacou has quit [Remote host closed the connection]
<j416> (see usage example at very bottom)
amacou has joined #ruby
heftig-z has quit [Remote host closed the connection]
Soilent has joined #ruby
jcromartie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
amacou has quit [Read error: No route to host]
amacou has joined #ruby
centrx has joined #ruby
MCDev has quit [Ping timeout: 250 seconds]
toretore has quit [Ping timeout: 264 seconds]
ARCADIVS has quit [Quit: WeeChat 0.4.3]
wolester has joined #ruby
<wolester> Hi all. I am learning ruby and I have written this program, can anyone please show me how can I refactor even this code to less lines? https://gist.github.com/anonymous/25a91290d8c2437572b7
toretore has joined #ruby
<wasamasa> lol, NoSuchStrategyError
LadyRainicorn has quit [Read error: Connection reset by peer]
LadyRainicorn has joined #ruby
<elaptics> wolester: what are player1 and player2? just strings of the letter played?
beseku has quit [Quit: Lingo - http://www.lingoirc.com]
<wolester> elaptics: these are arrays like this RockPaperScissors.winner(['Armando','P'], ['Dave','S'])
<centrx> wolester, If you make 'S', 'R', and 'P' into classes, you can make them comparable
lele has left #ruby ["Leaving"]
<wolester> hmmm
<wolester> I just have to overwrite <=> method now ?
dANOKELOFF has quit [Remote host closed the connection]
<wolester> and return P <=> S?
<wolester> right
<wolester> or B <=> A
<centrx> Then you can replace the whole method with just: [player1.first, player2.first].max
lele has joined #ruby
dANOKELOFF has joined #ruby
<wolester> okay, doing that
<centrx> or just make them 0,1,2
jackneill has joined #ruby
<centrx> except there's a loop I guess that wouldn't work
<centrx> 0 > 2
<centrx> maybe anyway
dANOKELOFF has quit [Remote host closed the connection]
dANOKELOFF has joined #ruby
<wolester> centrx: Thank you, it worked :)
<wolester> let me repaste it
dANOKELOFF has quit [Remote host closed the connection]
dANOKELOFF has joined #ruby
LadyRainicorn has quit [Read error: Connection reset by peer]
dANOKELOFF has quit [Remote host closed the connection]
LadyRainicorn has joined #ruby
dANOKELOFF has joined #ruby
<wolester> hope looks good to you
fgo has joined #ruby
<wolester> I would still need line 15 and 16 I guess?
<wolester> atleast 15th, right?
weeb1e has quit [Ping timeout: 272 seconds]
amacou has quit [Remote host closed the connection]
bmurt has joined #ruby
<wolester> also I need to check if the given values are in "P", "R" or "S" only
<centrx> wolester, Not sure what line 15 is for
Macaveli has quit [Remote host closed the connection]
sarkis has joined #ruby
weeb1e has joined #ruby
timonv_ has joined #ruby
Dr3amc0d3r|away has quit [Ping timeout: 240 seconds]
lxsameer has quit [Ping timeout: 264 seconds]
<wolester> now it looks messy again, centrx https://gist.github.com/anonymous/35e4d386e937a7f0505e :x
fgo has quit [Ping timeout: 250 seconds]
<centrx> What is the point of that if-statement
spyderman4g63 has joined #ruby
spyderman4g63 has quit [Remote host closed the connection]
<wolester> centrx: If either player's strategy is something other than "R", "P" or "S" (case-SENSITIVE), the method should raise a 'RockPaperScissors::NoSuchStrategyError' exception and provide the message: "Strategy must be one of R,P,S"
Macaveli has joined #ruby
<wolester> so it can be only "R", "P" or "S" only
<centrx> wolester, Okay, put that at the beginning of the method then
Macaveli has quit [Client Quit]
rVb_ntrl has joined #ruby
Dr3amc0d3r|away has joined #ruby
<centrx> unless [R,P,S].include?(player1) && [R,P,S].include?(player2) raise error
<wolester> mmmm
fgo has joined #ruby
sarkis has quit [Ping timeout: 250 seconds]
toastynerd has joined #ruby
rylev has quit [Remote host closed the connection]
jcromartie has joined #ruby
jcromartie has quit [Client Quit]
<wolester> centrx: now perfect I think https://gist.github.com/anonymous/e11db530f2d66864b436
DeanH has joined #ruby
klaut has joined #ruby
DeanH has quit [Max SendQ exceeded]
toastynerd has quit [Ping timeout: 272 seconds]
GriffinHeart has quit [Remote host closed the connection]
whyy has quit [Ping timeout: 255 seconds]
Macaveli has joined #ruby
tkuchiki has joined #ruby
timonv_ has quit [Ping timeout: 256 seconds]
tesuji has quit [Ping timeout: 256 seconds]
<Macaveli> Hello!
<Macaveli> screen irssi
hamakn_ has quit [Remote host closed the connection]
rylev has joined #ruby
Macaveli has quit [Client Quit]
Digidog has joined #ruby
NinoScript_ has joined #ruby
seanosaur has joined #ruby
namxam_ has quit [Remote host closed the connection]
britneywright has joined #ruby
tier has joined #ruby
<elaptics> wolester: I had a little play with your code - here's my first quick attempt to clean up the winner method and start to feel a little more object-y https://gist.github.com/andyh/b70654fd64571422a6ba
aganov has quit [Quit: Leaving]
oo_ has quit [Remote host closed the connection]
<wolester> elaptics: trying to understand it :p
oo_ has joined #ruby
<wolester> it's beyond my level I guess
cocotton has quit [Remote host closed the connection]
<elaptics> wolester: which bit/s?
<wolester> elaptics: don't understnd this part nless [player1, player2].map(&:playing).all? {|p| %w(R P S).include?(p)
<wolester> also going to look up fetch method
<elaptics> wolester: that's just making sure both players have played a valid move. It's just checking that the player objects playing method is one of those values
cocotton has joined #ruby
cocotton has quit [Remote host closed the connection]
gattuso has quit [Ping timeout: 260 seconds]
<elaptics> wolester: next thing I'd probably do is move that code into a method with a better name so it's clear what its intent is
cocotton has joined #ruby
<elaptics> just wanted to post the code as-is since my lunchtime is over :)
<wolester> elaptics: but when do we use & before the symbol?
<wolester> also %w
Ilyas_ has quit [Ping timeout: 264 seconds]
<wolester> map(&:playing).all?
<elaptics> wolester: %w is a shortcut method for creating an array of strings
<wolester> boo, that is over my head
<elaptics> wolester: try it in an irb console and you'll see
<wolester> aha
thams has joined #ruby
jcromartie has joined #ruby
<apeiros> wolester: .all?(&:playing)
<apeiros> no need for a temporary array
Sirupsen has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<elaptics> wolester: the &:symbol is another shortcut for converting a symbol to a proc - google it :)
techsethi has quit [Quit: techsethi]
<wolester> elaptics: i know what proc is :)
<elaptics> apeiros: oh yeah, I knew I could clean that up as I was writing it but my brain didn't want to tell me :)
gattuso has joined #ruby
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<apeiros> :foo.to_proc -> proc { |receiver, *args| receiver.__send__(:foo, *args) }
<wolester> but I still really don't understand this part [player1, player2].map(&:playing).all? {|p| %w(R P S).include?(p)}
tvw has joined #ruby
techsethi has joined #ruby
charliesome has joined #ruby
<apeiros> and with the & in `foo(&expression)` you tell ruby to treat `expression` as the block passed to the method foo. if `expression` does not evaluate to a Proc, it'll call to_proc on it (and then convert the Proc to a block)
Macaveli has joined #ruby
<apeiros> "this part" is rather large. what in it do you not understand?
<wolester> just that much now [player1, player2].map(&:playing)
<apeiros> as said: :playing.to_proc -> proc { |receiver, *args| receiver.__send__(:playing, *args) }
<centrx> It's the same as .map { |it| it.playing }
<apeiros> so: `[player1, player2].map(&:playing)` --> `[player1, player2].map { |player| player.playing }`
<apeiros> or to stay closer to the explanation:
djbkd has joined #ruby
{xenomorph} is now known as xenomorph
<wolester> gotcha
<apeiros> so: `[player1, player2].map(&:playing)` --> `[player1, player2].map { |receiver, *args| receiver.send(:playing, *args) }`
<wolester> I am going to save this somewhere for future :D
jdj_dk has joined #ruby
<Hanmac> apeiros: you forgot the **kargs
techsethi has quit [Client Quit]
proq has joined #ruby
obscured has joined #ruby
<apeiros> Hanmac: no
<apeiros> in the opposite. if you do that, you change the method signature.
seanosaur has left #ruby [#ruby]
deric_skibotn has quit [Ping timeout: 260 seconds]
bayed has joined #ruby
<wolester> I need to understand ostruct to know what playing is doing there?
djbkd has quit [Ping timeout: 260 seconds]
fifthofwry has joined #ruby
proq has quit [Ping timeout: 264 seconds]
<apeiros> it returns the value assigned to `playing`. if player is an openstruct
<apeiros> >> require 'ostruct'; player = OpenStruct.new; player.playing = 'X'; player.playing
<Mon_Robot> apeiros: => "X" (https://eval.in/171717)
oo_ has quit [Remote host closed the connection]
<wasamasa> hmm, what would be the oneliner to make ruby serve files via http server?
oo_ has joined #ruby
<wasamasa> I'm looking for the equivalent of `python3 -m http.server`
jdj_dk has quit [Remote host closed the connection]
tagrudev has quit [Remote host closed the connection]
Channel6 has joined #ruby
Ankhers has joined #ruby
<apeiros> wasamasa: https://gist.github.com/apeiros/d40d3bd3a6888b12f21d is what I used in the past
<apeiros> no guarantees that it is still working :)
ndrei has joined #ruby
northfurr has joined #ruby
banisterfiend has joined #ruby
<wasamasa> it's not an oneliner?
<wasamasa> :<
amacou has joined #ruby
LadyRainicorn has quit [Ping timeout: 240 seconds]
coderhs has quit [Ping timeout: 272 seconds]
<apeiros> make a gem
<apeiros> and I'm not aware of a oneliner
<wasamasa> well no, it's just an useful thing to know
LadyRainicorn has joined #ruby
<apeiros> you might check webricks docs
meinside has quit [Quit: Connection closed for inactivity]
<apeiros> might well be that there's a oneliner version around
siwica has joined #ruby
<centrx> The one-liner is install a web framework gem
philcrissman has joined #ruby
<siwica> can I split a module into multiple files?
<centrx> siwica, Yes
thams has quit [Quit: thams]
<centrx> siwica, When you specify module X in the second file, it opens up the X module if it already exists
<siwica> centrx: ok, cool. Thank you!
<apeiros> siwica: style guide is to have one file per module/class
<apeiros> mapping paths properly to classnames. e.g. FooBar::Baz --> foo_bar/baz.rb
<centrx> siwica, Better way to split your module up is to split it into multiple modules, not multiple files
<centrx> *or classes
Zenigor has joined #ruby
<siwica> apeiros: I am going to have a module that consists of multiple classes of which a number are Exception classes
<centrx> ok yeah that makes sense
<siwica> So style guideline would be to put each seperate class into a separate file and to think about splitting the module?
<LadyRainicorn> One line webserver in bash: httpd
<centrx> siwica, They are in the same module in the hierarchy, but they are actually in their own classes/modules underneath it
<centrx> siwica, Putting small limited classes like exceptions in the same file is okay I think
LadyRainicorn has quit [Read error: Connection reset by peer]
<siwica> centrx: ok, I see
LadyRainicorn has joined #ruby
<siwica> centrx: Is there a commonly accepted resource for ruby style guidelines?
<apeiros> siwica: yes. I do usually keep exception classes in the file of the containing modules
<apeiros> siwica: as they're normally 1-10 lines for me
codeurge has joined #ruby
lsmola has joined #ruby
Zenigor has quit [Ping timeout: 250 seconds]
philcrissman has quit [Remote host closed the connection]
kyb3r_ has quit [Read error: Connection reset by peer]
philcrissman has joined #ruby
<seph429> ls -alh
<seph429> oops
_maes_ has quit [Read error: Connection reset by peer]
rdark has quit [Ping timeout: 245 seconds]
Sirupsen has joined #ruby
mikecmpbll has quit [Ping timeout: 240 seconds]
sarkis has joined #ruby
rdark has joined #ruby
oo_ has quit [Remote host closed the connection]
lkba has joined #ruby
gauravag_ has joined #ruby
TomyWork has quit [Ping timeout: 250 seconds]
lanox has joined #ruby
arup_r has quit []
michael_lee has quit [Remote host closed the connection]
mikecmpbll has joined #ruby
<wolester> apeiros: may I pm you?
iamjarvo has joined #ruby
iamjarvo has quit [Max SendQ exceeded]
beef-wellington has joined #ruby
iamjarvo has joined #ruby
sarkis has quit [Ping timeout: 240 seconds]
<apeiros> wolester: sure. but if it's about code, ask in the channel please
toastynerd has joined #ruby
lanox has quit [Remote host closed the connection]
rylev has quit [Remote host closed the connection]
LadyRainicorn has quit [Read error: Connection reset by peer]
Rainicorn has joined #ruby
<wolester> does this code I have written makes any sense to you guys? https://gist.github.com/anonymous/be9ebffe1f350f375066
freerobby has joined #ruby
<wolester> I don't know why two attr_reader(s) are given
mikesplain has joined #ruby
mikesplain has quit [Max SendQ exceeded]
<wolester> when I to make attr_name+"_history" method using metaprogramming
<wolester> and return the history that doesn't contain the element just set before with attr_accessor
mikesplain has joined #ruby
<centrx> Dpm
failshell has joined #ruby
<centrx> Don't the attr_reader's have to be in the class eval as well
linojon has joined #ruby
<centrx> Also I would use define_method, not class_eval for the method
coderhs has joined #ruby
<centrx> And use a @class_instance_variable, not some apparently local variable "array"
<wolester> centrx: no the code was given as that is
Ilyas has joined #ruby
toastynerd has quit [Ping timeout: 272 seconds]
sailias has joined #ruby
machete has quit [Ping timeout: 245 seconds]
Zenigor has joined #ruby
<wolester> centrx: yeah, if I use the class_instance_variable how do I do that :s
<wolester> I read the specification for about 3 times but didn't get it
dumdedum has quit [Quit: foo]
ixti has joined #ruby
machete has joined #ruby
<centrx> Mainly it acts like a class variable
ixti has quit [Client Quit]
failshell has quit [Client Quit]
ixti has joined #ruby
beilabs has quit [Ping timeout: 264 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Macaveli has quit [Quit: Textual IRC Client: www.textualapp.com]
Channel6 has quit [Quit: Leaving]
cocotton has quit [Remote host closed the connection]
jmbrown412 has joined #ruby
Guest52913 has joined #ruby
Zenigor has quit [Read error: Connection reset by peer]
jmbrown412 has quit [Read error: Connection reset by peer]
jmbrown4_ has joined #ruby
<Guest52913> hi all
Guest52913 has left #ruby [#ruby]
ziyadb has joined #ruby
Zenigor has joined #ruby
mgberlin has joined #ruby
ALVAN has joined #ruby
coderhs has quit [Ping timeout: 256 seconds]
failshell has joined #ruby
JohnFord has joined #ruby
<ALVAN> hi all .. i ahve a foodcritic vilation error "Consider extracting long ruby_block to library" does anyone knows what it means ?
jmbrown4_ has quit [Remote host closed the connection]
JohnFord has quit [Read error: Connection reset by peer]
alekst has joined #ruby
philcrissman has quit [Remote host closed the connection]
DivineEntity has joined #ruby
eka has joined #ruby
<centrx> ALVAN, You probably have a really long block that could be shortened in various ways
banisterfiend has quit [Quit: Computer has gone to sleep.]
CodeLicker has joined #ruby
tier has quit [Remote host closed the connection]
coderhs has joined #ruby
<gauravagarwalr> ALVAN: Its just like it says.. there seems to be some code within an each/map/reduce or any other variant of it, which according to Foodcritic is very long..
beef-wellington has quit [Ping timeout: 260 seconds]
<gauravagarwalr> likely there are about 20+ lines!
andrewlio has quit [Remote host closed the connection]
hamakn has joined #ruby
timonv_ has joined #ruby
matrixdevuk has joined #ruby
_justin has quit [Quit: _justin]
tier has joined #ruby
beilabs has joined #ruby
<ALVAN> gauravagarwalr: ok thanks . .. i read about it buit dont know how to break it into libraries
<wolester> centrx: it has got no voice :p
geoffw8_ has joined #ruby
<centrx> ?
<matrixdevuk> Hola
hamakn has quit [Ping timeout: 255 seconds]
<matrixdevuk> How's it going?
<wolester> centrx: pm
<centrx> I saw links to Youtube video and tuned out
Rainicorn has quit [Read error: Connection reset by peer]
<gauravagarwalr> ALVAN: you can break it into method calls.. refactor the code to where it belongs.. move it inside other Class(es) or perhaps methods in the current class itself..
northfurr has quit [Quit: northfurr]
LadyRainicorn has joined #ruby
<wolester> centrx: yeah, there is no voice to understand what they are doing :(
beef-wellington has joined #ruby
tylersmith has joined #ruby
proq has joined #ruby
Avahey_ has quit [Quit: Connection closed for inactivity]
MartynKeigher has joined #ruby
charliesome has joined #ruby
graft has quit [Ping timeout: 240 seconds]
<MartynKeigher> hey all. i'm having issues with passing SQL variables (MySQL) in a ruby job file. - anyone have experience with this?
graft has joined #ruby
graft has joined #ruby
graft has quit [Changing host]
hectorrr has joined #ruby
<Karunamon> So here's a random question, not about solving a problem for a change: MatchData quacks like an array but lacks a .each method. Why is that?
<Karunamon> You can call to_a on it and get the same effect, I just wonder if there is a reason for that decision
momomomomo has joined #ruby
<centrx> Having a #to_a method does not mean it quacks like an array
DaniG2k has joined #ruby
<Karunamon> I mean you can do to_a if you really want to iterate through matches
jmbrown412 has joined #ruby
<centrx> Yes, I usually use #captures
Photism has joined #ruby
<centrx> Karunamon, You could add a method to Object so that any object with a #to_a method will also respond to #each
<Karunamon> I know, I know, there are multiple ways around it, this was more just a "Huh, interesting, wonder why" type question :)
<centrx> Karunamon, What would be the reason for using #each on what #to_a returns?
<centrx> I would have use for it with #captures
cocotton has joined #ruby
cocotton has quit [Remote host closed the connection]
<MartynKeigher> Can someone please shed some light onto WHY this is pulling the variable through to the SQL query? http://pastebin.com/3TyRUwsc Thanks.
<centrx> But that would be confusing if #each does not get the same results as #to_a
proq has quit [Ping timeout: 260 seconds]
<MartynKeigher> correction: Whay this is NOT puling the variable through! http://pastebin.com/3TyRUwsc
cocotton has joined #ruby
mary5030 has joined #ruby
_tpavel has quit [Quit: Leaving]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sambao21 has joined #ruby
momomomomo has quit [Client Quit]
<centrx> MartynKeigher, What happens if you try a more minimal case: sql = ("#{client[:id]}")
saarinen has joined #ruby
Gooder`` has quit [Ping timeout: 240 seconds]
mary5030 has quit [Remote host closed the connection]
<centrx> MartynKeigher, I don't see how it would not be interpolated. It must be something else. Why do you say it is not interpolating?
<MartynKeigher> let me try that.. one sec
mary5030 has joined #ruby
Lewix has joined #ruby
charliesome has joined #ruby
jdj_dk has joined #ruby
jshultz has joined #ruby
yfeldblum has joined #ruby
Digidog has quit [Quit: leaving]
<MartynKeigher> same.. no result.
hamakn has joined #ruby
<centrx> "no result", what does that mean?
<centrx> Just because a query returns no results does not mean the variable interpolation is failing
siwica has quit [Read error: Connection reset by peer]
<MartynKeigher> ah.. sorry. im trying to show the output on a dashboard!
duggiefresh has joined #ruby
<MartynKeigher> http://i.imgur.com/IluHRKo.jpg < im expecting a count in this column as a result of my rb job
bricker`LA has joined #ruby
rylev_ has joined #ruby
rylev_ has quit [Remote host closed the connection]
rylev_ has joined #ruby
Zebroid has joined #ruby
<centrx> MartynKeigher, Sure, but how have you determined why that count is not appearing?
hsps_ has joined #ruby
apeiros has quit [Remote host closed the connection]
yfeldblum has quit [Ping timeout: 256 seconds]
coderhs has quit [Read error: Connection reset by peer]
apeiros has joined #ruby
<centrx> MartynKeigher, e.g. this send_event thing looks pretty wacky. That's much more likely to be where the problem resides than "double-quoted string failing to interpolate variable!!!"
noop has quit [Ping timeout: 240 seconds]
namxam has joined #ruby
dangerou_ has quit [Read error: Connection reset by peer]
dangerousdave has joined #ruby
endash has joined #ruby
Zebroid has quit [Ping timeout: 260 seconds]
nowthatsamatt has joined #ruby
arup_r has joined #ruby
apeiros has quit [Ping timeout: 250 seconds]
ffranz has joined #ruby
kevind has joined #ruby
jcromartie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
absolutezeroff has joined #ruby
Martxel has joined #ruby
acrussell has joined #ruby
BBBThunda has quit [Remote host closed the connection]
arya_ has joined #ruby
rippa has joined #ruby
jdj_dk has quit [Remote host closed the connection]
beef-wellington has quit [Ping timeout: 250 seconds]
W0rmDr1nk has quit [Remote host closed the connection]
reisl has joined #ruby
IceDragon has joined #ruby
goshdarnyou has joined #ruby
osvimer has quit [Remote host closed the connection]
jdj_dk has joined #ruby
joast has quit [Quit: Leaving.]
awc737 has joined #ruby
GriffinHeart has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
namxam has quit [Remote host closed the connection]
<MartynKeigher> im actually using another file that does pass the variables through.. and the send event is send_event(server[:name], result: result)
jdj_dk has quit [Remote host closed the connection]
sarkis has joined #ruby
joast has joined #ruby
mgberlin has quit [Remote host closed the connection]
reisl is now known as larissa
treehug88 has joined #ruby
jobewan has joined #ruby
GriffinHeart has quit [Ping timeout: 255 seconds]
sigurding has joined #ruby
centrx has quit [Quit: Mead error: Connection reset by beer]
krz has quit [Quit: WeeChat 0.4.3]
lxsameer has joined #ruby
sarkis has quit [Ping timeout: 255 seconds]
cocotton has quit [Remote host closed the connection]
mercwithamouth has joined #ruby
sigurding has quit [Client Quit]
cocotton has joined #ruby
cocotton has quit [Remote host closed the connection]
jdj_dk has joined #ruby
charliesome has joined #ruby
momomomomo has joined #ruby
cocotton has joined #ruby
shawnjgoff has joined #ruby
wolester has quit [Quit: Page closed]
Pharaoh2 has quit [Remote host closed the connection]
lw has joined #ruby
bal has quit [Quit: bal]
endash has quit [Quit: endash]
<crazed> interesting.. faraday is stripping some important data from my query string
<crazed> basically i have multiple &target=one&target=two
<crazed> and it just keeps the last one
zz_jrhorn424 is now known as jrhorn424
snath has quit [Ping timeout: 240 seconds]
<sevenseacat> thats how its supposed to work
RandyT has quit [Quit: ZNC - http://znc.in]
Platini has joined #ruby
Wolland has joined #ruby
apeiros has joined #ruby
<crazed> heh except when the url you're calling supports multiple
<crazed> going from ruby -> python app for example
<crazed> less strict about that stuff
<sevenseacat> fairly sure the behaviour of HTTP is undefined when you do that
<sevenseacat> if you want an array of values, use array notation
<crazed> i'd believe it
SilkFox_ has quit [Ping timeout: 245 seconds]
<crazed> just need to hack around to make ruby not strip query parameters
amargherio has joined #ruby
jcromartie has joined #ruby
RandyT has joined #ruby
nateberkopec has joined #ruby
jaimef has quit [Excess Flood]
MCDev has joined #ruby
mocfive has joined #ruby
Morkel_ has joined #ruby
Morkel has quit [Ping timeout: 250 seconds]
Morkel_ is now known as Morkel
jtPretzel80 has joined #ruby
saarinen has quit [Quit: saarinen]
Photism has quit [Quit: Leaving]
jdj_dk has quit [Remote host closed the connection]
jaimef has joined #ruby
s2013 has joined #ruby
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jaequery has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
dangerousdave has joined #ruby
fifthofwry_ has joined #ruby
alekst has quit [Quit: Computer has gone to sleep.]
jlovick has joined #ruby
ascarter has joined #ruby
fifthofwry has quit [Ping timeout: 264 seconds]
beef-wellington has joined #ruby
Lewix has quit [Remote host closed the connection]
lxsameer has quit [Ping timeout: 260 seconds]
saarinen has joined #ruby
shredding has quit [Quit: shredding]
snath has joined #ruby
beef-wellington has quit [Ping timeout: 256 seconds]
xaxisx has joined #ruby
Bira_ has joined #ruby
awc737 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Tricon has joined #ruby
a46 has joined #ruby
<a46> how do I get the obj.methods list that doesn't include all the inherited ones?
BeanDip_ has joined #ruby
shredding has joined #ruby
Pharaoh2 has joined #ruby
BeanDip has quit [Ping timeout: 240 seconds]
terrellt has joined #ruby
proq has joined #ruby
moted has joined #ruby
fgo has quit [Read error: No route to host]
<a46> what's a more useful version of obj.methods?
fgo has joined #ruby
startupality has joined #ruby
fabrice31 has quit [Remote host closed the connection]
s2013 has quit [Ping timeout: 250 seconds]
benzrf|offline is now known as benzrf
yfeldblum has joined #ruby
fabrice31 has joined #ruby
<benzrf> a46: obj.methods(false)
<gregf_> well += is overloaded
<gregf_> sorry wrong chat :/
namxam has joined #ruby
<a46> that gives me an empty list
benzrf is now known as benzrf|offline
descala has quit [Read error: Connection reset by peer]
saarinen has quit [Quit: saarinen]
proq has quit [Ping timeout: 260 seconds]
lmickh has joined #ruby
yfeldblum has quit [Ping timeout: 255 seconds]
fabrice31 has quit [Ping timeout: 250 seconds]
descala has joined #ruby
jaequery has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
absolutezeroff has quit [Remote host closed the connection]
moted_ has joined #ruby
moted has quit [Quit: moted]
divhok has quit [Remote host closed the connection]
Bumptious has quit [Read error: Connection reset by peer]
mikecmpbll has quit [Quit: i've nodded off.]
Zebroid has joined #ruby
Bumptious has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
centrx has joined #ruby
BadQuanta has joined #ruby
moted_ has quit [Client Quit]
moted has joined #ruby
sambao21 has joined #ruby
fgo has quit [Read error: Connection reset by peer]
fgo has joined #ruby
xaxisx has quit [Quit: xaxisx]
sevenseacat has quit [Remote host closed the connection]
proq has joined #ruby
enebo has joined #ruby
Atrumx has joined #ruby
xaxisx has joined #ruby
renderful has joined #ruby
s2013 has joined #ruby
Zebroid has quit [Ping timeout: 250 seconds]
anikras has joined #ruby
ki0 has joined #ruby
mikecmpbll has joined #ruby
kmels has joined #ruby
tier has quit [Remote host closed the connection]
amacou has quit [Remote host closed the connection]
mordof_work has joined #ruby
amacou has joined #ruby
<mordof_work> Is there a channel to ask questions for Prawn? or should I just ask it here?
tier has joined #ruby
anikras has quit [Quit: Leaving]
cantonic has joined #ruby
moted has quit []
thams has joined #ruby
shredding has quit [Quit: shredding]
moted has joined #ruby
dangerou_ has joined #ruby
MatthewsFace has joined #ruby
asmodlol has joined #ruby
<apeiros> a46: obj.methods - <methods you don't want>
<apeiros> e.g. obj.methods - Object.instance_methods
dbasch has joined #ruby
carraroj has joined #ruby
awc737 has joined #ruby
amacou has quit [Ping timeout: 256 seconds]
dangero__ has joined #ruby
spider-mario has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
fabrice31 has joined #ruby
sarkis has joined #ruby
dangerou_ has quit [Ping timeout: 250 seconds]
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
relix has joined #ruby
cocotton has quit [Remote host closed the connection]
AlSquire has quit [Quit: This computer has gone to sleep]
MatthewsFace has quit [Quit: This computer has gone to sleep]
obscured has quit [Quit: leaving]
nonnatus has joined #ruby
cocotton has joined #ruby
cocotton has quit [Remote host closed the connection]
moted has quit []
cocotton has joined #ruby
moted has joined #ruby
mattstratton has joined #ruby
doev has quit [Quit: Verlassend]
britneywright has joined #ruby
sarkis has quit [Ping timeout: 245 seconds]
tylersmith has quit [Remote host closed the connection]
toastynerd has joined #ruby
baroquebobcat has joined #ruby
xaxisx has quit [Quit: xaxisx]
cocotton has quit [Remote host closed the connection]
dangero__ has quit [Read error: Connection reset by peer]
beneggett has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dangerousdave has joined #ruby
xaxisx has joined #ruby
Pharaoh2 has quit [Remote host closed the connection]
thams has quit [Quit: thams]
enebo has quit [Quit: enebo]
<a46> I guess it's because my obj is a class not an instance
olivier_bK has quit [Ping timeout: 272 seconds]
toastynerd has quit [Ping timeout: 250 seconds]
<mordof_work> Currently working with prawn - I'm trying to make a table that has all columns align: center, but then every other row a colspan: (full width), align: left cell.. i can't seem to find how to do this though
beneggett has quit [Client Quit]
xaxisx has quit [Client Quit]
SCHAAP137 has joined #ruby
<shevy> sounds like an advanced question mordof
<mordof_work> shevy: hey :)
xaxisx has joined #ruby
<mordof_work> bah.. lunch meeting. afk
baroquebobcat has quit [Quit: baroquebobcat]
toastynerd has joined #ruby
Joulse has quit [Quit: Joulse]
beef-wellington has joined #ruby
Soilent__ has joined #ruby
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Lewix has joined #ruby
charliesome has joined #ruby
beilabs has quit [Ping timeout: 255 seconds]
Soilent has quit [Ping timeout: 250 seconds]
timonv_ has quit [Remote host closed the connection]
jds has quit [Quit: Connection closed for inactivity]
mikecmpbll has quit [Quit: i've nodded off.]
__julien has joined #ruby
CaptainJet has joined #ruby
sarkis has joined #ruby
<__julien> hello , is there a correct syntax to do : hash["#{variable}"]
MatthewsFace has joined #ruby
<terrellt> __julien: hash[variable]
fifthofwry_ has quit [Ping timeout: 256 seconds]
Tricon has quit [Quit: Leaving...]
<terrellt> Assuming hash is a variable that's a hash..
<terrellt> And variable is a variable that's a string.
<terrellt> Or symbol
<terrellt> Or key.
DaniG2k has quit [Quit: leaving]
<seph429> what if its a taco
dANOKELOFF has quit []
jmbrown412 has quit [Remote host closed the connection]
anarang has quit [Quit: Leaving]
jmbrown412 has joined #ruby
jottr has quit [Ping timeout: 240 seconds]
dbasch has quit [Quit: dbasch]
<shevy> taco works as well
<shevy> a hash is very flexible
<shevy> as long as the taco is an object
<__julien> in fact it's a chef node attribute that is a hash
<seph429> taco.eat
<seph429> its not an object anymore :)
bricker`work has joined #ruby
jtz has quit [Ping timeout: 240 seconds]
<banister> __julien i hate chef more than i hate hell and all montagues
m-r-r has joined #ruby
<seph429> chef is pretty annoying
<m-r-r> Hello
wallerdev has joined #ruby
baroquebobcat has joined #ruby
<m-r-r> What does 'binding' means in Ruby ?
dbasch has joined #ruby
dbasch has quit [Client Quit]
jmbrown412 has quit [Ping timeout: 250 seconds]
Vivekananda_y510 has quit [Read error: Connection reset by peer]
oso|away is now known as oso96_2000
mikecmpbll has joined #ruby
Vivekananda_y510 has joined #ruby
chamblin has joined #ruby
<terrellt> m-r-r: Doing a triple back flip
yfeldblum has joined #ruby
maletor has joined #ruby
beilabs has joined #ruby
renderfu_ has joined #ruby
<banister> m-r-r hardcore stuff
j_mcnally_ has joined #ruby
ki0 has quit [Remote host closed the connection]
<banister> m-r-r it's a snapshot of a stack frame
ki0 has joined #ruby
jaequery has joined #ruby
yfeldblum has quit [Ping timeout: 255 seconds]
<m-r-r> Ok, thanks :-)
beef-wellington has quit [Ping timeout: 255 seconds]
renderful has quit [Ping timeout: 250 seconds]
geggam has joined #ruby
<m-r-r> Now i understand why i type 'binding.pry' to start pry, and why some ERB-related code use 'Kernel#binding' ...
jottr has joined #ruby
Martxel has quit [Read error: Connection reset by peer]
ki0 has quit [Ping timeout: 240 seconds]
klaut has quit [Remote host closed the connection]
shevy has quit [Ping timeout: 240 seconds]
cocotton has joined #ruby
Atrumx has quit [Quit: exit]
jamto11 has quit [Remote host closed the connection]
jtz has joined #ruby
cocotton has quit [Read error: Connection reset by peer]
cocotton_ has joined #ruby
xaxisx has quit [Quit: xaxisx]
mikecmpbll has quit [Quit: i've nodded off.]
xaxisx has joined #ruby
microdex has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
proq has quit [Remote host closed the connection]
jamto11 has joined #ruby
chrisramon has joined #ruby
mattstratton has quit [Read error: Connection reset by peer]
gauravag_ has quit [Quit: Leaving...]
gauravagarwalr has quit []
mattstratton has joined #ruby
bigkevmcd has quit [Quit: Ex-Chat]
cocotton_ has quit [Ping timeout: 264 seconds]
Zebroid has joined #ruby
<microdex> What is the meaning of # in Ruby ? e.g.
<microdex> where(foo: ['bar', 'baz', nil]) # => (WHERE foo IN ('bar', 'baz') OR foo IS NULL)
<pipework> microdex: Guess.
beneggett has joined #ruby
beneggett has quit [Client Quit]
<microdex> ID ?
xaxisx has quit [Client Quit]
mikepack has joined #ruby
GriffinHeart has joined #ruby
mikecmpbll has joined #ruby
<chamblin> microdex: it just begins a comment to the end of the line
<microdex> ;hoFHAHAHAHAHHAH
<chamblin> :)
mattstra_ has joined #ruby
<microdex> That threw me off super hard in the middle of the line like that
troyready has joined #ruby
larissa has quit [Quit: Leaving]
MindfulMonk has quit [Ping timeout: 264 seconds]
<microdex> What about ->
<chamblin> => ?
yokel has quit [Ping timeout: 245 seconds]
ki0 has joined #ruby
beef-wellington has joined #ruby
<chamblin> generally it's the hash association operator, but it's just conventionally used in comments to mean "this expression evaluates to"
<centrx> microdex, -> is the stabby lambda
<microdex> for example: scope :red, -> { where(color: 'red') }
mattstratton has quit [Ping timeout: 256 seconds]
<chamblin> oh that one.
<centrx> It is just shorthand for lambda
<microdex> oh
Zebroid has quit [Ping timeout: 240 seconds]
<microdex> and a lambda is just like a block yeah ?
<centrx> Sure, yes
Hamburglr has quit [Read error: Connection reset by peer]
<microdex> Thanks
<centrx> blocks, lambdas and Procs are very similar
namxam has quit [Remote host closed the connection]
<centrx> but not identical
qwebirc83742 has joined #ruby
IceDragon has quit [Ping timeout: 240 seconds]
<microdex> is there an easy to remember distinction between them ?
alem0lars has quit [Quit: alem0lars]
<microdex> Like why is the lambda being used here:
<microdex> scope :red, -> { where(color: 'red') }
<microdex> and why is there a comma between them
deric_skibotn has joined #ruby
shevy has joined #ruby
jcromartie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
namxam has joined #ruby
<centrx> microdex, scope is a method and :red is the first parameter
mattstratton has joined #ruby
IceDragon has joined #ruby
<centrx> microdex, The second parameter is passed as a lambda
wjimenez5271 has joined #ruby
GriffinHeart has quit [Ping timeout: 260 seconds]
<microdex> is it just this: scope( :red , lambda( where( color:'red' ) ) ?
mattstra_ has quit [Ping timeout: 255 seconds]
wallerdev has quit [Quit: wallerdev]
<centrx> For the scope method yes, that's not the syntax for lambda
wallerdev has joined #ruby
<shevy> hehe
<shevy> >> lambda { puts 'hi' }[]
<Mon_Robot> shevy: => hi... (https://eval.in/171774)
<microdex> oh right
<shevy> eval-in is now permanently Mon_Robot?
<microdex> scope( 'red' , lambda{ where(color:'red')} )
ki0 has quit [Ping timeout: 255 seconds]
momomomomo has quit [Quit: momomomomo]
MartinCleaver has quit [Quit: MartinCleaver]
tomblomfield has joined #ruby
centrx has quit [Quit: Mead error: Connection reset by beer]
endash has joined #ruby
beilabs has quit [Ping timeout: 255 seconds]
wallerdev has quit [Client Quit]
pietr0 has joined #ruby
<arup_r> shevy: Temperature is cool now there ? :-)
MartinCleaver has joined #ruby
dbasch has joined #ruby
lsmola has quit [Ping timeout: 250 seconds]
<shevy> arup_r yes
<shevy> it was much much better the last some days
<shevy> arup_r you are from India?
mikepack_ has joined #ruby
<arup_r> yes........
<shevy> my co-worker is from India, Mohit is his first name
benzrf|offline is now known as benzrf
NinoScript_ has quit [Quit: Textual IRC Client: www.textualapp.com]
<arup_r> shevy: How you come to know ?
<shevy> he creates electron transmission microscopic datasets, captured into .tif format, which eventually have to be reconstructed into 3D objects. I still don't understand half of it
NinoScript_ has joined #ruby
__julien has quit [Ping timeout: 255 seconds]
<shevy> arup_r stackoverflow - I tried to look if anyone has ruby questions, and saw you answered like all there are
<shevy> I noticed "hey, I saw that name on IRC didn't I ..."
bayed has quit [Quit: Connection closed for inactivity]
Atttwww has joined #ruby
ctp has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
saarinen has joined #ruby
thams has joined #ruby
mikecmpbll has quit [Quit: i've nodded off.]
LadyRainicorn has quit [Ping timeout: 260 seconds]
mikepack has quit [Ping timeout: 240 seconds]
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<arup_r> ohh! Yes..I always there.. But started to love this irc too... :-)
namxam has quit [Remote host closed the connection]
startupality has quit [Ping timeout: 272 seconds]
LadyRainicorn has joined #ruby
mehlah has quit [Quit: Leaving...]
<shevy> IRC is older than stackoverflow!
<shevy> but stackoverflow kinda beats IRC :(
baroquebobcat has quit [Quit: baroquebobcat]
<shevy> you get karma for helping people on stackoverflow
<shevy> and no karma on IRC
<shevy> :P
<arup_r> Humm .. But I was not aware of.. JEGII sent me here by saying, I will learn more from here..
<shevy> dunno it depends
djbkd has joined #ruby
<shevy> when apeiros is there then yes
<shevy> on weekends it is very quiet here
<shevy> especially Sunday
<arup_r> So I came... But one people is here who didn't like me or welcome me as I joined.. :(
cocotton has joined #ruby
cocotton has quit [Remote host closed the connection]
mikecmpbll has joined #ruby
<shevy> so what, it's not as if you depend on everyone liking you :P
cocotton has joined #ruby
CorpusCallosum has quit [Read error: Connection reset by peer]
fifthofwry has joined #ruby
<arup_r> shevy: What do you mean by "hey, I saw that name on IRC didn't I ..."
<arup_r> :-)
mocfive has quit [Remote host closed the connection]
Takle has joined #ruby
mocfive has joined #ruby
baroquebobcat has joined #ruby
rp__ has joined #ruby
<apeiros> whot?
rylev_ has quit [Remote host closed the connection]
mattstratton has joined #ruby
beilabs has joined #ruby
Shidash has joined #ruby
njibx has quit [Quit: ChatZilla 0.9.90.1 [Firefox 31.0/20140715214327]]
mocfive has quit [Ping timeout: 250 seconds]
Takle has quit [Read error: Connection reset by peer]
<shevy> yeah
<shevy> arup_r on stackoverflow, you use the same nicks
Hobogrammer has joined #ruby
<arup_r> ohh!!
NinoScript has quit [Ping timeout: 245 seconds]
razrunelord has joined #ruby
nisstyre has quit [Quit: WeeChat 0.4.3]
<arup_r> shevy: Mohit is Indian name.
nisstyre has joined #ruby
<shevy> hehe
wallerdev has joined #ruby
Xiti has joined #ruby
chrishough has quit [Quit: chrishough]
NinoScript has joined #ruby
timonv_ has joined #ruby
rayners has joined #ruby
havenwood has joined #ruby
vifino has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
dangerou_ has joined #ruby
MindfulMonk has joined #ruby
davispuh has joined #ruby
armenb has joined #ruby
<armenb> hello
Eiam has joined #ruby
<armenb> is there an easy way in ruby to get a time object of 10 minutes ago?
Tricon has joined #ruby
<armenb> i'm looking for the equivalent of timedelta in python
hectorrr has quit [Remote host closed the connection]
<vifino> Any way I can communicate between forks?
beneggett has joined #ruby
renderfu_ has quit [Remote host closed the connection]
dangerou_ has quit [Read error: Connection reset by peer]
nonnatus has quit [Ping timeout: 260 seconds]
hectorrr has joined #ruby
<elaptics> armenb: Time.now - (x*60) # x is the number of minutes :)
jimms has joined #ruby
sailias has quit [Quit: Leaving.]
dangerousdave has joined #ruby
<armenb> elaptics: thanks!
fabrice31 has quit [Remote host closed the connection]
yokel has joined #ruby
<davidcelis> i was gonna suggest that they look at the code behind ActiveSupport::Duration
<davidcelis> then i realized what a terrible idea that would be
<elaptics> :)
yfeldblum has joined #ruby
tomblomfield has quit [Quit: Computer has gone to sleep.]
<elaptics> davidcelis: ultimately it pretty much does what I just suggested :)
<shevy> :P
EMoreth has joined #ruby
aagdbl has joined #ruby
<davidcelis> yeah
<davidcelis> it just takes a lot more code to do it :(
bravmech has joined #ruby
tier has quit [Remote host closed the connection]
hectorrr has quit [Ping timeout: 240 seconds]
mattmcclure has joined #ruby
lethan has joined #ruby
davispuh has quit [Read error: Connection reset by peer]
davispuh has joined #ruby
blaines has joined #ruby
jcromartie has joined #ruby
<Karunamon> Recursively replacing strings in arbitrary hashes containing arbitrary hashes and arrays. This works, but is ugly. Is there a better way? https://gist.github.com/Karunamon/535aca8ff69e16daf488
yfeldblum has quit [Ping timeout: 255 seconds]
nanoyak has joined #ruby
<shevy> oh my god
iamjarvo has joined #ruby
<wasamasa> oh my ruby
<Karunamon> oh my matz?
zoo-zed has joined #ruby
zoo-zed has quit [Excess Flood]
sambao21 has joined #ruby
Spami has joined #ruby
rayners has quit [Read error: Connection reset by peer]
<wasamasa> oh my code!
Akagi201 has quit [Remote host closed the connection]
<seph429> oh my taco
<chamblin> you could put #recursive_replace_string on String, Array, and Hash so you could get rid of all the cases :)
CorpusCallosum has joined #ruby
namxam has joined #ruby
mikepack_ has quit [Remote host closed the connection]
chth0n has quit [Ping timeout: 255 seconds]
<toretore> Karunamon: your code is fine
mikepack has joined #ruby
<toretore> but don't put it in Hash
tomblomfield has joined #ruby
<shevy> lol
<shevy> "your code is fine - but don't use any input"
<shevy> he has a hash man!
<shevy> actually, Plan B would be to not build up an ugly hash in the first place
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
timonv_ has quit [Ping timeout: 255 seconds]
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
geoffw8_ has quit [Quit: Connection closed for inactivity]
mocfive has joined #ruby
brandonshowers has joined #ruby
brandonshowers has quit [Client Quit]
Tricon has quit [Quit: Leaving...]
aagdbl has quit [Quit: Leaving]
mocfive has quit [Remote host closed the connection]
<chamblin> Karunamon: would something like this work? https://gist.github.com/chamblin/251d6be03b0fba674f79
mocfive has joined #ruby
chrishough has joined #ruby
ziyadb has quit [Quit: Connection closed for inactivity]
tylersmith has joined #ruby
treehug88 has quit [Ping timeout: 245 seconds]
testcore has joined #ruby
<chamblin> it's slightly functionally different, i don't think you need to check if your strings include the string before subbing. this solution also goes down multiple arrays if needed, which might not be intended
brandonshowers has joined #ruby
niklasb has joined #ruby
codeurge has quit [Quit: Sleep.]
niklasb has quit [Client Quit]
niklasb has joined #ruby
m8 has joined #ruby
m8 has quit [Changing host]
m8 has joined #ruby
JohnFord has joined #ruby
wallerdev has quit [Ping timeout: 264 seconds]
wallerdev has joined #ruby
lazyguru has quit [Ping timeout: 250 seconds]
k0m has joined #ruby
niklasb has quit [Client Quit]
k0m has quit [Excess Flood]
NinoScript_ has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
banjara has joined #ruby
niklasb has joined #ruby
Zebroid has joined #ruby
k0m has joined #ruby
isthisreallife has joined #ruby
sailias has joined #ruby
x1337807x has joined #ruby
isthisreallife has left #ruby [#ruby]
s2013 has quit [Ping timeout: 256 seconds]
deric_skibotn has quit [Ping timeout: 245 seconds]
fgo has quit [Remote host closed the connection]
jaequery has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
hectorrr has joined #ruby
mikepack has quit [Remote host closed the connection]
geggam has quit [Remote host closed the connection]
Zebroid has quit [Ping timeout: 240 seconds]
geggam has joined #ruby
lazyguru has joined #ruby
djbkd has quit [Remote host closed the connection]
x1337807x has quit [Ping timeout: 260 seconds]
Asher1 is now known as Asher
jaequery has joined #ruby
emanu has joined #ruby
Hobogrammer has quit [Ping timeout: 260 seconds]
beef-wellington has quit [Ping timeout: 255 seconds]
sk87 has joined #ruby
larsam has joined #ruby
Rahul_Roy has joined #ruby
tier has joined #ruby
djbkd has joined #ruby
poguez_ has joined #ruby
sk87 has quit [Client Quit]
larsam has quit [Read error: Connection reset by peer]
edgarjs_afk has joined #ruby
edgarjs_afk is now known as edgarjs
Aryasam has joined #ruby
edgarjs has left #ruby [#ruby]
codeurge has joined #ruby
pandaant has quit [Quit: leaving]
Lewix has quit [Remote host closed the connection]
b00stfr3ak has joined #ruby
larsam has joined #ruby
beneggett has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
MatthewsFace has quit [Quit: This computer has gone to sleep]
Lewix has joined #ruby
renderful has joined #ruby
tvw has quit []
tier has quit [Ping timeout: 240 seconds]
larsam has quit [Read error: Connection reset by peer]
icarus_ has joined #ruby
vifino has quit [Quit: Ze Cat now leaves...]
ramfjord has joined #ruby
beef-wellington has joined #ruby
Tricon has joined #ruby
LadyRainicorn has quit [Ping timeout: 245 seconds]
jcromartie has quit [Ping timeout: 240 seconds]
chrisramon has quit [Quit: chrisramon]
jaequery has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jcromartie has joined #ruby
pandaant has joined #ruby
jaimef has quit [Excess Flood]
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
nanoyak has quit [Read error: Connection reset by peer]
pandaant has quit [Client Quit]
MatthewsFace has joined #ruby
jackneill has quit [Read error: Connection reset by peer]
nanoyak has joined #ruby
LadyRainicorn has joined #ruby
banister has joined #ruby
Spami has quit [Quit: Leaving]
alvaro_o_ has joined #ruby
melik has joined #ruby
nonnatus has joined #ruby
mocfive has quit []
yfeldblum has joined #ruby
Wolland has quit [Remote host closed the connection]
jaimef has joined #ruby
Ankhers has quit [Ping timeout: 264 seconds]
nanoyak has quit [Read error: Connection reset by peer]
nanoyak has joined #ruby
Spami has joined #ruby
icedp has quit [Ping timeout: 240 seconds]
cocotton has quit [Remote host closed the connection]
djbkd has quit [Remote host closed the connection]
deric_skibotn has joined #ruby
Hamburglr has joined #ruby
alvaro_o_ has quit [Quit: Ex-Chat]
MatthewsFace has quit [Quit: This computer has gone to sleep]
cocotton has joined #ruby
cocotton has quit [Remote host closed the connection]
baroquebobcat has quit [Quit: baroquebobcat]
jcromart_ has joined #ruby
cocotton has joined #ruby
jcromartie has quit [Ping timeout: 272 seconds]
relix has joined #ruby
icedp has joined #ruby
tier has joined #ruby
chrishough has quit [Quit: chrishough]
hectorrr has quit [Remote host closed the connection]
mikepack has joined #ruby
hectorrr has joined #ruby
Hobogrammer has joined #ruby
hectorrr has quit [Remote host closed the connection]
s2013 has joined #ruby
djbkd has joined #ruby
fmendez has joined #ruby
cocotton has quit [Remote host closed the connection]
hectorrr has joined #ruby
enebo has joined #ruby
Eiam has quit [Quit: ╯°□°)╯︵ǝpouǝǝɹɟ]
Takle has joined #ruby
hectorrr has quit [Ping timeout: 260 seconds]
razorgfx has joined #ruby
cocotton has joined #ruby
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
cocotton has quit [Remote host closed the connection]
cocotton has joined #ruby
__julien has joined #ruby
sjouke has joined #ruby
yetanotherdave has joined #ruby
Takle has quit [Ping timeout: 260 seconds]
<sjouke> I know this isn't a ruby on rails support channel, but I do have a question that I think is relevant to rubyists. in project_root/config/environment.rb there exists a [line? statement? not sure what you call it]:
<sjouke> Rails.application.initialize!
hectorrr has joined #ruby
<sjouke> oh, i see
<sjouke> sorry for the noise
fgo has joined #ruby
havenwood has quit [Remote host closed the connection]
qwebirc83742 has quit [Ping timeout: 246 seconds]
Zenigor has quit [Remote host closed the connection]
<jottr> Could someone be so kind and explain the following: hsh = Hash.new([]) hsh[:one] << "foo" hsh[:two] << "bar" . Strangely hsh => {}, but hsh[:one] => ["foo", "bar"]
havenwood has joined #ruby
mikepack has quit [Remote host closed the connection]
<toretore> >> hsh = Hash.new([]); hsh[:foo].object_id == hsh[:bar].object_id
<Mon_Robot> toretore: => true (https://eval.in/171781)
<benzrf> jottr: it doesnt automatically dup the object for each new key
<jottr> toretore: I know, but why?
<toretore> >> hsh = Hash.new{|h,k| h[k] = [] }; hsh[:foo].object_id == hsh[:bar].object_id
<Mon_Robot> toretore: => false (https://eval.in/171782)
nobodyzzz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<benzrf> jottr: if you do Hash.new {expr}, it will re-eval expr each time
<toretore> why? because that's the way it's implemented, and documented.
<benzrf> >> hash = Hash.new {[]}; hsh[:foo].object_id == hsh[:bar].object_id
<Mon_Robot> benzrf: => NameError: undefined local variable or method `hsh' for main:Object (https://eval.in/171783)
<benzrf> >> hsh = Hash.new {[]}; hsh[:foo].object_id == hsh[:bar].object_id
<Mon_Robot> benzrf: => false (https://eval.in/171784)
fgo has quit [Ping timeout: 240 seconds]
s2013 has quit [Ping timeout: 240 seconds]
edmz2 has joined #ruby
<toretore> >> hsh = Hash.new{[]}; hsh[:foo] << 1; hsh[:foo]
<Mon_Robot> toretore: => [] (https://eval.in/171785)
jaimef has quit [Excess Flood]
GriffinHeart has joined #ruby
bravmech has quit [Quit: Leaving]
ctp has joined #ruby
thams has quit [Quit: thams]
<benzrf> toretore: oh
<benzrf> oops
xmad has joined #ruby
thams has joined #ruby
geggam_ has joined #ruby
andrewlio has joined #ruby
testcore has quit [Quit: Connection reset by beer]
jaimef has joined #ruby
<atmosx> hello rubuists
aaronrl has joined #ruby
edmz2 has quit [Quit: WeeChat 0.4.3]
rebelshrug has joined #ruby
geggam has quit [Remote host closed the connection]
rebelshrug has quit [Client Quit]
Sauvin has quit [Remote host closed the connection]
<benzrf> atmosx: im not a rubuist
eduardo has joined #ruby
<benzrf> i dnt even know what rubu is
eduardo is now known as Guest48854
geggam has joined #ruby
treehug88 has joined #ruby
x1337807x has joined #ruby
GriffinHeart has quit [Ping timeout: 240 seconds]
geggam_ has quit [Max SendQ exceeded]
geggam has quit [Max SendQ exceeded]
<atmosx> benzrf: what are you then?
<atmosx> benzrf: you traitor
geggam has joined #ruby
Hanmac has quit [Ping timeout: 260 seconds]
Zenigor has joined #ruby
<benzrf> atmosx: im sort of a rubyist
ctp_ has joined #ruby
IceDragon has quit [Read error: No route to host]
<atmosx> benzrf: either you are or you're not
renderful has quit [Remote host closed the connection]
djbkd has quit [Remote host closed the connection]
<eam> >> class Fixnum; def -@; 7; end; end; [-1, - 1, -(1)]
<Mon_Robot> eam: => [-1, 7, 7] (https://eval.in/171792)
djbkd has joined #ruby
Sirupsen has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ctp has quit [Ping timeout: 240 seconds]
<jottr> toretore: hm. it seems I don't really grok the shovel operator...I couldn't find anything about << in the rdoc of Array and Hash
momomomomo has joined #ruby
mercwithamouth has quit [Ping timeout: 250 seconds]
<eam> jottr: << is just push()
<chamblin> jottr: i think it's the default initialization, not the <<, that causes the behavior you see
<eam> it's a method on Array -- not a method on hash
MatthewsFace has joined #ruby
Sirupsen has joined #ruby
nanoyak has quit [Read error: Connection reset by peer]
Zebroid has joined #ruby
nanoyak has joined #ruby
IceDragon has joined #ruby
s2013 has joined #ruby
djbkd has quit [Ping timeout: 264 seconds]
<chamblin> because the hash creates the array when it's instantiated. and then when you call hsh[:missing], it sets hsh[:missing] to that array for you. but since arrays are reference types, they all end up pointing to the same array.
Pharaoh2 has joined #ruby
<chamblin> but if you give it a proc, as in Hash.new{[]}, the result of each proc run is a unique and new array.
BadQuanta has quit [Ping timeout: 240 seconds]
thams has quit [Quit: thams]
Ankhers has joined #ruby
<eam> in jottr's example, why is #keys empty?
thams has joined #ruby
momomomomo has quit [Ping timeout: 255 seconds]
Zebroid has quit [Ping timeout: 260 seconds]
<eam> oh I see
momomomomo has joined #ruby
<jottr> ^^ thats what actually tripped me too
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<jottr> s/tripped/trips
<chamblin> :\
<eam> that's interesting behavior that the default is actually returned from each hash get instead of just being a default value used for set
<jottr> chamblin: sorry didn't see your last post.
<eam> I wouldn't expect that to be the case
BadQuanta has joined #ruby
<toretore> Hash.new(v) just sets Hash#default
<chamblin> oh i see.
<toretore> block -> default_proc
geggam_ has joined #ruby
mikepack has joined #ruby
geggam has quit [Quit: Leaving]
<toretore> default = returned on failed get; default_proc = executed on failed get
<toretore> nothing more, nothing less
jimbow has joined #ruby
<jimbow> how do we search for special characters on the search
nonnatus has quit [Ping timeout: 260 seconds]
<jimbow> i specifially want to know the difference between #{} and %{}
<jimbow> thank you
Hanmac has joined #ruby
nfk has joined #ruby
<jimbow> but that link doesn
<jimbow> doesn't have that
Sirupsen has quit [Ping timeout: 250 seconds]
<toretore> yes it does
<atmosx> my parents will bring me ice-cream! yay!
* atmosx soon will be 33 and still enjoys the small things in life
Poky has quit [Remote host closed the connection]
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nanoyak has quit [Quit: Computer has gone to sleep.]
Sirupsen has joined #ruby
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<jimbow> is %{} the same as %()
<toretore> it is explained in that reference
<toretore> you are too impatient
<toretore> it is the very first thing at http://www.zenspider.com/Languages/Ruby/QuickRef.html#strings
<jimbow> that guide is too advanced for me
nfk has quit [Client Quit]
zipace has joined #ruby
Wolland has joined #ruby
<eam> >> % {}
<Mon_Robot> eam: => SyntaxError: (eval):1: unterminated string meets end of file (https://eval.in/171796)
<eam> oh right, mon_robot eats whitespace
<benzrf> dang it Mon_Robot
<eam> >> % {} ;
<Mon_Robot> eam: => "{}" (https://eval.in/171797)
<eam> >> %{};
<Mon_Robot> eam: => "" (https://eval.in/171798)
<drizz> >> eval("% {} ;")
<Mon_Robot> drizz: => "{}" (https://eval.in/171800)
x1337807x has joined #ruby
nonnatus has joined #ruby
x1337807x has quit [Client Quit]
<eam> >> [not true]
<Mon_Robot> eam: => SyntaxError: (eval):1: syntax error, unexpected keyword_true, expecting '('... (https://eval.in/171801)
dvb_ua has joined #ruby
x1337807x has joined #ruby
Slavox is now known as Slavox|AFK
Tricon has quit [Quit: Leaving...]
soulcake has quit [Read error: Connection reset by peer]
jimbow is now known as passport
passport has quit [Remote host closed the connection]
Guest48854 is now known as edmz2
soulcake has joined #ruby
namxam has quit [Remote host closed the connection]
chrishough has joined #ruby
mehlah has joined #ruby
nfk has joined #ruby
iamjarvo has joined #ruby
roolo has joined #ruby
MatthewsFace has quit [Quit: This computer has gone to sleep]
spider-mario has quit [Remote host closed the connection]
pothibo has joined #ruby
Sirupsen has quit [Remote host closed the connection]
arup_r1 has joined #ruby
jay_ has joined #ruby
Fire-Dragon-DoL has joined #ruby
Bira_ has quit [Remote host closed the connection]
Eiam has joined #ruby
Sirupsen has joined #ruby
jay_ is now known as rubyonrailed
iamjarvo has quit [Client Quit]
Bira_ has joined #ruby
arup_r has quit [Ping timeout: 264 seconds]
emanu has quit [Quit: emanu]
kaspergrubbe_ has quit [Ping timeout: 250 seconds]
yfeldblum has quit [Ping timeout: 260 seconds]
awc737 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dbasch has quit [Quit: dbasch]
awc737 has joined #ruby
rezzack has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
MatthewsFace has joined #ruby
arup_r1 has quit [Ping timeout: 260 seconds]
mattstratton has joined #ruby
maestrojed has joined #ruby
reisl has joined #ruby
piraxx has joined #ruby
phutchins has quit [Ping timeout: 260 seconds]
fgo has joined #ruby
reisl has quit [Client Quit]
microdex has quit [Remote host closed the connection]
iamjarvo has joined #ruby
iamjarvo has quit [Max SendQ exceeded]
iamjarvo has joined #ruby
moritzs has joined #ruby
baroquebobcat has joined #ruby
mikepack has quit [Remote host closed the connection]
tvw has joined #ruby
yfeldblum has joined #ruby
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
fgo has quit [Ping timeout: 245 seconds]
jonahR has joined #ruby
maestrojed has quit [Quit: Computer has gone to sleep.]
Renich has joined #ruby
dbasch has joined #ruby
<Renich> Hey Rubyeiros
<Renich> I need help with this thing: http://paste.fedoraproject.org/120896/40631602/
<Renich> I am trying to make the Settings class find the configuration in either Path
<Renich> I've never went so far as using modules or classes; mostly procedural stuff for my own things. I need some feedback
<Renich> It's not working 'cause of the rescueless begin... anyway, how should I do this?
cocotton has quit [Remote host closed the connection]
<eam> Renich: found_configs = Path.select { |path| File.exists? path }
Bumptious has quit [Remote host closed the connection]
jaimef has quit [Excess Flood]
<Renich> eam: thanks ;=)
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<eam> as a bonus, you may want to complain if found_configs.length > 1
britneywright has joined #ruby
MartinCleaver has quit [Quit: MartinCleaver]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<Renich> eam: how about using the first one if finds; in the designated order (as regular PATH works)?
<eam> whatever you prefer
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
cocotton has joined #ruby
<Renich> eam: ok, thanks
reisl has joined #ruby
cocotton has quit [Remote host closed the connection]
<eam> if it's key/val you could also load both
cocotton has joined #ruby
edwardly is now known as edwardlz
reisl is now known as larissa
<Renich> eam: it is. But, then, the order should be inverted then; so the one loaded last overwrites the first, right?
edwardlz is now known as edwardly
frankle has joined #ruby
hectorrr has quit [Remote host closed the connection]
ctp_ has quit [Ping timeout: 240 seconds]
hectorrr has joined #ruby
<eam> likely, yes
<Renich> ok
Bira_ has quit [Remote host closed the connection]
mikepack has joined #ruby
iamjarvo has joined #ruby
iamjarvo has quit [Max SendQ exceeded]
iamjarvo has joined #ruby
MatthewsFace has quit [Quit: This computer has gone to sleep]
MatthewsFace has joined #ruby
jaimef has joined #ruby
chrishough has quit [Quit: chrishough]
JohnFord has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
JohnFord has joined #ruby
AskSteve has quit [Quit: Leaving.]
Zebroid has joined #ruby
mattstratton has joined #ruby
razorgfx has quit [Quit: Textual IRC Client: www.textualapp.com]
AskSteve has joined #ruby
thams has quit [Quit: thams]
Zebroid has quit [Read error: Connection reset by peer]
goshdarnyou has quit [Quit: Connection closed for inactivity]
Zebroid_ has joined #ruby
WormDrink has joined #ruby
AskSteve has left #ruby [#ruby]
emanu has joined #ruby
thams has joined #ruby
xaxisx has joined #ruby
Bira_ has joined #ruby
Pharaoh2 has quit [Remote host closed the connection]
momomomomo_ has joined #ruby
hobodave has joined #ruby
momomomomo has quit [Ping timeout: 250 seconds]
momomomomo_ is now known as momomomomo
bunnicula has joined #ruby
Zebroid_ has quit [Ping timeout: 264 seconds]
pietr0 has quit [Quit: pietr0]
robscormack has quit [Quit: Leaving]
chrishough has joined #ruby
fgo has joined #ruby
xaxisx has left #ruby [#ruby]
NinoScript has quit [Ping timeout: 256 seconds]
Sawbones has joined #ruby
JoshGlzBrk has joined #ruby
larissa has quit [Ping timeout: 240 seconds]
Ankhers has quit [Ping timeout: 264 seconds]
ctp has joined #ruby
jaequery has joined #ruby
NinoScript has joined #ruby
fgo has quit [Ping timeout: 260 seconds]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
emanu has quit [Quit: emanu]
beneggett has joined #ruby
NinoScript has quit [Read error: Connection reset by peer]
emanu has joined #ruby
NinoScript has joined #ruby
shanlar has quit [Quit: shanlar]
JoshGlzBrk has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
NinoScript has quit [Read error: Connection reset by peer]
Pharaoh2 has joined #ruby
NinoScript has joined #ruby
nfk has quit [Quit: yawn]
jamto11 has quit [Remote host closed the connection]
jimbow has joined #ruby
<jimbow> what does "first:" do?
Spami has quit [Quit: This computer has gone to sleep]
fantazo has joined #ruby
rubyonrailed has quit [Remote host closed the connection]
nonnatus has quit [Ping timeout: 240 seconds]
<havenwood> >> {first: 'coffee'}
<Mon_Robot> havenwood: => {:first=>"coffee"} (https://eval.in/171806)
nfk has joined #ruby
shanlar has joined #ruby
jamto11 has joined #ruby
geggam_ is now known as geggam
lkba has quit [Ping timeout: 240 seconds]
cantonic has quit [Quit: cantonic]
NinoScript has quit [Read error: Connection reset by peer]
<jimbow> i mean why do we need word followed by colon?
NinoScript has joined #ruby
<toretore> it's syntax sugar for {:first => ...}
<jimbow> this is super confusing
<toretore> not really
<jimbow> not when you know it
<eam> >> {:first: last:}
<Mon_Robot> eam: => SyntaxError: (eval):1: syntax error, unexpected ':', expecting =>... (https://eval.in/171807)
Photism has joined #ruby
<toretore> and now you know it, so it's not confusing anymore ;)
ascarter has joined #ruby
<eam> >> {first: :last}
<Mon_Robot> eam: => {:first=>:last} (https://eval.in/171808)
nanoyak has joined #ruby
iamjarvo has joined #ruby
iamjarvo has quit [Max SendQ exceeded]
wahben has joined #ruby
<eam> I agree it's pretty confusing
hobodave has quit [Ping timeout: 245 seconds]
zorak has joined #ruby
iamjarvo has joined #ruby
yfeldblum has quit [Quit: Leaving...]
iamjarvo has quit [Read error: Connection reset by peer]
yfeldblum has joined #ruby
NinoScript has quit [Ping timeout: 245 seconds]
hobodave has joined #ruby
iamjarvo has joined #ruby
towbes has quit [Ping timeout: 250 seconds]
hobodave has quit [Client Quit]
<jimbow> i still don't know anything toretore
hobodave has joined #ruby
hobodave has quit [Client Quit]
larissa has joined #ruby
<toretore> you know that {foo: 'bar'} and {:foo => 'bar'} are the same
Duckily has joined #ruby
andrewjanssen has joined #ruby
<toretore> you should avoid using {foo: 'bar'} for now
oso96_2000 is now known as oso|away
<jimbow> what is foo and what is bar?
NinoScript has joined #ruby
<toretore> same with all the %w{} stuff
<havenwood> FUBAR
<toretore> :foo is a symbol
<toretore> 'bar' is a string
<wahben> Hello Rubyists, so I have a UTF-8 encoded string with an invalid UTF-8 byte sequence, I'd like to remove the invalid byte sequence from the string without having to convert to UTF-16 which may have side effect, and which is a useless operation anyways. But it seems that the only possible solution is to convert to and from UTF-16: "\xed\xa0\xbd\xe2\x98\xba".encode('UTF-16', 'UTF-8', invalid: :replace, replace: '').encode('UTF-8',
<wahben> 'UTF-16')
MatthewsFace has quit [Ping timeout: 240 seconds]
cantonic has joined #ruby
djbkd has joined #ruby
jaequery has quit [Quit: Textual IRC Client: www.textualapp.com]
<wahben> Any idea how to strip invalid byte sequence without having to convert to / from utf16?
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
MatthewsFace has joined #ruby
apeiros_ has joined #ruby
kaspergrubbe_ has joined #ruby
crudson has joined #ruby
NinoScript has quit [Read error: Connection reset by peer]
dbasch has quit [Quit: dbasch]
apeiros has quit [Disconnected by services]
apeiros_ is now known as apeiros
zorak has quit [Ping timeout: 255 seconds]
ddv has quit [Changing host]
ddv has joined #ruby
<wahben> toretore: Brilliant!!
<wahben> thanks
NinoScript has joined #ruby
hobodave_ has joined #ruby
mattstratton has joined #ruby
<wahben> toretore: wait that's new to Ruby 2.1 I assume right?
<toretore> yes, i think so
<toretore> or 2.0
rubyonrailed has joined #ruby
<wahben> yea I'm on 2.0 and don't have that.. ah well.
nanoyak has quit [Quit: Computer has gone to sleep.]
MickeyO has joined #ruby
<toretore> just use 2.1 instead
<wahben> havenwood: perfect!
fifthofwry has quit [Ping timeout: 255 seconds]
renderful has joined #ruby
nanoyak has joined #ruby
jcromart_ has quit [Quit: Textual IRC Client: www.textualapp.com]
yalue has quit [Quit: Leaving]
jmbrown412 has joined #ruby
nanoyak has quit [Client Quit]
mikepack has quit [Remote host closed the connection]
NinoScript has quit [Ping timeout: 240 seconds]
GriffinHeart has joined #ruby
xaxisx has joined #ruby
razrunelord has quit []
emanu has quit [Quit: emanu]
awc737 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sirene has quit [Read error: Connection reset by peer]
Bumptious has joined #ruby
andrewjanssen has quit [Quit: Leaving...]
Bumptious has quit [Client Quit]
jmbrown412 has quit [Ping timeout: 256 seconds]
NinoScript has joined #ruby
Bumptious has joined #ruby
StephenA1 has joined #ruby
cocotton_ has joined #ruby
GriffinHeart has quit [Ping timeout: 264 seconds]
shanlar has quit [Remote host closed the connection]
Wolland has quit [Remote host closed the connection]
beilabs has quit [Ping timeout: 240 seconds]
Takle has joined #ruby
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
shanlar has joined #ruby
hobodave_ has quit [Quit: Computer has gone to sleep.]
StephenA1 has quit [Remote host closed the connection]
beilabs has joined #ruby
moritzs has quit [Ping timeout: 240 seconds]
cocotton has quit [Ping timeout: 264 seconds]
zorak has joined #ruby
zybi1 has joined #ruby
beef-wellington has quit [Ping timeout: 255 seconds]
clinicalpain has joined #ruby
nanoyak has joined #ruby
clinicalpain has left #ruby [#ruby]
hobodave has joined #ruby
namxam has joined #ruby
beef-wellington has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
x1337807x has joined #ruby
dangerousdave has joined #ruby
kachi8 has joined #ruby
__julien has quit [Quit: Leaving]
sarkis has quit [Ping timeout: 240 seconds]
postmodern has quit [Quit: Leaving]
JohnFord has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bunnicula has quit [Ping timeout: 240 seconds]
wallerdev has quit [Quit: wallerdev]
pietr0 has joined #ruby
lethan has quit []
tier has quit []
NinoScript has quit [Ping timeout: 255 seconds]
lkba has joined #ruby
emanu has joined #ruby
tobago has quit [Remote host closed the connection]
decoponio has quit [Quit: Leaving...]
Bira_ has quit [Remote host closed the connection]
elaptics is now known as elaptics`away
NinoScript has joined #ruby
einarj has joined #ruby
Bira_ has joined #ruby
JohnFord has joined #ruby
matrixdevuk has quit [Quit: Lingo - http://www.lingoirc.com]
blackmesa has joined #ruby
dbasch has joined #ruby
Zebroid has joined #ruby
saarinen has quit [Quit: saarinen]
concordiadiscors has joined #ruby
AlSquire has joined #ruby
Bira_ has quit [Remote host closed the connection]
hobodave has quit [Quit: Computer has gone to sleep.]
saarinen has joined #ruby
<jottr> Is it somehow possible to cd to the directory of the currently opened buffer? I.e. I edit /tmp/foodir/myfile.txt but launched vim from ~. Can I drop straight to that directory when exiting/backgrounding vim?
jimbow has quit [K-Lined]
namxam_ has joined #ruby
hobodave has joined #ruby
<apeiros> jottr: you can't modify the env of the parent process
Tricon has joined #ruby
<jottr> apeiros: ok.
mikepack has joined #ruby
<apeiros> at least not in any sane OS
momomomomo_ has joined #ruby
edmz2 has left #ruby ["WeeChat 0.4.3"]
NinoScript has quit [Ping timeout: 260 seconds]
Bira_ has joined #ruby
freerobby has quit [Quit: Leaving.]
Zebroid has quit [Ping timeout: 264 seconds]
Bira_ has quit [Remote host closed the connection]
freerobby has joined #ruby
momomomomo has quit [Ping timeout: 260 seconds]
momomomomo_ is now known as momomomomo
mattstratton has joined #ruby
namxam has quit [Ping timeout: 264 seconds]
postmodern has joined #ruby
Morkel has quit [Quit: Morkel]
NinoScript has joined #ruby
sjouke has quit [Ping timeout: 256 seconds]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sjouke has joined #ruby
Zenigor has quit [Remote host closed the connection]
jimms has quit []
fgo has joined #ruby
jlovick has quit [Ping timeout: 255 seconds]
skysploit has joined #ruby
skysploit has joined #ruby
chrishough has quit [Quit: chrishough]
piraxx has quit [Read error: Connection reset by peer]
awc737 has joined #ruby
NinoScript has quit [Ping timeout: 240 seconds]
timonv_ has joined #ruby
beef-wellington has quit [Ping timeout: 240 seconds]
cocotton_ has quit [Remote host closed the connection]
mikepack has quit [Ping timeout: 240 seconds]
NinoScript has joined #ruby
fgo has quit [Ping timeout: 250 seconds]
brandonshowers has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
djbkd has quit [Remote host closed the connection]
wahben has quit [Remote host closed the connection]
cocotton has joined #ruby
djbkd has joined #ruby
mattstratton has quit [Quit: Textual IRC Client: www.textualapp.com]
NinoScript has quit [Read error: Connection reset by peer]
Pharaoh2 has quit [Remote host closed the connection]
NinoScript has joined #ruby
linojon has quit [Quit: linojon]
sarkis has joined #ruby
Tricon has quit [Quit: Leaving...]
hectorrr has quit [Remote host closed the connection]
hectorrr has joined #ruby
djbkd has quit [Remote host closed the connection]
sailias has quit [Quit: Leaving.]
djbkd has joined #ruby
troyready has quit [Ping timeout: 250 seconds]
<apeiros> do you guys consider this readable? https://gist.github.com/apeiros/ac97957e09b44a76ab4d
x1337807x has joined #ruby
<pipework> apeiros: No, the numbers and letters on the last part of that link aren't really readable.
<apeiros> d'oh :)
Sirupsen has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<pipework> apeiros: Why does execute take multiple arguments like that?
<apeiros> to pass arguments separately, so you don't need to escape stuff
<pipework> sh.execute "bundle", "exec", "rake", "assets:precompile"
chrishough has joined #ruby
<pipework> Why is that better than %w|bundle exec rake assets:precompile| ?
<apeiros> pipework: well, just use that and splat it if you prefer that
sarkis has quit [Ping timeout: 272 seconds]
<pipework> apeiros: Well, why not just use a string?
<apeiros> because that's dangerous
<pipework> How is it?
hectorrr has quit [Ping timeout: 256 seconds]
<apeiros> sh.execute "bundle #{untrusted_input}"
<pipework> In what way is yours less dangerous?
towbes has joined #ruby
<apeiros> untrusted_input = "foo; rm -rf /"
<pipework> And how does yours prevent someone from doing that?
craigbowen3 has quit [Ping timeout: 264 seconds]
Pharaoh2 has joined #ruby
<apeiros> with mine, "foo; rm -rf /" is one argument
<pipework> So?
<apeiros> see rubys low level shell commands
<apeiros> so it won't run rm -rf
sjouke has quit [Ping timeout: 256 seconds]
wallerdev has joined #ruby
<apeiros> you haven't used shell commands like that before?
<pipework> Hm, I don't really buy it, but if you're expecting to take untrustable input, I guess.
jlovick has joined #ruby
jdj_dk has joined #ruby
<apeiros> see e.g. system
<pipework> Typically I don't have the problem where I have to santize input before running commands. I don't recall ever needing to.
xaxisx has quit [Quit: xaxisx]
<apeiros> system 'ls -la; rm -rf /' # deletes your stuff
sjouke has joined #ruby
xaxisx has joined #ruby
<pipework> While I can understand the benefit, I think it makes it uglier.
<apeiros> system 'ls', '-la; rm -rf /' # tells you that '-la; rm -rf /' is not a valid argument to ls
arya_ has quit [Ping timeout: 245 seconds]
<apeiros> I agree. but providing the non-ugly option has proven over time to let people do stupid shit :)
<pipework> apeiros: Do you expect the user of the code to be handling untrusted input before passing it to the system?
<apeiros> this is generic code. there's no reasonable expection
<pipework> They can still do stupid things, they're extraordinarily crafty at finding ways to be stupid.
<apeiros> *expectation
<pipework> Anyways, +1 for the safety, -1 for the DSL.
<apeiros> yes. but they less easily can do it accidentally.
<pipework> I'm probably just a bit too apathetic towards protecting users from themselves in this way.
<apeiros> I don't use any of rubys shell commands with a string unless it's an uninterpolated one
djbkd has quit [Remote host closed the connection]
<apeiros> pipework: you're the kind of guy who doesn't use bind variables in sql queries too? :)
<pipework> I usually just use Open3.
concordiadiscors has quit [Ping timeout: 260 seconds]
<apeiros> pipework: open3 doesn't magically protect you either
<pipework> apeiros: I don't do SQL, there's a millionty other people who can.
<apeiros> you have to use it in array form too
<pipework> apeiros: I know it doesn't.
djbkd has joined #ruby
<pipework> I just don't fuck up, and don't let users fuck up on my behalf. :D
<apeiros> how much do you want to bet that you never fucked up wrt user input? :)
<pipework> I also admittedly don't have situations where I'd benefit greatly from this.
Ilyas has quit [Ping timeout: 264 seconds]
<pipework> apeiros: How often do you run shell commands that use user input directly?
Wolland has joined #ruby
<pipework> apeiros is making exec-as-a-service clearly
carraroj has quit [Quit: Konversation terminated!]
Bira_ has joined #ruby
qwyeth has quit [Quit: Leaving]
<apeiros> pipework: everybody thinks "oh this code is perfectly save because it doesn't have user input" until they notice they have and that their variables could be manipulated in unexpected ways
<pipework> apeiros: Well, that's not really something that has ever come up for me.
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
dbasch has quit [Read error: Connection reset by peer]
<apeiros> pipework: if you write a custom shell script sure.
<pipework> I am lucky enough to not have user input directly involved with shelling out. The poor sod that does though, I can see the necessity.
dbasch has joined #ruby
<apeiros> pipework: if you write a library, the situation is a tad different, wouldn't you think?
mikesplain has quit [Ping timeout: 272 seconds]
acrussell has quit [Quit: Leaving.]
<pipework> apeiros: No, why would it?
<apeiros> pipework: "lets not add bind variables to sql libs because people should just write proper code"
<pipework> There's only so much work I will invest in protecting developers from being the fuckwits they are.
endash has quit [Quit: endash]
graft has quit [Ping timeout: 250 seconds]
<apeiros> sorry if I find that line of argument silly.
djbkd has quit [Ping timeout: 260 seconds]
<pipework> apeiros: I'm just saying I've never come across a case in my experience where I needed the amount of protection you're allowing.
<pipework> Not that you could just write good code.
bmurt has quit []
<apeiros> in other words you're saying "because I never came across, it should not be added"
chrishough has quit [Quit: chrishough]
<pipework> No, but I think we're done here because you clearly have some kind of skew you're adding to things I say.
<pipework> Good luck with the library, I'm sure someone will use it and benefit from the protection.
tylersmith has quit [Remote host closed the connection]
MCDev has quit [Ping timeout: 250 seconds]
<pipework> apeiros: To answer your other attempt to put words into my mouth, I just wouldn't use your library, because it solves a problem I do not have.
snath has quit [Ping timeout: 245 seconds]
wjimenez_5271_ has joined #ruby
<j_mcnally> !popcorn3
Bira_ has quit [Remote host closed the connection]
<apeiros> pipework: said every coder who didn't use bind variables or passed input to the shell. sorry, but I consider your attitude rather short-sighted.
MatthewsFace has quit [Ping timeout: 240 seconds]
<apeiros> it may very well be that you personally don't have crossed a use case
<pipework> apeiros: So I'm short-sighted because I don't make stupid mistakes? Brilliant.
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<pipework> Spot on you are with this one.
MatthewsFace has joined #ruby
kachi8 has quit [Ping timeout: 240 seconds]
jonahR has quit [Quit: ¡Adios amigos, me fui para el carajo!]
<apeiros> pipework: no, you're short-sighted because you prefer to rely on writing always perfect code instead of using safe constructs.
<apeiros> and because you expect every other coder to write similarly high quality code
Takle_ has joined #ruby
<pipework> apeiros: Oh, no I'm not short-sighted for that. I just don't find a lot of value in it given that I don't use user input in shell commands directly. :)
Takle has quit [Read error: Connection reset by peer]
cylofe has joined #ruby
<pipework> Seems like the safest approach. A library to encourage a developer to use user input in a shell commands sounds like an abominable waste of time, no matter what safety precautions it puts in place. :)
sarkis has joined #ruby
<apeiros> pipework: in that case you're short-sighted because you use your limited personal use-case to argue how it should be done in general.
RandyT has quit [Quit: ZNC - http://znc.in]
kachi8 has joined #ruby
wjimenez5271 has quit [Ping timeout: 255 seconds]
beef-wellington has joined #ruby
<pipework> apeiros: I actually haven't argued that way, you're still inventing false arguments.
jdj_dk has quit [Remote host closed the connection]
<pipework> Perhaps take 5 seconds to read what I say without trying to infer anything, it'd probably help with future discourse.
<apeiros> there's a scrollback which says you did
lxsameer has joined #ruby
duggiefresh has quit []
<pipework> Then I can't really help you if you've decided that you know what I was arguing better than me. Seems like you know everything, and I'm just damned to be short-sighted because of your ineffable wisdom.
<pipework> Your DSL still looks like shit though, can't fix that.
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<apeiros> lets take a step back. you say a plain string argument to pass to sh.execute would be nicer/less ugly. right?
<toretore> ur mom looks like shit
Starless has joined #ruby
<pipework> apeiros: I'm disinterested in discussing anything of technical merit with you at this time. I can't be expected to deal with your level of combativeness.
<apeiros> ok
failshell has quit []
RandyT has joined #ruby
charliesome has quit [Read error: Connection reset by peer]
<pipework> toretore: She's a nice lady though!
charliesome has joined #ruby
nowthatsamatt has quit [Quit: nowthatsamatt]
ldnunes has quit [Quit: Leaving]
<shevy> pics
x1337807x has joined #ruby
<apeiros> oh, pipework is spaceghost…
<apeiros> that explains things
havenwood has quit [Ping timeout: 264 seconds]
<shevy> are you stalking him
<shevy> kissy kissy kissy? :>
<pipework> My near perfection is explained by my identity.
<shevy> all I know is that pipework likes documentation
cocotton has quit [Remote host closed the connection]
<apeiros> shevy: ugh. stalking sounds like far too much work.
mikepack has joined #ruby
<shevy> perhaps I could stalk pipework for you!
<apeiros> pipework: yeah. sure.
<shevy> pipework what is your favourite colour?
MatthewsFace has quit [Ping timeout: 245 seconds]
<shevy> and are you allergic to cats
<Starless> shevy: yes, pipework; what is your favorite color?
<pipework> shevy: Probably the color of apeiros' face when he realizes that his library is silly.
<apeiros> sounds like somebody is butthurt
<pipework> Nawbruv, just trollin'
<shevy> oh man :P
<pipework> Ain't got the buttHz. I let shevy.
<pipework> apeiros: For what it's worth, while I find the DSL to be uglier with the safer method, I wasn't arguing against it being present, I was just saying that the use case for it isn't one I've ever come in contact with.
lw has quit [Quit: s]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<shevy> you hated it with all your guts pipework
chipotle has joined #ruby
<pipework> To be clear, I would either not use the library, or ask that I could pass a configuration option in to allow the use of a single string.
<shevy> actually, I came way too late to the party :(
Takle_ has quit [Read error: Connection reset by peer]
peret has joined #ruby
djbkd has joined #ruby
<apeiros> pipework: I'd probably follow zenspider's lead and use similar naming as https://github.com/seattlerb/minitest/blob/master/lib/minitest/test.rb#L25
jaimef has quit [Excess Flood]
<pipework> apeiros: I suppose.
<pipework> Seems like the kind of thing you would do.
jle` has quit [Ping timeout: 260 seconds]
MatthewsFace has joined #ruby
Takle has joined #ruby
<apeiros> but allowing it via config option only is a ponderable way
St_Marx has quit [Quit: Ex-Chat]
jaimef has joined #ruby
graft has joined #ruby
jle` has joined #ruby
x1337807x has joined #ruby
beef-wellington has quit [Ping timeout: 245 seconds]
pietr0 has quit [Read error: Connection reset by peer]
MickeyO has quit []
deric_skibotn has quit [Read error: Connection reset by peer]
deric_skibotn has joined #ruby
AlSquire has quit [Quit: This computer has gone to sleep]
Zebroid has joined #ruby
AlSquire has joined #ruby
pandaant has joined #ruby
centrx has joined #ruby
Renich has left #ruby [#ruby]
hobodave has quit [Quit: Computer has gone to sleep.]
xaxisx has quit [Quit: xaxisx]
skysploit has quit [Remote host closed the connection]
Zebroid has quit [Ping timeout: 272 seconds]
emanu has quit [Quit: emanu]
snath has joined #ruby
xaxisx has joined #ruby
<dopiee> can anyone explain t me wha .count does
<dopiee> i dont really understand it even looking at the docs
<apeiros> dopiee: same as .size and .length
<apeiros> that is, when used without an argument, like in your code
pietr0 has joined #ruby
sepp2k has joined #ruby
Tricon has joined #ruby
fgo has joined #ruby
<centrx> #count "counts" the number of element in the array/enumerable
<apeiros> could rewrite that code to: total -= 10*arr.count("A")
<wallerdev> >> [].count { |x| x + 1 }
<Mon_Robot> wallerdev: => 0 (https://eval.in/171848)
<apeiros> d'oh, omitted the if
<apeiros> could rewrite that code to: total -= 10*arr.count("A") if total > 21 # now
codeurge has quit [Quit: Sleep.]
xaxisx has left #ruby [#ruby]
Takle has quit [Remote host closed the connection]
<apeiros> meh. I think it's getting late. somehow didn't notice that it's subtracting from the same variable as it compares to… but could still be written shorter
Slavox|AFK is now known as Slavox
Shidash has quit [Quit: Leaving.]
fgo has quit [Ping timeout: 272 seconds]
rylev has joined #ruby
crudson has quit [Ping timeout: 260 seconds]
jrhorn424 has quit [Ping timeout: 240 seconds]
pandaant has quit [Quit: Lost terminal]
djbkd has quit [Remote host closed the connection]
garethrees has joined #ruby
memph1s has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<dopiee> so if A == 11 it would set A to 1
<dopiee> ?
<dopiee> "A"
djbkd has joined #ruby
hectorrr has joined #ruby
RandyT has quit [Ping timeout: 250 seconds]
m8 has quit [Quit: Sto andando via]
pandaant has joined #ruby
<dopiee> what des the 10*arr mean
<dopiee> sorry
<dopiee> just analyzing your code
amargherio has quit [Remote host closed the connection]
Starless has quit [Quit: Leaving]
zacts has left #ruby [#ruby]
ghr has quit [Ping timeout: 245 seconds]
<apeiros> `10*arr.count("A")` is executed in this order: `10*(arr.count("A"))`
jamto11 has quit [Remote host closed the connection]
ndrei has quit [Ping timeout: 272 seconds]
<apeiros> arr.count("A") returns how many times "A" occurs in arr
RandyT has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<dopiee> so its multiplying by 10 how ever many times A occurs?
agjacome has joined #ruby
djbkd has quit [Ping timeout: 245 seconds]
<apeiros> yes. but it doesn't properly limit it as the iterating code does
claymore has quit [Quit: Leaving]
beilabs has quit [Quit: Leaving]
brandonshowers has joined #ruby
GriffinHeart has joined #ruby
<shevy> is there a simple but effective way to disable specific warnings?
<shevy> /usr/lib/ruby/gems/2.1.0/gems/syck-1.0.1/lib/yaml/engine_manager.rb:18: warning: method redefined; discarding old yamler
MartynKeigher has quit [Read error: Connection reset by peer]
beef-wellington has joined #ruby
<shevy> something like "show me warnings as usual, but not from gem XYZ"
endthefed has joined #ruby
St_Marx has joined #ruby
Umang has quit [Ping timeout: 260 seconds]
terrell_t has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
GriffinHeart has quit [Ping timeout: 255 seconds]
kmels has quit [Ping timeout: 256 seconds]
beef-wellington has quit [Ping timeout: 245 seconds]
joast has quit [Quit: Leaving.]
pietr0 has quit [Quit: pietr0]
DrShoggoth has quit [Quit: Leaving]
<shevy> huh weird... I thought $VERBOSE would have valuesl ike 0, 1 or 2
renderful has quit [Remote host closed the connection]
terrellt has quit [Ping timeout: 255 seconds]
<shevy> ok, seems to work when changing $VERBOSE and then restoring the old default again. it is not pretty but it seems to work
hectorrr has quit [Remote host closed the connection]
cocotton has joined #ruby
fabrice31 has joined #ruby
cocotton has quit [Remote host closed the connection]
pietr0 has joined #ruby
hectorrr has joined #ruby
kkh has quit [Read error: Connection reset by peer]
dbasch has quit [Read error: Connection reset by peer]
kkh has joined #ruby
zorak has quit [Read error: Connection reset by peer]
dbasch has joined #ruby
fabrice31 has quit [Remote host closed the connection]
kkh has quit [Read error: Connection reset by peer]
kkh has joined #ruby
awc737 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
nemesit|znc has quit [Ping timeout: 240 seconds]
momomomomo_ has joined #ruby
sjouke has quit [Quit: leaving]
Sawbones has quit [Remote host closed the connection]
renderful has joined #ruby
samotarnik has joined #ruby
momomomomo has quit [Ping timeout: 250 seconds]
momomomomo_ is now known as momomomomo
jlovick has quit [Ping timeout: 240 seconds]
zz_jrhorn424 has joined #ruby
momomomomo has quit [Client Quit]
zz_jrhorn424 is now known as jrhorn424
kies has joined #ruby
Sgeo has joined #ruby
Sirupsen has joined #ruby
jamto11 has joined #ruby
roodee has joined #ruby
nemesit|znc has joined #ruby
s2013 has quit [Ping timeout: 264 seconds]
kies has quit [Client Quit]
ctp has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
namxam_ has quit [Remote host closed the connection]
samotarnik has left #ruby ["Leaving"]
MCDev has joined #ruby
GinoMan has joined #ruby
riotjones has quit [Ping timeout: 240 seconds]
j416_ has joined #ruby
awc737 has joined #ruby
robscormack has joined #ruby
riotjones has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
nateberkopec has quit [Quit: Leaving...]
toretore has quit [Ping timeout: 250 seconds]
x1337807x has joined #ruby
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
j416 has quit [Ping timeout: 272 seconds]
thams has quit [Quit: thams]
choke has quit [Quit: Leaving]
toretore has joined #ruby
davedev24_ has quit [Read error: Connection reset by peer]
namxam has joined #ruby
Rahul_Roy has quit [Quit: Connection closed for inactivity]
davedev24_ has joined #ruby
rails_flix has joined #ruby
endthefed has quit [Read error: Connection reset by peer]
<rails_flix> Hi how to convert doc files to text in ruby on a linux machine?
<rails_flix> win32ole gem only works on windows
<centrx> There may be a Linux program that does that on the command-line
<centrx> or an online service that will do it
timonv_ has quit [Remote host closed the connection]
<toretore> i'd look at openoffice
<rails_flix> hmm there is no ruby gem?
<pipework> What kinds of doc files? Like the doc format or docx?
ziprar has joined #ruby
<rails_flix> pipework, both
<rails_flix> resumes
<pipework> rails_flix: Ah, do you have a list of acceptable formats?
<rails_flix> pdf, doc, docx and rtf
beef-wellington has joined #ruby
kkh has quit [Read error: Connection reset by peer]
icarus_ has quit [Remote host closed the connection]
fold has quit [Ping timeout: 250 seconds]
<shevy> unfortunately I think there is no trivial way to do that
<shevy> perhaps libreoffice would offer some commandline switch, then you could use system() from ruby
garethrees has quit []
<apeiros> there was a headless openoffice. I'd assume that still exists for libreoffice
<pipework> There is a headless version of abiword and openoffice.
zipace has quit [Ping timeout: 256 seconds]
lmickh has quit [Remote host closed the connection]
beef-wellington has quit [Ping timeout: 260 seconds]
ephemerian has left #ruby [#ruby]
mikepack has quit [Remote host closed the connection]
larissa has quit [Quit: Leaving]
jimms has joined #ruby
nateberkopec has joined #ruby
mary5030 has quit [Remote host closed the connection]
wjimenez_5271_ has quit [Remote host closed the connection]
andrewlio has quit [Remote host closed the connection]
Zebroid has joined #ruby
Mon_Ouie has joined #ruby
Mon_Ouie has joined #ruby
Mon_Ouie has quit [Changing host]
hectorrr has quit [Remote host closed the connection]
mary5030 has joined #ruby
robscormack has quit [Quit: This computer has gone to sleep]
wjimenez5271 has joined #ruby
hectorrr has joined #ruby
Bumptious has quit [Remote host closed the connection]
phutchins has joined #ruby
robclancy has quit [Quit: Konversation terminated!]
mikepack has joined #ruby
namxam has quit [Remote host closed the connection]
mary5030 has quit [Ping timeout: 240 seconds]
Zebroid has quit [Ping timeout: 240 seconds]
freerobby has quit [Quit: Leaving.]
jobewan has quit [Quit: Leaving]
fgo has joined #ruby
Sauvin has joined #ruby
blaines has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
chrishough has joined #ruby
blaines has joined #ruby
fgo has quit [Ping timeout: 240 seconds]
<atmosx> headless openoffice?
<atmosx> how exactly does this work?
<pipework> atmosx: you tell me.
dangerousdave has quit [Read error: Connection reset by peer]
JohnFord has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<atmosx> pipework: you pray and a geeny arises
<pipework> sounds legit
banisterfiend has joined #ruby
<davidcelis> genie
Sirupsen has quit [Quit: Textual IRC Client: www.textualapp.com]
<atmosx> yeah whatever you call it in English :-)
dangerousdave has joined #ruby
<pipework> jeanie
robscormack has joined #ruby
Bira has joined #ruby
nanoyak has quit [Quit: Computer has gone to sleep.]
MCDev has quit [Ping timeout: 250 seconds]
renderful has quit [Remote host closed the connection]
enebo has quit [Quit: enebo]
<davidcelis> Djinni
nanoyak has joined #ruby
marr has quit [Ping timeout: 240 seconds]
<shevy> I think pipework was dreaming of Barbara Eden
rylev has quit [Remote host closed the connection]
timonv_ has joined #ruby
LadyRainicorn has quit [Ping timeout: 250 seconds]
LadyRainicorn has joined #ruby
rdark has quit [Quit: leaving]
inside has joined #ruby
thumpba_ has quit [Remote host closed the connection]
lxsameer has quit [Quit: Leaving]
tylersmith has joined #ruby
jottr_ has joined #ruby
jottr has quit [Ping timeout: 250 seconds]
brandonshowers has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
m-r-r has quit [Quit: Hi, I'm a quit message virus. Please replace your old line with this line and help me take over the world of IRC.]
baroquebobcat has quit [Quit: baroquebobcat]
amacou has joined #ruby
mikepack has quit [Remote host closed the connection]
xmad has quit [Ping timeout: 240 seconds]
tomblomfield has quit [Quit: Computer has gone to sleep.]
Pharaoh2 has quit [Quit: Leaving...]
thumpba has joined #ruby
banisterfiend has quit [Quit: Computer has gone to sleep.]
xmad has joined #ruby
b00stfr3ak has quit [Ping timeout: 240 seconds]
wallerdev has quit [Quit: wallerdev]
einarj has quit [Remote host closed the connection]
shawnjgoff has quit [Ping timeout: 255 seconds]
banisterfiend has joined #ruby
timonv_ has quit [Ping timeout: 260 seconds]
sunya7a has joined #ruby
inside has quit [Read error: Connection reset by peer]
freerobby has joined #ruby
jrhe has quit [Quit: Connection closed for inactivity]
nateberkopec has quit [Quit: Leaving...]
Takle has joined #ruby
brandonshowers has joined #ruby
mary5030 has joined #ruby
terrell_t has quit [Remote host closed the connection]
terrellt has joined #ruby
Takle has quit [Read error: Connection reset by peer]
GinoMan has quit [Remote host closed the connection]
_JokerDoom has joined #ruby
mercwithamouth has joined #ruby
RTG`` has joined #ruby
RTG` has quit [Disconnected by services]
fold has joined #ruby
aaronrl_ has joined #ruby
melik_ has joined #ruby
renier_ has joined #ruby
kyb3r_ has joined #ruby
j_mcnall- has joined #ruby
maxmanders_ has joined #ruby
thejoecarroll_ has joined #ruby
nopc0de- has joined #ruby
headius_ has joined #ruby
troulouliou_dev has joined #ruby
jamto11 has quit [Remote host closed the connection]
gnarld_ has joined #ruby
mattp__ has joined #ruby
diego_k has joined #ruby
dawkirst_ has joined #ruby
Beoran has quit [Ping timeout: 250 seconds]
kmels has joined #ruby
PaulePan1er has joined #ruby
jamooo has joined #ruby
jsaak_ has joined #ruby
dazeddev_ has joined #ruby
error404_ has joined #ruby
bunnicula has joined #ruby
peck__ has joined #ruby
a46_ has joined #ruby
gtc|ghost has joined #ruby
qpok_ has joined #ruby
eythorium has joined #ruby
suffice_ has joined #ruby
patteh_ has joined #ruby
davispuhh has joined #ruby
cout_ has joined #ruby
troulouliou_dev has quit [Client Quit]
yeltzooo4 has joined #ruby
mary5030_ has joined #ruby
brandonshowers has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
j_mcnally has quit [Killed (hobana.freenode.net (Nickname regained by services))]
j_mcnall- is now known as j_mcnally
kavinder has joined #ruby
j_mcnally has quit [Remote host closed the connection]
davispuh has quit [Disconnected by services]
mspah_ has joined #ruby
davispuhh is now known as davispuh
MCDev has joined #ruby
sam113102 has joined #ruby
<mspah_> Hey guys, are there any must have rails books? I'm looking for something as good as Eloquent Ruby and Practical Object-Oriented Design in Ruby
quarcu_ has joined #ruby
mary5030 has quit [*.net *.split]
centrx has quit [*.net *.split]
aaronrl has quit [*.net *.split]
treehug88 has quit [*.net *.split]
melik has quit [*.net *.split]
hsps_ has quit [*.net *.split]
drawingthesun has quit [*.net *.split]
teejar has quit [*.net *.split]
eeezkil has quit [*.net *.split]
dawkirst has quit [*.net *.split]
dayepa1 has quit [*.net *.split]
bronson has quit [*.net *.split]
ra4king has quit [*.net *.split]
sam113101 has quit [*.net *.split]
jdoles has quit [*.net *.split]
JokerDoom has quit [*.net *.split]
xMopxShell has quit [*.net *.split]
maxmanders has quit [*.net *.split]
everett has quit [*.net *.split]
gtc has quit [*.net *.split]
peeja has quit [*.net *.split]
nug has quit [*.net *.split]
clamstar has quit [*.net *.split]
renier has quit [*.net *.split]
yeltzooo has quit [*.net *.split]
Mattias has quit [*.net *.split]
verto has quit [*.net *.split]
Adran has quit [*.net *.split]
quarcu has quit [*.net *.split]
a46 has quit [*.net *.split]
Kabaka has quit [*.net *.split]
PaulePanter has quit [*.net *.split]
M-Technic has quit [*.net *.split]
hl has quit [*.net *.split]
Slavox has quit [*.net *.split]
error404 has quit [*.net *.split]
eythoriu1 has quit [*.net *.split]
waltz has quit [*.net *.split]
20WAAQK00 has quit [*.net *.split]
Schmidt has quit [*.net *.split]
mburns has quit [*.net *.split]
peck_ has quit [*.net *.split]
thejoecarroll has quit [*.net *.split]
dazeddev has quit [*.net *.split]
qpok has quit [*.net *.split]
diegok has quit [*.net *.split]
TheMoonMaster has quit [*.net *.split]
SirFunk has quit [*.net *.split]
headius has quit [*.net *.split]
nopc0de has quit [*.net *.split]
ji0n has quit [*.net *.split]
cout has quit [*.net *.split]
patteh has quit [*.net *.split]
gattuso has quit [*.net *.split]
jamooo_ has quit [*.net *.split]
Eiam has quit [*.net *.split]
mattp_ has quit [*.net *.split]
jsaak has quit [*.net *.split]
suffice has quit [*.net *.split]
St_Marx has quit [*.net *.split]
blackmesa has quit [*.net *.split]
end_guy has quit [*.net *.split]
atmosx has quit [*.net *.split]
DrCode has quit [*.net *.split]
gnarld_ is now known as nug
teejar_ has joined #ruby
jdoles_ has joined #ruby
j_mcnally has joined #ruby
waltz has joined #ruby
jdoles_ is now known as jdoles
sam113102 is now known as sam113101
drawingthesun has joined #ruby
Adran has joined #ruby
peeja_ has joined #ruby
peeja_ is now known as peeja
sam113101 has quit [Changing host]
sam113101 has joined #ruby
Mattias has joined #ruby
Slavox has joined #ruby
mburns has joined #ruby
M-Technic has joined #ruby
SirFunk has joined #ruby
jrhorn424 is now known as zz_jrhorn424
hsps_ has joined #ruby
<Mon_Ouie> You should ask that question in #rubyonrails
gattuso has joined #ruby
Eiam has joined #ruby
banisterfiend has quit [Quit: Computer has gone to sleep.]
pietr0 has quit [Quit: pietr0]
everett has joined #ruby
Schmidt has joined #ruby
TheMoonMaster has joined #ruby
ra4king has joined #ruby
heftig has joined #ruby
hl has joined #ruby
brandonshowers has joined #ruby
Kabaka has joined #ruby
clamstar has joined #ruby
brandonshowers has quit [Client Quit]
bunnicula has quit [Ping timeout: 256 seconds]
omenks has joined #ruby
Beoran has joined #ruby
<mspah_> thanks Mon
mspah_ has quit [Quit: Leaving]
Zebroid has joined #ruby
k0m has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jrhe has joined #ruby
rails_flix has quit [Quit: This computer has gone to sleep]
Emmanuel_Chanel has quit [Read error: Connection reset by peer]
Emmanuel_Chanel has joined #ruby
omenks has quit []
bunnicula has joined #ruby
d4nk has quit [Read error: Connection reset by peer]
Zebroid has quit [Ping timeout: 250 seconds]
Wolland has quit [Read error: Connection reset by peer]
rails_flix has joined #ruby
d4nk has joined #ruby
Mon_Robot has quit [Ping timeout: 240 seconds]
dawkirst_ has quit [Ping timeout: 240 seconds]
dawkirst has joined #ruby
kavinder has quit [Remote host closed the connection]
asmodlol has quit [Quit: Leaving]
thams has joined #ruby
Lingo has joined #ruby
Avahey_ has joined #ruby
kavinder has joined #ruby
razorgfx has joined #ruby
hectorrr has quit [Remote host closed the connection]
zorak has joined #ruby
razorgfx has quit [Client Quit]
hectorrr has joined #ruby
razorgfx has joined #ruby
razorgfx has quit [Client Quit]
ping-pong has joined #ruby
razorgfx has joined #ruby
razorgfx has quit [Client Quit]
kavinder_ has joined #ruby
razorgfx has joined #ruby
thumpba has quit [Remote host closed the connection]
Bira has quit [Remote host closed the connection]
GriffinHeart has joined #ruby
kavinder has quit [Ping timeout: 245 seconds]
s2013 has joined #ruby
Channel6 has joined #ruby
thumpba has joined #ruby
razorgfx has quit [Client Quit]
hectorrr has quit [Ping timeout: 260 seconds]
robscormack has quit [Quit: Leaving]
thumpba has quit [Ping timeout: 255 seconds]
GriffinHeart has quit [Ping timeout: 264 seconds]
xmad has quit [Ping timeout: 240 seconds]
rails_flix has quit [Quit: This computer has gone to sleep]
kmels has quit [Ping timeout: 250 seconds]
mary5030_ has quit [Remote host closed the connection]
sailias has joined #ruby
awc737 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mikecmpbll has quit [Quit: ciao.]
awc737 has joined #ruby
awc737 has quit [Client Quit]
awc737 has joined #ruby
nateberkopec has joined #ruby
EMoreth has quit [Quit: Lingo - http://www.lingoirc.com]
rails_flix has joined #ruby
WormDrink has quit [Ping timeout: 255 seconds]