apeiros_ changed the topic of #ruby to: Ruby 1.9.3-p286: http://ruby-lang.org || Paste >3 lines of text on http://gist.github.com
Takehiro has quit [Ping timeout: 244 seconds]
yaymukund has joined #ruby
workmad3 has quit [Ping timeout: 272 seconds]
hiroyuki has quit [Remote host closed the connection]
CodeVision has quit [Quit: WeeChat 0.3.9]
Bosma has quit [Quit: leaving]
<ryanf> RYanNielson: yeah, you want nokogiri
hoofman has quit [Ping timeout: 260 seconds]
clj_newb has quit [Ping timeout: 272 seconds]
GVRV has joined #ruby
alvaro_o_ has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
stephh has joined #ruby
alvaro_o has quit [Read error: Connection reset by peer]
MentalGrinds has quit [Quit: MentalGrinds]
ngoldman has quit [Remote host closed the connection]
<ryannielson> ryanf: Ya, seemed like the solution I just wanted to be sure. Thanks!
LouisGB has quit []
ngoldman has joined #ruby
Tarential has joined #ruby
shammancer has quit [Remote host closed the connection]
kendrick_ has joined #ruby
hadees has quit [Quit: hadees]
nari_ has quit [Ping timeout: 256 seconds]
joeycarmello has joined #ruby
swarley has quit [Ping timeout: 246 seconds]
judd7 has quit [Quit: judd7]
tomsthumb has quit [Quit: Leaving.]
irleif has joined #ruby
heriC has joined #ruby
kendrick has quit [Ping timeout: 246 seconds]
heriC has left #ruby [#ruby]
jonathanwallace has joined #ruby
ryannielson has quit [Quit: Page closed]
ngoldman has quit [Ping timeout: 265 seconds]
reuf has joined #ruby
jamjam has quit [Ping timeout: 240 seconds]
Ktaze has quit [Quit: Leaving]
Bosox20051 has joined #ruby
r1ddl3r has joined #ruby
Synthead has joined #ruby
MentalGrinds has joined #ruby
dmiller has quit [Remote host closed the connection]
v0n has joined #ruby
justinmc_ has joined #ruby
csalvato has quit [Quit: csalvato]
CodeVision has joined #ruby
justinmcp has quit [Ping timeout: 260 seconds]
Spooner_ has joined #ruby
ephemerian has quit [Quit: Leaving.]
Spooner has quit [Ping timeout: 246 seconds]
irleif has quit [Quit: Computer has gone to sleep.]
icole has joined #ruby
reset has quit [Ping timeout: 272 seconds]
fbernier has quit [Quit: ZNC - http://znc.in]
bigmcq77 has joined #ruby
c0rn_ has joined #ruby
nwest_ has joined #ruby
cbuxton has quit [Ping timeout: 246 seconds]
r1ddl3r has quit [Quit: Leaving.]
h4mz1d has quit [Ping timeout: 252 seconds]
davidcelis has quit [Quit: K-Lined.]
TomJ has joined #ruby
Takehiro has joined #ruby
swarley has joined #ruby
swarley_ has joined #ruby
ryannielson has joined #ruby
irleif has joined #ruby
<ryannielson> So I managed to get a pages html with Nokogiri, and add an element. I then use to_html to return it and it renders the page. The only issue is images that were simply /image.jpg instead of the whole sites url, are broken because it's trying to get /image.jpg from me locally. Any way around that?
<swarley_> everyone calm down, i'm back now
<matti> swarley_: Yay!
<swarley_> :D
ryanf has quit [Quit: leaving]
swarley has quit [Disconnected by services]
swarley has joined #ruby
hbpoison has joined #ruby
swarley has quit [Disconnected by services]
swarley_ is now known as swarley
swarley| has joined #ruby
brianpWins has quit [Quit: brianpWins]
savage- has quit [Remote host closed the connection]
jitesh_shetty has quit [Remote host closed the connection]
irleif has quit [Client Quit]
Michae___ has joined #ruby
Takehiro has quit [Remote host closed the connection]
bigmcq77 has quit [Quit: Computer has gone to sleep.]
bradhe has quit [Remote host closed the connection]
Foxandxss has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
hbpoison has quit [Ping timeout: 246 seconds]
nyrb has joined #ruby
hadees has joined #ruby
xbayrockx has joined #ruby
w2f2 has quit [Read error: Connection reset by peer]
arubin has joined #ruby
iamjarvo has quit [Ping timeout: 245 seconds]
_Rui_ has joined #ruby
aantix has quit [Ping timeout: 246 seconds]
maletor has quit [Quit: Computer has gone to sleep.]
_Rui_ has left #ruby [#ruby]
robertotauille has joined #ruby
rcosta has joined #ruby
iamjarvo has joined #ruby
kiyoura has joined #ruby
MentalGrinds has quit [Quit: MentalGrinds]
xbayrockx has quit [Ping timeout: 246 seconds]
Konboi has joined #ruby
bricker has quit [Ping timeout: 260 seconds]
LouisGB has joined #ruby
stkowski has quit [Quit: stkowski]
SegFaultAX|work has quit [Ping timeout: 272 seconds]
judd7 has joined #ruby
dpatel has quit [Quit: dpatel]
tjbiddle has quit [Ping timeout: 272 seconds]
drago757 has joined #ruby
c0rn_ has quit [Quit: Computer has gone to sleep.]
dylanjha has joined #ruby
bradhe has joined #ruby
ryanf has joined #ruby
apok has quit [Ping timeout: 260 seconds]
JonnieCache has joined #ruby
drago757 has quit [Ping timeout: 260 seconds]
<Spooner_> RyanNielson You can access Img/src and set the fully qualified address. You know what the page's original address was so you just need to add the rest of the URI before the image.
mahmoudimus has quit [Quit: Computer has gone to sleep.]
samphippen has quit [Quit: Computer has gone to sleep.]
<ryannielson> Spoonder_: Ya, I thought of that after I wrote teh question. Thne ya, used URI to fix any relative image links. :) Thanks
<Spooner_> RyanNielson: THought you mighjt have worked it out by the time I looked at #ruby again, but thought I'd poke you in case you hadn't ;)
stephh has quit [Ping timeout: 252 seconds]
<ryannielson> Spooner_: Ya, I appreciate the help. If I didn't figure it out, that would have helped me immensely.
artOfWar has quit [Remote host closed the connection]
judd7_ has joined #ruby
judd7_ has quit [Client Quit]
stephh has joined #ruby
mahmoudimus has joined #ruby
rburton- has quit [Quit: Leaving...]
xbayrockx has joined #ruby
manizzle has quit [Ping timeout: 260 seconds]
daniel_- has quit [Quit: WeeChat 0.3.9]
sjuxax has joined #ruby
judd7 has quit [Ping timeout: 245 seconds]
yshh has joined #ruby
xaq has joined #ruby
<sjuxax> Hi all. I need something like setuid to a non-privileged user. It is my understanding that setuid can only be used by root, so I don't want to use it directly. Basically, I want to replace the shell with the shell of the right user, if possible. I tried calling su with Process::spawn, but the program just waits until I exit that shell to continue.
<sjuxax> Is there a way to do this, or am I going to have to use setuid?
v0n has quit [Read error: Operation timed out]
hbpoison has joined #ruby
nwest_ has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
<heftig> sjuxax: replace what shell?
rakl has quit [Quit: sleeping]
Astral has joined #ruby
<sjuxax> The shell that I ran "ruby ..." from. Basically, I want to drop privileges, set uid on the script before its execution continues
Astral is now known as Guest17270
<sjuxax> as not root
icole has quit [Remote host closed the connection]
<heftig> if you're not root, you have no privileges to drop
kiyoura has quit [Quit: Leaving]
<heftig> (well, barring setcap, but that's rare)
kiyoura has joined #ruby
Bosma has joined #ruby
ryannielson has quit [Ping timeout: 245 seconds]
Astral_ has quit [Ping timeout: 265 seconds]
drago757 has joined #ruby
<sjuxax> Right, "drop user" I guess. ;)
walbert has quit [Remote host closed the connection]
<heftig> you need root to change user
<heftig> (helpers like su and sudo are setuid root)
heriC has joined #ruby
baphled has joined #ruby
heriC has left #ruby [#ruby]
Bosox20051 has quit [Remote host closed the connection]
<sjuxax> Yeah. I was hoping there was some su trickery I could use to change the process without running the script itself as root, because I have passwordless sudo configured. In Ruby, it seems Process::Sys.setuid would work, but I don't know how to say "do this to process id xxx", and feed the current pid in. Seems I have to spawn a process for it to be effective.
<heftig> you can
<heftig> you can't do that
bigmcq77 has joined #ruby
khakimov has joined #ruby
<sjuxax> heftig: OK, thanks.
<sjuxax> Is there a way to setuid on current process with Ruby's setuid stuff? It seems designed only to work on spawned processes.
reset has joined #ruby
reset has quit [Read error: Connection reset by peer]
sent-hil has joined #ruby
gabrielrotbart has quit [Remote host closed the connection]
roadt has joined #ruby
MentalGrinds has joined #ruby
<heftig> sjuxax: setuid always affects the current process
sn0wb1rd has quit [Quit: sn0wb1rd]
<nesoi> hi, what's a good and easy way to send mail from a ruby program?
<matti> nesoi: Net::SMTP?
<matti> nesoi: Simple API.
endzyme has quit [Remote host closed the connection]
jxf has quit [Read error: Connection reset by peer]
stephenjudkins has quit [Quit: stephenjudkins]
miso1337 has joined #ruby
<nesoi> thanks matti. any idea where I'd find documentation/examples?
<matti> nesoi: Sue.
<matti> Sure*
mahmoudimus has quit [Quit: Computer has gone to sleep.]
<matti> nesoi: If you Google for "net::smtp ruby example" you will get a lot of takes ;]
<matti> Night folks ;]
<kiyoura> night
<matti> tx kiyoura ;]
<nesoi> thanks matti
ElderFain has joined #ruby
ElderFain_ has quit [Ping timeout: 272 seconds]
<sakh> how can I exclude a keyword from a [a-zA-Z]* domain in regexp
xaq has quit [Remote host closed the connection]
rcosta has quit [Remote host closed the connection]
ofcom has quit [Quit: IRC is just multiplayer notepad]
tos9 has quit [Excess Flood]
icole has joined #ruby
judd7 has joined #ruby
tos9 has joined #ruby
`brendan has joined #ruby
jxf has joined #ruby
chimkan has joined #ruby
nesoi has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
<Spooner_> sakh : Pretty sure you can't, but you could apply another regexp to exclude it (depending on what you are using the regexp for).
chimkan has quit [Client Quit]
punkrawkR has quit [Read error: Connection reset by peer]
Michae___ has quit [Remote host closed the connection]
chin-tastic has quit [Ping timeout: 252 seconds]
punkrawkR has joined #ruby
Michael__ has joined #ruby
ttt has joined #ruby
MentalGrinds has quit [Quit: MentalGrinds]
nari_ has joined #ruby
Guest17270 has quit [Ping timeout: 276 seconds]
stephenjudkins has joined #ruby
MildNerd has quit [Quit: MildNerd]
UberNerdGirl has joined #ruby
Monie has quit [Ping timeout: 244 seconds]
ckrailo has quit [Quit: Computer has gone to sleep.]
chimkan_ has joined #ruby
MentalGrinds has joined #ruby
artnez has joined #ruby
bradhe has quit [Remote host closed the connection]
UberNerdGirl has quit [Quit: UberNerdGirl]
UberNerdGirl has joined #ruby
graeme has quit [Quit: graeme]
Michael__ has quit [Remote host closed the connection]
ryanf has quit [Ping timeout: 255 seconds]
hadees has quit [Quit: hadees]
sjuxax has left #ruby [#ruby]
jipiboily is now known as jipiboily-zzzzzz
chin-tastic has joined #ruby
katherinem13 has quit [Quit: Might IS right.]
dmerrick has quit [Quit: dmerrick]
katherinem13 has joined #ruby
zodiak has joined #ruby
judd7 has quit [Quit: judd7]
hadees has joined #ruby
Michael__ has joined #ruby
heftig has quit [Quit: leaving]
sambio has quit []
gabrielrotbart has joined #ruby
sn0wb1rd has joined #ruby
dylanjha has quit [Quit: Leaving...]
nateberkopec has quit [Quit: Linkinus - http://linkinus.com]
sn0wb1rd_ has joined #ruby
heftig has joined #ruby
judd7 has joined #ruby
cakehero has quit [Quit: Computer has gone to sleep.]
sn0wb1rd has quit [Ping timeout: 244 seconds]
banisterfiend has joined #ruby
freezey has joined #ruby
<banisterfiend> any ruby core members here?
Goles has joined #ruby
axl__ has quit [Quit: axl__]
sn0wb1rd has joined #ruby
sn0wb1rd_ has quit [Ping timeout: 256 seconds]
<swarley> sweet, parser is done.. i think
<swarley> now i have to figure out how the hell to make this thread safe..
sn0wb1rd has quit [Read error: Connection reset by peer]
sn0wb1rd has joined #ruby
recycle has joined #ruby
Guest80824 has quit [Quit: Konversation terminated!]
Guest80824 has joined #ruby
sn0wb1rd has quit [Remote host closed the connection]
<sent-hil> if i wanted to get class instance variables using binding.eval, what arg do I send?
<sent-hil> binding.eval('local_variables') and binding.eval('global_variables') worked
lledet has joined #ruby
chrishunt has quit [Ping timeout: 268 seconds]
Michael__ has quit [Remote host closed the connection]
Guest80824 has quit [Ping timeout: 248 seconds]
jxf has quit [Ping timeout: 256 seconds]
<banisterfiend> sent-hil: binding.eval("instance_variables")
<banisterfiend> where 'binding' has self set to a class
<sent-hil> banisterfiend: ah cool, thx
<Spooner_> sent-hil : class instance variables don't exist, per se, in Ruby. They would be self.class.instance_variables
radic_ has quit [Read error: Connection reset by peer]
UberNerdGirl has quit [Quit: UberNerdGirl]
radic has joined #ruby
<swarley> is there a way to enforce mutex within a class itself?.. this probably isnt good practice but until i can find a way to make this thread safe there is just no way
<swarley> Ah, i'm dumb
voodoofish430 has quit [Quit: Leaving.]
<swarley> Yes, i know the answer to the mutex question
<swarley> carry on
Michael__ has joined #ruby
Takehiro_ has joined #ruby
Takehiro_ has quit [Remote host closed the connection]
judd7 has quit [Quit: judd7]
cbuxton has joined #ruby
cbuxton has left #ruby [#ruby]
nesoi has joined #ruby
stephenjudkins has quit [Quit: stephenjudkins]
<nesoi> so what's a good way to do a mailmerge kind of thing in ruby? I want to send an email to recepients from a database, and fill in their name and other details in each message.
baphled has quit [Ping timeout: 246 seconds]
stephenjudkins has joined #ruby
lledet has quit [Quit: lledet]
bigmcq77 has quit [Quit: Computer has gone to sleep.]
ryanf has joined #ruby
erichmenge has quit [Quit: Be back later]
<nesoi> another way to ask that is, what's a good way to insert variable information into a string :)
gabrielrotbart has quit [Remote host closed the connection]
caleb_io has joined #ruby
Takehiro_ has joined #ruby
c0rn_ has joined #ruby
icole has quit [Remote host closed the connection]
MentalGrinds has quit [Quit: MentalGrinds]
gabrielrotbart has joined #ruby
icole has joined #ruby
h4mz1d has joined #ruby
mohits has joined #ruby
mohits has quit [Changing host]
mohits has joined #ruby
<swarley> actually, how do i utilize mutex in the C code?
moshee has quit [Ping timeout: 252 seconds]
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
<swarley> well, i guess i could proxy it through a function in ruby
<banisterfiend> nesoi: "%{hello} %{baby}" % {:hello => "pig", :baby => "horse" }
gabrielrotbart has quit [Remote host closed the connection]
<banisterfiend> nesoi: "pig horse"
arietis has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
icole has quit [Remote host closed the connection]
quest88 has joined #ruby
banisterfiend has quit [Remote host closed the connection]
ffranz has quit [Quit: Leaving]
chin-tastic has quit [Ping timeout: 276 seconds]
MentalGrinds has joined #ruby
swarley has quit [Read error: Operation timed out]
medik has quit [Quit: Leaving]
swarley| has quit []
ckrailo has joined #ruby
ngoldman has joined #ruby
ckrailo is now known as ckrailo|dinner
fixl has joined #ruby
mercwithamouth has quit [Ping timeout: 264 seconds]
Vert has quit [Remote host closed the connection]
gabrielrotbart has joined #ruby
ryanf has quit [Quit: leaving]
sent-hil has quit [Remote host closed the connection]
Forevernade has joined #ruby
ForevernadeAFK has joined #ruby
vitor-br has joined #ruby
dmerrick has joined #ruby
LouisGB has quit [Ping timeout: 246 seconds]
MentalGrinds has quit [Quit: MentalGrinds]
krz has joined #ruby
Michael__ has quit [Remote host closed the connection]
Spooner_ has quit [Ping timeout: 256 seconds]
xpen has joined #ruby
Chryson has quit [Quit: Leaving]
dmiller has joined #ruby
chin-tastic has joined #ruby
gabrielrotbart has quit [Remote host closed the connection]
dmerrick has quit [Quit: dmerrick]
c0rn_ has quit []
justinmc_ has quit [Ping timeout: 276 seconds]
justinmcp has joined #ruby
tnk1 has quit [Ping timeout: 246 seconds]
chin-tastic has quit [Ping timeout: 268 seconds]
aajjbb has quit [Remote host closed the connection]
freakazoid0223 has left #ruby ["Leaving"]
LucidDreamZzZ has quit [Quit: Leaving]
bradhe has joined #ruby
bradhe has quit [Read error: Connection reset by peer]
LucidDreamZzZ has joined #ruby
bradhe has joined #ruby
ryanlecompte has joined #ruby
matrixise has joined #ruby
brianpWins has joined #ruby
jalcine has joined #ruby
dmiller has quit [Remote host closed the connection]
mohits has quit [Remote host closed the connection]
xaq has joined #ruby
sayem has joined #ruby
zemanel has quit [Quit: Remote hottie closed the connection]
shammancer has joined #ruby
maletor has joined #ruby
kryl99_ has joined #ruby
minijupe has joined #ruby
wmoxam has joined #ruby
caleb_io has quit [Quit: Leaving...]
robertotauille has quit [Quit: Leaving...]
Progster has quit [Ping timeout: 264 seconds]
<nesoi> hm... so I tried what bannisterfiend suggested, and it worked in his example, but when I try to do something like
chin-tastic has joined #ruby
Takehiro_ has quit [Remote host closed the connection]
cousine has joined #ruby
<nesoi> message = "Hello %{name}, How are you?" and then message = message %{:name => "George Smith"}
<nesoi> I get message_test.rb:19:in `%': unnumbered(1) mixed with named (ArgumentError)
<nesoi> from message_test.rb:19:in `<main>'
jitesh_shetty has joined #ruby
cousine has quit [Remote host closed the connection]
<nesoi> any idea how to do the substitution?
<heftig> what's your format string?
kryl99_ has quit [Quit: Colloquy for iPad - http://colloquy.mobi]
<nesoi> oops format string?
<nesoi> what's this called? I'll look up some documentation on it
elsifaka has quit [Read error: Connection reset by peer]
elsifaka has joined #ruby
slainer68 has joined #ruby
xaq has quit [Remote host closed the connection]
dakine has joined #ruby
cableray has quit [Quit: cableray]
JonnieCache has quit [Ping timeout: 276 seconds]
chimkan__ has joined #ruby
rellin has joined #ruby
kamsky has joined #ruby
<kamsky> sup folks
chimkan_ has quit [Ping timeout: 265 seconds]
macmartine has joined #ruby
slainer68 has quit [Ping timeout: 265 seconds]
<nesoi> can one assign a multi-line string to a variable with "
<nesoi> "
<nesoi> ? or is there some oddness to it?
hbpoison_ has joined #ruby
stephh has quit [Ping timeout: 246 seconds]
<nesoi> if I do this it works:
hbpoison has quit [Ping timeout: 246 seconds]
<nesoi> message_text = "Dear %{name}, how are you?"
<nesoi> message_formatted = message_text %{:name => "George Smith"}
<nesoi> if message_text contains a multi-line string, it fails
epitron_ is now known as epitron
evilsushi has joined #ruby
evilsushi has quit [Changing host]
evilsushi has joined #ruby
evilsushi has left #ruby [#ruby]
gabrielrotbart has joined #ruby
c0rn_ has joined #ruby
Scriptwriter has joined #ruby
Scriptwriter has quit [Client Quit]
c0rn_ has quit [Client Quit]
kiyoura has quit [Quit: Leaving]
hbpoison has joined #ruby
hbpoison_ has quit [Ping timeout: 256 seconds]
mneorr_ has joined #ruby
skaczor has quit [Read error: Operation timed out]
mneorr has quit [Ping timeout: 276 seconds]
jamesaxl has quit [Ping timeout: 240 seconds]
jamesaxl has joined #ruby
wtfleming has quit [Quit: Leaving]
dmiller has joined #ruby
chin-tastic has quit [Remote host closed the connection]
chin-tastic has joined #ruby
rabidpraxis has quit [Remote host closed the connection]
dmiller_ has joined #ruby
mneorr_ has quit [Remote host closed the connection]
mneorr has joined #ruby
h4mz1d has quit [Ping timeout: 260 seconds]
ForevernadeAFK has quit [Remote host closed the connection]
makeawish has quit []
jamesaxl has quit [Ping timeout: 246 seconds]
gabrielrotbart has quit [Remote host closed the connection]
dmiller has quit [Ping timeout: 260 seconds]
xor_mind- has joined #ruby
macmartine has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
rburton- has joined #ruby
burgestrand has joined #ruby
xor_mind- has quit [Read error: Connection reset by peer]
xor_mind- has joined #ruby
hbpoison has quit [Ping timeout: 245 seconds]
kyletcarey has quit [Ping timeout: 260 seconds]
rburton- has quit [Client Quit]
xor_mind- has quit [Read error: Connection reset by peer]
nesoi has left #ruby ["I'm a happy Miranda IM user! Get it here: http://miranda-im.org"]
maletor has quit [Quit: Computer has gone to sleep.]
xor_mind- has joined #ruby
jrist is now known as jrist-out
nesoi has joined #ruby
<nesoi> can someone take a look at this very short code and tell me why I get this error message:
<nesoi> message_test.rb:22:in `%': unnumbered(1) mixed with named (ArgumentError)
<nesoi> from message_test.rb:22:in `<main>'
xor_mind- has quit [Read error: Connection reset by peer]
kamsky has left #ruby ["Leaving"]
joeycarmello has quit [Remote host closed the connection]
xor_mind- has joined #ruby
<nesoi> can someone take a look at this very short code and tell me why I get this error message:
<nesoi> message_test.rb:22:in `%': unnumbered(1) mixed with named (ArgumentError)
<nesoi> from message_test.rb:22:in `<main>'
siyusong has joined #ruby
xor_mind- has quit [Read error: Connection reset by peer]
dmiller_ has quit [Remote host closed the connection]
harushimo has left #ruby ["Leaving"]
xor_mind- has joined #ruby
grizlo42 has joined #ruby
mando has joined #ruby
h4mz1d has joined #ruby
baroquebobcat has joined #ruby
xor_mind- has quit [Read error: Connection reset by peer]
xpen has quit [Remote host closed the connection]
burgestrand has quit [Quit: Leaving.]
h4mz1d has quit [Ping timeout: 246 seconds]
sayem has quit [Remote host closed the connection]
gabrielrotbart has joined #ruby
hekin has joined #ruby
ZubKonst has joined #ruby
nesoi has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
rakl has joined #ruby
nesoi has joined #ruby
<nesoi> was I coming through or was I blocked somehow?
<emdub> nesoi: what are you trying to do there?
<nesoi> I'm trying to do a mail merge - have a message and then put stuff into it based on who it's going to
chimkan__ has quit [Quit: chimkan__]
ZubKonst_ has quit [Ping timeout: 246 seconds]
<nesoi> what do you think emdub?
Vinz_` is now known as Vinz_
<emdub> i think you're doing something very wrong :)
<nesoi> ok, but what's a good way to do it?
<emdub> or what you're doing is way above my head!
<nesoi> really? I have no idea what I'm doing. I Just want to substitute variable information into the middle of a text string
<emdub> well, if you're trying to replace text in a string, you could do "Hello %s" % "world"
<nesoi> that doesn't seem to work in a multi-line string
<emdub> why not?
<emdub> that seems to work?
<nesoi> message_test.rb:22:in `%': unnumbered(1) mixed with named (ArgumentError)
<nesoi> from message_test.rb:22:in `<main>'
<nesoi> hmm.. but how would I do it for named variables?
<nesoi> like name, etc.
<emdub> replace "fred" with name
<emdub> (no quotes)
<nesoi> no, I mean "Hello %name, thank you for %activity" etc.
<nesoi> or however to do it
<emdub> if you want string interpolation like that you need to use #{variable}
<emdub> so "Hello, my name is #{name}"
hbpoison has joined #ruby
mneorr has quit [Remote host closed the connection]
<nesoi> this is what didn't work: https://gist.github.com/5c46fbea35c5d918449d
mneorr has joined #ruby
TomJ has quit [Quit: TomJ]
<nesoi> so do #{name} and then what's the syntax for substituting it?
<emdub> when you have a string, say "Hello, my name is #{name}", ruby will automatically put the value of the variable name in place of the #{name} portion
<nesoi> with what syntax?
<emdub> so if you did new string = "Hello, my name is #{name}"
<emdub> and name = "fred"
<emdub> string would be "Hello, my name is fred"
<nesoi> what about when I want name to be "george" later?
<emdub> well, if you want to be able to change the name, i'd probably make a method to do it, something like this (sec)
jjang has quit [Remote host closed the connection]
<nesoi> yeah #{name} doesn't work unless name is defined first
<nesoi> I need to define the string first, then put in different values and output in a loop
karstensrage has joined #ruby
karstensrage has quit [Max SendQ exceeded]
Vinz_ is now known as Vinz_`
<nesoi> ah cool, that will do it. I can make that the send message routine and have the message parameters passed in as values
<nesoi> thanks!
<emdub> sure
<nesoi> that will work with a multiline string?
<emdub> sure
manizzle has joined #ruby
<emdub> if the goal is just to pass a name to a method and get a string back that's modified, reload the pastie
<emdub> that way you can do new_message = hello("fred") and new_message will be your modified string
<nesoi> hm. same pastie
<emdub> it changed the url on me
<nesoi> nice
<nesoi> thanks
<nesoi> !
<emdub> welcome
Targen has quit [Ping timeout: 246 seconds]
davidcelis has joined #ruby
<nesoi> odd that people don't use that approach more. I looked this up and found all kinds of complicated ways to do it
<nesoi> emdub : how would I make a default value for the variables in case they are not supplied to the routine or are null
gabrielrotbart has quit [Remote host closed the connection]
<nesoi> ?
<emdub> you'd do def hello(name="john")
<emdub> and if name wasn't passed to hello, it would be "john"
<Paradox> def goodbye { exit }
chin-tastic has quit [Ping timeout: 240 seconds]
<nesoi> thanks Paradox!
<nesoi> I mean, thanks emdub
<emdub> that only works if the variable isn't passed, passing nil is perfectly valid
<emdub> if you did, hello(nil), name would be nil
gabrielrotbart has joined #ruby
<emdub> you should put some logic around your calls to the hello method to make sure that name is valid, if you have concerns about the input being bogus
<nesoi> hm. it still seems to requrie both variabls
<nesoi> variables
<emdub> not sure what you mean both variables
<nesoi> I mean a parameter
<emdub> are you trying to have multiple params with default values?
<emdub> and only passing some of them?
<nesoi> yeah, just in case
<emdub> that gets a bit more complex
FifthWall has joined #ruby
<nesoi> actually it doesn't accept nil, it wants a string
<emdub> well sure, if you pass nil it's going to barf
<emdub> :)
<emdub> but that doesn't mean name isn't nil
Forevernade has left #ruby ["http://quassel-irc.org - Chat comfortably. Anywhere."]
stephh has joined #ruby
<nesoi> hm
MentalGrinds has joined #ruby
`brendan has quit [Ping timeout: 255 seconds]
tonini has joined #ruby
a_a_g has joined #ruby
rakm has quit [Ping timeout: 256 seconds]
rakm has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
rabidpraxis has joined #ruby
rabidpraxis has quit [Ping timeout: 264 seconds]
pdelgallego has joined #ruby
burgestrand has joined #ruby
MentalGrinds has quit [Quit: MentalGrinds]
arubin has quit [Quit: Computer has gone to sleep.]
hekin has quit [Quit: hekin]
sepp2k has joined #ruby
tjbiddle has joined #ruby
justinmcp has quit [Ping timeout: 260 seconds]
stat1x has joined #ruby
cakehero has joined #ruby
statix_ has quit [Ping timeout: 245 seconds]
joeycarmello has joined #ruby
justinmcp has joined #ruby
ckrailo|dinner is now known as ckrailo
jitesh_shetty has quit [Remote host closed the connection]
jgonzalezd has quit [Quit: jgonzalezd]
bapa has joined #ruby
answer_42 has joined #ruby
joeycarmello has quit [Ping timeout: 252 seconds]
a_a_g1 has joined #ruby
a_a_g has quit [Read error: Connection reset by peer]
pdelgallego has quit [Quit: pdelgallego]
areil has joined #ruby
gabrielrotbart has quit [Remote host closed the connection]
mikepack has joined #ruby
JohnBat26 has joined #ruby
MentalGrinds has joined #ruby
mucker has joined #ruby
MentalGrinds has quit [Read error: Connection reset by peer]
Targen has joined #ruby
siyusong has quit [Quit: Computer has gone to sleep.]
haxrbyte has joined #ruby
haxrbyte_ has joined #ruby
nesoi has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
havenn has joined #ruby
ryanf has joined #ruby
haxrbyte has quit [Ping timeout: 264 seconds]
drago757 has quit [Quit: drago757]
bapa has quit [Ping timeout: 246 seconds]
bradhe has quit [Remote host closed the connection]
JonnieCache has joined #ruby
bapa has joined #ruby
_cheney2 has quit [Ping timeout: 240 seconds]
_cheney has joined #ruby
mmlac has joined #ruby
quest88 has quit [Quit: quest88]
matrixise has quit [Read error: Operation timed out]
jonathanwallace has quit [Remote host closed the connection]
nemesit has joined #ruby
bapa has quit [Ping timeout: 246 seconds]
dnyy has quit [Remote host closed the connection]
justinmcp has quit [Remote host closed the connection]
UberNerdGirl has joined #ruby
dnyy has joined #ruby
stephh has quit [Ping timeout: 244 seconds]
Goles has quit [Ping timeout: 244 seconds]
jamesaxl has joined #ruby
ananthakumaran has joined #ruby
bapa has joined #ruby
vlad_starkov has joined #ruby
dnyy has quit [Remote host closed the connection]
ngoldman_ has joined #ruby
ngoldman_ has quit [Remote host closed the connection]
margle has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
vlad_starkov has joined #ruby
bapa has quit [Ping timeout: 265 seconds]
mando has quit [Remote host closed the connection]
xbayrockx has quit [Read error: Connection reset by peer]
xbayrockx has joined #ruby
justinmcp has joined #ruby
arkiver has joined #ruby
drago757 has joined #ruby
ryanlecompte has quit [Remote host closed the connection]
brianpWins has quit [Quit: brianpWins]
UberNerdGirl has quit [Quit: UberNerdGirl]
nai has joined #ruby
lewis has joined #ruby
<lewis> hi
<lewis> HI
lewis has quit [Changing host]
lewis has joined #ruby
drago757 has quit [Quit: drago757]
piotr_ has joined #ruby
<Paradox> HI
<Paradox> puts "hi"
dr_bob has joined #ruby
apple has joined #ruby
Morkel has joined #ruby
cakehero has quit [Ping timeout: 255 seconds]
zigomir has joined #ruby
joofsh has quit [Remote host closed the connection]
<TTilus> 'hi'.display
<apple> hey
justinmcp has quit [Ping timeout: 248 seconds]
maletor has joined #ruby
maesbn has joined #ruby
justinmcp has joined #ruby
jenrzzz has joined #ruby
codefyre has joined #ruby
cakehero has joined #ruby
bradhe has joined #ruby
glyytchy has joined #ruby
ryanf has quit [Quit: broken pipes |||]
timonv has joined #ruby
RudyValencia has joined #ruby
rakunHo has joined #ruby
nemesit|osx has joined #ruby
aganov has joined #ruby
bairui has quit [Ping timeout: 252 seconds]
cakehero has quit [Quit: Computer has gone to sleep.]
nai has quit [Ping timeout: 272 seconds]
siyusong has joined #ruby
<dr_bob> p "Good morning!"
Banistergalaxy has joined #ruby
<Banistergalaxy> Hey bids
<Banistergalaxy> Boys*
<apple> hello
arturaz has joined #ruby
nemesit has quit [Ping timeout: 248 seconds]
<Banistergalaxy> Another steve jobs fanboy?;)
codefyre has quit [Quit: Leaving]
<apple> went in with the default name :P
jayeshsidhwani has joined #ruby
<dr_bob> like orange?
bairui has joined #ruby
<Banistergalaxy> Dr_bob use pry pls
Virunga has joined #ruby
georgi has joined #ruby
jenrzzz has quit [Ping timeout: 276 seconds]
Morkel has quit [Read error: Operation timed out]
jayeshsidhwani has quit [Quit: jayeshsidhwani]
grizlo42 has left #ruby [#ruby]
Morkel has joined #ruby
hotovson has joined #ruby
timonv has quit [Remote host closed the connection]
sspiff has joined #ruby
pdelgallego has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
margle has quit [Quit: Computer has gone to sleep.]
thone has joined #ruby
mikepack has quit [Remote host closed the connection]
Virunga has quit [Remote host closed the connection]
v0n has joined #ruby
artnez has quit [Quit: artnez]
margle has joined #ruby
Synthead has quit [Quit: p33 ba115]
thone_ has quit [Ping timeout: 260 seconds]
GeekOnCoffee has quit [Ping timeout: 244 seconds]
mahmoudimus has joined #ruby
Virunga has joined #ruby
havenn has quit [Remote host closed the connection]
GeekOnCoffee has joined #ruby
stephh has joined #ruby
jenrzzz has joined #ruby
djdb has joined #ruby
Takehiro_ has joined #ruby
matrixise has joined #ruby
xorigin has joined #ruby
mahmoudimus has quit [Quit: Computer has gone to sleep.]
nemesit|osx has quit [Read error: Connection reset by peer]
pdelgallego has quit [Remote host closed the connection]
nemesit has joined #ruby
dhruvasagar has joined #ruby
FifthWall has quit [Quit: Zzzzzzzzzzzzz]
und3f has joined #ruby
jenrzzz has quit [Ping timeout: 256 seconds]
pdelgallego has joined #ruby
jayeshsidhwani has joined #ruby
stephh has quit [Ping timeout: 248 seconds]
<rking> Hrm. I wonder what systems have the "INFO" signal. E.g. ruby -e 'p Signal.list'
<apple> any good open source repos that a new-mid level rubyist can contribute to?
ephemerian has joined #ruby
<rking> apple: There are thousands. What are you interested in?
<apple> something which a new-mid level guy ilk eme can spend a week to get a hang of the code and start writing features or do bug fixes
<apple> have any repos in mind?
<apple> or have ur own?
ryanf has joined #ruby
khakimov has quit [Quit: Computer has gone to sleep.]
Takehiro_ has quit [Remote host closed the connection]
<rking> Hehe, that would be so self-serving if I was to draw you into my labyrinth of pain, suffering, and vain ambitions.
<rking> But do you have a Github account?
Monie has joined #ruby
Monie has joined #ruby
Monie has quit [Changing host]
tchebb has quit [Ping timeout: 255 seconds]
Banistergalaxy has quit [Ping timeout: 252 seconds]
glyytchy has quit [Ping timeout: 244 seconds]
ryanf has quit [Quit: leaving]
ryanf has joined #ruby
bluOxigen has joined #ruby
siyusong has quit [Quit: Computer has gone to sleep.]
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
freezey has quit [Quit: freezey]
mneorr has quit [Remote host closed the connection]
mneorr has joined #ruby
tnk1 has joined #ruby
<burgestrand> apple: %
<burgestrand> Uh. ^
ckrailo has quit [Quit: Computer has gone to sleep.]
<apple> yes
<apple> murtuzakz is my handle
chin-tastic has joined #ruby
<burgestrand> apple: if I were you I’d find a project I enjoy using, look at the issues, possibly mail the maintainer (or mailing list) and just contribute something, even if it’s just a fix for trailing whitespace.
mneorr has quit [Remote host closed the connection]
<burgestrand> You don’t necessarily need to understand the entirety of a project to contribute it.
mneorr has joined #ruby
<apple> i forked out some projects like capistrano etc
<apple> but got lost in code
<apple> and heirarchy
<burgestrand> Documentation is often easy to start with. ^^
arkiver has quit [Quit: Leaving]
margle has left #ruby ["Textual IRC Client: http://www.textualapp.com/"]
banisterfiend has joined #ruby
<rking> That's very true
<apple> u have some small-mid sized repos in mind
<rking> If you go through some amount of suffering to learn some software, you can leave a trail for the next guy (and save the developers some time, while also getting feedback from them on what you produce)
peterhellberg has joined #ruby
chin-tastic has quit [Ping timeout: 272 seconds]
Elhu has joined #ruby
<rking> apple: If you want to learn Pry, its Wiki could definitely use some help from someone new to it.
banisterfiend has quit [Remote host closed the connection]
Banistergalaxy has joined #ruby
tjbiddle has quit [Read error: Connection reset by peer]
_md has joined #ruby
tjbiddle has joined #ruby
tjbiddle has quit [Client Quit]
justinmcp has quit [Remote host closed the connection]
mneorr has quit [Ping timeout: 272 seconds]
hoelzro|away is now known as hoelzro
<JohnBat26> Hello
<JohnBat26> How in ruby send string to stdin other process ?
zmo_ has joined #ruby
QaDeS has joined #ruby
sideshowcoder has joined #ruby
mjbamford has joined #ruby
wallerdev has quit [Quit: wallerdev]
Astral has joined #ruby
love_color_text has quit [Remote host closed the connection]
Astral is now known as Guest82531
AndIrc_32 has joined #ruby
love_color_text has joined #ruby
Pip has quit [Quit: 离开]
AndIrc_32 has left #ruby [#ruby]
mucker has quit [Quit: leaving]
AndIrc_32 has joined #ruby
AndIrc_32 has quit [Client Quit]
Guest80824 has joined #ruby
flight16 has joined #ruby
flight16 has quit [Quit: Leaving]
minijupe has quit [Quit: minijupe]
eldariof has joined #ruby
freeayu__ has joined #ruby
freeayu has quit [Ping timeout: 272 seconds]
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
mneorr has joined #ruby
GeekOnCoffee has quit [Read error: Connection reset by peer]
minijupe has joined #ruby
graeme has joined #ruby
wizard` has quit [Ping timeout: 245 seconds]
elaptics`away is now known as elaptics
elliot_ has joined #ruby
elliot98 has quit [Ping timeout: 240 seconds]
GeekOnCoffee has joined #ruby
minijupe has quit [Quit: minijupe]
Mon_Ouie has quit [Ping timeout: 246 seconds]
Guest80824 has quit [Ping timeout: 248 seconds]
BeLucid_ has joined #ruby
BeLucid has quit [Read error: Connection reset by peer]
hotovson_ has joined #ruby
jgrevich_ has joined #ruby
hotovson has quit [Ping timeout: 246 seconds]
robotmay has joined #ruby
Vainoharhainen has joined #ruby
Virunga has quit [Remote host closed the connection]
_md has quit [Quit: Linkinus - http://linkinus.com]
tommyvyo has quit [Quit: Computer has gone to sleep.]
mneorr has quit [Remote host closed the connection]
Virunga has joined #ruby
rakunHo has quit [Remote host closed the connection]
jgrevich has quit [Ping timeout: 260 seconds]
jgrevich_ is now known as jgrevich
Spooner has joined #ruby
awestroke has joined #ruby
mneorr has joined #ruby
cezar has joined #ruby
cezar has quit [Client Quit]
pskosinski has joined #ruby
xpen has joined #ruby
Xeago has joined #ruby
mneorr has quit [Remote host closed the connection]
JonnieCache has quit [Ping timeout: 276 seconds]
maletor has quit [Quit: Computer has gone to sleep.]
bradhe has quit [Remote host closed the connection]
GVRV has quit [Ping timeout: 240 seconds]
jgrevich has quit [Quit: jgrevich]
Asher has quit [Quit: Leaving.]
timmow has joined #ruby
zmo_ has quit [Ping timeout: 240 seconds]
timonv has joined #ruby
Floydzy has joined #ruby
Asher has joined #ruby
mjbamford has quit [Quit: Leaving...]
Stalebread has joined #ruby
Beoran_ has joined #ruby
pigggie has joined #ruby
simao_ has joined #ruby
simao_ has quit [Client Quit]
pigggie has left #ruby [#ruby]
simao_ has joined #ruby
simao_ has quit [Client Quit]
Beoran__ has quit [Ping timeout: 240 seconds]
francisfish has quit [Remote host closed the connection]
workmad3 has joined #ruby
fantazo has quit [Remote host closed the connection]
berserkr has joined #ruby
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
JonnieCache has joined #ruby
Stalebread has quit [Quit: Leaving]
jenrzzz has joined #ruby
Spooner has quit [Ping timeout: 256 seconds]
pigggie has joined #ruby
Agis__ has joined #ruby
hotovson_ has quit [Remote host closed the connection]
Virunga has quit [Remote host closed the connection]
<Agis__> guys, since when we can write on heroku's filesystem?
vlad_starkov has joined #ruby
robozahn has joined #ruby
tonini has quit [Remote host closed the connection]
Virunga has joined #ruby
Virunga has quit [Remote host closed the connection]
<JonnieCache> since they brought in the new stack
jayeshsidhwani has quit [Quit: jayeshsidhwani]
<JonnieCache> its almost a vps instance now. you can put nginx on it apparently
<Agis__> you mean Cedar?
<JonnieCache> think so
<Agis__> cool
Araxia has quit [Quit: Araxia]
mhi^ has left #ruby [#ruby]
vlad_starkov has quit [Ping timeout: 252 seconds]
miso1337 has quit [Quit: afk]
lkba has quit [Ping timeout: 252 seconds]
<peterhellberg> I just found out about the vim-ruby-xmpfilter plugin, it allows you to run ruby code straight from a vim buffer :)
<peterhellberg> That is "1+1" expands to "1+1 # => 2"
apple has quit [Quit: apple]
<JonnieCache> that is pretty cool
<JonnieCache> i want a sublime plugin that will execute the selected code rather than the whole of the current file
<peterhellberg> Yeah, I thought so too when I saw Avdi use it in RubyTapas
<JonnieCache> the second option is already there in the form of the build system
<hoelzro> peterhellberg: link?
zmo_ has joined #ruby
sagax has joined #ruby
<hoelzro> thanks!
Villadelfia has quit [Remote host closed the connection]
SeySayux has quit [Remote host closed the connection]
SeySayux has joined #ruby
<peterhellberg> JonnieCache: vim-ruby-xmpfilter is able to run only the selected code (visual mode)
Villadelfia has joined #ruby
<JonnieCache> peterhellberg: thats very nice for you. i said a sublime plugin :)
<peterhellberg> JonnieCache: Yeah… :)
<peterhellberg> JonnieCache: How well does the "vim-mode" in Sublime work?
<JonnieCache> peterhellberg: its pretty basic. any proper user of vim will complain that it only supports a fraction of their favourite mortal kombat style keyboard incantations
<peterhellberg> JonnieCache: Haha, good to know :)
<JonnieCache> however the vim mode is entirely implemented in sublime's extension apis so if you really are a proper user of vim it should be pretty trivial to port them
Virunga has joined #ruby
Virunga is now known as LennyLinux
<JonnieCache> for example, https://github.com/SublimeText/VintageEx
<peterhellberg> Sounds neat, but I’ll stick with Vim
<JonnieCache> heh im not trying to convert you (that never works) just spreading information
xpen has quit [Remote host closed the connection]
<peterhellberg> Yes, and I’m grateful for that :)
xpen has joined #ruby
<peterhellberg> I’ve finally figured out how to use RSolr from Sidekiq (Celluloid)
<peterhellberg> Turns out that Celluloid is pretty awesome, and that it doesn’t really care if your code is using blocking i/o… but I did need to open a new connection to Solr for each thread (obviously, but I found it to be a bit tricky to achieve)
kartouch has joined #ruby
<peterhellberg> I can also highly recommend the connection_pool gem
<pigggie> if i have class One with two child classes - Two and Three, what is the preferred way to refer to Two from within the definition for Three? Should I use the whole name "One::Two", or just "Two"?
v0n has quit [Ping timeout: 246 seconds]
mneorr has joined #ruby
justinmcp has joined #ruby
chin-tastic has joined #ruby
<pigggie> Is it just a matter of taste? Or should I avoid one or the other?
<peterhellberg> pigggie: You should try not have low coupling between the classes, possibly by using dependency injection. http://kresimirbojcic.com/2011/11/19/dependency-injection-in-ruby.html
<peterhellberg> s/not/to/
Artheist has joined #ruby
<pigggie> thanks, will have a read!
<peterhellberg> pigggie: Also make sure that you follow the Liskov substitution principle (that is that Two and Three can be used "as" a One)
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
chin-tastic has quit [Ping timeout: 265 seconds]
banisterfiend has joined #ruby
ephemerian has quit [Quit: Leaving.]
<pigggie> peterhellberg: Are subclasses and child classes the same thing? Maybe my terminology is all wrong.
<banisterfiend> pigggie: yeah they are
<peterhellberg> pigggie: And yes, as banisterfiend just confirmed
jayeshsidhwani has joined #ruby
<banisterfiend> pigggie: not to be confused with 'inner class'
<peterhellberg> pigggie: There are often a bunch of different names for the same concepts when it comes to programming
<JonnieCache> inner classes dont exist in ruby right?
<JonnieCache> i mean you can define a class inside a class definition but it doesnt do anything
<pigggie> banisterfiend: So if I refer to a child class or subclass, I'm talking about inheritance (in that case - whoops)
apple has joined #ruby
<pigggie> peterhellberg: Yeah, I'm suddenly rather confused!
<banisterfiend> JonnieCache: yeah they dont really exist, though some people refer to class constants nested under another class to be inner classes
<banisterfiend> if accessed properly you do get access to constants defined in the enclosing class
<banisterfiend> but that's more a function of constant look up rules, not really 'inner class' stuff
<pigggie> banisterfiend: A class defined within a class that provides some sort of service to that class... What would that be called?
<banisterfiend> pigggie: hmm, i dont think we have a name for them really, i guess we call them 'nested classes'
<banisterfiend> we can call them*
<banisterfiend> pigggie: but they dont have any privileged access to data in the enclosing class
<banisterfiend> except for some constants (but again that's a function of constant lookup rules)
<peterhellberg> pigggie: I’m currently reading Practical Object-Oriented Design in Ruby: An Agile Primer by Sandi Metz, and it is shaping up to be a REALLY good book.
under_my_shoes has quit [Quit: Leaving]
robozahn_ has joined #ruby
<pigggie> banisterfiend: So lets substitute "child" for "nested" in my original question, what would the case be then? (I'll repost it if you want)
under_my_shoes has joined #ruby
<banisterfiend> pigggie: repost
jxf has joined #ruby
<pigggie> peterhellberg: Thanks Peter, that sounds like just the kind of thing I need ;)
<banisterfiend> peterhellberg: how does it compare to 'eloquent ruby' ? tell me something cool you learned already :)
<peterhellberg> pigggie: Oh, and you can do something like this for DI: def foo(klass = Bar); klass.do_something; end;
<peterhellberg> banisterfiend: Oh, that was the book I read just before POODR
<pigggie> banisterfiend: Okay, if I have class One with two nested classes (Two and Three), what is the preferred way to refer to Two from wihtin the definition of Three? Should I use the whole name "One::Two", or just "Two"?
robozahn has quit [Ping timeout: 244 seconds]
<banisterfiend> pigggie: it depends how yu open Three
<peterhellberg> banisterfiend: Eloquent was more on the idiomatic side of Ruby, POODR isn’t necessarily limited to Ruby
jenrzzz has quit [Ping timeout: 260 seconds]
<banisterfiend> pigggie: if you open Three like this: class One::Three then you cannot access Two without fully qualifying it as One::Two
<peterhellberg> banisterfiend: As in being more concerned with the design aspects of the system, rather than syntax.
<banisterfiend> pigggie: but if you open Three like this: class One; class Three; then u can access Two without full qualification (i.e just as Two)
beiter has joined #ruby
<banisterfiend> peterhellberg: so it's all about design patterns or what? also, how does it compare to 'refactoring: ruby edition' i have that, too. And it's great
<pigggie> banisterfiend: Ah okay, I see. And is there anything wrong with the latter?
<peterhellberg> banisterfiend: I haven’t read the refactoring book yet, so I can’t really compare the two. (One of my all time favorite Ruby books is 'Design Patterns in Ruby')
<banisterfiend> pigggie: no...i prefer the latter, as i get access to constants defined in One
robozahn_ has quit [Ping timeout: 244 seconds]
<banisterfiend> pigggie: the only advantage in class One::Two is that it maybe looks slightly neater
<banisterfiend> also, u dont have to remember if One is a class or a module :)
<peterhellberg> banisterfiend: From the introduction of POODR: "This book is about designing object-oriented software. It is not an academic tome, it is a programmer’s story about how to write code. It teaches how to arrange software so as to be productive today and to remain so next month and next year."
<banisterfiend> pigggie: so, you can later refactor One from Class to Module or vice versa and it'll still work, but that's rare i guess and not tha tmuch of an advantage
<pigggie> banisterfiend: Yeah, I went through my code using only the second case but in some cases thought the naming wasn't entirely clear without the context so I suppose it's a stylistic thing.
<peterhellberg> pigggie: POODR has a whole chapter on managing dependencies: http://my.safaribooksonline.com/book/programming/ruby/9780132930895
* JonnieCache misses his safari account
bradhe has joined #ruby
<pigggie> peterhellberg: Looks like I've found my next book then!
<peterhellberg> Oh, and it looks like that is the sample chapter (aka: free)
<peterhellberg> :)
robozahn has joined #ruby
<peterhellberg> Sandi is also a great speaker, I met her at Rocky Mountain Ruby this year, and will do so again at Øredev
Zai has joined #ruby
bradhe has quit [Ping timeout: 256 seconds]
<banisterfiend> peterhellberg: what's her name again?
<peterhellberg> banisterfiend: Sandi Metz
<peterhellberg> Good checklist for dependencies: An object has a dependency when it knows he name of another class, the name of a message, the arguments that a message requires, the order of those arguments.
lolmaus has joined #ruby
Agis__ has quit [Quit: Agis__]
djdb has quit [Quit: Ухожу я от вас (xchat 2.4.5 или старше)]
hsbt has quit [Ping timeout: 264 seconds]
hsbt has joined #ruby
SeySayux has quit [Read error: Connection reset by peer]
Villadelfia has quit [Read error: Connection reset by peer]
Zai has quit [Read error: Connection reset by peer]
Progster has joined #ruby
gokul has joined #ruby
<peterhellberg> Also “It is not the class of the object that’s important, it’s the message you plan to send to it.”
<peterhellberg> I should probably stop quoting that book now, but it is just that good :)
zmo_ has quit [Ping timeout: 246 seconds]
<pigggie> It's all appreciated :)
Villadelfia has joined #ruby
SeySayux has joined #ruby
Jellyg00se has quit [Ping timeout: 245 seconds]
<Xeago> peterhellberg: thanks for that checklist
hbpoison has quit [Ping timeout: 245 seconds]
<Xeago> it's usefull
xpen has quit [Remote host closed the connection]
<peterhellberg> Xeago: All thanks to Sandi :)
awestroke has quit [Remote host closed the connection]
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
awestroke has joined #ruby
fermion has joined #ruby
heisenmink has joined #ruby
heisenmink has quit [Read error: Connection reset by peer]
heisenmink has joined #ruby
<Xeago> how much can you read for free there :O?
heisenmink has quit [Read error: Connection reset by peer]
<peterhellberg> Just that chapter, and the introduction
<peterhellberg> The book is absolutely worth buying
heisenmink has joined #ruby
heisenmink has quit [Read error: Connection reset by peer]
heisenmink has joined #ruby
heisenmink has quit [Read error: Connection reset by peer]
margle has joined #ruby
heisenmink has joined #ruby
emergion has joined #ruby
awestroke has quit [Ping timeout: 260 seconds]
Astral_ has joined #ruby
heisenmink has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
x0F_ has joined #ruby
x0F has quit [Disconnected by services]
ecksit has joined #ruby
x0F_ is now known as x0F
awestroke has joined #ruby
hotovson has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
pigggie has quit [Quit: leaving]
awestroke has joined #ruby
justinmcp has quit [Remote host closed the connection]
Eplemosen has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
Guest82531 has quit [Ping timeout: 260 seconds]
awestroke has joined #ruby
dhruvasagar has quit [Quit: Lost terminal]
dhruvasagar has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
Jellyg00se has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
rakl has quit [Ping timeout: 252 seconds]
awestroke has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
<Xeago> why not use a block for initializing stuff?
awestroke has quit [Read error: Connection reset by peer]
dhruvasagar has quit [Client Quit]
awestroke has joined #ruby
<Xeago> Gear.new do chainring=4; cog=19; wheel=Wheel.new; end
<Xeago> ?
awestroke has quit [Read error: Connection reset by peer]
dhruvasagar has joined #ruby
awestroke has joined #ruby
<workmad3> Xeago: that wouldn't work
Liothen has joined #ruby
Liothen has quit [Changing host]
Liothen has joined #ruby
<JonnieCache> because it shits up your code with instance_exec(&block)
<Xeago> and why would that be?
<workmad3> Xeago: you just created 3 local variables rather than initializing stuff ;)
awestroke has quit [Read error: Connection reset by peer]
<Xeago> then strip out the equals sign
awestroke has joined #ruby
<Xeago> and have chainring(val) methods
<Xeago> I know that is not ruby'ish
<workmad3> Xeago: and then you can't use attr_accessor...
<workmad3> Xeago: and it gets a bit... confusing if you instance_eval blocks too much
awestroke has quit [Read error: Connection reset by peer]
RudyValencia- has joined #ruby
<Xeago> okay than the following
Gajanan has joined #ruby
RudyValencia has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
<Xeago> Gear.new do |gear| gear.chainring=4;end
<workmad3> Xeago: yeah, that works
mmlac has quit [Quit: mmlac]
<Xeago> with block.call(self)
awestroke has quit [Read error: Connection reset by peer]
gokul has quit [Quit: Leaving]
<workmad3> Xeago: although why you'd prefer that to 'Gear.new chainring: 4, cog: 2'...
<Xeago> because I don't have 1.9.3 in production :3
awestroke has joined #ruby
samphippen has joined #ruby
<workmad3> Xeago: hehe
<Xeago> and doesn't rely on a hash
GVRV has joined #ruby
<Xeago> and imo, allows for easier defaults
awestroke has quit [Read error: Connection reset by peer]
<Xeago> just set it in initialize and then call block
<workmad3> Xeago: defaults work the same either way
awestroke has joined #ruby
mjbamford has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
beiter has quit [Quit: beiter]
<workmad3> Xeago: and what do you have against hashes? they aren't going away, they're part of core ruby (same as blocks)
awestroke has joined #ruby
<Xeago> mostly the use of || to provide defaults
<workmad3> ?
awestroke has quit [Read error: Connection reset by peer]
<Xeago> @chainring = args[:chainring] || 40
under_my_shoes has quit [Quit: Leaving]
<Xeago> if you specify it as false
<workmad3> Xeago: args = args.merge(default_options)
<Xeago> it becomes 40
jbnurm has joined #ruby
under_my_shoes has joined #ruby
awestroke has joined #ruby
<Xeago> workmad3: I've not seen that in production here, have seen ||..
jayeshsidhwani has quit [Quit: jayeshsidhwani]
awestroke has quit [Read error: Connection reset by peer]
<Xeago> and we had issues with it
<workmad3> Xeago: it's not our fault that your production code doesn't do the more normal way of providing default options
<workmad3> Xeago: :P
<Xeago> wait!
<Xeago> code from the company I currently am an intern
<Xeago> which I didn't make myself
awestroke has joined #ruby
<workmad3> Xeago: I know ;) I'm teasing you now ;)
<Xeago> tbh, videofy.me is a mess
awestroke has quit [Read error: Connection reset by peer]
<Xeago> in the month I have been coding here, I've written more documentation than they have over 3years
withnale has joined #ruby
<Xeago> and my documentation fits under 2kb
awestroke has joined #ruby
<Xeago> you can count the words in your head..
<workmad3> heh
<workmad3> documentation... fun :P
awestroke has quit [Read error: Connection reset by peer]
<workmad3> right, back to proof-reading
awestroke has joined #ruby
<workmad3> :(
awestroke has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
<workmad3> Xeago: also, I got the merge the wrong way around... it should be args = default_options.merge(args)
<workmad3> Xeago: and then obviously you specify a default_options hash somewhere :)
awestroke has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
<Xeago> i'd use args.merge! default_options
awestroke has joined #ruby
<Xeago> let me test
<workmad3> Xeago: no, that would overwrite args with default_options if they conflicted
<Xeago> crap
<Xeago> das wrong ;p
<workmad3> Xeago: which is what I meant when I got it the wrong way around :P
awestroke has quit [Read error: Connection reset by peer]
<Xeago> well then, args.reverse_merge!
<Xeago> HA!
<workmad3> heh
awestroke has joined #ruby
<Xeago> except it doesn't exist outside of active support
<Xeago> damn that gem is big
<workmad3> yeah, they added things like that in... specifically to support the easy use of default options like this ;)
awestroke has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
<workmad3> it's worth having a look through active support, they have some other nice option processing stuff in there, iirc... including things like throwing argument errors if unknown option keys are passed
<JonnieCache> Xeago: its constructed so you can require it piecemeal
<workmad3> ^^ that too (at least since 3.0)
awestroke has joined #ruby
<Xeago> I just hit a brick wall everytime I open irb
<JonnieCache> require 'active_support/core_ext/hash/reverse_merge'
<Xeago> to walk around it again and again
<workmad3> Xeago: rails app?
awestroke has quit [Read error: Connection reset by peer]
<Xeago> padrino
<workmad3> ah
<Xeago> due to the use of sequel
<Xeago> which validates the db on launch
<Xeago> it takes about 40 seconds to launch
<Xeago> 20seconds at ec2
awestroke has joined #ruby
<workmad3> Xeago: you could bundle exec irb
<workmad3> Xeago: assuming you're using bundler
<workmad3> although that won't require things anymore...
<workmad3> ok, you're stuck :P
arietis has joined #ruby
<JonnieCache> Xeago: link? at the new work we use sequel a lot
awestroke has quit [Read error: Connection reset by peer]
<workmad3> Xeago: write your own startup script ;)
<Xeago> ordinary sequel gem
<Xeago> tho a bit old version
awestroke has joined #ruby
<workmad3> Xeago: 'require "irb"; require "your gem"; IRB.start'
awestroke has quit [Read error: Connection reset by peer]
<JonnieCache> no i mean link to some docs or smth where they talk about validating the db for 40 seconds at load
Eplemosen has quit [Quit: Hexchat FTW! http://www.hexchat.org/]
<JonnieCache> or just the name for it or whatever
<Xeago> no that's just our app here
<workmad3> Xeago: give than a #!, make it executable, viola, project-specific IRB script ;)
<workmad3> *that
<JonnieCache> ohhh
<Xeago> it requires validation of the db
awestroke has joined #ruby
<Xeago> for weird reasons
<Xeago> (mostly importing test data it seems >.<)
g-ram has quit [Quit: Computer has gone to sleep.]
awestroke has quit [Read error: Connection reset by peer]
awestroke has joined #ruby
Progster has quit [Ping timeout: 246 seconds]
asuka_ has quit [Ping timeout: 246 seconds]
awestroke has quit [Read error: Connection reset by peer]
<Xeago> we're using virtual models aswell
<Xeago> which makes it worse
jxf has quit [Ping timeout: 246 seconds]
Elhu has quit [Quit: Computer has gone to sleep.]
awestroke has joined #ruby
asuka has joined #ruby
<Xeago> not to start about inheritance in the sequel addon gem
mneorr has quit [Remote host closed the connection]
<Xeago> that requires 4 queries per model that inherits
awestroke has quit [Read error: Connection reset by peer]
<Xeago> and they are slow queries
<workmad3> Xeago: see above regarding project-specific IRB script so you don't need to spend half your life remembering which gems to load in IRB :P
<Xeago> I us eirbc.rc
awestroke has joined #ruby
mneorr has joined #ruby
mucker has joined #ruby
<workmad3> is that ruby code?
<Xeago> yea
<JonnieCache> requires validation of the db? is it often broken then?
awestroke has quit [Read error: Connection reset by peer]
<JonnieCache> that sounds painful
<Xeago> JonnieCache: 'ish
Guest80824 has joined #ruby
<Xeago> it is..
<workmad3> Xeago: so add in a 'load ENV['HOME'] + '.eirb.rc' ' line
irleif has joined #ruby
jayeshsidhwani has joined #ruby
awestroke has joined #ruby
<Xeago> why that? I can just require 'active_support'
zmo_ has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
<workmad3> Xeago: what about if you don't have active_support in a project?
<Xeago> tbh, I'd prefer to use padrino console
<Xeago> and strip out sequel
<workmad3> Xeago: also it would be 'active_support/all' ;)
awestroke has joined #ruby
<Xeago> because I am not dealing with that
<Xeago> aah
<Xeago> thanks for /all
awestroke has quit [Read error: Connection reset by peer]
<Xeago> as I'd like most of my models to be available
<Xeago> but I don't need database interaction
<Xeago> only elasticsearch
awestroke has joined #ruby
<workmad3> that /all won't load all your stuff, that's just for loading all of active_support
<Xeago> requiring 'active_support' didn't give me reverse_merge :P
bluenemo has joined #ruby
bluenemo has quit [Changing host]
bluenemo has joined #ruby
awestroke has quit [Read error: Connection reset by peer]
<Xeago> /all did
<workmad3> Xeago: yeah :)
<workmad3> Xeago: because 'require "active_support" ' doesn't really load much
awestroke has joined #ruby
<workmad3> ok, I'm now procrastinating...
awestroke has quit [Read error: Connection reset by peer]
<Xeago> been doing that for a week now lol
<Xeago> if you get the subscription for safaribooks
elsifaka has quit [Quit: Veloma e!]
<Xeago> are you limited in the amount books to read?
emergion has quit [Quit: Computer has gone to sleep.]
<Xeago> what is the bookshelf thing?
<JonnieCache> no
<JonnieCache> i wasnt when i used to have it
<JonnieCache> maybe there are some account types that are limited though
lkba has joined #ruby
beiter has joined #ruby
elsifaka has joined #ruby
anoNxeRo has joined #ruby
meskyanichi has joined #ruby
Xeago has quit []
Xeago has joined #ruby
rumba has joined #ruby
Axsuul has quit [Ping timeout: 268 seconds]
Guest80824 has quit [Ping timeout: 246 seconds]
irleif has quit [Quit: Computer has gone to sleep.]
anoNxeRo has quit [Max SendQ exceeded]
hsbt is now known as hsbt_away
rakl has joined #ruby
hsbt_away is now known as hsbt
anoNxeRo has joined #ruby
Mathieu has joined #ruby
Guest80824 has joined #ruby
mucker has quit [Quit: leaving]
<ecksit> i am looking to write a gem for interacting with git (retrieving commits, author details, repo stats). would using grit be a better idea?
robozahn has quit [Ping timeout: 244 seconds]
<banisterfiend> ecksit: it entirely depends if grit is good enough 4 u
<banisterfiend> ecksit: i thin kthere's a better thing called rugged
<banisterfiend> check that out 1st
<Xeago> else, libgit
<rumba> how can i use SOAP::WSDLDriver with HTTP authentication? my code currently looks like this: http://pastebin.com/AH2qaSup but it doesn't reach line 11
<Xeago> or was it libgit2
mucker has joined #ruby
<banisterfiend> Xeago: rugged uses libgit2
<banisterfiend> it's a rub wrapper around it
<banisterfiend> ruby
<ecksit> ah right. i see
<Xeago> ah cool!
<ecksit> sad face. i was going to write a gem for this. :(
<banisterfiend> ecksit: u still could, grit is pretty buggy and weird
hsbt has quit [Ping timeout: 256 seconds]
<banisterfiend> and i could never get rugged working
Eplemosen has joined #ruby
reinaldob has joined #ruby
<ecksit> i want a mroe straight forward gem though. something like my_repo.commits.last to get the last commit
<rumba> or could someone recommend some other module?
<ecksit> or repo.authors.view_details(author_name)
vlad_starkov has joined #ruby
<banisterfiend> ecksit: u coudl always write a wrapper around grit/rugged
<banisterfiend> rather than reimplementing everything yourself
LennyLinux has quit [Remote host closed the connection]
<ecksit> but then i also inherit the issues or problems that grit/rugged have.
<ecksit> tough one
<Xeago> if you're gonna wrap rugged, you might aswell use libgit2 directly imo
hsbt has joined #ruby
RudyValencia- is now known as RudyValencia
vlad_starkov has quit [Ping timeout: 272 seconds]
robozahn has joined #ruby
rclark has joined #ruby
mklappstuhl has joined #ruby
rclark has quit [Client Quit]
rippa has joined #ruby
Guest80824 has quit [Ping timeout: 246 seconds]
haxrbyte_ has quit [Ping timeout: 246 seconds]
chin-tastic has joined #ruby
rdark has joined #ruby
rdark has quit [Client Quit]
kaawee has joined #ruby
LennyLinux has joined #ruby
rdark has joined #ruby
graeme has quit [Quit: graeme]
mklappstuhl has quit [Remote host closed the connection]
chin-tastic has quit [Ping timeout: 240 seconds]
robertotauille has joined #ruby
postmodern has quit [Quit: Leaving]
Eplemosen has quit [Quit: Hexchat FTW! http://www.hexchat.org/]
Michael__ has joined #ruby
emergion has joined #ruby
awestroke has joined #ruby
irleif has joined #ruby
greenarrow has joined #ruby
scx has joined #ruby
kaawee has quit [Read error: Connection reset by peer]
hbpoison has joined #ruby
Xeago has quit [Remote host closed the connection]
awestroke has quit [Remote host closed the connection]
awestroke has joined #ruby
Xeago has joined #ruby
Floydzy has quit [Quit: Floydzy]
guiocavalcanti has joined #ruby
karstensrage has joined #ruby
karstensrage has quit [Max SendQ exceeded]
fermion has quit [Ping timeout: 248 seconds]
sagax has quit [Quit: Ухожу я от вас]
pdelgallego has quit [Ping timeout: 246 seconds]
nari_ has quit [Ping timeout: 245 seconds]
mjbamford has quit [Quit: Leaving...]
fixl has quit [Ping timeout: 260 seconds]
tk__ has joined #ruby
zmo_ has quit [Ping timeout: 260 seconds]
jayeshsidhwani has quit [Quit: jayeshsidhwani]
peterhellberg has left #ruby [#ruby]
peterhellberg has joined #ruby
Michael__ has quit [Remote host closed the connection]
Floydzy has joined #ruby
hbpoison has quit [Ping timeout: 265 seconds]
samphippen has quit [Quit: Computer has gone to sleep.]
<JonnieCache> theres definitely room for a minimal ruby wrapper around libgit2
<JonnieCache> the others are too heavy and weird as people have said
slainer68 has joined #ruby
<ecksit> maybe it is worthwhile starting a more simple wrapper
margle has quit [Quit: Computer has gone to sleep.]
margle has joined #ruby
<ecksit> what about rugged? still too heavy?
<Xeago> yes
<Xeago> imo
<JonnieCache> you could deliberately keep it to a very limited feature set, and have that as a feature of the lib
TomJ has joined #ruby
TomJ has quit [Changing host]
TomJ has joined #ruby
zmo_ has joined #ruby
<JonnieCache> most people only need very basic features to do with extracting information about a repo
<ecksit> yes, my purpose also.
jipiboily-zzzzzz is now known as jipiboily
Goles has joined #ruby
<ecksit> rugged doesn't seem too bad.
slainer68 has quit [Ping timeout: 246 seconds]
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
<banisterfiend> ecksit: how do u switch brances using your api?
irleif has quit [Quit: Computer has gone to sleep.]
<banisterfiend> branches
<banisterfiend> say i want the last commit on the dev branch
<banisterfiend> or the last commit on the master branch
g-ram has joined #ruby
<ecksit> that could be added in.
pdelgallego has joined #ruby
<ecksit> those were a set of features i came up with on the fly. obviously as demand grows, so does he functionlity.
<banisterfiend> ecksit: it's fundamental ;)
sailias has joined #ruby
<banisterfiend> or does it just work on the currently checked out branch?
<ecksit> at this stage, it would be the currently checked out.
<ecksit> you would then need to swap the branch or extend the method to take the branch as a param.
<banisterfiend> ecksit: can it make commits too? or is it just for analysing the repo?
<ecksit> no write, just read.
<Xeago> will changing the checked out branch change the filesystem?
<banisterfiend> ecksit: i wrote a git wrapper a while ago too, but it was a slightly different concept, it worked on the method level
<banisterfiend> ecksit: so u could get diffs / view blame for specific methods in the code base
hbpoison has joined #ruby
<banisterfiend> ecksit: http://github.com/pry/pry-git
ephemerian has joined #ruby
<ecksit> that may be worth a look into
<JonnieCache> banisterfiend: lol the pry plugins just go on and on
<ecksit> (as in looking at for guidance) :p
<banisterfiend> JonnieCache: yeah hehe
<JonnieCache> banisterfiend: does that one work properly? the code is a year old
<banisterfiend> JonnieCache: pry-git could be really awesome but i got lazy and left it half complete
<banisterfiend> i might finish it at some point
<banisterfiend> JonnieCache: it works OK
<banisterfiend> JonnieCache: i use it occasionally, but it could be 100x better
<JonnieCache> it needs a flag to blame so i can send insulting emails to the rest of the team from within the repl
<banisterfiend> hehe, pull requests welcome ;)
skaczor has joined #ruby
<banisterfiend> probably best to use a proper ruby parser when doing pry-git stuff
<banisterfiend> im just messing with regexes which still works properly around 80% (im guessing) of the time
nanderoo has joined #ruby
<Xeago> a package got delivered at work
Jellyg00se has quit [Ping timeout: 246 seconds]
<Xeago> sales and management enjoy 2 hours of fun
<Xeago> splatting all the bubbles
<matti> Xeago: ;]
frogprince_mac has joined #ruby
<Xeago> ill post it a highlight in a sec
binaryplease has joined #ruby
skaczor has quit [Remote host closed the connection]
vlad_starkov has joined #ruby
Gajanan has quit [Quit: Leaving.]
Gajanan has joined #ruby
under_my_shoes has quit [Quit: Leaving]
robert_ has joined #ruby
under_my_shoes has joined #ruby
lledet has joined #ruby
elliot_ has quit [Remote host closed the connection]
Goles has quit [Ping timeout: 255 seconds]
elliot_ has joined #ruby
Gajanan has quit [Ping timeout: 272 seconds]
Elhu has joined #ruby
Gajanan has joined #ruby
Gajanan has left #ruby [#ruby]
Elhu has quit [Client Quit]
irleif has joined #ruby
banisterfiend has quit [Read error: Connection reset by peer]
chimkan_ has joined #ruby
yshh has quit [Remote host closed the connection]
robert_ has quit [Ping timeout: 260 seconds]
Jellyg00se has joined #ruby
F1skr has joined #ruby
mark_locklear has joined #ruby
binaryplease has quit [Read error: Operation timed out]
binarypl1 has joined #ruby
<ecksit> having issues with getting the rugged gem installed on my system. https://gist.github.com/9d3e4593d056e590d771 is the output
rippa has quit [Ping timeout: 256 seconds]
jxf has joined #ruby
fbernier has joined #ruby
[Neurotic] has quit [Remote host closed the connection]
<matti> ecksit: By reading this output, what do you think might be missing? ;]
<ecksit> the libaries however rugged and libgit are both installed.
emergion has quit [Quit: Computer has gone to sleep.]
krawchyk has joined #ruby
tos9 has quit [Excess Flood]
irleif has quit [Quit: Computer has gone to sleep.]
jonathanwallace has joined #ruby
pdelgallego has quit [Ping timeout: 246 seconds]
<Xeago> libgit != libgit2
joaoh82 has quit [Remote host closed the connection]
tos9 has joined #ruby
<Xeago> libgit dates from 2009/2010'ish
joaoh82 has joined #ruby
<ecksit> sorry, libgit2 is
graeme has joined #ruby
<Xeago> http://videofy.me/v/652814 for office fun :\
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
Elhu has joined #ruby
sailias has quit [Ping timeout: 246 seconds]
irleif has joined #ruby
lledet has quit [Quit: lledet]
Ruler_Of_Heaven_ is now known as pipopopo
tommyvyo has joined #ruby
tommyvyo has quit [Client Quit]
robotmay has quit [Ping timeout: 246 seconds]
jitesh_shetty has joined #ruby
beiter has quit [Ping timeout: 272 seconds]
larissa has joined #ruby
pdelgallego has joined #ruby
beiter has joined #ruby
irleif has quit [Quit: Computer has gone to sleep.]
nick_h has quit [Ping timeout: 256 seconds]
lorn has quit [Quit: ZNC - http://znc.sourceforge.net]
pdelgallego has quit [Remote host closed the connection]
nick_h has joined #ruby
lorn has joined #ruby
Zai has joined #ruby
Dreamer3 has quit [Quit: Leaving...]
joaoh82 has quit [Remote host closed the connection]
joaoh82 has joined #ruby
<ecksit> ah got it. cmake was fubar.
josh^ has quit [Remote host closed the connection]
binarypl1 has quit [Quit: WeeChat 0.3.9]
kaawee has joined #ruby
rabidpraxis has joined #ruby
jonathanwallace has quit [Remote host closed the connection]
rabidpraxis has quit [Read error: Connection reset by peer]
frogprince_mac has quit [Quit: Leaving...]
apple has quit [Quit: apple]
Doc_X_ is now known as Doc_X
under_my_shoes has quit [Quit: Leaving]
tommyvyo has joined #ruby
tommyvyo has quit [Changing host]
tommyvyo has joined #ruby
under_my_shoes has joined #ruby
tos9 has quit [Quit: Gone.]
enroxorz-work has quit [Read error: Connection reset by peer]
vlad_starkov has quit [Remote host closed the connection]
<sonne> using form_for() in rails i see that i can use the "submit" method to create a submit button... i've seen examples around that specify an image instead of a button (f.submit "foo", :type => image)
reisl has joined #ruby
<sonne> i can't find any docs on it... how do i find out what are the accepted types of submits?
berserkr has quit [Quit: Leaving.]
larissa has quit [Ping timeout: 246 seconds]
linoj has joined #ruby
ananthakumaran has quit [Quit: Leaving.]
margle has quit [Quit: Computer has gone to sleep.]
rdark has quit [Ping timeout: 246 seconds]
<Xeago> sonne: you could read the code
<Xeago> you should ask in #rails tho
rdark has joined #ruby
yshh has joined #ruby
<sonne> Xeago, tried the latter... i'm quite scared by the former :)
mercwithamouth has joined #ruby
cantonic_ has joined #ruby
jcaudle has joined #ruby
dhruvasagar has quit [Ping timeout: 245 seconds]
cantonic has quit [Ping timeout: 246 seconds]
cantonic_ is now known as cantonic
mneorr has quit [Remote host closed the connection]
akemEikko has quit [Ping timeout: 260 seconds]
mneorr has joined #ruby
somazero has joined #ruby
tos9 has joined #ruby
tos9 has quit [Client Quit]
<tommyvyo> anyone have any recommendations on a solid stable websocket engine?
Ktaze has joined #ruby
slainer68 has joined #ruby
Konboi has quit [Remote host closed the connection]
emergion has joined #ruby
<zykes-> anyone tha can help me with how I can "split" http://paste.ubuntu.com/1289261/ into 2 files ? The first file should have the content until the line "ALTER TABLE ach" and the other one from that line and onwards
geekbri has joined #ruby
joaoh82 has quit [Remote host closed the connection]
GoGoGarrett has joined #ruby
apple has joined #ruby
joaoh82 has joined #ruby
kaneda__ has quit [Ping timeout: 246 seconds]
zmo_ has quit [Quit: Leaving]
nitti has joined #ruby
matti is now known as zombie_matti
Konboi has joined #ruby
rdark has quit [Ping timeout: 256 seconds]
zombie_matti is now known as matti
profx_ has quit [Remote host closed the connection]
<JonnieCache> tommyvyo: define websockets engine
<JonnieCache> faye is well used and well liked http://faye.jcoglan.com/
<JonnieCache> if thats what youre talking about
jitesh_shetty has quit [Remote host closed the connection]
rdark has joined #ruby
mneorr has quit [Remote host closed the connection]
<JonnieCache> sonne: the correct rails channel is #rubyonrails
<JonnieCache> Xeago seemingly enjoys sending people to the wrong one
mneorr has joined #ruby
<tommyvyo> it is JonnieCache, ive seen faye im just not 100% sold on it yet. thanks tho
joaoh82 has quit [Remote host closed the connection]
Konboi has quit [Ping timeout: 252 seconds]
joaoh82 has joined #ruby
kaawee has quit [Ping timeout: 246 seconds]
freeayu__ has quit [Remote host closed the connection]
<JonnieCache> this is lame as fuck im only getting 600kb/s
<JonnieCache> ports must not be open
sailias has joined #ruby
mmlac has joined #ruby
jonathanwallace has joined #ruby
zmo_ has joined #ruby
robotmay has joined #ruby
rdark has quit [Ping timeout: 264 seconds]
theRoUS has joined #ruby
cascalheira has joined #ruby
Goles has joined #ruby
tos9 has joined #ruby
carloslopes has joined #ruby
negev has left #ruby [#ruby]
cakehero has joined #ruby
rdark has joined #ruby
samphippen has joined #ruby
dr_bob has quit [Quit: Leaving.]
<sonne> JonnieCache, thanks :)
dmerrick has joined #ruby
Astral_ has quit [Read error: Connection reset by peer]
maesbn has quit [Remote host closed the connection]
Astral_ has joined #ruby
zigomir has quit [Read error: Connection reset by peer]
bluenemo has quit [Remote host closed the connection]
Debolaz has quit [Quit: ZNC - http://znc.in]
zigomir has joined #ruby
jeffreybaird has joined #ruby
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
GraemeLion has joined #ruby
rdark has quit [Ping timeout: 240 seconds]
a_a_g1 has quit [Quit: Leaving.]
nitti has quit [Remote host closed the connection]
bbttxu has joined #ruby
rdark has joined #ruby
mando has joined #ruby
guiocavalcanti has quit [Remote host closed the connection]
lledet has joined #ruby
rakl has quit [Ping timeout: 252 seconds]
uris has joined #ruby
mmitchell has joined #ruby
somazero has quit [Ping timeout: 246 seconds]
Debolaz has joined #ruby
Debolaz has quit [Changing host]
Debolaz has joined #ruby
iamjarvo has quit [Read error: Operation timed out]
F1skr has quit [Quit: WeeChat 0.3.9]
g-ram has quit [Quit: Computer has gone to sleep.]
joofsh has joined #ruby
krz has quit [Quit: krz]
deadalus has joined #ruby
deadalus has quit [Changing host]
deadalus has joined #ruby
mneorr has quit [Remote host closed the connection]
mneorr has joined #ruby
chimkan_ has quit [Ping timeout: 256 seconds]
ffranz has joined #ruby
Zai has quit [Quit: Zai]
enroxorz-work has joined #ruby
frogstarr78 has quit [Ping timeout: 248 seconds]
sspiff has quit [Remote host closed the connection]
gmurphey has joined #ruby
frogstarr78 has joined #ruby
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
cmol has quit [Quit: Leaving]
fir_ed has quit [Read error: Connection reset by peer]
IrishGringo has joined #ruby
fir_ed has joined #ruby
stopbit has joined #ruby
<otters> has anybody here used rubyzip
clj_newb has joined #ruby
theRoUS has quit [Ping timeout: 244 seconds]
<peterhellberg> otters: I think so, or possibly zipruby
<otters> it's using 800MB of RAM
<otters> I think that's bad
<peterhellberg> So do I
Montas has joined #ruby
<peterhellberg> otters: What is the size of the zip and the extracted files?
joshman_ has joined #ruby
<otters> The folder I'm compressing is 1.22GB in size
recycle has quit [Remote host closed the connection]
<peterhellberg> Also, are you using Zip::ZipFileSystem?
<otters> No, should I be?
<peterhellberg> Not sure really
<otters> It's pretty stable at 108MB right now actually
<otters> I'll see if it skyrockets again
<peterhellberg> It looks like Zip::ZipOutputStream might be what you are really after
<otters> I killed the last process because it was shoving everything into swap and my computer was running slow
Uranio has joined #ruby
<otters> The rubyzip docs say that the file isn't actually committed to the filesystem until it's closed
<otters> which makes it sounds like it's storing everything in memory
<Montas> hi, how could i convert hash like in this example? https://gist.github.com/3918412
<love_color_text> Montas: .map and split('.') i suppose
<otters> Oh, hang on
<otters> It's not the compression step that's using all the memory
dnstbr has joined #ruby
<JonnieCache> yeah you definitely want to be streaming that shit
<otters> I'm using the AWS S3 SDK
<otters> It looks like the culprit is S3Object#write
<peterhellberg> You should also stream to S3
scx has quit [Read error: Connection reset by peer]
<otters> I am
<otters> Oh wait I know what the problem is
answer_421 has joined #ruby
BiHi has joined #ruby
<otters> reading the entire file to do an MD5 digest for some reason :|
jitesh_shetty has joined #ruby
JohnBat26 has quit [Ping timeout: 265 seconds]
answer_42 has quit [Ping timeout: 276 seconds]
A124 has joined #ruby
pothibo has joined #ruby
<otters> surely md5sum doesn't load the entire input file into memory
Targen has quit [Ping timeout: 252 seconds]
<Montas> love_color_text: ok, I can split each key and create new nested hash. now how do i merge them together? I have N hashes in array
<love_color_text> Hash#merge ?
<love_color_text> i actually like your puzzle, im trying to solve it right now
Ankhers has joined #ruby
<love_color_text> lets compare answers
<love_color_text> h/o
nitti has joined #ruby
<Montas> well im trying to do it in one line :P
<Montas> all i have is all.collect{|k,v| pts = k.split('.'); {pts[0] => {pts[1] => v}}}
<love_color_text> ya i did it in 13 lines. hmm does that one work?
<love_color_text> well, 10 lines if you include your hash too
<Montas> well its not merged
<love_color_text> Montas: https://gist.github.com/3918412#comments thats how i did it
<love_color_text> some of that ||= stuff might be unnecessary
<love_color_text> i didnt think of collect, let me try to remember what that does :D
theRoUS has joined #ruby
theRoUS has quit [Changing host]
theRoUS has joined #ruby
chrishunt has joined #ruby
<love_color_text> oh collect is same as map ok, no wonder i had forgotten XD
Goles has quit [Quit: Computer has gone to sleep.]
reinaldob has quit [Remote host closed the connection]
<Montas> I think there was a way to pass variable between each iteration in map and return that
<peterhellberg> Montas you might also want to look into Hash Autovivification
dmiller has joined #ruby
<love_color_text> hash ... vivification... ?
<love_color_text> is that a real ruby thing?
nitti_ has joined #ruby
imami|afk is now known as banseljaj
nitti has quit [Ping timeout: 252 seconds]
<love_color_text> interesting
* love_color_text has been writing extra lines... and here i thought i was being so concise!
elico has quit [Quit: elico]
workmad3 has quit [Ping timeout: 272 seconds]
dmiller has quit [Remote host closed the connection]
<peterhellberg> v = Hash.new(&(p=lambda{|h,k| h[k] = Hash.new(&p)}))
<peterhellberg> v['a']['b']['c'] = '123'
R3dy has quit [Quit: Lost terminal]
alanp_ has quit [Ping timeout: 252 seconds]
ZubKonst_ has joined #ruby
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
<peterhellberg> Ugly, but it does work :)
<peterhellberg> Perl and PHP does this natively
<love_color_text> thanks peter, very cool indeed
jenrzzz has joined #ruby
<peterhellberg> I’d love for Ruby to have proper support for anaphora, but that will never happen :/
ttt has quit [Remote host closed the connection]
<love_color_text> today i learned 2 new words. :)
mmlac has quit [Quit: mmlac]
<peterhellberg> love_color_text: Good article on the subject https://github.com/raganwald/homoiconic/blob/master/2012/05/anaphora.md
ZubKonst has quit [Ping timeout: 276 seconds]
<love_color_text> why would that never happen? isn't ruby all about being able to modify itself? and arent you doing anaphora by referring to p in the way you are doing so? what syntax would you have preferred? are we talking about your example still?
<love_color_text> correction, by modify itself i mean being able to extend the language into any form you want
<peterhellberg> love_color_text: The point is that I’d like not having the "p" at all
<love_color_text> modify the language*. and thanks i'll read this
`brendan has joined #ruby
roadt has quit [Ping timeout: 246 seconds]
Floydzy has quit [Quit: Floydzy]
axl__ has joined #ruby
mmlac has joined #ruby
<peterhellberg> I’ve still to get a grip on the status of “autoload” in Ruby.
<Montas> peterhellberg: so if i get it right, You create Hash that can do hash["asd"]["qwe"]["zxc"] = "qwe" ?
<peterhellberg> I guess it is better to disregard it completely (since it is to be removed in Ruby 3)
burgestrand has quit [Quit: Leaving.]
<peterhellberg> Montas: Yes
v0n has joined #ruby
v0n has quit [Client Quit]
samphippen has quit [Quit: Computer has gone to sleep.]
kpshek has joined #ruby
nateberkopec has joined #ruby
hoofman has joined #ruby
mando has quit [Remote host closed the connection]
samphippen has joined #ruby
_md has joined #ruby
mmlac has quit [Quit: mmlac]
havenn has joined #ruby
reisl has quit [Quit: Leaving]
Araxia has joined #ruby
metrix has joined #ruby
beiter has quit [Quit: beiter]
troessner has joined #ruby
Spooner has joined #ruby
iamjarvo has joined #ruby
<metrix> I am running applications on a windows platform where I won't have access to creating my own scheduled tasks.. Is there a good(popular) ruby schedular that I can create as a service one time that I can use to schedule processes from a ruby script?
samphippen has quit [Quit: Computer has gone to sleep.]
jenrzzz has quit [Ping timeout: 244 seconds]
<peterhellberg> metrix: I’ve been very happy with https://github.com/daddye/forever (But I’m not sure if it would run under Windows, I don’t touch that with a stick :)
clj_newb has quit [Ping timeout: 244 seconds]
<metrix> LOL
<peterhellberg> Oh, moved to https://github.com/DAddYE/foreverb
Araxia has quit [Client Quit]
_JamieD_ has joined #ruby
<metrix> I wish I could run everything from linux... I don't know what I would do without cygwin
morozovm has joined #ruby
<peterhellberg> metrix: You might also want to look into if any of the scheduling worker queues (Like Sidekiq) support Windows
<metrix> ok, will do
<metrix> thank you!
<peterhellberg> np
georgi has quit [Ping timeout: 244 seconds]
cakehero has quit [Quit: Computer has gone to sleep.]
<reactormonk> metrix, god ol' vbox?
LennyLinux has quit [Remote host closed the connection]
philcrissman has joined #ruby
Goles has joined #ruby
<metrix> I have a Debian virtualBox when I need to do something that Cygwin couldn't do, but in general I just use Cygwin. Policy at my place of work is that all servers must be Windows based.
<troessner> lol
<troessner> seriously?
<troessner> may i ask where you work metrix
<matti> Yeah.
<matti> So we can put it on a "avoid list" ;]
samphippen has joined #ruby
<troessner> :D
<metrix> LOL it's a city in West Texas
<metrix> you can just avoid the area ;)
<matti> Phew.
<matti> I am safe in London ;d
<matti> metrix: :)
<troessner> and i assume all your grapic designers must use Plan 9 as a policy
<troessner> :)
<matti> Hahah
<metrix> This is a small shop.... Only 4 programmers
manizzle has quit [Ping timeout: 260 seconds]
tommyvyo has quit [Quit: Computer has gone to sleep.]
klaas has quit [Ping timeout: 260 seconds]
metrix has quit [Quit: ChatZilla 0.9.89 [Firefox 16.0.1/20121010144125]]
h4mz1d has joined #ruby
under_my_shoes has quit [Quit: Leaving]
tjbiddle has joined #ruby
under_my_shoes has joined #ruby
scx has joined #ruby
chrisramon has joined #ruby
dnstbr has quit [Quit: Computer has gone to sleep.]
tomsthumb has joined #ruby
BiHi has quit [Read error: Connection reset by peer]
chin-tastic has joined #ruby
<Montas> guys, simple... how do i turn "súčasťou" to "sucastou" ? remove all interpuction
dakine has quit [Quit: Leaving]
<Muz> "Simple" hahah.
<Xeago> Montas: using icu
dakine has joined #ruby
BiHi has joined #ruby
<peterhellberg> Heh, gisted some ugly hash autovivification and eval trickery over at https://gist.github.com/3918727
dmiller has joined #ruby
<peterhellberg> Montas: You need to look into transliteration
<peterhellberg> Montas: Possibly by using Iconv
jxf has quit [Ping timeout: 256 seconds]
<troessner> just a shot in the blue, seems valid
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
<peterhellberg> troessner: He wants to transliterate, not remove invalid characters… right?
ecksit has quit [Quit: Gone to sleep.]
<troessner> peterhellberg, good point, my bad
<troessner> :)
mando has joined #ruby
lolmaus has quit []
pdelgallego has joined #ruby
pdelgallego has quit [Client Quit]
jamescarr has joined #ruby
itnomad has joined #ruby
peterhellberg has left #ruby [#ruby]
the_jeebster has joined #ruby
hsbt is now known as hsbt_away
hsbt_away is now known as hsbt
und3f has quit [Quit: Leaving.]
g-ram has joined #ruby
chimay has joined #ruby
Astral_ has quit [Read error: Connection reset by peer]
wallerdev has joined #ruby
arturaz has quit [Ping timeout: 246 seconds]
Astral_ has joined #ruby
BSaboia has joined #ruby
NoICE has joined #ruby
davidcelis has quit [Quit: K-Lined.]
glupo has joined #ruby
chrishunt has quit [Ping timeout: 246 seconds]
Agis__ has joined #ruby
robotmay has quit [Read error: Connection reset by peer]
baroquebobcat has joined #ruby
robotmay has joined #ruby
khakimov has joined #ruby
haxrbyte has joined #ruby
Rizzle has joined #ruby
roadt has joined #ruby
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
jonathanwallace has quit [Remote host closed the connection]
Floydzy has joined #ruby
frogprince has quit [Ping timeout: 252 seconds]
havenn has quit [Remote host closed the connection]
hsbt has quit [Ping timeout: 244 seconds]
frogprince has joined #ruby
Mon_Ouie has joined #ruby
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby
cnf has joined #ruby
Michael- has joined #ruby
Michael- has quit [Client Quit]
roadt has quit [Ping timeout: 246 seconds]
Elhu has quit [Ping timeout: 245 seconds]
hotovson_ has joined #ruby
davidcelis has joined #ruby
<the_jeebster> can't wait for rubyconf!
hadees_ has joined #ruby
davidcelis has quit [Client Quit]
<the_jeebster> excited to check out denver as well
Elhu has joined #ruby
Liothen_ has joined #ruby
mikekelly has quit [Ping timeout: 256 seconds]
matrixise has quit [Ping timeout: 260 seconds]
mikepack has joined #ruby
WhereIsMySpoon_ has quit [Quit: No Ping reply in 180 seconds.]
hadees has quit [Ping timeout: 246 seconds]
hadees_ is now known as hadees
_cheney2 has joined #ruby
WhereIsMySpoon has joined #ruby
moshee has quit [Ping timeout: 260 seconds]
meskyanichi has quit [Ping timeout: 246 seconds]
hotovson has quit [Ping timeout: 246 seconds]
_cheney has quit [Ping timeout: 246 seconds]
dreamfall has quit [Ping timeout: 246 seconds]
alanp has joined #ruby
hsbt has joined #ruby
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
fbernier has quit [Ping timeout: 246 seconds]
vitor-br has quit [Ping timeout: 246 seconds]
rking has quit [Ping timeout: 246 seconds]
Liothen has quit [Ping timeout: 246 seconds]
QaDeS has quit [Ping timeout: 246 seconds]
rking has joined #ruby
dreamfall has joined #ruby
fbernier has joined #ruby
Ankhers has quit [Remote host closed the connection]
vitor-br has joined #ruby
QaDeS has joined #ruby
mikekelly has joined #ruby
elsifaka has quit [Quit: Veloma e!]
minijupe has joined #ruby
d2dchat has joined #ruby
scx has quit [Read error: Connection reset by peer]
Ankhers has joined #ruby
Artheist has quit [Remote host closed the connection]
bricker has joined #ruby
<Uranio> guest that I'm already make this question but.. hoe could I dialogue with a html form
<Uranio> I mena... get a page, fill the form, get the cookie and continue authenticated for the enxt page
<Uranio> s/mena/mean/
invisime has joined #ruby
<Uranio> s/hoe/how/
<love_color_text> Uranio: uhm... try looking at Capybara or Mechanize or using Net::HTTP or HTTParty ....
chrisramon_ has joined #ruby
<love_color_text> or Selenium even
chin-tastic has quit [Ping timeout: 245 seconds]
aganov has quit [Remote host closed the connection]
<Uranio> I prefer Net::HTTP... with curl in bash I use the -d option for send the for anme and value
<Uranio> I think ruby must have better way for do that
Appineer has joined #ruby
hbpoison has quit [Ping timeout: 260 seconds]
freezey has joined #ruby
tommyvyo has joined #ruby
tommyvyo has quit [Changing host]
tommyvyo has joined #ruby
chrisramon has quit [Ping timeout: 244 seconds]
chrisramon_ is now known as chrisramon
kpshek has quit []
uris has quit [Remote host closed the connection]
<love_color_text> a web form is nothing but a way for the user to fill in fields that ultimately end up as parameters that get sent to the server. so if you know these parameters you can send them with net::http
Appineer has left #ruby [#ruby]
<love_color_text> you'll need to know if its a POST, PUT, DELETE, etc
graeme has quit [Quit: graeme]
<love_color_text> and then just construct your request with Net::HTTP and you're good to do. take a look at Net::HTTP documentation (and yes this is the best option in order to not have dependencies in your program, since Net::HTTP is part of ruby standard lib)
<love_color_text> good to go*
graeme has joined #ruby
slainer68 has quit [Remote host closed the connection]
joeycarmello has joined #ruby
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
<Uranio> love_color_text: now but for example, the page have a form named "user" for username
<Uranio> and a button for submit, how could that in NET::HTTP
<ddd> write it for me! i don't want to look at docs!
<Uranio> (I dont't ask you programing, jsut the grose idea)
maesbn has joined #ruby
<Uranio> ddd: for exmaple, that would be "get the page, parse it and send the post"
<Uranio> that culd be a answer to my question
maesbn has quit [Remote host closed the connection]
noyb has quit [Ping timeout: 246 seconds]
<Xeago> Uranio: parsing html is a devious process
<ddd> he just told you basically that, and told you to look at the docs for an example and the methods Net::HTTP uses to do that
tjbiddle has quit [Quit: tjbiddle]
<Uranio> ok.. could be sayed that Net::HTTP native support the bussine of the auth with forms
zmo_ has quit [Quit: Leaving]
caleb_io has joined #ruby
Vinz_` is now known as Vinz_
v0n has joined #ruby
dnyy has joined #ruby
caleb_io has quit [Client Quit]
somazero has joined #ruby
ryanlecompte has joined #ruby
emergion has quit [Quit: Computer has gone to sleep.]
NoICE has left #ruby [#ruby]
samphippen has quit [Quit: Computer has gone to sleep.]
bigmcq77 has joined #ruby
Virunga has joined #ruby
havenn has joined #ruby
<Uranio> thanks love_color_text
<love_color_text> your welcome.
mahmoudimus has joined #ruby
cakehero has joined #ruby
d2dchat has quit [Remote host closed the connection]
perry has quit [Excess Flood]
banseljaj has quit [Excess Flood]
banseljaj has joined #ruby
stephenjudkins has quit [Quit: stephenjudkins]
margle has joined #ruby
hoelzro is now known as hoelzro|away
UberNerdGirl has joined #ruby
perryh has joined #ruby
mmlac has joined #ruby
chin-tastic has joined #ruby
under_my_shoes has quit [Quit: Leaving]
areil has quit [Remote host closed the connection]
under_my_shoes has joined #ruby
klaas has joined #ruby
kpshek has joined #ruby
awarner has joined #ruby
savon_noir has joined #ruby
tommyvyo has quit [Quit: Computer has gone to sleep.]
savon_noir has left #ruby ["I'm busy"]
answer_421 has quit [Remote host closed the connection]
Uranio has quit [Quit: WeeChat 0.3.8]
<minijupe> is there string enclosing syntax other than ' and " ?
<love_color_text> minijupe: there are a lot of ways to create string literals in ruby
<love_color_text> %{} is a favorite of mine
hadees has quit [Quit: hadees]
v0n has quit [Ping timeout: 246 seconds]
dnstbr has joined #ruby
kpshek has quit [Client Quit]
<love_color_text> googling "ruby string literal constructors" or something to that effect might bring up the list
sertaconay has joined #ruby
<minijupe> got it, was trying but apparently the 'literal' part is what i needed
jso has quit []
sertaconay has quit [Remote host closed the connection]
<troessner> i think only perl has equally many ways to construct strings
answer_421 has joined #ruby
<troessner> in ruby it's like a gazillion
<troessner> just a rough estimate
<minijupe> love_color_text: looks like % and any {} () ... pair will work
GraemeLion has quit [Quit: out]
<troessner> not to forget about %w!! %W!! and its friends
aantix has joined #ruby
<troessner> errrr
<troessner> with "q", not "w" of course
jipiboily has left #ruby [#ruby]
Elhu has quit [Ping timeout: 245 seconds]
under_my_shoes has quit [Quit: Leaving]
kpshek has joined #ruby
under_my_shoes has joined #ruby
jipiboily has joined #ruby
<ddd> so many ways to do things
fourlastor has joined #ruby
<fourlastor> hello everyone :)
hbpoison has joined #ruby
<fourlastor> is there any library to edit ebooks (epub,mobi) inline? eg putting a social drm in the ebook?
<ddd> great thing bout lurking here, so many little items covered daily. whether they apply to your day or not, someone somewhere asks something that gets solved that leaves you going "Oh cool! Didn't think of that!"
alvaro_o__ has joined #ruby
rakl has joined #ruby
hsbt is now known as hsbt_away
hsbt_away is now known as hsbt
Elhu has joined #ruby
awestroke has quit [Remote host closed the connection]
chrishunt has joined #ruby
davidcelis has joined #ruby
caleb_io has joined #ruby
jonathanwallace has joined #ruby
alvaro_o_ has quit [Ping timeout: 244 seconds]
sideshowcoder has quit [Ping timeout: 248 seconds]
xorigin has quit [Quit: leaving]
sepp2k has quit [Quit: Leaving.]
sepp2k has joined #ruby
jonatha__ has joined #ruby
samphippen has joined #ruby
Elhu has quit [Ping timeout: 245 seconds]
maletor has joined #ruby
yaymukund has quit [Ping timeout: 260 seconds]
<Monie> oh typo
ephemerian has quit [Quit: Leaving.]
cdzombak has joined #ruby
<troessner> :)
hsbt is now known as hsbt_away
v0n has joined #ruby
robozahn has quit [Quit: Lost terminal]
hsbt_away is now known as hsbt
jonathanwallace has quit [Ping timeout: 252 seconds]
bradhe has joined #ruby
jgonzalezd has joined #ruby
Agis__ has quit [Quit: Agis__]
hadees has joined #ruby
Elhu has joined #ruby
Ktaze has quit [Quit: Leaving]
healpay has joined #ruby
recycle has joined #ruby
dmiller has quit [Remote host closed the connection]
somazero has quit [Quit: Leaving]
hsbt has quit [Ping timeout: 248 seconds]
erichmenge has joined #ruby
hsbt_away has joined #ruby
hsbt_away is now known as hsbt
recycle has quit [Remote host closed the connection]
joeycarmello has quit [Remote host closed the connection]
stephh has joined #ruby
caleb_io has quit [Quit: Leaving...]
rakl has quit [Quit: sleeping]
cbuxton has joined #ruby
a_a_g has joined #ruby
hsbt has quit [Ping timeout: 248 seconds]
jgonzalezd has left #ruby [#ruby]
A124 has quit [Quit: Leaving.]
kaawee has joined #ruby
tjbiddle has joined #ruby
eldariof has quit []
philcrissman has quit [Remote host closed the connection]
hsbt has joined #ruby
apple has quit [Quit: apple]
jcaudle has quit [Quit: jcaudle]
mahmoudimus has quit [Quit: Computer has gone to sleep.]
samphippen has quit [Quit: Computer has gone to sleep.]
stephh has quit [Ping timeout: 255 seconds]
theRoUS has quit [Ping timeout: 252 seconds]
JonnieCache has quit [Ping timeout: 244 seconds]
rabidpraxis has joined #ruby
stephenjudkins has joined #ruby
khakimov has quit [Quit: Computer has gone to sleep.]
siyusong has joined #ruby
rabidpraxis has quit [Read error: Connection reset by peer]
rabidpraxis has joined #ruby
jslowe has joined #ruby
Synthead has joined #ruby
Araxia has joined #ruby
samphippen has joined #ruby
Araxia has quit [Read error: Connection reset by peer]
Araxia has joined #ruby
brianpWins has joined #ruby
dmiller has joined #ruby
SegFaultAX|work has joined #ruby
fantazo has joined #ruby
rabidpraxis has quit [Remote host closed the connection]
fourlastor has quit [Quit: Sto andando via]
rabidpraxis has joined #ruby
QaDeS has quit [Ping timeout: 246 seconds]
awestroke has joined #ruby
theRoUS has joined #ruby
theRoUS has quit [Changing host]
theRoUS has joined #ruby
artOfWar has joined #ruby
binaryplease has joined #ruby
slainer68 has joined #ruby
rabidpraxis has quit [Ping timeout: 246 seconds]
icooba has quit [Quit: Computer has gone to sleep.]
Elhu has quit [Ping timeout: 245 seconds]
artOfWar_ has joined #ruby
slainer68 has quit [Remote host closed the connection]
Elhu has joined #ruby
mahmoudimus has joined #ruby
cantonic has quit [Read error: Connection reset by peer]
phinfonet has joined #ruby
Elhu has quit [Client Quit]
cantonic has joined #ruby
jenrzzz has joined #ruby
ShiintoRyuu has joined #ruby
artOfWar has quit [Ping timeout: 256 seconds]
timonv has quit [Remote host closed the connection]
havenn has quit [Remote host closed the connection]
deadSnowman has quit [Ping timeout: 245 seconds]
morozovm has quit [Read error: Connection reset by peer]
graft has quit [Ping timeout: 260 seconds]
morozovm has joined #ruby
mikepack has quit [Read error: Connection reset by peer]
Vainoharhainen has quit [Quit: Leaving...]
mikepack has joined #ruby
erichmenge has quit [Quit: Be back later]
lledet has quit [Read error: Connection reset by peer]
lledet has joined #ruby
havenn has joined #ruby
iamjarvo has quit [Quit: Computer has gone to sleep.]
clj_newb has joined #ruby
tommyvyo has joined #ruby
tommyvyo has quit [Changing host]
tommyvyo has joined #ruby
_md has quit [Quit: Leaving...]
TomJ has quit [Read error: Connection reset by peer]
BiHi has quit [Quit: bye]
haxrbyte_ has joined #ruby
caleb_io has joined #ruby
QaDeS has joined #ruby
Neomex has joined #ruby
Neomex has quit [Client Quit]
binaryplease has quit [Quit: WeeChat 0.3.9]
havenn has quit [Ping timeout: 246 seconds]
apok has joined #ruby
haxrbyte has quit [Ping timeout: 264 seconds]
Monie has quit [Quit: Quit]
samphippen has quit [Quit: Computer has gone to sleep.]
Mon_Ouie has quit [Ping timeout: 260 seconds]
Rydefalk_ has quit [Read error: Connection reset by peer]
Rydefalk has joined #ruby
<Xeago> and not a single line of code was written this day..
carloslopes has quit [Quit: Leaving.]
jonatha__ has quit [Remote host closed the connection]
<caleb_io> haha
dylanjha has joined #ruby
sepp2k has quit [Ping timeout: 246 seconds]
philcrissman has joined #ruby
x82_nicole has joined #ruby
sepp2k has joined #ruby
chimay has quit [Quit: WeeChat 0.4.0-dev]
tchebb has joined #ruby
mneorr has quit [Remote host closed the connection]
sideshowcoder has joined #ruby
mneorr has joined #ruby
fermion has joined #ruby
jamescarr has quit [Ping timeout: 245 seconds]
voodoofish430 has joined #ruby
tk__ has quit [Quit: ばいばい]
stephh has joined #ruby
mneorr has quit [Remote host closed the connection]
mneorr has joined #ruby
reuf has quit [Quit: Leaving]
shaman42 has quit [Ping timeout: 256 seconds]
happosad1 has quit [Ping timeout: 255 seconds]
nw_ has quit [Ping timeout: 255 seconds]
jbnurm has quit [Remote host closed the connection]
apple has joined #ruby
mrsolo has joined #ruby
erichmenge has joined #ruby
graft has joined #ruby
graft has quit [Changing host]
graft has joined #ruby
iamjarvo has joined #ruby
g-ram has quit [Quit: Computer has gone to sleep.]
kaneda__ has joined #ruby
niklasb has joined #ruby
uris has joined #ruby
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
timmow has quit [Quit: has left the building]
graeme_ has joined #ruby
jasond has joined #ruby
cascalheira has quit [Quit: Linkinus - http://linkinus.com]
g-ram has joined #ruby
stephenjudkins has quit [Quit: stephenjudkins]
graeme has quit [Ping timeout: 246 seconds]
graeme_ is now known as graeme
brianpWins has quit [Quit: brianpWins]
bigkevmcd has quit [Quit: outta here]
baphled has joined #ruby
happosade has joined #ruby
noyb has joined #ruby
shadoi has joined #ruby
siyusong has quit [Quit: Computer has gone to sleep.]
nw has joined #ruby
sepp2k has quit [Ping timeout: 260 seconds]
chrishunt has quit [Ping timeout: 255 seconds]
shevy has quit [Read error: Operation timed out]
Xeago_ has joined #ruby
siyusong has joined #ruby
sepp2k has joined #ruby
pdswan has joined #ruby
Xeago_ has quit [Remote host closed the connection]
apple has quit [Quit: apple]
headius has joined #ruby
phinfonet has quit [Ping timeout: 248 seconds]
delinquentme has joined #ruby
stkowski has joined #ruby
<delinquentme> SOOO im looking around and it seems that minitest is the go-to test suite for ruby / ror?
<delinquentme> amiright?
bradhe_ has joined #ruby
shaman42 has joined #ruby
Xeago has quit [Ping timeout: 265 seconds]
frogprince_mac has joined #ruby
yekta has joined #ruby
samphippen has joined #ruby
bradhe has quit [Ping timeout: 268 seconds]
graeme has quit [Quit: graeme]
chrisramon has quit [Quit: chrisramon]
sepp2k1 has joined #ruby
haxrbyte has joined #ruby
sepp2k has quit [Ping timeout: 256 seconds]
kil0byte has joined #ruby
jamjam has joined #ruby
haxrbyte_ has quit [Ping timeout: 256 seconds]
g-ram has quit [Quit: Computer has gone to sleep.]
under_my_shoes has quit [Quit: Leaving]
timtux has quit [Ping timeout: 245 seconds]
mneorr has quit [Remote host closed the connection]
chrishunt has joined #ruby
under_my_shoes has joined #ruby
noyb has quit [Ping timeout: 246 seconds]
mneorr has joined #ruby
timtux has joined #ruby
g-ram has joined #ruby
shevy has joined #ruby
IrishGringo has quit [Quit: ChatZilla 0.9.89 [Firefox 16.0.1/20121010144125]]
blazes816 has left #ruby [#ruby]
erichmenge has quit [Quit: Be back later]
lolzie has joined #ruby
hoofman has quit [Ping timeout: 260 seconds]
samphippen has quit [Quit: Computer has gone to sleep.]
<Spooner> delinquentme : RSpec and minitest, probably https://www.ruby-toolbox.com/categories/testing_frameworks
<lolzie> Hi guys
<Spooner> Hi lolzie
mmlac has quit [Quit: mmlac]
<lolzie> I want to do obj = Obj.new.attr1(val1).attr2(val2).attr3(val3)
<lolzie> Therefore each setter method should return self
<Spooner> Setters should return the value, not self.
<lolzie> Spooner: have you not seen that pattern before, though?
<Spooner> But those aren't normal setters (which would be attr1=(val1)).
Ivo has joined #ruby
g-ram has quit [Quit: Computer has gone to sleep.]
<Spooner> Yes, but they aren't setters, they are methods that happen to set something ;)
<lolzie> Ah
<lolzie> Spooner: well in doing this, do I have to completely abandon the attr_* settings?
<lolzie> All else I'd have wanted would've been readers
<Spooner> I don't entirely know where you are asking for help. In the way to call or the way to implement attr1, etc?
etherdev has quit [Ping timeout: 246 seconds]
<lolzie> Running that results in bob.rb:14:in `name': wrong number of arguments (0 for 1) (ArgumentError)
etherdev has joined #ruby
<lolzie> I'd like to not have to write a whole bunch of def attr; attr; end; methods
<Spooner> lolzie : You can't do that in Ruby is the simple answer. We don't have polymorphic functions./
<Spooner> So your def age(age) will overwrite the attr_reader version of age().
carloslopes has joined #ruby
<lolzie> I don't remember Ruby lacking that 0_o
<lolzie> wow
<xclite> lolzie, shouldn't this really be bob = Person.new(21, 180, "Bob")
<lolzie> I'm a little rusty on this
<Spooner> When we want setters, we do def age=(age); @age = age; end
<lolzie> xclite: I was just experimenting
<xclite> lolzie, i figured it was a little contrived
<Spooner> (or attr_writer :age, of course, which does the same thing).
baphled has quit [Ping timeout: 276 seconds]
<xclite> you could extend object with a method that creates the sort of thing you're looking for
<xclite> sorry, Object
icole has joined #ruby
rdark has quit [Ping timeout: 255 seconds]
baphled has joined #ruby
g-ram has joined #ruby
<Spooner> lolzie : But anyway, even if you didn't have the attr_readers, setting values like that in Ruby would be very unusual.
<arubin-> lolzie: Why not pass that information to the constructor?
<xclite> arubin-, already covered that lol
<lolzie> I'm trying to remember where I saw this sort of pattern before, I recall it being justified in its circumstances
siyusong has quit [Quit: Computer has gone to sleep.]
<Spooner> lolzie : You could also allow Person.new age: 21, height: 180, name: "Bob" if you had a lot of values and wanted them named rather than just a big list.
FDj has joined #ruby
UberNerdGirl has quit [Quit: UberNerdGirl]
<FDj> what's the best way to create a path of nested directories? i.e. mkdir -p my/nested/directory/path ?
<Spooner> The problem with that example, is that a Person that isn't set isn't really a full person, so those sort of values should be in the constructor (or defaulted if that is appropriate). At the point of Person.new the object is actually unusable.
the_jeebster has quit [Quit: Leaving.]
bradhe_ has quit [Read error: Connection reset by peer]
Neomex has joined #ruby
<lolzie> Spooner: is that effectively a hash?
<Spooner> FDj require 'fileutils'; Fileutils.mkdir_p
<FDj> ah
<FDj> thx
bradhe has joined #ruby
<Spooner> lolzie : Yeah, it is the 1.9 hash syntax.
Goles has quit [Read error: Operation timed out]
slainer68 has joined #ruby
<Spooner> lolzie : Though if you only have 3 params, then it probably isn't such a problem if you just use ordering for parameters. I don't like using Hash options except for options, rather than to name params. Maybe in 2.0 I'll change my mind though.
akem has joined #ruby
cpruitt has joined #ruby
wuzzzzaah has joined #ruby
Xeago has joined #ruby
headius has quit [Quit: headius]
sideshowcoder has quit [Read error: Operation timed out]
<Spooner> *lolzie : Yeah, it is the 1.9 syntax for Hashes with symbolic keys.
sdwrage has joined #ruby
love_color_text has quit [Ping timeout: 264 seconds]
kirun has joined #ruby
slainer68 has quit [Ping timeout: 255 seconds]
manizzle has joined #ruby
stkowski has quit [Quit: stkowski]
love_color_text has joined #ruby
<lolzie> Spooner: cheers mate :)
lolzie has quit [Quit: Page closed]
<Spooner> lolzie the other config idiom that is popular is: Person.new do |p| p.name = "frog"; p.age = 21; end (e.g. used in gemspecs).
Neomex has quit [Quit: Neomex]
sagax has joined #ruby
Russell^^ has joined #ruby
nitti_ has quit [Remote host closed the connection]
jbw has quit [Ping timeout: 240 seconds]
phinfonet has joined #ruby
bemson has joined #ruby
chrisramon has joined #ruby
yaymukund has joined #ruby
fermion has quit [Quit: P]
<bemson> ruby noob here - anyone know if there is any gem comparable to node's express.js?
<Spooner> bemson : We probably don't know what express.js is, even if we know about similar gems.
dnstbr has quit [Quit: Computer has gone to sleep.]
<oz> Spooner: well express.js is kinda similar to Sinatra :)
<Spooner> bemson : Sinatra ;)
<bemson> Spooner: yes, sorry.. express.js lets you easily define routes for a server to respond with
kil0byte_ has joined #ruby
<bemson> Spooner: yes, I believe it borrows from Sinatra
stephh has quit [Ping timeout: 248 seconds]
<Spooner> oz Ta :D
daniel_- has joined #ruby
sent-hil has joined #ruby
stkowski has joined #ruby
kil0byte has quit [Ping timeout: 256 seconds]
apok has quit [Remote host closed the connection]
<bemson> Spooner: many thx - just found sinatrarb.com and it's exactly the same api
<bemson> thx!
love_color_text has quit [Ping timeout: 252 seconds]
apok has joined #ruby
<Spooner> bemson : Sinatra is ace, so you can't go wrong.
hotovson_ has quit [Remote host closed the connection]
BSaboia__ has joined #ruby
vlad_starkov has joined #ruby
cableray has joined #ruby
_Mon_Ouie_ is now known as Mon_Ouie
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby
love_color_text has joined #ruby
BSaboia has quit [Ping timeout: 248 seconds]
IrishGringo has joined #ruby
xorigin has joined #ruby
dmiller has quit [Remote host closed the connection]
wuzzzzaah has quit [Ping timeout: 260 seconds]
wuzzzzaah has joined #ruby
SegFaultAX|work has quit [Ping timeout: 246 seconds]
UberNerdGirl has joined #ruby
chrisramon has quit [Ping timeout: 260 seconds]
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
armenb has quit [Ping timeout: 248 seconds]
stephh has joined #ruby
yaymukund has quit [Ping timeout: 264 seconds]
Takehiro has joined #ruby
yaymukund has joined #ruby
sambio has joined #ruby
<shevy> hmm off topic... I have a .pdf file and would like to modify it. any ideas how to? like, highlight some text parts yellow
yxhuvud2 has quit [Quit: Nettalk6 - www.ntalk.de]
chrisramon has joined #ruby
yxhuvud has joined #ruby
bwlang has joined #ruby
SegFaultAX|work has joined #ruby
mneorr has quit [Remote host closed the connection]
mneorr has joined #ruby
dnstbr has joined #ruby
Doc_X has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
morozovm has quit [Quit: morozovm]
aldodelgado has joined #ruby
havenn has joined #ruby
carlyle has joined #ruby
nemesit has quit [Quit: Linkinus - http://linkinus.com]
dangerousdave has joined #ruby
Servidorv has joined #ruby
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
havenn has quit [Remote host closed the connection]
hbpoison has quit [Ping timeout: 252 seconds]
servidorv_ has joined #ruby
answer_421 has quit [Ping timeout: 276 seconds]
stephenjudkins has joined #ruby
servidorv_ has quit [Client Quit]
h4mz1d has quit [Ping timeout: 260 seconds]
Servidorv has quit [Ping timeout: 256 seconds]
swarley has joined #ruby
Xeago has joined #ruby
Floydzy has quit [Read error: Connection reset by peer]
reset has joined #ruby
Floydzy has joined #ruby
iamjarvo has quit [Quit: Computer has gone to sleep.]
fantazo has quit [Ping timeout: 255 seconds]
robert_ has joined #ruby
CaptainKnots has joined #ruby
CaptainKnots has quit [Changing host]
CaptainKnots has joined #ruby
armenb has joined #ruby
havenn has joined #ruby
Ethan has quit [Read error: Connection reset by peer]
rowsdower has joined #ruby
haxrbyte has quit [Remote host closed the connection]
Ethan has joined #ruby
iamjarvo has joined #ruby
answer_421 has joined #ruby
minijupe has quit [Quit: minijupe]
bemson has quit [Quit: bemson]
sambio has quit [Ping timeout: 256 seconds]
mmlac has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
sdwrage has quit [Quit: geekli.st/programmer]
Araxia has quit [Read error: Connection reset by peer]
Takehiro has quit [Remote host closed the connection]
sebastorama has joined #ruby
nitti has joined #ruby
glupo has quit [Remote host closed the connection]
Araxia has joined #ruby
delinquentme has left #ruby ["Leaving"]
LouisGB has joined #ruby
piotr__ has joined #ruby
piotr_ has quit [Ping timeout: 260 seconds]
bradhe has quit [Remote host closed the connection]
reset has quit [Quit: Leaving...]
JonnieCache has joined #ruby
yoklov has joined #ruby
reset has joined #ruby
ryanlecompte has quit [Remote host closed the connection]
aldodelgado has quit [Quit: aldodelgado]
Morkel_ has joined #ruby
TomJ has joined #ruby
TomJ has quit [Changing host]
TomJ has joined #ruby
<sent-hil> am i misunderstanding how set_trace_function works? https://gist.github.com/0909d88dece4481edb54
<sent-hil> should the numbers increase by one, instead of being 3 all the time?
rahul_ has joined #ruby
LouisGB has quit [Ping timeout: 260 seconds]
<sent-hil> *shouldn't?
g-ram has quit [Quit: Computer has gone to sleep.]
Morkel has quit [Ping timeout: 268 seconds]
Morkel_ is now known as Morkel
under_my_shoes has quit [Quit: Leaving]
maletor has quit [Quit: Computer has gone to sleep.]
JonnieCache has quit [Ping timeout: 244 seconds]
under_my_shoes has joined #ruby
UberNerdGirl has quit [Quit: UberNerdGirl]
Araxia has quit [Read error: Connection reset by peer]
Araxia has joined #ruby
rahul_ has left #ruby ["Leaving"]
Araxia has quit [Read error: No route to host]
nateberkopec has quit [Quit: Leaving...]
Araxia_ has joined #ruby
dnstbr has quit [Quit: Computer has gone to sleep.]
sepp2k1 has quit [Quit: Leaving.]
sepp2k has joined #ruby
Eplemosen has joined #ruby
Astral__ has joined #ruby
chin-tastic has quit [Ping timeout: 252 seconds]
g-ram has joined #ruby
Ziioynx has joined #ruby
mjbamford has joined #ruby
Astral_ has quit [Ping timeout: 252 seconds]
sideshowcoder has joined #ruby
Araxia_ has quit [Read error: No route to host]
Araxia has joined #ruby
sent-hil has quit [Read error: Connection reset by peer]
sent-hil has joined #ruby
x82_nicole has quit [Read error: Operation timed out]
tsd_usa has joined #ruby
reset has quit [Quit: Leaving...]
_cheney2 has quit [Read error: Connection reset by peer]
_cheney has joined #ruby
timonv has joined #ruby
sebastorama has quit [Ping timeout: 244 seconds]
tsd_usa has quit [Remote host closed the connection]
ShiintoRyuu has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
jenrzzz has quit [Ping timeout: 268 seconds]
sailias1 has joined #ruby
sailias has quit [Quit: Leaving.]
rumba has quit [Quit: Page closed]
Takehiro has joined #ruby
sailias has joined #ruby
sailias2 has joined #ruby
sailias1 has quit [Client Quit]
wargasm has left #ruby [#ruby]
wargasm has joined #ruby
xorigin has quit [Quit: leaving]
Floydzy has quit [Quit: Floydzy]
icooba has joined #ruby
Takehiro has quit [Ping timeout: 246 seconds]
alvaro_o_ has joined #ruby
kil0byte_ has quit [Remote host closed the connection]
sailias has quit [Read error: Operation timed out]
hsbt is now known as hsbt_away
<rking> Man, I've completely awoken from the rspec spell. For so many reasons, MiniTest is the one true way for me.
<swarley> rking; i use minitest/spec :p
<rking> My #1 complaint is that it compiles to junky ASTs. Test::Unit style is Plain Old Classes. minitest/spec fixes that somewhat
hsbt_away is now known as hsbt
freezey has quit [Quit: freezey]
love_color_text has quit [Remote host closed the connection]
h4mz1d has joined #ruby
<rking> But I've been using the non-spec minitest stuff, and I don't miss ".should" at all
hbpoison has joined #ruby
<rking> This way makes it so easy to scan and see what's boilerplate stuff versus what is assertions.
<rking> it "blah" do … end doesn't communicate any more (or even golf down) def test_blah … end
alvaro_o__ has quit [Ping timeout: 268 seconds]
mengu has joined #ruby
<swarley> rking; i like the minitest/unit stuff as well. Especially the "must" trick
<rking> I do like how really advanced use, with implied subjects, etc., can look… but I view RSpec (and specs) as an interesting but overly-fancy experiment.
<rking> swarley: Hrm, I don't know that.
love_color_text has joined #ruby
<swarley> Test::Unit is minitest by the way
<swarley> in 1.9
<ddd> hehe keep feeding me these testunit and minitest urls
<ddd> i'll take em all day long
mengu has quit [Read error: Connection reset by peer]
tomku has quit [Quit: WeeChat 0.3.7]
mengu has joined #ruby
vlad_starkov has joined #ruby
mengu has quit [Changing host]
mengu has joined #ruby
tomku has joined #ruby
<rking> swarley: What am I missing? Why would it be better to say must 'foo' do … end over def test_foo … end ?
hsbt has quit [Ping timeout: 246 seconds]
mando has quit [Remote host closed the connection]
<rking> All that does is obscure the actual method that will be created, so you have a harder time tinkering around at run-time (e.g. from within irb or pry)
<swarley> It's just for readability
<rking> That's not any more readable IMO
peregrine81 has joined #ruby
<rking> It makes you stop and say, "wait, huh… oh, Ok… I guess."
<swarley> It will say something along the lines of
<swarley> Failed test "must be empty"
<rking> Your eyes instantly filter the "def test_" part down
blazes816 has joined #ruby
<ddd> mine don't but that i think is because i'm new to it
<rking> The output of test_foo is similar
hbpoison has quit [Ping timeout: 265 seconds]
hsbt has joined #ruby
workmad3 has joined #ruby
<rking> ddd: So when you're reading somebody's suite, you feel like if you saw:
<rking> must 'swizwangle' do
jenrzzz has joined #ruby
dnyy has quit [Read error: Connection reset by peer]
<rking> That would help you more than seeing the same body prefixed by:
<rking> def test_swizwangle
<ddd> rking: for *me* yes
<rking> Kk, I appreciate that feedback.
<ddd> but again, thats probably because i'm new to tu and mt
<rking> I've seen Test::Unit style methods too much to be slowed down by that.
<rking> Actually I don't even read that thing at first, I just look at what it says after "assert…"
dnyy has joined #ruby
<ddd> to *me* that reads normal enough english to instantly grok it without the added mental step of removing the def test_ part and then going on with the test meat
<rking> Then back up to what it did to get to the assertion (and again, in Test::Unit style you can see which are the assertions and which are the setup much easier than RSpec)
<rking> *Then* I might read the name of the test
<rking> ddd: Well, for all we know "must" is some special thing that does more than simply assert.
<rking> Urr, it doesn't assert. It just runs.
<rking> I assume (after glancing around at it)
<ddd> rking: i'm actually in the process of trying to rewrite all my rspecs into minitest so i know both syntax structures.
awarner has quit [Remote host closed the connection]
<rking> That's exactly my point, we're clueless about whether it's a synonym or a subtle distinction.
<rking> ddd: Cool exercise.
<ddd> rking: come see me when i'm done. it migh tbe that with the exposure of doing so, my mind will change. idk
under_my_shoes has quit [Quit: Leaving]
sambio has joined #ruby
<rking> ddd: Are you using plymouth? It's fun.
under_my_shoes has joined #ruby
<ddd> no. i'm still in the educate-myself mode
<ddd> reading
<ddd> i've never written a single TU or MT before. read them in other people's source but not written a single one of my own
<ddd> went from cuke to turnip+rspec, to just rspec. only TFs i've used.
<rking> plymouth is a bit of an experimental workflow. Sometimes it wins, sometimes it loses.
bemson has joined #ruby
<rking> This will help a good bit: https://github.com/guard/guard/issues/344
<ddd> rking: you're referencing https://github.com/banister/plymouth#readme correct?
samphippen has joined #ruby
baphled has quit [Ping timeout: 252 seconds]
<ddd> ehh ignore that #readme part, just c7P'd my go bar
kendrick_ has quit [Remote host closed the connection]
freezey has joined #ruby
aquaranto has quit [Remote host closed the connection]
g-ram has quit [Quit: Computer has gone to sleep.]
<rking> ddd: c7P'd?
freezey has quit [Client Quit]
<ddd> huh, supports rspec too i see. i'll play with it
<ddd> hehe forgot to press shift. meant &
<rking> c&p, sorry
<rking> Hehe, yeah, not trying to give you a hard time. I thought I was about to learn some cool clipboard-related shortcut. ☹
<rking> ddd: Yeah, that plymouth.
<Eiam> if I have an array like a = ["a","z","hello","test"] and another array thats b= ["z","a","yo","hello"], I want to sort b so it matches a as closely as it can in order
<rking> BTW be warned that it will work with rspec, but it'll work better with Test::Unit
<ddd> rking: thanks. i'll spend the weekend playing with it then.
<Eiam> so b would be sorted like ["a","z","hello","yo"]
<rking> ddd: Please do. There are lots of exciting possibilities for streamlining the testing process through something like this.
<ddd> rking: btw, still wanting to do the docs, just working on some stuff before i get to that.
walbert has joined #ruby
baphled has joined #ruby
<graft> hey anyone know a good colormapping gem?
<rking> ddd: Yep, same here man.
<ddd> kids interupting mostly hehe
<swarley> graft; for what?
<graft> for, say, turning 0.0-1.0 to colors from blue to red
<Spooner> Eiam: b.sort_by {|x| [a.index(x), a] }
<yxhuvud> eiam: b.sort_by {|el| a.index(el)}
<rking> Winner: yxhuvud.
reset has joined #ruby
<Spooner> rking Not on my screen ;)
<rking> Oh snap
<Eiam> i see Spooner first
<Eiam> hehe
<Eiam> ill give it a worl
<yxhuvud> not on mine either.
<Eiam> whirl
<Eiam> thakns
frogprince_mac has quit [Ping timeout: 260 seconds]
<rking> Nono, I mean by virtue of a simpler solution in (almost) the same time.
<Spooner> Eiam : However, the answers are different. Depends how you want things sorted if they aren't in the a list.
<rking> Actually, yxhuvud's fails
under_my_shoes has quit [Ping timeout: 246 seconds]
<rking> So does Spooners.
stephenjudkins has quit [Quit: stephenjudkins]
deadalus has quit [Ping timeout: 256 seconds]
<rking> You guys just sketch straight into IRC? =P
<yxhuvud> yes?
zigomir has quit [Quit: Leaving]
<Spooner> Yep ;) I was in a race...
<rking> b.sort_by {|el| a.index(el) || 0}
<swarley> :p i never test my one liners before posting them
<rking> Un-pro.
<swarley> Well, my correct to incorrect ratio is pretty good so far
<yxhuvud> rking: uh. that will position all the unincluded matches along with the first element.
<Spooner> rking : Still doesn't give ["a","z","hello","yo"], but it doesn't fail ;)
<swarley> so i'd say i'm doing pretty well
<rking> Here's the one-liner for the incurably lazy: gem install pry && pry -e ' a = ["a","z","hello","test"] ; b= ["z","a","yo","hello"]; b.sort_by {|el| a.index(el) || -1}'
havenn has quit [Remote host closed the connection]
<rking> Spooner: How can you get "yo" out of "test"?
<swarley> lol
<swarley> <Eiam> so b would be sorted like ["a","z","hello","yo"]
<swarley> rking; how do you get test out of yo?
Araxia has quit [Read error: No route to host]
<Spooner> rking : b.sort_by {|x| a.index(x) || Float::INFINITY } Is strictly correct ;) However, how it works with multiple unfound elements is undefined by the original spec :D
mockra has joined #ruby
Araxia has joined #ruby
<swarley> wait what are we doing?
<yxhuvud> I suppose (a & b) + (b - a) might work too
<swarley> What is the goal?
jitesh_shetty has quit [Remote host closed the connection]
<yxhuvud> though it depends on how duplicates should be handled
nemesit has joined #ruby
<rking> swarley: The input says "test" and the output says "yo"
<rking> Spooner: I like that.
<Spooner> a = ["a","z","hello","test"]; b= ["z","a","yo","hello"]; something to get ["a","z","hello","yo"] by sortin b as much as possible similarly to a.
<swarley> ah
<rking> Spooner: Either Float::INFINITY or -1 are right answers
<swarley> hm
<pothibo> can you manipulate a?
Servidorv has joined #ruby
<Spooner> rking : No, since in the example output, the unfound item is at the end, so -1 is not correct.
Dreamer3 has joined #ruby
caleb_io has quit [Quit: Leaving...]
<rking> Spooner: Aha, I missed his 2nd line. You're right.
<swarley> b = a (b-a)
<swarley> :)
<Dreamer3> Something.new() => nil - can i write code to do that?
codezombie has joined #ruby
Ziioynx has quit [Remote host closed the connection]
<swarley> err
mneorr has quit [Remote host closed the connection]
<Spooner> rking : However, I failed in my original, so I count it as a shared victory ;)
nwertman has joined #ruby
<yxhuvud> swarley: no. you have to remove the parts of a that isn't in b. Also, duplicates.
<pothibo> b = (a & b).uniq ?
<Spooner> Dreamer3 : That makes no sense whatsoever. You could do it but it would be fundamentally wrong :D
<codezombie> can anyone take a look at this, and let me know if I'm doing anything incredibly stupid? I'm trying to efficiently convert a PDF to JPG, and resize to various versions for display.
mneorr has joined #ruby
<Dreamer3> Spooner: how would i do it?
<Dreamer3> Spooner: i have a class and if it's passed nil instead of a data structure i'd prefer it return nil
<Spooner> Dreamer3 : Yes, but you know then that you are making it impossible to actually create an object?
<Dreamer3> Spooner: i want to do it conditionally
<Spooner> Dreamer3 : The correct way to deal with that is to raise an exception if the data is wrong.
<Dreamer3> nil is allowed
Gajanan has joined #ruby
<Dreamer3> you mean raise and rescue? i see… i'd prefer the constructor just be able to handle it but i didn't know if ruby could do that
under_my_shoes has joined #ruby
<Dreamer3> Generic.new(nil) => nil; Generic.new("blah") => <Generic>
<Ivo> If I want to create a hash which uses an array for keys and the values all '1', what's the nicest way to do that?
<swarley> (a - (b-a))
deadalus has joined #ruby
deadalus has quit [Changing host]
deadalus has joined #ruby
<swarley> oh
krawchyk has quit [Remote host closed the connection]
<swarley> i was trying to get
<pothibo> ((a&b) + b).uniq
<yxhuvud> swarley: no. that will give you a list of all elements in a that isn't in b.
<Spooner> Dreamer3: Yes, you should raise on a constructor error. Doing it the other way is just wrong. You _could_ however, make a different constructor: def Generic.moop(arg); arg ? Generic.new(arg) : nil; end
<swarley> "yo", so i had it right
<swarley> i changed it to get the opposite
awarner has joined #ruby
<pothibo> I didn't see you had to keep the "yo"
<swarley> (a - (a-b)) + (b-a) :p
Gajanan has quit [Client Quit]
<Spooner> swarley And sort them based on the postion in a.
<swarley> That's what I had before i started working on the wrong thing
<swarley> Ah, good point
<Dreamer3> Spooner: ha, why didn't i think of that :)
<swarley> - doesnt care
recycle has joined #ruby
<pothibo> am I gettting ignored?
<yxhuvud> swarley: go back up your scrollback and read my previous answer using & - and +.
dylanjha has quit [Quit: Leaving...]
<Spooner> Dreamer3 : Oh good. I persuaded you not to break .new for humanity ;)
recycle has quit [Remote host closed the connection]
<swarley> Does position in b matter?
sideshow1oder has joined #ruby
<Spooner> swarley: No idea, we got lost and I think the questioner fell in a pit trap.
SJr has quit [Excess Flood]
sideshowcoder has quit [Ping timeout: 252 seconds]
SJr has joined #ruby
SJr has quit [Excess Flood]
slainer68 has joined #ruby
deadalus has quit [Ping timeout: 264 seconds]
piotr__ has quit [Read error: Operation timed out]
rubious has quit [Read error: Connection reset by peer]
`brendan has quit [Ping timeout: 276 seconds]
rubious has joined #ruby
c0rn_ has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
SJr has joined #ruby
piotr_ has joined #ruby
judd7 has joined #ruby
caleb_io has joined #ruby
<Spooner> Ivo h = [:a, :b].each_with_object({}) {|e, h| h[e] = 1 }; h[:a] #=> 1
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
fantazo has joined #ruby
awestroke has quit [Remote host closed the connection]
<mr-rich> Is there a way to quell warnings within a ruby script? Because of rvm, I have to shebang the call to ruby (#!/usr/bin/env ruby) and it does not allow the passing of arguments like -W0 ...
bradhe has joined #ruby
Eplemosen has quit [Quit: Hexchat FTW! http://www.hexchat.org/]
<swarley> spo12;
<swarley> ...
<swarley> sorry
<swarley> Spooner; i found a solution!!!... its probably able to be optimized, have fun
<swarley> [26] pry(main)> (a.each_with_object([a.dup, b.dup, [], []]) {|x,y| if(y[1].include? y[0][0]) then y[2].push y.first.shift; y[1].delete(y[2].last); else y.last.push y[0].shift end })[2,3].flatten
<swarley> => ["a", "z", "hello", "test"]
<Spooner> swarley : You are perverse.
<swarley> indeed
<swarley> wait
<Spooner> Pity the output should be ["a","z","hello","yo"] :D
<swarley> I totally missed using the each lol
<swarley> WAT
<swarley> damn it
nina has joined #ruby
<swarley> it should be
<Spooner> Output should be elements of b, ordered the same as a (with elements not in a at the end).
<swarley> else y.last.push y[1].shift
mark_locklear has quit [Remote host closed the connection]
<swarley> Yeah, that's probably not the best way to do it.. but it works
yekta has quit [Quit: yekta]
<Spooner> Poor guy who asked the question never thought it would take 1000 lines of of IRC to solve ;)
<swarley> LOL
<swarley> It was probably an exercise in a book too
maletor has joined #ruby
yoklov has quit [Quit: bye!]
<shevy> hmm
<shevy> I have something like this right now...
<shevy> user_input = $stdin.gets.chomp
<swarley> mk?
<shevy> and then, I have two case/when menus.
<swarley> "The essence of XML is this: the problem it solves is not hard, and it does not solve the problem well." -- Phil Wadler, POPL 2003
<shevy> the first acts on the first word (until ' ' was found), the second acts on all words
sdwrage has joined #ruby
Neomex has joined #ruby
Neomex has quit [Client Quit]
<shevy> I dont remember why I wanted to use two different case / when menus back then... hmmm
<shevy> but it annoys me!
haxrbyte has joined #ruby
<shevy> I dont remember why I did that
invisime has quit [Quit: Leaving.]
cpruitt has quit [Quit: cpruitt]
haxrbyte has quit [Remote host closed the connection]
elaptics is now known as elaptics`away
<shevy> this will be one huge case / when menu
<shevy> like 3000 lines
robustus has joined #ruby
NemesisD has joined #ruby
<Spooner> swarley : "The essense of XML is that regardless of how bad it is, it is still getting used almost ubiquitously because people have sunk so much time working with it in the past" -- Spooner 2012
Takehiro has joined #ruby
<NemesisD> hi all, i've got a datetime in the format of 2012-10-19 16:18:15, I'm pretty sure that's eastern time. is there a reliable way to parse it to UTC?
bradhe has quit [Ping timeout: 244 seconds]
Morkel has quit [Quit: Morkel]
<workmad3> Spooner: added to which, XML isn't actually too bad... just it's used for so many fracking unsuitable things
<swarley> no its just awful
<NemesisD> i can't just add -0500 to the end of it because that number changes according to daylight savings time. i'd prefer to not add activesupport as a dependency as well
<swarley> it looks awful, its terrible to write
<swarley> 0 readability
<workmad3> swarley: it's actually a really nice, readable format for some things
geekbri has quit [Remote host closed the connection]
<workmad3> swarley: but most of those aren't the things that it's used for
<swarley> Usually when i see something using XML i say to myself
<swarley> "Wow, if only this used YAML or JSON"
bigmcq77 has quit [Quit: Computer has gone to sleep.]
<swarley> "Maybe i could see what the hell was going on"
Takehiro has quit [Ping timeout: 246 seconds]
<troessner> :D
<troessner> same with me swarley
<troessner> but i guess the same goes for EVERY non java dev
<swarley> i understand that sometimes you want a schema or whatever
<workmad3> troessner: I'm no java dev :P
<troessner> workmad3, no offense.:)
awestroke has joined #ruby
sailias2 has quit [Quit: Leaving.]
<troessner> to be fair, 80% of all java devs i know prefer json over xml
<workmad3> sometimes XML fits... I don't find YAML more readable for largish tree structures, for example, and I don't find large JSON readable at all
<troessner> so there IS progress
<troessner> :)
mando has joined #ruby
<workmad3> but there's a massive amount of XML misuse, and I certainly don't think it's very good for machine-machine communication :)
icole has quit [Ping timeout: 260 seconds]
nitti has quit [Remote host closed the connection]
hbpoison has joined #ruby
robertotauille has quit [Quit: Leaving...]
<swarley> its too big for machine to machine
<swarley> having all of the open and close tags
<Servidorv> hey guys how are you??
<troessner> actually I'd say if you have huge xml trees your data abstractions are wrong
<troessner> but that's a cheap shot, i know
<workmad3> troessner: not huge, just largish ;)
Bosma has quit [Quit: leaving]
<troessner> ah, there's a difference, i see..:D
<swarley> Yeah, XML should be reserved for standardized variance
nitti has joined #ruby
<swarley> where things can be wildly different
<swarley> but sort of the same
burgestrand has joined #ruby
<swarley> i.e HTML
ryanlecompte has joined #ruby
drago757 has joined #ruby
sdwrage has quit [Read error: Connection reset by peer]
nitti has quit [Remote host closed the connection]
timonv has quit [Remote host closed the connection]
hbpoison has quit [Ping timeout: 276 seconds]
LucidDreamZzZ has quit [Remote host closed the connection]
iamjarvo has quit [Quit: Computer has gone to sleep.]
skaczor has joined #ruby
Xeago has quit [Remote host closed the connection]
burgestrand has quit [Quit: Leaving.]
troessner has quit [Quit: Leaving]
conor_ireland has joined #ruby
timonv has joined #ruby
stephenjudkins has joined #ruby
caleb_io has quit [Quit: Leaving...]
g-ram has joined #ruby
MrVamp has joined #ruby
manizzle has quit [Ping timeout: 252 seconds]
blazes816 has quit [Quit: blazes816]
asobrasil has left #ruby [#ruby]
bradhe has joined #ruby
<MrVamp> is someone here on the CS169.1x ?
<swarley> ?
nitti has joined #ruby
<MrVamp> its an online course
<MrVamp> and is using Ruby
<MrVamp> :d
nitti has quit [Remote host closed the connection]
<conor_ireland> MrVamp: any good? what level is it at?
<MrVamp> saas
GoGoGarrett has quit [Remote host closed the connection]
<conor_ireland> ah
<MrVamp> check it out at edx.org
<conor_ireland> I watched some of that last time, did some of the assignments too
icole has joined #ruby
<MrVamp> im really newbee on programation and got stuck in some things...
jenrzzz has joined #ruby
<MrVamp> wonder if someone could assist or kind og walkthrought
<conor_ireland> MrVamp: someone might, you will have to ask a question to find out though
<Spooner> MrVamp : Don't ask us. We are the worst kind of Roobs.
<conor_ireland> My Ruby is just poor php and some decent java in ruby syntax
graft has quit [Ping timeout: 272 seconds]
bluOxigen has quit [Ping timeout: 276 seconds]
Araxia_ has joined #ruby
<MrVamp> lol
Araxia has quit [Read error: No route to host]
Araxia_ is now known as Araxia
bapa has joined #ruby
<Spooner> MrVamp : But yes, since we have varying interests and specialities, it is best to ask so that we can decide to answer, not ask for an individual who knows the answer to all questions.
timonv has quit [Remote host closed the connection]
<conor_ireland> Spooner: where is that person, I would like to meet them
under_my_shoes has quit [Quit: Leaving]
g-ram has quit [Quit: Computer has gone to sleep.]
under_my_shoes has joined #ruby
<Spooner> conor_ireland : She's too busy to hang out in #ruby to answer questions ;)
tommyvyo has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
<conor_ireland> Spooner: good point, haha
mneorr has quit [Remote host closed the connection]
<MrVamp> haha thanks people
mneorr has joined #ruby
sepp2k has quit [Remote host closed the connection]
philcrissman has quit [Remote host closed the connection]
havenn_ has joined #ruby
rburton- has joined #ruby
devdazed has quit [Quit: Bye]
mneorr has quit [Remote host closed the connection]
mneorr has joined #ruby
Araxia has quit [Ping timeout: 246 seconds]
<MrVamp> in %td= link_to "#{movie.release_date}", movie_path(movie) how to i change the output from 1992-11-25 00:00:00 UTC to 1992-11-25 ?? anu sugestion :D
<conor_ireland> use a formatting method on that release_date most likely
<Spooner> MrVamp : #strftime
<asteve> strftime
<asteve> damn, too late
stephh has quit [Ping timeout: 248 seconds]
peregrine81 has quit [Quit: Goodbye.]
<asteve> but, .strftime("Y-m-d")
<swarley> %Y-%m-%d
<asteve> that's what I said
<MrVamp> ok let me try, thanks steve
<Spooner> I was letting MrVamp look it up ;)
stephenjudkins has quit [Quit: stephenjudkins]
<asteve> Spooner: don't let people think for themselves
<swarley> But without % :p
<asteve> you'll never create sheeps
<asteve> swarley: I'm pretty sure they're there
<conor_ireland> I don't like how ruby uses functions sometimes but methods other times, is date not an object?
<swarley> <asteve> but, .strftime("Y-m-d")
<asteve> [17:11:32] <asteve> but, .strftime("%Y-%m-%d")
<Spooner> conor_ireland : No functions there.
<asteve> see
nemesit has quit [Quit: Leaving...]
<asteve> swarley: you must have a problem with your monitor
<Spooner> conor_ireland : In fact, not a single function in Ruby.
DrShoggoth has joined #ruby
<conor_ireland> Spooner: oops, was looking online missed the t. part, it is a method my bad
<swarley> I dont know
<swarley> I'm pretty sure you didnt put the %
nyrb has quit [Remote host closed the connection]
stephenjudkins has joined #ruby
<Spooner> conor_ireland : Even the things that look like functions (e.g. puts) are actually methods on Kernel and call $stdout.puts
under_my_shoes has quit [Quit: Leaving]
<conor_ireland> Spooner: operators too
<Spooner> Indeed yes.
under_my_shoes has joined #ruby
<conor_ireland> I got very mixed up for a second, my bad
enricostn has joined #ruby
Virunga has quit [Remote host closed the connection]
lobak_ has quit [Read error: Connection reset by peer]
lobak has joined #ruby
<enricostn> does anybody know why ruby is no more supported by GTK+? http://www.gtk.org/language-bindings.php
<Spooner> enricostn : BEcause noone kept them up to date.
<Spooner> *kept the bindings
<swarley> how do you check included modules?
<Spooner> I heard someone talking about plans to wrap GTK3 only this week, but I'm not sure where they'd get with it.
Servidorv has quit [Ping timeout: 260 seconds]
<enricostn> Spooner, does it means that no one is using ruby with gtk+ ?
<swarley> People use it
<swarley> just no one is maintaining the gem
<swarley> because a project that big, is just not fun to wrap
<Spooner> Yes, but I'd guess that by now it only supports a very, very old version of GTK and probably doesn't support Ruby 1.9.
awestroke has quit [Remote host closed the connection]
<swarley> Spooner; it supports 1.9
<swarley> the gnome version at least
<enricostn> what gui library do you suggest to build linux based apps?
nemesit has joined #ruby
<swarley> I would recommend WX widgets
<swarley> since its cross system compatible
under_my_shoes has quit [Quit: Leaving]
<swarley> but here is the ruby gnome 2 page http://ruby-gnome2.sourceforge.jp/
neku has joined #ruby
love_color_text has quit [Remote host closed the connection]
under_my_shoes has joined #ruby
<Spooner> FOX toolkit has long since lapsed (and definitely doesn't supoprt 1.9). I used to use that.
<swarley> I personally use wx if i really NEED too
love_color_text has joined #ruby
dylanjha has joined #ruby
<enricostn> I'm planning to write a twitter client for linux in ruby
yxhuvud has quit [Ping timeout: 272 seconds]
<enricostn> so, I'll give a look to WX
<swarley> oh, use wx widgets
<enricostn> thanks
<swarley> it uses GTK
<swarley> as its backend
<enricostn> ok
<swarley> also, you'll need oauth of course
apok_ has joined #ruby
caleb_io has joined #ruby
carloslopes has quit [Quit: Leaving.]
<enricostn> swarley, sure
<swarley> Code academy had a good article on a client in python
carl_ has joined #ruby
<enricostn> oh
carl_ has quit [Client Quit]
s0ber has quit [Read error: Connection reset by peer]
locriani_ has joined #ruby
love_color_text has quit [Ping timeout: 246 seconds]
apok_ has quit [Remote host closed the connection]
apok_ has joined #ruby
apok has quit [Read error: Connection reset by peer]
apok_ is now known as apok
stephh has joined #ruby
s0ber has joined #ruby
locriani has quit [Ping timeout: 265 seconds]
ryanlecompte has quit [Remote host closed the connection]
asteve has quit []
sideshow1oder has quit [Ping timeout: 256 seconds]
caleb_io has quit [Quit: Leaving...]
judd7 has quit [Quit: judd7]
nwertman has quit [Quit: leaving]
nwertman has joined #ruby
stephh has quit [Ping timeout: 260 seconds]
Dreamer3 has quit [Quit: Computer has gone to sleep.]
bbttxu has quit [Quit: bbttxu]
Dreamer3 has joined #ruby
yaroslav has joined #ruby
khakimov has joined #ruby
hotovson has joined #ruby
hotovson has quit [Remote host closed the connection]
sideshowcoder has joined #ruby
JonnieCache has joined #ruby
under_my_shoes has quit [Quit: Leaving]
MrVamp has left #ruby [#ruby]
under_my_shoes has joined #ruby
mucker has quit [Quit: leaving]
jgrevich has joined #ruby
medik has joined #ruby
swarley has quit [Ping timeout: 272 seconds]
walbert has quit [Remote host closed the connection]
nemesit has quit [Quit: Leaving...]
carlyle has quit [Remote host closed the connection]
Takehiro has joined #ruby
cdzombak has quit []
vlad_starkov has quit [Remote host closed the connection]
JonnieCache has quit [Read error: Operation timed out]
rasbonics has joined #ruby
bemson has quit [Quit: bemson]
justinmcp has joined #ruby
Takehiro has quit [Ping timeout: 244 seconds]
stephh has joined #ruby
caleb_io has joined #ruby
rburton- has quit [Quit: Linkinus - http://linkinus.com]
sideshowcoder has quit [Ping timeout: 246 seconds]
hbpoison has joined #ruby
arietis has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
caleb_io has quit [Client Quit]
yoklov has joined #ruby
love_color_text has joined #ruby
<rking> Hehe, in this gem, somebody uses a temp var "map" and another "inject", for random things.
<rking> Kinda confusing to read.
<rking> (Within 3 lines of each other, BTW.)
<Spooner> Any reason why I should get a certificate verify failed error pushing a gem? I have double-checked my ./gem/credentials file is correct.
sdwrage has joined #ruby
swarley has joined #ruby
sdwrage has quit [Read error: Connection reset by peer]
<Spooner> rking : in making games, I often confuse myself by having a map object ;) But at least that is a map.
sent-hil_ has joined #ruby
timonv has joined #ruby
<conor_ireland> x_map
sdwrage has joined #ruby
<rking> map_ maybe?
<Spooner> rking : I used to work with a "professional" programmer who named all his variables after characters/creatures in the LotR books. Needless to say, they couldn't fire him ;)
<rking> I think that's a Python custom (because they have so many important things in global namespace)
dmerrick has quit [Ping timeout: 246 seconds]
<Paradox> Spooner, map inherits enumerable which lets you map maps
<rking> Spooner: That's cool. I like that guy.
caleb_io has joined #ruby
<rking> "Code obscurity is job security." — Ingy döt Net
<conor_ireland> except at a good company
<Spooner> rking : When he wasn't doing that, he was sleeping or playing flash games. It was not terribly good for morale that he literally couldn't get himself fired for that ;)
sent-hil has quit [Ping timeout: 260 seconds]
answer_421 has quit [Ping timeout: 276 seconds]
<caleb_io> rking maybe when you've been employed 5 years.. if you go into a company and start writing obscure code, I feel that you wouldn't last very long ;P
<caleb_io> unless you're the only programmer.
<rking> Oh yeah
<rking> You gotta give it that first month of pretending to try.
<rking> If I was malicious, I'm 100% sure I could get hired at a series of 3 or 4 jobs in sequence and get paid by doing this maneuver.
<caleb_io> exactly. then you're valued when the other programmers can't figure out what you're typing ;) you appear.... more intelligent.
<conor_ireland> unless they have code reviews, like any decent company
<rking> Just work a bit, ensconce a bit, chill a lot.
<rking> conor_ireland: Sure. And decent companies are what, 1 out of 10?
<Spooner> rking yeah, I was going to say that :D
<rking> You could get hired on the 9 out of 10 companies and do just enough to be unfirable, then go play in the daisies for a living.
<caleb_io> that's why you work in internal tools... surely anything you make could be an internal tool ;)
<caleb_io> you just happen to create a media encoder to watch a movie.
<rking> Haha
<conor_ireland> rking: yes, but I would sooner actually work there than get an easy "for-life" job writing obscure code at a bad one
under_my_shoes has quit [Quit: Leaving]
Faris has joined #ruby
<rking> conor_ireland: Absolutely my man. I'm just talking a hypothetical, here.
under_my_shoes has joined #ruby
<conor_ireland> rking: yeah, I agree with the point and have seen it several times
<conor_ireland> but it is a generally silly one imo
erichmenge has joined #ruby
rowsdower has quit [Quit: Konversation terminated!]
theRoUS has quit [Ping timeout: 264 seconds]
<swarley> If i get hired, I'll just use a code compresser to take out all unnecessary spaces, tabs, and new lines. Then store the original code on a flash drive that i'll keep in my closet c:
Monie has joined #ruby
Monie has quit [Changing host]
Monie has joined #ruby
<swarley> boom stupid job security
erichmenge has quit [Client Quit]
<Spooner> swarley : If you were serious, you'd write all your code as regexps!
<conor_ireland> as butterfly flaps
<swarley> LoL
h4mz1d has quit [Ping timeout: 246 seconds]
<swarley> conor_ireland; nice xkcd reference :p
<conor_ireland> love xkcd
vhd has joined #ruby
<caleb_io> anyone see opal today? the ruby -> javascript compiler?
Faris has quit [Client Quit]
<Spooner> swarley : The problem with the white-space remover is that you can jsut spit it through some sort of lint to get it all formatted again. You need to auto-rename all methods and variables as x_000001, etc too, for that to work properly.
armenb has quit [Ping timeout: 260 seconds]
<caleb_io> Spooner: can obfuscate like Google does.
<rking> Spooner: Dude, that's a serious option.
<rking> Just do it gentler than that
<rking> Make a code half-obscurer
aajjbb has joined #ruby
codezombie has quit [Quit: Linkinus - http://linkinus.com]
<rking> I plan on making a project where, in vim, before I edit any files I gg=G, but after I'm done I :%ce
nitti has joined #ruby
<rking> Or :%ri, I haven't decided.
<rking> But if you did a subtle form of that you could be absolutely irremovable.
burgestrand has joined #ruby
alanp_ has joined #ruby
alanp_ has quit [Read error: Connection reset by peer]
<Spooner> Ultimately, though, they could fire you and get someone to rebuild it. You need to make sure the thing you make is core functionality and not easily replicable.
Pip has joined #ruby
<Pip> Any good IDE for ruby on windows?
<Spooner> I think slacking, at that level, is probably hard work ;)
icooba has quit [Quit: Computer has gone to sleep.]
alanp_ has joined #ruby
<Spooner> pip I use Rubymine
<conor_ireland> rking: I have a feeling some people have that option by the way some of their code is
<swarley> Spooner; i could always just encrypt the code with a salted encryption
<Pip> Spooner, Is it free software?
<swarley> also, did you guys know that begin; rescue; end structures have an else clause for if rescue is never reached?
<Spooner> swarley : Yeah, but you'd have to unencrypt it at run-time, so they could access it easy enough.
<swarley> Because i didnt
timonv has quit [Remote host closed the connection]
<rking> conor_ireland: Yes, but then *they* have to deal with it. What's that one "cleverness principle", Kernigan I think, that says "Later on, I'll have less context than I do now. So, by definition, if I write the cleverest code possible, I'll be unable to understand it afterward."
jeffreybaird has quit [Quit: jeffreybaird]
<Spooner> Pip nope. You didn't specify (I use a free version though, since I only make free, open source software with it).
<conor_ireland> rking: sometimes, a lot of the time, they don't have to deal with it
mjbamford has quit [Quit: Leaving...]
<Pip> Spooner, Is there a free version of it?
<conor_ireland> Pip: netbeans
<Spooner> Pip No, you have to apply for a free license to use it for non-commerical open source work.
<caleb_io> pip I also use RubyMine, I like it. I know that Aptana has one I think.
<conor_ireland> not based off that, it is just a great free ide that is decent with ruby
<Spooner> pip 30 day trial though.
<Pip> conor_ireland, Isn't it outdated plugin?
<caleb_io> RadRails I think, never used it.
nitti has quit [Ping timeout: 246 seconds]
* Pip forgets about Rubymine
<caleb_io> And NetBeans has a ruby plugin for an older NetBeans.
<conor_ireland> Pip: yeah, still works though
<rking> It's Kernigʜan, and, "Everyone knows that debugging is twice as hard as writing a program in the first place. So if you're as clever as you can be when you write it, how will you ever debug it?"
<caleb_io> If you do a lot of Ruby/Rails pip, RubyMine is worth the cost imo.
<conor_ireland> I used textmate, no windows version
<Pip> I don't want to pay half a penny for this
mjbamford has joined #ruby
* Pip goes to install ruby plugin for netbeans
<caleb_io> Aptana RadRails is free.
<caleb_io> and open source.
icooba has joined #ruby
<caleb_io> it's built on eclipse I think though.
bwlang has left #ruby [#ruby]
alanp has quit [Ping timeout: 276 seconds]
<Pip> Is it better than netbeans?
<caleb_io> I used to use Zend Studio for Eclipse for PHP, and really liked Eclipse.
<Spooner> caleb_io : As you say, I think it would be worth it if you used it commercially...and if you are non-commercial it is free. Nothing to complain about there.
<caleb_io> and used Aptana Studio as well and liked it, so I can imagine RadRails would be good.
<caleb_io> Spooner: I use it both at work (commercially) and at home (paid for even though I only use it for non-commercial)
<Spooner> caleb_io : I'll pay for it if I ever manage to get paid for Ruby, which is unlikely :D
zodiak has quit [Ping timeout: 244 seconds]
<caleb_io> haha why is that.
Dreamer3 has quit [Quit: Computer has gone to sleep.]
hadees has quit [Quit: hadees]
<swarley> i would love to get paid for ruby
<swarley> but i know i probably wont
<Spooner> swarley : If I give you $1 for Ruby and you give me $1 for Ruby, then we both get paid ;)
<caleb_io> why not? j/w.
<swarley> Ya
<swarley> The most likely way currently that you would get paid to code in ruby is rails
<Spooner> caleb_io Because he thinks he sucks and I know I suck.
<swarley> i suppose i could force myself to use rails..
<swarley> Spooner; no you dont lol
koivula has quit [Ping timeout: 240 seconds]
<swarley> also, aren't you working on the new make system?
koivula has joined #ruby
<Spooner> swarley : Make? Nope.
roychri has quit [Quit: And that's the way the cookie crumbles!]
<swarley> I can't remember what it was
<Spooner> Do you mean Releasy?
<swarley> what's your github page?
<swarley> Yes that
Montas has quit [Quit: Page closed]
<caleb_io> hey I suck too but got hired. I did PHP for a decade and got hired for Ruby and just learn as I go.
<swarley> caleb_io; doing rails work?
iamjarvo has joined #ruby
<caleb_io> yep
c0rn_ has quit []
locriani_ has quit [Read error: Connection reset by peer]
<swarley> yeah that's the thing
<davidcelis> careful...
<caleb_io> but I do just plain ruby as well, a lot of our internal stuff just relies on Ruby.
locriani has joined #ruby
<swarley> oh cool
mmitchell has quit [Ping timeout: 268 seconds]
Ivo has quit [Quit: WeeChat 0.3.9]
Ivo has joined #ruby
robustus has quit [Quit: ZNC - http://znc.in]
<Spooner> caleb_io : When can swarley start? He'll code for food stamps, you know!
<swarley> I indeed
robotmay has quit [Read error: Connection reset by peer]
<swarley> I already code constantly anyway
<swarley> might as well get paid for it
<davidcelis> swarley: ABC
<Spooner> swarley : If you are getting paid for it, though, you aren't allowed to build XML parsers.
<davidcelis> err, ABS
robotmay has joined #ruby
tomsthumb has quit [Quit: Leaving.]
tommyvyo has joined #ruby
<swarley> Spooner; I'm currently converting rapidxml's header to C. I'll write my own parser after i've had more time to spend on theory and design.
<Eiam> swarley, rking sorry I had to step out to some meetings. You were correct in that unfound items are just appended at the end and their order isn't 'relevant' as long as they are at the end
<Pip> At least Python has IDLE
<swarley> davidcelis; ?
<davidcelis> swarley: ALWAYS BE SHIPPING
<swarley> I don't get it :S
<davidcelis> Always. Be. Shipping.
<swarley> so
Ethan has quit [Quit: i use linux l o l]
<swarley> basically, get my ass to work
mneorr has quit [Remote host closed the connection]
<Eiam> Spooner ^ you too
mneorr has joined #ruby
<Eiam> Spooner for the re: the sorting question
<Spooner> Eiam : Yeah, we discussed the finer points for about an hour or so :D
<swarley> xD
<Spooner> It gave us something to do.
<swarley> did you see my massive disgusting result? :p
<Eiam> i saw sort_by {|x| a.index(x) || Float::INFINITY }
<Eiam> or are you talking aout the pry?
<Eiam> i saw that too =)
<swarley> i dont know if its very ethical to show you what i came up with :p
<Spooner> That was the right one. The others were interesting, but wrong.
mneorr has quit [Remote host closed the connection]
<swarley> Spooner; technically mine worked
undersc0re97 has joined #ruby
undersc0re97 has joined #ruby
undersc0re97 has quit [Changing host]
mneorr has joined #ruby
<Spooner> swarley : Technically def answer(a, b); return expected_result; end is actually right if you input an expected a and b.
<vhd> The * operator before a function parameter definition, is equivelent to specifying an optional amount of parameters, yes?
<Spooner> I should have done that.
<swarley> well, mine worked
<swarley> it was just
<swarley> evil scientisty
<burgestrand> vhd: 0 to n, yes
daniel_- has quit [Read error: Connection reset by peer]
daniel_-_ has joined #ruby
<burgestrand> vhd: unless something comes after it
<Spooner> vhd It does, putting the arguments into an array.
<vhd> thank you
<swarley> def foo(*bar); puts bar.inspect; end; foo("hello", "world");
<swarley> ["hello", "world"]
NemesisD has quit [Quit: leaving]
fixl has joined #ruby
xclite has quit [Remote host closed the connection]
joshman_ has quit [Ping timeout: 272 seconds]
<matti> Woohoo
<matti> /opt/ruby/bin/ruby: ELF 64-bit LSB executable, x86-64, version 1 (FreeBSD), dynamically linked (uses shared libs), for FreeBSD 9.0 (900044), not stripped
<matti> ;d
bemson has joined #ruby
undersc0re97 has quit [Quit: i use linux l o l]
mengu has quit [Remote host closed the connection]
jamjam has quit [Ping timeout: 256 seconds]
<Eiam> well, i just tested it and it appears sort_by {|x| a.index(x) || Float::INFINITY } does indeed do exactly what I was expecting
caleb_io has quit [Quit: Leaving...]
chin-tastic has joined #ruby
<Eiam> based on the spec provided and maybe things I forgot to mention, it behaves correctly for what I was after
g-ram has joined #ruby
justinmcp has quit [Remote host closed the connection]
mneorr has quit [Ping timeout: 272 seconds]
v0n has quit [Ping timeout: 260 seconds]
hbpoison has quit [Ping timeout: 244 seconds]
undersc0re97 has joined #ruby
<Eiam> time to figure out what the hell float::infinity means =p
undersc0re97 has quit [Changing host]
undersc0re97 has joined #ruby
hadees has joined #ruby
Astral__ has quit [Ping timeout: 260 seconds]
<burgestrand> infinity
chin-tastic has quit [Read error: Operation timed out]
Solnse has joined #ruby
kirun has quit [Quit: Client exiting]
gmurphey has quit [Ping timeout: 252 seconds]
kkiero has joined #ruby
Nisstyre-laptop has joined #ruby
yaroslav has quit [Quit: yaroslav]
<kkiero> hi, do you know any website with simle or maybe not ruby task to make knowledge about programming/ruby better?
<kkiero> *simple
Araxia has joined #ruby
Takehiro has joined #ruby
burgestrand1 has joined #ruby
<undersc0re97> kkiero: Koans
aantix_ has joined #ruby
<davidcelis> kkiero: Koans
axl__ has quit [Quit: axl__]
Ankhers has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
dangerousdave has quit [Ping timeout: 256 seconds]
mmlac has quit [Quit: mmlac]
burgestrand has quit [Ping timeout: 246 seconds]
walbert has joined #ruby
aantix has quit [Ping timeout: 260 seconds]
aantix_ is now known as aantix
neku has quit [Quit: Linkinus - http://linkinus.com]
Takehiro has quit [Ping timeout: 265 seconds]
<kkiero> ok thanks, but I thought more of simple kind of algorithms task to get to know ruby better
<kkiero> or any other language in the future
uris has quit [Quit: Leaving]
<davidcelis> the koans _would_ give you ruby knowledge
ebobby has joined #ruby
<davidcelis> or programming knowledge that would help you learn other languages
enricostn has quit [Remote host closed the connection]
caleb_io has joined #ruby
LouisGB has joined #ruby
robotmay has quit [Read error: Connection reset by peer]
<kkiero> well I don't have problems with learning new languages. the point is to have some problem to solve so you can get familiar with syntax in practice
<swarley> try the book, the well grounded rubyist
caleb_io has quit [Client Quit]
_JamieD_ has quit [Quit: _JamieD_]
robotmay has joined #ruby
bemson has quit [Quit: bemson]
<swarley> good god i'm having such a hard time focusing on code
BSaboia__ has quit [Read error: Connection reset by peer]
chin-tastic has joined #ruby
freeayu has joined #ruby
<bricker> How would I store a Proc or similar in a hash as a value, so that when the pair gets called, the Proc gets called? I ask because I'm storing a Time value in a hash which is a class constant
<swarley> you mean, like a dynamic key?
bbttxu has joined #ruby
marius has joined #ruby
g-ram has quit [Quit: Computer has gone to sleep.]
<bricker> swarley: no, the value is dynamic. DEFAULTS = { time: -> { Time.now } }
<swarley> oh
jenrzzz has quit [Ping timeout: 272 seconds]
<swarley> in that example
<swarley> DEFAULTS[:time][]
kpshek has quit []
<swarley> [] is the same as doing DEFAULTS[:time].call
<bricker> swarley: so I can call DEFAULTS[:time].call, but I am looking for how to make that happend automatically since I'll be passing that constant directly into a method
<swarley> ah
<swarley> use lazy
pdswan_ has joined #ruby
<swarley> do this
mikepack has quit [Remote host closed the connection]
pdswan has quit [Ping timeout: 246 seconds]
pdswan_ is now known as pdswan
a_a_g has quit [Quit: Leaving.]
<swarley> you'd need to use the lazy gem.. But in all honesty, its not that complicated
Kruppe has joined #ruby
Liothen_ is now known as Liothen
Liothen has quit [Changing host]
Liothen has joined #ruby
<bricker> swarley: yeah this isn't a big enough to deal to use a gem. I think I might just put the hash into a method and do it that way
workmad3 has quit [Read error: Operation timed out]
<swarley> you can easily implement the class in a few lines i think
Tearan has joined #ruby
kaawee has quit [Ping timeout: 255 seconds]
nanderoo has quit [Quit: Leaving.]
kaawee has joined #ruby
mjbamford has quit [Quit: Leaving...]
<swarley> ah, lazy isnt always dynamic
TomRone has quit [Ping timeout: 240 seconds]
EPIK has quit [Read error: Connection reset by peer]
EPIK has joined #ruby
Tearan has quit [Quit: Sleepy Badger....]
stopbit has quit [Quit: Leaving]
chrishunt has quit [Ping timeout: 255 seconds]
mando has quit [Remote host closed the connection]
shadoi has quit [Quit: Leaving.]
Koshian__ has quit [Ping timeout: 240 seconds]
jenrzzz has joined #ruby
Pip has quit [Ping timeout: 245 seconds]
TomRone has joined #ruby
artOfWar_ has quit [Ping timeout: 252 seconds]
rowsdower has joined #ruby
pdswan_ has joined #ruby
Koshian__ has joined #ruby
lindenle_ has joined #ruby
<lindenle_> If I have two versions of a gem installed is there a way to say use version A?
chrishunt has joined #ruby
Pip has joined #ruby
pdswan has quit [Ping timeout: 246 seconds]
pdswan_ is now known as pdswan
nitti has joined #ruby
LucidDreamZzZ has joined #ruby
<Spooner> lindenle_ : Bundler is the standard way to specify gem versions.
sambio has quit [Ping timeout: 264 seconds]
<lindenle_> Spooner: can I use rvm?
Dreamer3 has joined #ruby
<Spooner> lindenle_ : Yeah, you can use gem-sets in rvm too, but I haven't used them, since the Bundler gem is fine.
hoelzro|away is now known as hoelzro
Solnse2 has joined #ruby
chichou has joined #ruby
m_3 has quit [Ping timeout: 252 seconds]
c0rn_ has joined #ruby
banseljaj is now known as imami|afk
nitti has quit [Ping timeout: 260 seconds]
rowsdower has quit [Remote host closed the connection]
rowsdower has joined #ruby
m_3 has joined #ruby
jenrzzz has quit [Ping timeout: 245 seconds]
Solnse has quit [*.net *.split]
fixl has quit [*.net *.split]
cibs has quit [*.net *.split]
Ivo has quit [*.net *.split]
bier has quit [Ping timeout: 246 seconds]
icooba has quit [Quit: Computer has gone to sleep.]
mmitchell has joined #ruby
Floydzy has joined #ruby
ebobby has quit [Ping timeout: 276 seconds]
Xeago has joined #ruby
UberNerdGirl has joined #ruby
robotmay has quit [Remote host closed the connection]
piotr_ has quit [Read error: Operation timed out]
mmlac has joined #ruby
Dreamer3 has quit [Quit: Computer has gone to sleep.]
clj_newb has quit [Ping timeout: 260 seconds]
mmitchell has quit [Ping timeout: 246 seconds]
UberNerdGirl has quit [Client Quit]
bemson has joined #ruby
bradhe has quit [Remote host closed the connection]
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
fixl has joined #ruby
codewrangler has joined #ruby
niklasb has quit [Ping timeout: 264 seconds]
hbpoison has joined #ruby
graeme has joined #ruby
bier has joined #ruby
lkba has quit [Ping timeout: 272 seconds]
bemson has quit [Quit: bemson]
codewrangler has quit [Remote host closed the connection]
rasbonics has quit [Quit: rasbonics]
LouisGB has quit [Ping timeout: 260 seconds]
reset has quit [Ping timeout: 276 seconds]
armenb has joined #ruby
hbpoison has quit [Ping timeout: 265 seconds]
moshee has quit [Ping timeout: 260 seconds]
moshee has joined #ruby
ebobby has joined #ruby
ebobby is now known as Guest80007
cakehero has quit [Quit: Computer has gone to sleep.]
ffranz has quit [Quit: Leaving]
LucidDreamZzZ has quit [Ping timeout: 276 seconds]
hoelzro is now known as hoelzro|away
davidcelis has quit [Quit: K-Lined.]
nina has quit [Quit: Leaving.]
<kkiero> is there any library so I can genereate graphic output on os x?
g-ram has joined #ruby
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
Takehiro has joined #ruby
lkba has joined #ruby
<shadewind> where can I find a complete reference for ruby regex?
palyer has joined #ruby
palyboy has quit [Read error: Connection reset by peer]
Canthar has joined #ruby
Solnse2 has quit []
chichou has quit [Remote host closed the connection]
nina has joined #ruby
nina has left #ruby [#ruby]
LucidDreamZzZ has joined #ruby
<shadewind> nevermind, I found it :)
glyytchy has joined #ruby
yaymukund has quit [Quit: leaving]
<Spooner> kkiero : You mean opengl type output or imagemagick type or GUI type?
<swarley> fuck xml.
miso1337 has joined #ruby
<Spooner> swarley : I believe XML may be your White Whale!
Takehiro has quit [Ping timeout: 265 seconds]
<swarley> I'm going to finish this x_x
<swarley> I swear to god, if this is slow as hell when i'm done i'm going to be pissed lol
<kkiero> Spooner: something like new windows pop ups and script is drawing basic shapes in it
queequeg1 has joined #ruby
miso1337 has quit [Client Quit]
<kalleth> shadewind: just an FYI: http://rubular.com/
<kalleth> i love that site
<Spooner> kkiero : Right. Try the one of the "games" libraries, like Gosu or Ray.
<Spooner> kkiero : You could also maybe use a GUI library and make an drawing canvas inside that window, but I'm not up on which GUI libraries still work ;)
emergion has joined #ruby
<kkiero> ok, thanks
awarner has quit [Remote host closed the connection]
<swarley> When i finish this. I really hope it doesnt suck ass
<swarley> i dont know why i'm saying that. because it will
Guest80007 is now known as fms
<Spooner> swarley : People have been writing XML libraries for decades. If you can do better in a week, then you truly are the master!
fms is now known as ebobby
<Spooner> Nothing to lose.
emergion has quit [Client Quit]
Canthar has left #ruby [#ruby]
<Spooner> Although if it is slower than a pure-Ruby XML library, then you really do suck ;)
JonnieCache has joined #ruby
<swarley> I'm avoiding using the ruby api until the last minute, for lazy evaluation sort of.
Goles has joined #ruby
<swarley> Since having everything in C structs is better for memory and a lot faster
<Spooner> Yep.
under_my_shoes has quit [Quit: Leaving]
under_my_shoes has joined #ruby
<shadewind> hmm... class methods cannot be called without the class name from an instance method?
<swarley> if you define it as
<swarley> ClassName.method_name
pdswan has quit [Ping timeout: 252 seconds]
<swarley> i.e def Foo.bar(); ...; end
<swarley> then you have to call it as Foo.bar
<Spooner> shadewind : Yeah, otherwise you'd be calling the instance method.
<shadewind> I'm just used to every other language where both class methods and instance methods occupy the same namespace
<Spooner> shadewind : Though you could delegate by making an instance method that called the class method if that is appropriate (def frog(*args); self.class.frog(*args); end).
havenn_ has quit [Remote host closed the connection]
ngoldman has quit [Remote host closed the connection]
<shadewind> I think I'll just make it an instance method instead so I don't have to type as much ;)
Xeago has quit [Remote host closed the connection]
<Spooner> Well, sounds like it was an instance-method all the time.
<swarley> shadewind; be careful
<swarley> they are for different uses
<swarley> Foo.bar is not meant to be used the same way as Foo.new.bar generally
pdswan_ has joined #ruby
<swarley> well, that's a bad example
JonnieCache has quit [Ping timeout: 240 seconds]
snuglepuss has joined #ruby
<Spooner> No, but if Foo.bar is only called from inside an instance and doesn't maintain state (civars) then it might as well be an instance method.
<swarley> I'm trying to say that class methods should be used when you want to provide a method without needing the scope of an object
<shadewind> Spooner: well, it was but it probably shouldn't be since it doesn't access any members of the instance
SegFaultAX|work has quit [Ping timeout: 276 seconds]
reuf has joined #ruby
<shadewind> in C++, I generally make such "utility methods" static (a class method, in other words)
kiyoura has joined #ruby
<Spooner> I generally wouldn't in Ruby. I'd just make them protected instance methods.
havenn has joined #ruby