<speakingcode>
floors what i want. i was referring to to_i up there
jjang_ has joined #ruby
<nfk>
speakingcode, i expect to_i truncates it
<speakingcode>
it does
<speakingcode>
you are correct
<yfeldblum>
yes, Float#to_i truncates
<yfeldblum>
or, rounds towards zero
<nfk>
yfeldblum, same thing?
<yfeldblum>
same effect, different perspectives
chriskk has joined #ruby
<nfk>
does it matter?
jjang_ has quit [Remote host closed the connection]
jjang has quit [Ping timeout: 260 seconds]
<speakingcode>
practically, no. just describing it in alternative ways
<speakingcode>
anyway thanks for the assistance
jjang has joined #ruby
jjang has quit [Remote host closed the connection]
<nfk>
how do i DRY navigation generation?
jjang has joined #ruby
jjbohn has quit [Ping timeout: 260 seconds]
mrsolo has quit [Quit: Leaving]
pkrnj has quit [Read error: Connection reset by peer]
generalissimo has quit [Remote host closed the connection]
<nfk>
currently i have an array of controllers in the application layout and views have such arrays too per view
<nfk>
surely it can be done better
krz has joined #ruby
pkrnj has joined #ruby
szck has joined #ruby
stevechiagozie has quit [Quit: Computer has gone to sleep.]
Edward_ has joined #ruby
RagingDave has quit [Quit: Ex-Chat]
jjang_ has joined #ruby
jds_ has joined #ruby
AlbireoX has quit [Remote host closed the connection]
AlbireoX has joined #ruby
urrk has quit [Ping timeout: 264 seconds]
fir_ed has quit [Ping timeout: 265 seconds]
emmanuelux has quit [Remote host closed the connection]
jjang_ has quit [Remote host closed the connection]
<shevy>
sounds rails specific
urrk has joined #ruby
<shevy>
in rails people apply a routine pattern to solve a task
jjang has quit [Ping timeout: 256 seconds]
szck has quit [Ping timeout: 244 seconds]
Spooner has quit [Quit: Leaving]
cardoni has quit [Quit: cardoni]
zph has joined #ruby
AlbireoX has quit [Read error: Operation timed out]
ossareh has joined #ruby
ner0x has joined #ruby
ephemerian has quit [Quit: Leaving.]
bluenemo has quit [Remote host closed the connection]
jjbohn has joined #ruby
ffranz has quit [Quit: Leaving]
jds_ has quit [Ping timeout: 244 seconds]
dwnichols has joined #ruby
cardoni has joined #ruby
woolite64 has quit []
ryannielson has joined #ruby
yakko has quit [Remote host closed the connection]
<ryannielson>
I see code that looks like: https://gist.github.com/4498486 . What exactly is that syntax called, and what is it doing?
danneu has joined #ruby
razibog has joined #ruby
nathancahill_ has joined #ruby
nathancahill has quit [Read error: Connection reset by peer]
nathancahill_ is now known as nathancahill
<Eiam>
would 'string !~ /\d/ ' be a 'safe' way to see if a string has numbers in it or not?
<Eiam>
I've got some data that occasionally puts a string thats "characters" (a-zA-z) instead of numbers (0-9) in it, which means the data is bad and needs to be cleaned up instead of consumed
jjbohn has quit [Quit: Leaving...]
<razibog>
Could anyone help with net/http module? I'm trying to submit a post request to a form in a website.
jjang has joined #ruby
jjang has quit [Read error: No route to host]
yshh has joined #ruby
jjang has joined #ruby
joofsh has quit [Remote host closed the connection]
postmodern has joined #ruby
slainer68 has quit [Remote host closed the connection]
<zph>
Might have better luck with pry. You can 'cd' into an object and see it's state and also 'edit-method' to open a method in question… is that what you're getting at?
<zph>
(Pry is like irb but many more features)
<zph>
Hope that works for ya reppard
reppard has quit [Ping timeout: 265 seconds]
d2dchat has joined #ruby
tommyvyo has joined #ruby
adeponte has quit [Remote host closed the connection]
tommyvyo has quit [Client Quit]
jesse has quit [Excess Flood]
jesse has joined #ruby
tommyvyo has joined #ruby
joeycarmello has quit [Remote host closed the connection]
horofox has joined #ruby
rakl has quit [Quit: sleeping]
twoism has joined #ruby
<ryannielson>
Any gem recommendations for basically creating temp directories and files. I'm using test-construct which works, but it keeps outputting lines saying it's creating folders and files which are making my tests harder to read.
IceDragon has quit [Quit: Space~~~]
whitedawg has joined #ruby
whitedawg has quit [Client Quit]
horofox has quit [Client Quit]
solidresolve has quit [Remote host closed the connection]
jbw has quit [Ping timeout: 260 seconds]
pavilionXP has quit [Read error: Connection timed out]
<shevy>
is anyone here using any GUI toolkit in ruby?
horofox has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
szck has joined #ruby
szck has quit [Read error: Connection reset by peer]
<ryannielson>
zph: K, I'll take a look at that. Thans
tommyvyo has joined #ruby
<zph>
ryannielson And if you didn't get an answer earlier, that gist you linked to is using a 'HERE DOC' with yaml embedded in it
<ryannielson>
zph: Ya, I managed to find it out. Thanks though.
<ryannielson>
zph: I seem to be able to do something similar to HEREDOC with %Q{}, any disadvantags to that?
Virunga has quit [Remote host closed the connection]
szck1 has quit [Ping timeout: 264 seconds]
billy_ran_away has quit [Ping timeout: 248 seconds]
<zph>
Heredocs tend to be used for longer content because they avoid issues related to juggling escape characters or not being able to use {} characters (in your example)
LouisGB has joined #ruby
<zph>
So, "" for simple stuff that needs variable interpolation, alt syntax %Q{} for the same if you might need " marks embedded, and HEREDOCS to avoid all those hassles
megha has quit [Ping timeout: 276 seconds]
bradhe has joined #ruby
billy_ran_away has joined #ruby
<ryannielson>
zph: Oh okay, that makes sense. Thanks!
<zph>
ryannielson TLDR, if you don't need {} marks in your quoted content, keep using %Q{}. Unless it starts spanning too many lines
<zph>
=D
mmitchell has quit [Remote host closed the connection]
fuzai has quit [Remote host closed the connection]
judesamp has joined #ruby
judesamp has left #ruby [#ruby]
twoism has quit [Ping timeout: 240 seconds]
cakehero has joined #ruby
horofox has quit [Quit: horofox]
lolcathost has quit [Quit: When I come back, please tell me in what new ways you have decided to be completely wrong.]
lolcathost has joined #ruby
ryanf_ has quit [Quit: leaving]
io_syl has quit [Quit: Computer has gone to sleep.]
lolcathost has quit [Read error: Connection reset by peer]
lolcathost has joined #ruby
crackfu has joined #ruby
mockra has joined #ruby
Playground has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
lolcathost has quit [Ping timeout: 260 seconds]
Slivka has quit [Remote host closed the connection]
luckyruby has joined #ruby
baroquebobcat has joined #ruby
jonahR has joined #ruby
adkron has joined #ruby
davidokner has quit [Quit: Lost terminal]
Vert has joined #ruby
ViPi has quit [Quit: Computer has gone to sleep.]
Playground has quit [Ping timeout: 248 seconds]
maletor has quit [Quit: Computer has gone to sleep.]
baroquebobcat has quit [Client Quit]
cardoni has quit [Quit: cardoni]
brandon has joined #ruby
brandon has quit [Client Quit]
ManK has joined #ruby
jrist is now known as jrist-afk
zeade has joined #ruby
bwlang has left #ruby [#ruby]
libertyp1ime has joined #ruby
libertyp1ime has quit [Client Quit]
szck has joined #ruby
zz_pacbard is now known as pacbard
tchebb has quit [Ping timeout: 265 seconds]
ManK has quit [Quit: Leaving]
tchebb has joined #ruby
SCommette has joined #ruby
fuzai has joined #ruby
poli has quit [Ping timeout: 264 seconds]
slainer68 has joined #ruby
stevechiagozie has joined #ruby
tjbiddle has quit [Ping timeout: 256 seconds]
joeycarmello has joined #ruby
tchebb has quit [Ping timeout: 256 seconds]
tchebb has joined #ruby
SCommette has quit [Client Quit]
mneorr has quit [Remote host closed the connection]
ManK has joined #ruby
slainer68 has quit [Ping timeout: 248 seconds]
joeycarmello has quit [Ping timeout: 245 seconds]
adkron has quit [Ping timeout: 246 seconds]
<fuzai>
Hi i'm using this module https://github.com/obrie/turntabler to write a bot for turntable. I've been trying to figure out how to create timed events that doesn't block when sleeping that allows use the i/o calls of the module. TT.run was suggested to me, which sorta works, but sleep blocks, can someone help me?
bwlang has joined #ruby
ryannielson has left #ruby [#ruby]
razibog has joined #ruby
bwlang has left #ruby [#ruby]
fuzai_ has joined #ruby
matip_ has left #ruby ["Leaving"]
reset has quit [Ping timeout: 265 seconds]
cardoni has joined #ruby
fuzai has quit [Ping timeout: 256 seconds]
amaya_the has joined #ruby
gabrielrotbart has quit [Remote host closed the connection]
joofsh has quit [Remote host closed the connection]
yxhuvud has joined #ruby
lolcathost has joined #ruby
rakl has quit [Quit: gone]
tchebb has quit [Read error: Connection reset by peer]
retro|cz has quit [Ping timeout: 248 seconds]
macmartine has joined #ruby
Jedi_SCT1 has quit [Quit: See ya]
rakl has joined #ruby
Fuzai has quit [Ping timeout: 252 seconds]
Jedi_SCT1 has joined #ruby
stemid has joined #ruby
cardoni has quit [Ping timeout: 240 seconds]
otherj has joined #ruby
<stemid>
I don't know anything about ruby. I just barely got a rails app working that I wanted to use. and now this vulnerability. but how do I know my app is vulnerable? and how do I patch a bundled app?
toekutr has quit [Remote host closed the connection]
tchebb has joined #ruby
mvangala has joined #ruby
<wmoxam>
stemid: (1) ask in #rubyonrails (2) when you ask, mention what app it is and where you got it
mvangala_ has quit [Read error: Connection reset by peer]
mvangala has quit [Read error: Connection reset by peer]
c3vin has quit [Ping timeout: 240 seconds]
mibitzi has joined #ruby
mvangala has joined #ruby
crackfu has quit [Remote host closed the connection]
<yfeldblum>
stemid, it's vulnerable; `bundle update rails` to update rails, and then run the test suite to ensure it's not broken; and then deploy
cardoni has joined #ruby
Diger_s has quit [Ping timeout: 276 seconds]
crackfu has joined #ruby
noric has quit [Quit: Disconnecting]
noric has joined #ruby
medik has quit [Quit: medik]
crackfu has quit [Ping timeout: 256 seconds]
<noric>
Given a value which is expensive to compute, you can evaluate it lazily using a block. Pass the block around until the value is needed: { expense_value_to_compute() }
<noric>
My question is, if I have multiple independent consumers of the value, how would you prevent the (static) value from being computed multiple times?
<noric>
Given a value which is expensive to compute, you can evaluate it lazily using a block. Pass the block around until the value is needed: { expense_value_to_compute() }
<noric>
My question is, if I have multiple independent consumers of the value, how would you prevent the (static) value from being computed multiple times?
<yfeldblum>
noric, if you're not worried about thread-safety: `res = nil ; ->{ res ||= expensive_value_to_compute() }`
quest88 has joined #ruby
d2dchat has quit [Remote host closed the connection]
<noric>
yfeldblum: Ah ok, I see your point, the block can only be used further down the stack, so saving the value in a local is np because the local will be alive as long as the block
<noric>
now the question seems dumb :P
io_syl has joined #ruby
<yfeldblum>
noric, gotta see it to believe it
<noric>
wouldn't that work in a multithreaded environment, or recursively, since each local is separate? Or I am misunderstanding how the closures work
heyitsdave has joined #ruby
otherj has quit [Quit: otherj]
nfk has quit [Quit: yawn]
SCommette has quit [Quit: SCommette]
<yfeldblum>
noric, if you have a separate local and a separate block and a separate expensive computation in each thread, it's fine
<yfeldblum>
noric, if you have one local and one block and one expensive computation serving multiple threads, it's *kaboom*
a_a_g has joined #ruby
<noric>
Ah, but as long as the computation is threadsafe, each thread would get its own "res" when calling into the method, right?
<noric>
Well, each thread would redundantly compute its own value
<noric>
but the "res" bit is threadsafe, right?
<yfeldblum>
noric, no
<yfeldblum>
noric, nothing is threadsafe that you don't handle thread-safely
<noric>
def a; res = nil; value = -> { res ||= expensive_threadsafe_value() }; .. use value lots; end; 10.times do Thread.new do a end end # BOOM?
zph has quit [Quit: Computer has gone to sleep.]
kenneth has quit [Quit: kenneth]
tommyvyo has joined #ruby
stemid has left #ruby [#ruby]
ManK has joined #ruby
heyitsdave has quit [Ping timeout: 248 seconds]
cobragoa_ has joined #ruby
<cobragoa_>
is anyone experienced with aws-sdk-ruby?
generalissimo has joined #ruby
asteve has joined #ruby
<SirFunk>
ugh this is a weird scope issue. I've never seen a scope issue like this before
<SirFunk>
time to gist
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
<yfeldblum>
noric, no, since each `res` set of local + block is declared in their own thread
tchebb_ has joined #ruby
JohnBat26 has joined #ruby
madwilliamflint has quit []
tchebb has quit [Ping timeout: 256 seconds]
tchebb_ is now known as tchebb
yacks has quit [Remote host closed the connection]
amaya_the has quit [Ping timeout: 255 seconds]
a_a_g has quit [Read error: Connection reset by peer]
radic has quit [Disconnected by services]
radic_ has joined #ruby
tchebb has quit [Client Quit]
rippa has joined #ruby
yacks has joined #ruby
a_a_g has joined #ruby
jenrzzz has joined #ruby
jekotia has quit [Ping timeout: 260 seconds]
a_a_g has quit [Read error: Connection reset by peer]
a_a_g has joined #ruby
GoGoGarrett has joined #ruby
dross has quit [Ping timeout: 246 seconds]
pu22l3r_ has joined #ruby
rakl has quit [Quit: sleeping]
dross has joined #ruby
billy_ran_away has quit [Ping timeout: 246 seconds]
pu22l3r has quit [Ping timeout: 265 seconds]
bradhe has quit [Remote host closed the connection]
jlast has quit [Remote host closed the connection]
adeponte has joined #ruby
amaya_the has joined #ruby
billy_ran_away has joined #ruby
TomyLobo has quit [Quit: Standby mode...]
dross has quit [Ping timeout: 240 seconds]
Loaft has quit [Ping timeout: 252 seconds]
dross has joined #ruby
a_a_g has quit [Read error: Connection reset by peer]
a_a_g has joined #ruby
kenneth has joined #ruby
tchebb has joined #ruby
Loaft has joined #ruby
dross has quit [Remote host closed the connection]
dross has joined #ruby
awaage has joined #ruby
clooth has quit [Quit: clooth]
jjang_ has joined #ruby
stkowski has quit [Quit: stkowski]
dross has quit [Remote host closed the connection]
jjang has quit [Ping timeout: 255 seconds]
dross has joined #ruby
s1nful has quit [Ping timeout: 244 seconds]
richardjortega has joined #ruby
macmartine has quit [Quit: Computer has gone to sleep.]
dross has quit [Ping timeout: 265 seconds]
a_a_g has quit [Read error: Connection reset by peer]
a_a_g has joined #ruby
dross has joined #ruby
tchebb has quit [Read error: Connection reset by peer]
macmartine has joined #ruby
Takehiro has quit [Remote host closed the connection]
vDubG has joined #ruby
tchebb has joined #ruby
clooth has joined #ruby
dawkirst_ has joined #ruby
tchebb has quit [Read error: Connection reset by peer]
Zespre has joined #ruby
dawkirst_ has quit [Client Quit]
tchebb has joined #ruby
Nisstyre has quit [Ping timeout: 240 seconds]
lolcathost has quit [Ping timeout: 255 seconds]
dem0n has joined #ruby
jeffreybaird has joined #ruby
bradhe has joined #ruby
jlast has joined #ruby
gridaphobe has joined #ruby
postmodern has quit [Ping timeout: 255 seconds]
cakehero has quit [Quit: Computer has gone to sleep.]
pskosinski has quit [Quit: Learn Life's Little Lessons]
Spami has quit [Quit: This computer has gone to sleep]
dross has quit [Ping timeout: 240 seconds]
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
a_a_g has quit [Quit: Leaving.]
dhruvasagar has joined #ruby
jpfuentes2 has joined #ruby
aaronmacy has joined #ruby
pu22l3r_ has quit [Remote host closed the connection]
emanu has joined #ruby
dhruvasagar has quit [Read error: Connection reset by peer]
<emanu>
I did a gem install pry at the command line, but when I run my ruby script it still tells me: "journalism:3: undefined method `pry' for #<Binding:0x108a3deb0> (NoMethodError)"
<topriddy>
hi guys...thanks for yesterday. I'm sorry I come with more questions...premise I am a Java programmer
beiter has quit [Quit: beiter]
<Hanmac_>
topriddy yeah we are all feel sorry for you, but your tourture is over, now you are have chosen an better language :P
lolcathost has quit [Ping timeout: 240 seconds]
<topriddy>
hehe...well my question is this. Ruby doesnt enforce type on method parameters. hence it is easy to pass in the wrong types. I read what ruby does to fix this is to "advise" programmers to write a unit test (have not seen this yet, but assume unit test would test the type => doesnt make much sense). Anyway, in java compiler can avoid this error. hence, you can survive more in java with less unit typing
zommi has joined #ruby
coder_neo has joined #ruby
* topriddy
for this purpose | is newline
stevechiagozie has quit [Quit: Computer has gone to sleep.]
jenrzzz has joined #ruby
andrewhl has quit [Remote host closed the connection]
<yfeldblum>
topriddy, in practice, in most cases, in most ruby applications, this is not a problem
<topriddy>
def square_perimeter (lenght) | lenght * 4 | end
dmiller1 has quit [Ping timeout: 240 seconds]
<yfeldblum>
topriddy, when it is a problem, you can easily solve it in ruby with explicit typechecks
<yfeldblum>
topriddy, arg1.kind_of?(String) || arg1.kind_of?(Hash) or raise TypeError, "expected arg1 to be a String or a Hash"
<reactormonk>
topriddy, btw, ; is equivalent to a newline to the ruby interpreter, so def square_prem(length) ; length * 4; end is runnable code
locriani_ has quit [Read error: Connection reset by peer]
<reactormonk>
topriddy, and don't bother with any kind of type restrictions in ruby - not gonna happen. Pick scala if you want types without the Java pain
shemerey has joined #ruby
<Hanmac_>
topriddy: in ruby you can do: implicit type test: obj.is_a?(Klass), explicit type test: obj.respond_to?(:*), but sometimes in ruby you just let it crash
locriani has joined #ruby
arturaz has joined #ruby
<reactormonk>
Hanmac_, sometimes? I have seen really few type tests in ruby, maybe one or two respond_to?
<topriddy>
enterprise apps shouldn't crash
xpen has joined #ruby
<Hanmac_>
topriddy: you can rescue the raised errors
<topriddy>
no offence meant, but you guys remind me of some Zed Shaw blog...the one where it is difficult to see something because you are used to another
* topriddy
off to retrieve article
mavenastic has quit [Quit: Page closed]
<reactormonk>
topriddy, type errors aren't the only stuff that can crash your stuff - welcome to null pointers.
<arturaz>
morning :)
<sn0wb1rd>
Is it possible to obtain the name of a passed variable inside a method?
<reactormonk>
topriddy, and java doesn't protect you from null pointers.
<reactormonk>
sn0wb1rd, wtf are you doing?
<arturaz>
reactormonk, and proper static languages use Option/Maybe for that :)
<reactormonk>
arturaz, Yes, they do. I didn't want to mention that ;-)
<yfeldblum>
java doesn't even protect you from type errors; at best you get a ClassCastException or something
<sn0wb1rd>
reactormonk: I need to get the variable name to pass it to eval.
<Hanmac_>
reactormonk i for myself do it (use respond_to?), but i use the C method of it because i need to take care, like you said about null pointers and empty objects
<reactormonk>
sn0wb1rd, still same
generalissimo has quit [Remote host closed the connection]
<reactormonk>
Hanmac_, can you recover in case of a false to a respond_to? or is it simply to provide a better error message.
<arturaz>
sn0wb1rd, eval "local_vars", binding
<arturaz>
err, you can just call local_variables for variable names at the top of method
<topriddy>
i'm not arguing languages or trolling...i'm just pointing something i consider unusual without type specification...i'll continue but would be back if i have a real world example in ruby. but it looks such a common pitfall especially when you write a library and users try to use it passing the wrong params/param_type. they dont know till runtime
<sn0wb1rd>
arturaz: Thanks. Let me try that,
<reactormonk>
topriddy, I'd file that with good API design and some thinking from the coders side.
<topriddy>
that;s the neglect article...it doesn't allow you see some things. good read
<reactormonk>
zedshaw is a good read if you're bored, but that's about it
Morkel has joined #ruby
<Hanmac_>
reactormonk i do: 1) when the object is from XYZ::Colour: get the DATA ptr, 2) when the object resond_to red,green,blue create an new color object and set the values, 3) when the object is a string use some convert method to get the color,4) otherwise raise an error that object is not a XYZ::Colour object
<reactormonk>
Hanmac_, so basically monkey-patching String to define red,green,blue without monkey-patching it.
<sn0wb1rd>
Hanmac_: Sure
<Hanmac_>
reactormonk yeah something like that ... i do the same for Rect, Size, Vector2,Vector3,Vector4 classes and other "basic" objects ... its because if i have two bindings that define colour, i want that both can interact with the colour objects from the other binding
<yfeldblum>
topriddy, it's a very big problem in theory; in practice, it's a much smaller problem
<yfeldblum>
topriddy, most of the time, calling code passes objects of the expected types; and in ruby, there is a widespread culture of testing which helps to catch any errant or misbehaving code
<becom33>
trying to parse the last table in http://pastebin.com/uXwJHkyf with Nokogiri . tried table[3] doesnt work . help ?
savage- has quit [Quit: savage-]
<topriddy>
yfeldblum: yeah...so it seems. i'll continue to see if i would face this problem in "practice". As for user inputs, the same gotcha seems to be in every lang...thanks
shemerey has quit [Quit: Leaving...]
osaut has joined #ruby
slainer68 has joined #ruby
[Neurotic] has quit [Remote host closed the connection]
scruple has quit [Quit: Leaving]
Morkel_ has joined #ruby
aganov has joined #ruby
pencilcheck has quit [Remote host closed the connection]
aaronmacy has joined #ruby
arturaz has quit [Ping timeout: 248 seconds]
Morkel has quit [Ping timeout: 264 seconds]
Morkel_ is now known as Morkel
slainer68 has quit [Ping timeout: 256 seconds]
<sn0wb1rd>
Hanmac_: That worked but didn't satisfy my needs. I have a method that takes variable arguments like this: def method1(*vars, &block) and I couldn't get the name of all parameters.
<Hanmac_>
method().parameters shows ecaclty as you defined in the method
<buhman>
I'm not exactly sure how to make passenger work for a specific ruby version
nemesit has joined #ruby
<buhman>
I need to use 1.8, but my distribution's passenger is for 1.9
c3vin has quit [Ping timeout: 240 seconds]
pen has joined #ruby
workmad3 has joined #ruby
Elhu has quit [Quit: Computer has gone to sleep.]
krzkrz has joined #ruby
bitZero__ has quit [Ping timeout: 252 seconds]
TomRone has quit [Ping timeout: 256 seconds]
dmiller1 has joined #ruby
eldariof has joined #ruby
kudos has quit [Ping timeout: 264 seconds]
<sn0wb1rd>
buhman: Are you installing passenger ruby gem?
yacks has quit [Ping timeout: 255 seconds]
<buhman>
passenger: no
<Hanmac_>
buhman: dont use 1.8 :( or santa puts you on the naughty list
SCommette has quit [Quit: SCommette]
<buhman>
Hanmac_: please inform the puppet dashboard developers of this
<buhman>
I would greatly appreciate it
ale`` has quit [Remote host closed the connection]
Playground has joined #ruby
timonv has joined #ruby
<buhman>
sn0wb1rd: the only gem I have is a rake (for ruby-1.8)
lolcathost has quit [Read error: Connection reset by peer]
krzkrz has quit [Client Quit]
<sn0wb1rd>
Why don't you install passenger ruby gem?
krzkrz has joined #ruby
<buhman>
:S no idea
<sn0wb1rd>
I guess that would get you the one compatible with your version of ruby
zigomir has joined #ruby
yacks has joined #ruby
jenrzzz has quit [Ping timeout: 244 seconds]
TomRone has joined #ruby
TomRone has quit [Changing host]
TomRone has joined #ruby
TomRone has joined #ruby
robbyoconnor has quit [Read error: Connection reset by peer]
TheFuzzball has joined #ruby
bitZero__ has joined #ruby
rdk1 has left #ruby [#ruby]
dmiller1 has quit [Ping timeout: 252 seconds]
Mon_Ouie has joined #ruby
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby
iaj has joined #ruby
blaxter has joined #ruby
workmad3 has quit [Ping timeout: 276 seconds]
jds_ has joined #ruby
tonini has joined #ruby
FlyingFoXy has quit [Read error: Connection reset by peer]
FlyingFoX has joined #ruby
_cheney has quit [Read error: Connection reset by peer]
gyre008 has joined #ruby
main has joined #ruby
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
nomenkun has joined #ruby
jenrzzz has joined #ruby
cirwin has quit [Quit: Leaving.]
apeiros_ has joined #ruby
timonv has quit [Remote host closed the connection]
main has quit [Ping timeout: 248 seconds]
mockra has joined #ruby
<Fuzai>
if message.content =~ /^\/t.+/ i'm trying to match a string that looks like "/t Description of the theme i'm trying to set" where anything after "/t " can be anything to any length just not multi lined
<Fuzai>
.+ doesn't seem to work
TomRone has quit [Ping timeout: 248 seconds]
fteem has joined #ruby
quest88 has quit [Quit: quest88]
aaronmacy has quit [Quit: Leaving.]
pencilcheck has joined #ruby
mockra has quit [Ping timeout: 248 seconds]
jprovazn has joined #ruby
TomRone has joined #ruby
TomRone has quit [Changing host]
TomRone has joined #ruby
TomRone has joined #ruby
dmerrick has quit [Quit: dmerrick]
emergion has joined #ruby
pen has quit [Ping timeout: 246 seconds]
<Hanmac_>
fuzai:
pskosinski has joined #ruby
<Fuzai>
hi
<Hanmac_>
>> p "/t Description of the theme i'm trying to set"[/^\/t\s*(.+)/,1]
<eval-in>
Hanmac_: Output: "\"Description of the theme i'm trying to set\"\n" (http://eval.in/6336)
<Fuzai>
:)
megha has quit [Ping timeout: 255 seconds]
<Fuzai>
You're wonderful
* Hanmac_
yes yes i am
tjbiddle has quit [Quit: tjbiddle]
serhart has quit [Quit: Leaving.]
coder_neo has left #ruby ["Leaving"]
jenrzzz has quit [Ping timeout: 244 seconds]
coderhut has quit [Quit: Page closed]
Elhu has joined #ruby
Takehiro has quit [Remote host closed the connection]
ViPi has quit [Quit: Computer has gone to sleep.]
greg5green has quit [Remote host closed the connection]
a_a_g has joined #ruby
krzkrzkrz has joined #ruby
brianpWins has quit [Quit: brianpWins]
krzkrzkrz has quit [Client Quit]
greg5green has joined #ruby
timonv has joined #ruby
cobragoa_ has quit [Remote host closed the connection]
gyre008 has quit [Remote host closed the connection]
woolite64 has joined #ruby
jgrevich has quit [Quit: jgrevich]
<buhman>
/opt/ruby1.8/lib/ruby/site_ruby/1.8/rubygems.rb:779:in `report_activate_error': Could not find RubyGem rake (>= 0) (Gem::LoadError)
Playground has quit [Ping timeout: 240 seconds]
cdt has joined #ruby
aaronmacy has joined #ruby
statarb3 has quit [Ping timeout: 276 seconds]
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
<becom33>
can we use hirb inside a script
tmi_ has quit [Quit: ./]
<buhman>
% gem-1.8 list | grep rake
<buhman>
rake (10.0.3, 0.8.7)
callenb has joined #ruby
<Hanmac_>
buhman you could try to require "rubygems" before but it looks that something wrong with your ruby1.8
jimeh has joined #ruby
virtuose has quit [Ping timeout: 248 seconds]
<buhman>
..but I ran 'rake' and it's the correct rake for 1.8
<buhman>
why the fsck does it care if that gem exists?
main has joined #ruby
greg- has joined #ruby
Monie has quit [Read error: Connection reset by peer]
francisfish has joined #ruby
mrmist has quit [Changing host]
mrmist has joined #ruby
maxmanders has joined #ruby
<Hanmac_>
i dont know ... maybe fsck is broken or not designed for 1.8?
<buhman>
wat
mahmoudimus has joined #ruby
<Hanmac_>
its maybe fsck that forgot to require "rubygems"
<csmrfx>
JonnieCache: you ask, means your homework isn't done
<JonnieCache>
its easier to know the color once you remember where things are on the hue spectrum
dmiller1 has quit [Ping timeout: 276 seconds]
aapzak has joined #ruby
<csmrfx>
JonnieCache: ask anyone, without letting them refer to a program or chart, which color is hue 145 fully saturated?
mikecmpbll has joined #ruby
<csmrfx>
JonnieCache: look buddy, you are speaking nonsense
timonv has quit [Read error: Connection reset by peer]
<JonnieCache>
i dont know because i havent memorised what order the colors are on the hue scale
timonv has joined #ruby
clooth has quit [Quit: clooth]
<JonnieCache>
alright no need to get upset theyre just color encoding schemas
<csmrfx>
look, I've used hsl over 15 years and I still cant tell.
<csmrfx>
rgb, it is simple imo
<csmrfx>
(I have fine artist education anyways)
amaya_the has joined #ruby
<csmrfx>
JonnieCache: not getting upset, just trying to convey facts
<JonnieCache>
fair enough. i believe you.
<Hanmac_>
we only need four colours: "black, white, non-black, non-white" :D
<csmrfx>
JonnieCache: what really peeves me (after all, we have palette programs etc), is why we are still on 8-bit per channel color
yacks has quit [Ping timeout: 276 seconds]
<JonnieCache>
its certainly easier to use a hsl picker than an rgb picker. for me anyway
<kzar>
Hanmac_: That's two, black is non-white and vice versa
<csmrfx>
Oh well color pickers are another matter altogether
<JonnieCache>
doing "make this color darker" with rgb is so annoying.
goganchic has quit [Quit: Leaving]
<csmrfx>
drop value from every channel
developer has joined #ruby
<JonnieCache>
yeah i know that. im not a moron :P its just unintuitive if you dont work with color very oftenb
developer has quit [Client Quit]
<JonnieCache>
for me anyway. i like being able to just drag the sat/brightness sliders to modify the shade i have chosen
buscon has joined #ruby
greg- has quit [Quit: greg-]
<Xeago>
csmrfx: wouldn't screens costs more if we would increase the the bits/channel?
<workmad3>
JonnieCache: hsl is good for calculating complementary, contrasting and 'close' colours though
<JonnieCache>
exactly
<csmrfx>
Xeago: perhaps, but theyve been worknig on pixel density alone for years now
<csmrfx>
neither rgb nor hsl is meant for humans anyways
pskosinski has quit [Ping timeout: 256 seconds]
buscon has quit [Client Quit]
<csmrfx>
and also, it is strange that slider based color pickers are so popular
<shevy>
when I have .cgi scripts
<shevy>
can I use webrick to display them locally?
<JonnieCache>
arent most "good" new monitors 12 bit now?
<csmrfx>
in the 90s all kinds of 2d and 3d colorpicker things were white hot, and have almost disappeared
<JonnieCache>
the apple cinema displays etc
<csmrfx>
JonnieCache: they may have 12 bit IO, but the darn panels are 8 bit color chan
<csmrfx>
(last I checked)
<JonnieCache>
what do you have to shell out to get proper 12 bit displays?
fyolnish has quit [Ping timeout: 240 seconds]
gyre007 has quit [Ping timeout: 256 seconds]
gyre007 has joined #ruby
<csmrfx>
shevy: sure, if you have a server running
<shevy>
csmrfx hmm... I have apache
<shevy>
but the shit doesnt wanna serve my ruby .cgi scripts
squidBits has quit [Quit: squidBits]
<JonnieCache>
why do you have ruby cgi scripts man
taoru has quit [Remote host closed the connection]
<shevy>
JonnieCache because they work
<csmrfx>
shevy are those plain ruby or erb?
<JonnieCache>
is it to do with your plans for world domination
<shevy>
csmrfx pure ruby
<csmrfx>
with shabang on top?
<shevy>
csmrfx yeah
<csmrfx>
enabled cgi/fcgi/whatever on apache?
clooth has joined #ruby
<shevy>
I tried to fiddle with httpd.conf but I decided to give up
yacks has joined #ruby
<shevy>
csmrfx, yeah to the best of my knowledge... I am on some strange linux distribution though, and 64 bit.. it worked when I was on linuxmint + 32bit
<csmrfx>
shevy people are helpful in #httpd (/join #apache) ime, if you provide details and do your homework
blaxter has joined #ruby
osaut_ has joined #ruby
Spooner has joined #ruby
<Xeago>
ime = in my experience?
jonahR has quit [Quit: jonahR]
<csmrfx>
yes
a_a_g1 has joined #ruby
<shevy>
hmm
<shevy>
what alternatives are there to .cgi pages?
<kzar>
With this crazy Rails exploit am I right in saying Sinatra apps aren't effected?
<csmrfx>
shevy erb
<Hanmac_>
shevy does you had questions about marshal last night?
gyre008 has joined #ruby
j0sh\a has quit [Remote host closed the connection]
<csmrfx>
shevy reverse proxy your ruby app to apache
<shevy>
Hanmac_ hmm not marshal per se, more like storing all kind of objects
<shevy>
csmrfx aha
<shevy>
when you write ruby app, you mean something like sinatra?
<csmrfx>
shevy: might make your life easier
<Xeago>
if it is a webapp, for example
<shevy>
right now all my .cgi pages are one class, and I fill up the needed data for that class each, then display that
bradhe has quit [Ping timeout: 240 seconds]
a_a_g has quit [Ping timeout: 248 seconds]
<shevy>
(one class per .cgi page that is)
<csmrfx>
shevy: you can do plain ruby but probably will end up something like sinatra, only spaghettier
<Hanmac_>
shevy some objects like procs or IO objects cant be nicly stored ...
gyre007 has quit [Read error: Connection reset by peer]
cina has joined #ruby
cableray has quit [Quit: cableray]
cascalheira has joined #ruby
<shevy>
Hanmac_ yeah you wrote that before too :)
<shevy>
get some sleep Hanmac !!!
cardoni has joined #ruby
mikekelly has quit [Ping timeout: 265 seconds]
wallerdev has quit [Quit: wallerdev]
gyre008 has quit [Ping timeout: 256 seconds]
viuo_ has joined #ruby
<Hanmac_>
i allready got some sleep, that why i did not revice your answer tonight
<chiel>
hmm.. now it's giving me "No config file found"
<chiel>
anyone having experience with thin saying that?
gyre007 has quit [Ping timeout: 256 seconds]
poli has joined #ruby
dwu1 has quit [Quit: Leaving.]
marr has quit []
jds_ has quit [Ping timeout: 256 seconds]
Mission-Critical has joined #ruby
<becom33>
shevy, hey dude Im using nokogiri to do a html parse . look at this http://pastebin.com/0aGN0Ja9 Im gettin "\n" . Im trying add this into terminal-table help ?
bluenemo has joined #ruby
<shevy>
sorry I dont do XML
<shevy>
doc.xpath('//table[2]/tr/td//text()')
<shevy>
I find this visually displeasing
<shevy>
there is no beauty and no harmony in it
csgui has quit [Quit: csgui]
nkr has joined #ruby
<Hanmac_>
becom33 why are you using <font> ?
cina has quit [Ping timeout: 255 seconds]
<becom33>
Hanmac, its not my app . its a remote app . just using the code here
<JonnieCache>
shevy: regexen must make you very unhappy indeed
tonini has quit [Remote host closed the connection]
<Hanmac_>
the html code is so ugly, its nearly pre2000
staafl has joined #ruby
cina has joined #ruby
<shevy>
JonnieCache yeah, I hate regexes too, but they are too useful to avoid
<JonnieCache>
but i suppose yes even regular expressions have an elegance that xpath lacks
<shevy>
if regexes are short, then they are not so bad
nomenkun has joined #ruby
<shevy>
I just hate the /"§%/()%!"/)(%&!/=)"&!"/ ones
<JonnieCache>
xpath is almost as powerful as regexes though
bradhe has joined #ruby
<becom33>
Hanmac, u have no idea . still anyway could use sine help tho
<JonnieCache>
in their own way
<becom33>
some *
cdt_ has joined #ruby
<shevy>
becom33, one day you will decide to stop using nokogiri. you'll be a happier man that day too
<becom33>
shevy, do you have a better way to html table parsing ?
cdt has quit [Ping timeout: 256 seconds]
<shevy>
dunno. remove the tags you dont want until you just have the raw data
<Hanmac_>
shervy for parsing xml/html there is currently nothing better than nokogiri
<shevy>
look at what you have there
<shevy>
<strong>
<shevy>
what info does that tag give you
<shevy>
it's totally useless
<JonnieCache>
what could you possibly dislike about nokogiri
<shevy>
it's ugly
<shevy>
doc.xpath('//table[2]/tr/td//text()')
Virunga has joined #ruby
macsim has quit [Quit: Quitte]
<shevy>
is that even right becom33???
<JonnieCache>
thats xpath's fault not nokogiris
<Hanmac_>
<strong> is bot the worst ... using <p> without closing it agaib is crapy
macsim has joined #ruby
<Hanmac_>
is not
<becom33>
shevy, yea thats right . but thats not the problem Im having . I have the problem with the "\n"
<becom33>
Hanmac, html code is not mine to be changed . can't comment on that
<macsim>
I'm still stuck wih ruby unicorn and redmine here what I got when I start unicorn https://gist.github.com/4501225 I'm on ruby 1.9.1 but it show lot of ruby 1.8
osaut_ has joined #ruby
<shevy>
becom33 why cant you change the html? remove the stuff you dont need, then use nokogir
<becom33>
Im using a source of a remove app
dwu1 has joined #ruby
csgui has joined #ruby
Mission-Critical is now known as MissionCritical
<workmad3>
Hanmac_: <p> is actually defined in the HTML4 and HTML5 as allowing the </p> to be optional
<workmad3>
Hanmac_: so it's not 'crappy' to do it... unless the doc is using the XHTML doctype, in which case it's invalid
statarb3 has quit [Ping timeout: 256 seconds]
<Hanmac_>
but about the <font> tags ... wasnt they even in html4 deprecated ?
<chiel>
hm.. why does thin HAVE to be in your gemfile to work?
jjang_ has quit [Remote host closed the connection]
buscon has quit [Quit: Leaving]
akl has quit [Ping timeout: 255 seconds]
jso has quit [Ping timeout: 276 seconds]
Guest9041 has quit [Ping timeout: 260 seconds]
akl has joined #ruby
akl has quit [Changing host]
akl has joined #ruby
cina_ has joined #ruby
dwu1 has quit [Quit: Leaving.]
gyre008 has quit [Ping timeout: 256 seconds]
<workmad3>
Hanmac_: yeah, font was deprecated in html4
tris has quit [Read error: Operation timed out]
Guest9041 has joined #ruby
coder_neo has quit [Ping timeout: 240 seconds]
tris has joined #ruby
csmrfx has left #ruby ["later!"]
cina has quit [Ping timeout: 246 seconds]
dmiller1 has joined #ruby
jso has joined #ruby
coder_neo has joined #ruby
* Hanmac_
really hates outdated code
<becom33>
Hanmac, well nothing helps me yet
gyre007 has joined #ruby
pcarrier has quit []
dmiller1 has quit [Ping timeout: 276 seconds]
buscon has joined #ruby
keanehsiao has quit [Quit: keanehsiao]
larissa has joined #ruby
bluOxigen has joined #ruby
noric has quit [Read error: Connection reset by peer]
ddd has quit [Quit: college matriculation time! later all]
osaut_ has joined #ruby
<heftig>
Xeago: yeah. opening a new paragraph implicitly closes the last one
<heftig>
of course, that's not allowed in xhtml
<heftig>
some other tags also implicitly close a <p>, i think at least headings and tables do
<Xeago>
never knew
woolite64 has quit [Ping timeout: 255 seconds]
<JonnieCache>
wtf
xpen has quit [Remote host closed the connection]
<JonnieCache>
heftig: are you sure thats allowed by html5?
<heftig>
SGML is big and ugly
<heftig>
JonnieCache: yes.
jochu has quit [Ping timeout: 264 seconds]
pcarrier has joined #ruby
<JonnieCache>
even better than that! "A p element’s end tag may be omitted if the p element is immediately followed by an address, article, aside, blockquote, dir, div, dl, fieldset, footer, form, h1, h2, h3, h4, h5, h6, header, hr, menu, nav, ol, p, pre, section, table, or ul element, or if there is no more content in the parent element and the parent element is not an a element."
<JonnieCache>
i use haml anyway
<heftig>
i prefer xhtml
<workmad3>
JonnieCache: it doesn't matter if you have the </p> and you attempt to nest an element inside a <p> element that isn't allowed there
<heftig>
wee xslt
<workmad3>
JonnieCache: that then just creates invalid HTML, which browsers tend to fix up
nathancahill has quit [Quit: nathancahill]
krz has quit [Quit: krz]
skcin7 has quit []
cina has joined #ruby
<workmad3>
JonnieCache: in the case of chrome, it has a tendency to either the tag before the invalid element and open it afterwards
<JonnieCache>
all the html i write gets worked over by the designers before it goes out anyway :)
Nisstyre has joined #ruby
pavilionXP has joined #ruby
cina_ has quit [Ping timeout: 244 seconds]
wreckimnaked has quit [Ping timeout: 252 seconds]
nathancahill has joined #ruby
<workmad3>
JonnieCache: right :) I'd hope they know what's valid to nest where
<JonnieCache>
"it only appears that self-closing tags are permitted in HTML5. In actuality, the browser parser treats non-void, self-closed tags as start tags and closes them for you."
<workmad3>
JonnieCache: self-closing tags aren't the same as optional closes
<workmad3>
JonnieCache: a self-close is <img />
<JonnieCache>
thats the point of the article
<workmad3>
JonnieCache: or <br />
<JonnieCache>
no those are "void tags" apparently
gyre007 has quit [Ping timeout: 256 seconds]
<heftig>
<br/>
<heftig>
wee
<heftig>
the space is just for parsers that don't understand xml
<heftig>
they treat the / as an attribute they don't know, and ignore it
<workmad3>
JonnieCache: no, those are what, in XML and XHTML, would be self-closed tags (and more, would be required to be self-closed by the XHTML spec)
elico has quit [Quit: elico]
<workmad3>
JonnieCache: the meaning of /> did change between html4 and html5 though
<workmad3>
html5 basically ignores the /, which means that you can write stuff that's valid XML and it'll go through fine.
<heftig>
workmad3: do the html parsers still choke on <br/>?
<JonnieCache>
tbh i take great pleasure in never thinking about any of that kind of stuff
<JonnieCache>
(unless i actually need to obviously)
gyre007 has joined #ruby
<kapowaz>
I believe there are still exceptions, workmad3
<kapowaz>
iirc you still can't include javascript with <script src="foo.js/>
zz_chrismcg is now known as chrismcg
<JonnieCache>
but i mean doing xml is like doing maintainance on your house, loads of time and money and effort expended and no sense of gain or achievement, or satisfaction
<kapowaz>
and if you do <script src="foo.js"> it expects there to be inline JS after that
Nisstyre has quit [Ping timeout: 276 seconds]
<workmad3>
kapowaz: right, because that is <script src="foo.js">, and <script> tags aren't allowed to have optional closes
<kapowaz>
aye
<kapowaz>
although it ought to be possible, given how often you'd write <script src="foo.js"></script>
<workmad3>
kapowaz: and in XHTML, <script> isn't allowed to be self-closing either
<workmad3>
kapowaz: but that's still nicer that what the html4 spec says it should be ;) which is that <script/> is equivalent to <script>>
<kapowaz>
eesh
<heftig>
JonnieCache: really depends on what you're doing with it
Sgeo_ is now known as LowerMoreAcidic
pcarrier has quit []
<Donkeycoder>
Hey guys. hope one got experience with rabbitmq / amqp-gem. just can't make it do what i want it to do.. may you have a look at this ? gists https://gist.github.com/66c4946690a64bd99692
bradhe has joined #ruby
pcarrier has joined #ruby
nicobrevin1 has joined #ruby
<Donkeycoder>
messages are published but they never appear (no ack and don't show up in web socket.rb
<kapowaz>
Donkeycoder: I can't help, but it would probably be worth your while making sure your editor uses 2 spaces for tabs.
timonv has quit [Remote host closed the connection]
fyolnish has joined #ruby
<Donkeycoder>
good hint :)
jds_ has joined #ruby
<Donkeycoder>
need tabs for sinatra (haml syntax)
reinaldob has joined #ruby
pcarrier has quit [Client Quit]
<kapowaz>
that needs actual tab characters? I've definitely worked with HAML that uses spaces for tabs before…
marr has joined #ruby
<Donkeycoder>
you have to choose tabs or spaces
<Donkeycoder>
but tabs are more viable to me
pavilionXP has quit [Quit: Forget progress by proxy. Land on your own moon.]
<kapowaz>
fair enough. Using TextMate, I guess?
<Donkeycoder>
ill convert when i post gists next time
timonv has joined #ruby
<Donkeycoder>
text mate before now on sublime2
<kapowaz>
I wish TextMate let me set indentation settings per-filetype
<workmad3>
kapowaz: same as with python, tabs or spaces are fine, and with spaces you can decide how many spaces you want... the only thing you need to be is consistent
<kapowaz>
if it was up to me I'd use 2 spaces everywhere but I'm now working on a team where they use 4 spaces (with PHP)
theRoUS has joined #ruby
theRoUS has joined #ruby
theRoUS has quit [Changing host]
<kapowaz>
workmad3: I only brought it up as 2 spaces is quite a widely-used coding style for Ruby
<workmad3>
kapowaz: wait, something that vim does that textmate doesn't? :)
<workmad3>
kapowaz: textmate is about 20 years behind vim though :)
jds_ has quit [Ping timeout: 264 seconds]
<kapowaz>
I'm not going to switch editor, so I'm not sure there's much point in you continuing to extoll its virtues
<Donkeycoder>
text mate is nice but i like that mass mark in sublime
<kapowaz>
I like TextMate. I'm happy enough to stay with it.
chrismcg is now known as zz_chrismcg
<JonnieCache>
st2 just textmate but better
<JonnieCache>
everything thats in textmate is there in st2 with the same keybinding and less ui lag
<Donkeycoder>
depends on your likings i think
<kapowaz>
I tried ST2 — that's manifestly not the same.
<Donkeycoder>
has some handy features
<kapowaz>
I'm sure it's a great editor, but I'm not interested in switching.
<Donkeycoder>
ever worked with text mate 2?
<tobiasvl>
they're all very good editors
Nisstyre has joined #ruby
<tobiasvl>
all editors are
<tobiasvl>
EXCEPT EMACS
<JonnieCache>
lol
keanehsiao has joined #ruby
carloslopes has joined #ruby
jimeh has quit [Quit: Computer has gone to sleep.]
<Donkeycoder>
and nano xD
<tobiasvl>
and notepad
<JonnieCache>
nano is l33t man
pcarrier has joined #ruby
fteem has quit [Read error: No route to host]
fteem has joined #ruby
philcrissman has joined #ruby
<Donkeycoder>
removing line endings in a 300 lines files is l33t -.- bnt.down backspace…….
<Donkeycoder>
Donkey work… xD
gyre007 has quit [Ping timeout: 256 seconds]
cjs226 has quit []
<JonnieCache>
bnt.down? whats that from?
<JonnieCache>
but yeah in st2 its cmd+A, cmd+shft+L, backspace
<Donkeycoder>
arrowkey
<JonnieCache>
no i mean what editor are you referring to there
<Donkeycoder>
nano
<Donkeycoder>
the leet one
rdark has joined #ruby
carloslopes has quit [Ping timeout: 248 seconds]
<JonnieCache>
i still dont know what you mean
<JonnieCache>
(i was joking about it being l33t)
<Donkeycoder>
me 2
<Donkeycoder>
just was saying removing 1 char in every line in a 300 lines file sucks in nano because you make 300 keypresses..
<Donkeycoder>
*600 keypresses.
<JonnieCache>
yeah fuck that
carloslopes has joined #ruby
<JonnieCache>
tbh thats what sed and the like are for :)
chussenot has quit [Quit: chussenot]
Nisstyre has quit [Ping timeout: 260 seconds]
<Donkeycoder>
sure when you think about see when you're pissed by a file like that
<Donkeycoder>
*sed
allsystemsarego has joined #ruby
allsystemsarego has quit [Changing host]
allsystemsarego has joined #ruby
larissa has quit [Ping timeout: 256 seconds]
<JonnieCache>
well i can do all of that stuff in st2 because it has multiple cursors and the ability to put one of those multiple cursors after every match of a regex
larissa has joined #ruby
<JonnieCache>
and each of those cursors has its own clipboard
<Donkeycoder>
compare them to arrays and then do a diff ?
<Donkeycoder>
*convert
hotovson has joined #ruby
<JonnieCache>
i just went require "active_support/core_ext/hash/diff" in the end because apparently this project alreayd depends on AS anyway
Pip has joined #ruby
stetho has joined #ruby
<Pip>
What's the smallest string in ruby?
Nisstyre has joined #ruby
<Pip>
smallest in ASCII table
<workmad3>
Pip: ""
<Pip>
workmad3, Well, it looks reasonable, since it means nothing in the string
<Pip>
And what's the value of the empty string?
Jamone has joined #ruby
<workmad3>
Pip: I no longer have even a vague clue what the hell you're talking about
<workmad3>
Pip: or what you're asking
yonahw has quit [Quit: WeeChat 0.3.7]
<Pip>
zero?
<Pip>
Or null?
<Pip>
'a' < 'b' => true
<Pip>
Because 'a' is before 'b' in the ASCII table
<tobiasvl>
Pip: just test it? :)
<tobiasvl>
the best way to get comfortable with programming
<tobiasvl>
test stuff you wonder about all the time
<Pip>
So how to print the value of ASCII character ''?
cina_ has joined #ruby
<Hanmac_>
Pip on MRI ruby strings are stored differently depending on the size and the refernce ... strings under 23 chars are stored as C-Strin[], strings with more chars are stored as f
<workmad3>
Pip: there are no ascii characters (or any other characters) in an empty string
<workmad3>
Pip: otherwise it wouldn't be an empty string
<tobiasvl>
Pip: there's no ASCII character there, i just meant you should see what '' < 'a' returns in irb
<Pip>
workmad3, I know, so empty sting doesn't have a value?
cina has quit [Ping timeout: 255 seconds]
<Hanmac_>
<23 chars => char[], >23chars => char*
<Pip>
it returns true
<tobiasvl>
yes
<tobiasvl>
and what does just the empty string return?
theRoUS has quit [Ping timeout: 256 seconds]
<Pip>
So what does the "true" mean here?
bluOxigen has quit [Ping timeout: 265 seconds]
<tobiasvl>
itself, the empty string, the value of the empty string
<tobiasvl>
what "true" means?
<tobiasvl>
uh
<Hanmac_>
if you duplicate an 23chare string and does not change it, the second points to the first one
Monie has quit [Ping timeout: 276 seconds]
<Pip>
the returned value of '' < 'a'
<workmad3>
Pip: it means that, according to the operator < on strings, '' is < 'a'
<Spooner>
Hmm, I'm missing something with Slop. How do I get the non-option part of the command? (script.rb -x=12 --frog THIS BIT) ARGV isn't altered and I can't, for the life of me, see if I can ask Slop for it
zommi has joined #ruby
Jell` has quit [Remote host closed the connection]
rippa has joined #ruby
Jell` has joined #ruby
aaronmacy has quit [Quit: Leaving.]
TomyLobo has joined #ruby
bradhe has joined #ruby
sepp2k has joined #ruby
hybris has joined #ruby
philcrissman has joined #ruby
inokenty has joined #ruby
pcboy_ has quit [Remote host closed the connection]
vDubG has quit [Ping timeout: 256 seconds]
csgui has quit [Quit: csgui]
inokenty has left #ruby [#ruby]
<Pip>
How to remove a specific element from an array?
<becom33>
.pop()
<Fuzai>
pop or shift
<becom33>
Pip,
<Pip>
I don't think so
vDubG has joined #ruby
<Pip>
I mean a specified element
zipace has joined #ruby
<Fuzai>
delete
<Pip>
For example, I want to remove a[4]
<becom33>
a.pop(4)
<Pip>
becom33, Are you sure?
<zipace>
hi, are questions regarding trollop (the commandline parser) okay? :|
<Pip>
"If a number n is given, returns an array of the last n elements "
cjs226 has joined #ruby
cina has joined #ruby
<zipace>
anyway, i guess it won't hurt to ask.. the problem I have, that i want to achieve a commandline option parsing similar to, say, valgrind, where arguments of remaining arguments (in this case ARGV) are *not* parsed by trollop anymore
samphippen has joined #ruby
SEToChan has quit [Quit: Lost terminal]
LowerMoreAcidic is now known as Sgeo
kil0byte has joined #ruby
osaut has quit [Read error: Operation timed out]
<zipace>
for instance, ./blah.rb --my-arg=1 --another-trollop-arg=2 anargument --a-command-for-previous-argument (bte, i'm aware of subcommands - except that in this case, the subcommand is not known, hence the example with valgrind)
pcboy_ has joined #ruby
jenrzzz has quit [Ping timeout: 244 seconds]
<becom33>
Pip, use delete_at
Woofy has joined #ruby
Woofy has quit [Read error: Connection reset by peer]
<Pip>
becom33, then I need to know the index, right?
<becom33>
ye
<becom33>
yes
<Hanmac_>
Pip if you want to remove more than ones use ary[idx,count]=[]
Woofy has joined #ruby
Woofy has quit [Read error: Connection reset by peer]
<Pip>
Okay
<becom33>
Hanmac, u asked me to lookup into ncurse . dude too much work for a simple output .
Woofy has joined #ruby
Woofy has quit [Read error: Connection reset by peer]
<zipace>
heftig: i just stared a little harder at trollop's doc, and it turns out it understands stop_on_unknown, which does exactly what i was looking for. \o/
<becom33>
Hanmac, umm "
<becom33>
ok
<zipace>
it's a shame that trollop isn't part of ruby's stdlib, because it's actually quite nice to work with
xpen has joined #ruby
bradhe has quit [Ping timeout: 264 seconds]
danguita has quit [Ping timeout: 252 seconds]
busybox42 has quit [Ping timeout: 264 seconds]
Spami has quit [Quit: This computer has gone to sleep]
heyitsdave has joined #ruby
sie has quit [Ping timeout: 265 seconds]
mvangala has quit [Read error: Connection reset by peer]
timonv has quit [Remote host closed the connection]
jimeh has quit [Ping timeout: 256 seconds]
timonv has joined #ruby
tommyvyo has joined #ruby
ephemerian has left #ruby [#ruby]
DrCode has quit [Ping timeout: 276 seconds]
Virunga has joined #ruby
<Fuzai>
Is there an eliza module for ruby that I could feed a string and it will return with it's reply?
<JonnieCache>
lol there should be
elico has joined #ruby
jpfuentes2 has joined #ruby
dustint has joined #ruby
joofsh has joined #ruby
ChampS666 has joined #ruby
DrCode has joined #ruby
GoGoGarrett has quit [Remote host closed the connection]
nfk has joined #ruby
cina has joined #ruby
pen has joined #ruby
jds_ has joined #ruby
krz has joined #ruby
<lupine>
bah. So close, yet so far, set
timonv_ has joined #ruby
yshh has quit [Remote host closed the connection]
timonv has quit [Read error: Connection reset by peer]
Jackneill has joined #ruby
Jackneill has joined #ruby
cina_ has quit [Ping timeout: 276 seconds]
mercwithamouth has joined #ruby
bradhe has quit [Ping timeout: 252 seconds]
Xabarus has quit [Remote host closed the connection]
JohnTeddy has quit [Ping timeout: 255 seconds]
jimeh has joined #ruby
<lupine>
(if set allowed you to do get_member(value_of_member_hash_attribute) it would be perfect
akl_ has quit [Read error: No route to host]
Coolhand|laptop has joined #ruby
akl_ has joined #ruby
fteem has quit [Ping timeout: 240 seconds]
jds_ has quit [Ping timeout: 255 seconds]
Coolhand has quit [Remote host closed the connection]
pcarrier has quit [Ping timeout: 244 seconds]
ruby-lang800 has quit [Ping timeout: 245 seconds]
fbernier has joined #ruby
pcarrier has joined #ruby
yacks has quit [Remote host closed the connection]
jrist-afk is now known as jrist
JohnTeddy has joined #ruby
cha1tanya has quit [Ping timeout: 256 seconds]
jrist is now known as jrist-demo
dawkirst has quit [Remote host closed the connection]
dave has joined #ruby
dave has quit [Remote host closed the connection]
yacks has joined #ruby
dave has joined #ruby
tk_ has joined #ruby
dave is now known as Guest34315
malkomalko has quit [Remote host closed the connection]
nateberkopec has joined #ruby
gyre008 has joined #ruby
lkba has quit [Ping timeout: 260 seconds]
jeffreybaird has joined #ruby
a_a_g1 has quit [Quit: Leaving.]
timonv_ has quit [Remote host closed the connection]
sonne has quit [Ping timeout: 252 seconds]
gyre007_ has joined #ruby
Guest34315 has quit [Remote host closed the connection]
itsdavem has joined #ruby
fteem has joined #ruby
<apeiros_>
lupine: hu?
blazes816 has joined #ruby
ner0x has joined #ruby
mikecmpbll has joined #ruby
GoGoGarrett has joined #ruby
gyre008 has quit [Ping timeout: 256 seconds]
pskosinski has joined #ruby
<lupine>
apeiros_, because I'm evil, I want Hash#key(hashcode)
jerius has joined #ruby
<lupine>
(to return in constant time the hash key identified by the given hashcode)
<apeiros_>
what's the point of that?
blazes816 has quit [Client Quit]
amaya_the_ has joined #ruby
<apeiros_>
it's impossible anyway, you forfeit on collisions
Spami has joined #ruby
<lupine>
well, collisions wouldn't be an issue for my use case
vlad_starkov has joined #ruby
amaya_the_ has quit [Client Quit]
<apeiros_>
then {hashcode => key}. enjoy.
kil0byte_ has joined #ruby
kpshek has quit []
<apeiros_>
though, I don't see the point of such a construct
<lupine>
it's necessary to implement Set#get_member(hashcode)
<pskosinski>
I have a sinatra app and I am using thin server. When I am accessing site using web browser I am getting site, when using curl I'm getting 500 error, any tip why? Something to defend from bad chakiers?
<apeiros_>
lupine: again, to what avail?
razibog has joined #ruby
<lupine>
in the interests of turning slow bad code into fast bad code :/
<apeiros_>
pskosinski: you should probably read the exception you get
amaya_the_ has joined #ruby
gyre007 has joined #ruby
<apeiros_>
lupine: you think Set#include?(obj.hash) would be faster than Set#include?(obj) ?
<apeiros_>
also, why do you only have obj.hash and not obj?
breakingthings has joined #ruby
<apeiros_>
it sounds to me like you're going down the wrong road… and I doubt better performance is down that road…
dmiller1 has joined #ruby
<lupine>
well, what I'm doing at the moment is building an identity map so I can have obj, and not just obj.hash
amaya_the has quit [Ping timeout: 264 seconds]
clooth_ has joined #ruby
amaya_the_ is now known as amaya_the
ananthakumaran has quit [Quit: Leaving.]
clooth has quit [Read error: Connection reset by peer]
clooth_ is now known as clooth
<pskosinski>
apeiros_: Oh… ty. Well, I am not getting any. When I am using: curl url then I am getting site. When I want to check only headers with: curl -I url then I am getting error…
<lupine>
(this is someone else's code. the purpose is to allow callbacks to be triggered when a collection is updated, or a member of the collection is updated, added or removed)
gyre007_ has quit [Read error: Connection reset by peer]
kil0byte has quit [Ping timeout: 252 seconds]
kil0byt__ has joined #ruby
<apeiros_>
pskosinski: when you get a 500 server error, you definitively get somewhere more information than just "500 server error"
<apeiros_>
your server logs or sinatra log or whatever
<lupine>
I have two objects with different #object_id but the same #hash, one has the callbacks but one does not
<pskosinski>
ah.
<lupine>
(the instance without callbacks being the one I constructed when given what is the hashcode of the instance embedded in the hash in the set)
<apeiros_>
pskosinski: if you don't find those, you can just as well try to rely on voodoo and pixie dust…
nomenkun_ has joined #ruby
<lupine>
I'm aware that this sounds horribly gnarly, and it is
rvmeier has joined #ruby
nomenkun has quit [Read error: Connection reset by peer]
<lupine>
i'm just griping because I can't sensibly monkey-patch Hash ^^
kil0byte_ has quit [Ping timeout: 256 seconds]
serhart has joined #ruby
<apeiros_>
lupine: why do you construct an object based on the hash of another?
dmiller1 has quit [Ping timeout: 264 seconds]
bradhe has joined #ruby
<lupine>
originally, so I could do Set#member?(second_object)
<apeiros_>
anyway, same solution still - {constructed_object => real_object}, and then go 2 levels
<lupine>
if I could do Set#get_member(hashcode) then I wouldn't need to
zph has joined #ruby
<lupine>
any, that's my identity map
<lupine>
aye*
xargoon has quit [Ping timeout: 255 seconds]
<apeiros_>
you can improve performance of Hash by using Hash#compare_by_identity
<apeiros_>
don't know how much, though
nomenkun_ has quit [Read error: Connection reset by peer]
<lupine>
at the moment, I'm all about reducing number of comparisons, not speed of individual comparisons
ThaDick has joined #ruby
nomenkun has joined #ruby
gyre007 has quit [Ping timeout: 248 seconds]
zz_chrismcg is now known as chrismcg
<lupine>
(through various tricks of dup-and-iterate-all when adding or changing a resource in the collection, 10,000 resources ends up as ~24 million lookups of objects)
<Donkeycoder>
anyone ever had this ? Encoding::CompatibilityError - incompatible character encodings: UTF-8 and ISO-8859-1: <- yesterday all was good, now this comes up for no reason..
itsdavem has quit [Remote host closed the connection]
ttt has quit [Ping timeout: 245 seconds]
<workmad3>
hashpuppy: they're using Error as both the base class to derive their errors from and as the namespace
GuidovanPossum has joined #ruby
itsdavem has joined #ruby
mmitchell has joined #ruby
<workmad3>
hashpuppy: so they have the base-class to ensure all their errors derive from StandardError and have a few tweaks... but I'd probably contend they should have gone with Twitter::Error::Base for that
blaxter has joined #ruby
timonv has quit [Read error: Connection reset by peer]
pcarrier has quit [Read error: Connection reset by peer]
<workmad3>
JonnieCache: it defines both +ve and -ve infinities
karasawa has joined #ruby
<JonnieCache>
yeah must check that out sometime
<workmad3>
nah, you really shouldn't... unless you suffer from severe insomnia
usultis_ has quit [Ping timeout: 260 seconds]
<JonnieCache>
interesting that you can t add positive and negative infinities to get zero
zph has quit []
usultis has quit [Ping timeout: 248 seconds]
<JonnieCache>
i suppose thats mathematically accurate
nomenkun has quit [Remote host closed the connection]
<workmad3>
technically, it's not mathmatically accurate just by having the infinities in there
<JonnieCache>
how so
<workmad3>
floating points, by having them, are no longer really a representation of the reals
<JonnieCache>
ah
nomenkun has joined #ruby
<workmad3>
because the reals have no way to deal with infinities... that's really moving into hyperreals
<ericwood>
I tie down the points so they don't float away
chussenot has quit [Quit: chussenot]
<workmad3>
and floats aren't even there, because the hyperreals have both infinities and infinitesimals
<JonnieCache>
thats way over my head
<workmad3>
:)
<JonnieCache>
reals are decimals of infinite precision, right?
<workmad3>
basically, infinity isn't something you can reasonably talk about in the real number system
zph has joined #ruby
cina_ has quit [Ping timeout: 252 seconds]
<workmad3>
the reals are rationals and irrationals, basically
<workmad3>
but they're representation-neutral
vlad_starkov has quit [Ping timeout: 264 seconds]
slainer68 has joined #ruby
* JonnieCache
heads to wikipedia in shame
bradhe has quit [Ping timeout: 252 seconds]
<workmad3>
so it's not really 'decimals of infinite precision', more that some decimal representations of real numbers require a decimal expansion that never ends
nandopaf has left #ruby [#ruby]
<JonnieCache>
i cant even remember what rationals are with any confiedence
chussenot has joined #ruby
sailias has joined #ruby
lateau has quit [Ping timeout: 256 seconds]
<workmad3>
rationals are a/b
<workmad3>
where a and b are integers
<JonnieCache>
last time i was in a maths classroom that was called a fraction
<workmad3>
it's also called a ratio :)
ViPi has joined #ruby
karasawa has quit [Ping timeout: 265 seconds]
<JonnieCache>
but i was thinking of the right thing at least when i said decimals of infinite precision so thats some comfort
<workmad3>
but yes, rationals are the set of numbers that can be represented in terms of integer ratios
<workmad3>
or as integer fractions
Vainoharhainen has joined #ruby
<workmad3>
irrationals are the numbers that can't be :)
<workmad3>
things like pi, sqrt(2), etc
vlad_starkov has joined #ruby
Guest9041 has quit [Remote host closed the connection]
<workmad3>
and while it's really nice and easy to talk about reals, and irrationals, in terms of infinities, infinite precision, etc... it's not a robust concept there
yale has joined #ruby
<workmad3>
more just an aid to understandability
gyre007 has joined #ruby
Guest9041 has joined #ruby
<JonnieCache>
yeah i get that i just needed reminding
eian has joined #ruby
<workmad3>
the hyperreals is an extension to the reals that adds them in robustly though :)
alex__c2022 has joined #ruby
geekbri has joined #ruby
<Sgeo>
Rationals can also be represented as numbers such that it takes either a finite, or infinitely repeating group of numbers after the decimal point to represent
<Sgeo>
^^bad phrasing
<workmad3>
so it adds in the concept of infinities, and infinitesimals (an infinitesimal being a number infinitely close to 0), and extends the basic arithmetic operations to deal with them
karasawa has joined #ruby
sayan has quit [Ping timeout: 256 seconds]
<workmad3>
Sgeo: decimal representations of rationals are indeed either a finite number of significant digits in precision, or an infinite but repeating group of digits
<Sgeo>
Thank you. I need to learn how to English
<workmad3>
yeah, you need to english your math right up ;)
zommi has joined #ruby
krz has joined #ruby
<apeiros_>
is there a good yaml-diff tool?
<Sgeo>
Sad thing is English is the only language I know
krz has quit [Max SendQ exceeded]
marty_mcfly has joined #ruby
<Sgeo>
It's not my second language
phantasm66 has joined #ruby
phantasm66 has joined #ruby
phantasm66 has quit [Changing host]
<workmad3>
Sgeo: the sad thing is, you know no languages... :P
<Sgeo>
lol
stopbit has joined #ruby
krz has joined #ruby
Glacer232 has joined #ruby
Glacer232 has quit [Max SendQ exceeded]
rismoney has joined #ruby
krz has quit [Max SendQ exceeded]
Glacer232 has joined #ruby
Glacer232 has quit [Max SendQ exceeded]
banister`sleep is now known as banisterfiend
segv- has joined #ruby
<workmad3>
JonnieCache: so, in essence and coming back to the point, floating points are really their own number system, which include some extra concepts (like +/- infinity and NaN) that maps reasonably closely onto the reals, so that computers have a way of approximating calculations within usful areas of the real number system
krz has joined #ruby
kpshek has joined #ruby
kpshek has quit [Client Quit]
<workmad3>
JonnieCache: and the standard for them is basically a standard for how to represent them in memory, and a whole heap of error correcting stuff that implementations should do in order to stay as close to the reals as possible
<workmad3>
Sgeo: but what you always, always, end up with is an approximation, not an exact representation
gyre007 has joined #ruby
nemesit has quit [Ping timeout: 255 seconds]
<Sgeo>
workmad3, the idea is to specify the approximation at the end of all calculations, though
<JonnieCache>
this is an exact representation: π
<lirimaery>
is there some way to dump data with YAML with some parameter which will add !!str to the output ?
<workmad3>
JonnieCache: :)
vlad_sta_ has joined #ruby
<Sgeo>
Erm, specifiy the precision of the approximation
<JonnieCache>
pi is fucked up
<workmad3>
pi is transcendental
solidoodlesuppor has quit [Read error: Connection reset by peer]
<hashpuppy>
workmad3: i'm creating a rails site that uses yahoo's api. i'm trying to standardize the yahoo errors into my own errors. is this how my exceptions should look for my app and yahoo errors: http://pastie.org/private/ecg5wis5icnnimk4xvmeg
vlad_starkov has quit [Read error: Connection reset by peer]
<hashpuppy>
MyInvalidError should inherit Base
<hashpuppy>
typo
<Sgeo>
"Exact reals must allow us to run a huge series of computations, prescribing only the precision of the end result. Intermediate computations, and determining their necessary precision must be achieved automatically, dynamically."
yshh has joined #ruby
<JonnieCache>
workmad3: possible to express the fundamental laws of physics without any constants, except a small list that you *cant* get rid of. one of them is π. nobody knows why.
PragCypher has joined #ruby
<JonnieCache>
i think i is also on the list
<JonnieCache>
that kind of thing messes with my head late at night
<workmad3>
JonnieCache: do you know euler's identity?
<Sgeo>
I'd imagine various dimensionless constants would be on there
<workmad3>
JonnieCache: e^iπ + 1 = 0
<banisterfiend>
workmad3: can u prove it
<workmad3>
banisterfiend: I could at one point
gyre008 has joined #ruby
<workmad3>
banisterfiend: but I can't remember how to approach the proof anymore :(
samuel02 has quit [Remote host closed the connection]
<fbernier>
yo if I have a file containing a ruby hash, and I want to load it from another file. Is there a better way than myvar = eval(File.read('myfile')) ?
gyre007 has quit [Read error: Connection reset by peer]
<banisterfiend>
workmad3: yeah, just should the taylor expansions of e^(ix) is equivalent to taylor expansion of i*sin(x) + cos(x)
<banisterfiend>
show*
<banisterfiend>
workmad3: it's pretty ez
<heftig>
fbernier: use another storage format, e.g. JSON, YAML or Marshal
<JonnieCache>
workmad3: π obviously expresses something about the true nature of spacetime. its craaazy
<workmad3>
banisterfiend: of course, I've completely forgotten how the hell I take taylor expansions :)
itsdavem has quit [Remote host closed the connection]
<fbernier>
heftig: I only see downsides to using YAML
<lirimaery>
any idea how to disable implicit conversion during loading YAML files/Strings
<workmad3>
JonnieCache: either that, or it's simply something that crops up a lot in the maths we know currently and our current knowledge of physics builds up on that maths
<apeiros_>
workmad3: re precise pi - I think there are libs which can do symbolic calculation
<apeiros_>
i.e. they'll keep π as a variable
yshh has quit [Ping timeout: 256 seconds]
sonne has joined #ruby
<workmad3>
JonnieCache: don't conflate our current understanding of the laws of physics and their representation as mathematical equations too heavily with deep meaning in reality :)
cina has joined #ruby
<workmad3>
apeiros_: ah yeah, I meant to mention about doing symbolic calculations :)
Neomex has quit [Client Quit]
heyitsdave has quit [Ping timeout: 264 seconds]
<JonnieCache>
good point. its the fact that pi shows up everywhere, even when it has no business being there. that combined with the fact that you cant get rid of it, smells fishy to me
<apeiros_>
workmad3: true! we don't know yet what random number generator god used.
<JonnieCache>
but i know thing about this stuff so i shouldnt speculate
<workmad3>
JonnieCache: incidentally, Carl Sagen's 'Contact' has a nice bit in it about searching for meaning in pi :)
<Donkeycoder>
https://gist.github.com/98bd71ac4622a34b7719 could someone tell me why the web socket , like dies ? or better said, looks like the amqp thread dies, can't figure out why (happens on website reload /socket connection)
_alejandro has joined #ruby
<banisterfiend>
workmad3: mclaurin expansion is easy (special case of taylor around 0). Basically you just match derivatives of a power series to the original fucntion, based on the idea that x^n/n! when differentaited 'n' times gives u 1, so you, have a series like this: 1 + x + x^2/2! + x^3/3! + x^4/4! and u multiply the nth term in that series by the nth derivative of the function u r expandingn at 0
<hashpuppy>
and is there a way to reference the parent Base instead of doing ::Exceptions::Base?
<JonnieCache>
workmad3: im not talking about meaning in the actual value of pi. thats just numerology ;)
<workmad3>
banisterfiend: ah, that seems familiar too :)
<apeiros_>
hashpuppy: toplevel module named "Exceptions"? bad idea :-p
<apeiros_>
hashpuppy: I prefer inheriting from proper exceptions, i.e. not Exceptions::Base
<apeiros_>
hashpuppy: if you need a way to identify all exceptions from the same library, use include
<workmad3>
JonnieCache: it was more to do with exploring the expansions of them in certain representations and finding sequences that are statistically highly improbable at that point
<apeiros_>
hashpuppy: e.g. class InvalidPort < ArgumentError; include MyGemName::Exception; end
<JonnieCache>
theres a bit in one of the discworld where a guy makes a device where all the cogs were machined with pi == 3.0 in order to save time and effort. the device ends up as a time machine haha
bradhe has joined #ruby
<apeiros_>
hashpuppy: you can then rescue MyGemName::Exception, or InvalidPort, or ArgumentError
nari has quit [Ping timeout: 256 seconds]
<JonnieCache>
workmad3: you mean the 9 9s or whatever? thats just basic probability theory isnt it? ie. weird shit happens, get used to it
goodman1 has joined #ruby
<workmad3>
JonnieCache: e.g. finding (in binary expansion) a sequence of 0/1s in the expansion that, when displayed as a square, is a circle of 1s
<hashpuppy>
apeiros_: interesting. i'll take a look at it. i'm using a library that uses net/http and unfortunately have to rescue Timeout::Error, Errno::EINVAL, Errno::ECONNRESET, EOFError, Net::HTTPBadResponse, Net::HTTPHeaderSyntaxError, Net::ProtocolError
<workmad3>
JonnieCache: and that, while statistically provable to happen somewhere in the expansion of pi, is (in the idea of the book) something that occurs much earlier than would be expected
<hashpuppy>
so, i was just going to rescue that and raise Exceptions::Yahoo::ConnectionError
jonahR has joined #ruby
obryan has quit [Read error: Connection reset by peer]
<JonnieCache>
workmad3: yeah but it is expected that unexpected things happen
gyre007 has joined #ruby
<JonnieCache>
so its not weird :P
gyre008 has quit [Read error: Connection reset by peer]
Spami has quit [Quit: This computer has gone to sleep]
<workmad3>
JonnieCache: it wasn't claimed to be weird :) but it is a really nice idea, and also that by looking at and trying to work out why these things happen you can gain deep insight into the roots of mathematics and the nature of the universe that gives rise to them
<JonnieCache>
i need to read that sagan book. ive seen the film. its good.
dmiller1 has joined #ruby
becom33 has quit [Ping timeout: 252 seconds]
becom33 has joined #ruby
becom33 has quit [Changing host]
becom33 has joined #ruby
<JonnieCache>
the film seems incredibly daring when you watch it now
clocKwize has quit [Quit: clocKwize]
<JonnieCache>
it would never get made now.
GoGoGarr_ has joined #ruby
<workmad3>
I haven't watched the film in years
rondale_sc has joined #ruby
haxrbyte has joined #ruby
timonv has quit [Remote host closed the connection]
samphippen has joined #ruby
haxrbyte has quit [Remote host closed the connection]
GoGoGarrett has quit [Ping timeout: 256 seconds]
haxrbyte has joined #ruby
dmiller1 has quit [Ping timeout: 246 seconds]
samphippen has quit [Client Quit]
generalissimo has joined #ruby
pavilionXP has joined #ruby
<JonnieCache>
all the stuff about religion in it would stop it getting funded now
dmiller1 has joined #ruby
thatguycraig has joined #ruby
thatguycraig has quit [Max SendQ exceeded]
<Xeago>
JonnieCache: make a kickstarter :D
<Xeago>
I'd donate
inokenty has joined #ruby
thatguycraig has joined #ruby
thatguycraig has quit [Max SendQ exceeded]
thatguycraig has joined #ruby
thatguycraig has quit [Max SendQ exceeded]
thatguycraig has joined #ruby
jrist is now known as jrist-bbs
<JonnieCache>
Xeago: the films already been made. thats the point. thats how i know it wouldnt get made now
allsystemsarego has quit [Quit: Leaving]
<Xeago>
ah
<JonnieCache>
because ive seen it
<Xeago>
nust've missed that ;'(
Hanmac_ has quit [Ping timeout: 245 seconds]
rondale_sc has left #ruby [#ruby]
<workmad3>
Xeago: it was made in the 90's iirc
theRoUS has joined #ruby
theRoUS has quit [Changing host]
theRoUS has joined #ruby
<JonnieCache>
yeah back before the evangelicals rose to absolute power
<JonnieCache>
but lets not get into that
<JonnieCache>
it is a good film either way. apparently sagan did the screenplay but died before it got filmed
skcin7 has joined #ruby
companion has quit [Quit: Poweroff]
companion has joined #ruby
samphippen has joined #ruby
jlast has joined #ruby
razibog has quit [Read error: Operation timed out]
jlast has quit [Remote host closed the connection]
bean has joined #ruby
jlast has joined #ruby
<ericwood>
ugh, I get to work early since I'm a morning person, but my coworkers don't show up until 10
<ericwood>
....and now I'm stuck waiting for them to show up because all of a sudden I need to consult them
dr_neek has joined #ruby
shadow_fox has joined #ruby
kayloos has joined #ruby
jonathanwallace has quit [Ping timeout: 248 seconds]
danneu has joined #ruby
Hanmac_ has joined #ruby
d2dchat has joined #ruby
timonv has joined #ruby
<JonnieCache>
go back and fix all that shonky code you left because you didnt have time to refactor it ;)
<Xeago>
what should I think about whytheluckystiff.net?
<Hanmac_>
goodman1 you need an C++ Compiler, and this gem maybe does not work on ruby1.8
xpen has quit [Ping timeout: 256 seconds]
<bolivar>
hi all. I have a very noob question (learning ruby from a book). Anyone have time?
<Xeago>
bolivar: just ask :)
<ericwood>
Xeago: the 2nd coming is upon us
<bean>
Xeago: there was an interesting hackernews post about it
<Xeago>
and coming implies?
<bean>
that _why may come back
<ericwood>
you'll know when the time comes
<hoelzro>
Xeago: end of the world
<hoelzro>
;)
frem has joined #ruby
<Xeago>
bean: reading it now, I joined #ruby about a month after he vanished
<ericwood>
bolivar: don't ask to ask, just go ahead and ask your question!
<ericwood>
we'll answer
<bean>
ah,
<JonnieCache>
bean: interesting? it seemed to be the usual arguing
<bean>
eh, I ignore the arguing
<ericwood>
JonnieCache: that, and complaining about those damn ruby rockstars and kids on their grass
<bean>
I just wanted to know what the printer spool contained
krz has quit [Quit: Leaving]
<bean>
and saying that _why wrote shit code.
<ericwood>
well, he did
<JonnieCache>
printer spool?
tagrudev has quit [Remote host closed the connection]
<bolivar>
I'm trying to understand something about object variables. If I assign an object variable inside a method (that's inside a class, of course...), will it be available to all methods of that class? Or just to that method?
<bean>
I'd say the point of _why's stuff wasn't code quality.
<ericwood>
bolivar: by object variable do you mean instance variable?
<hoelzro>
bolivar: all methods
<bolivar>
I mean @foo
bradhe has quit [Ping timeout: 248 seconds]
<Xeago>
JonnieCache: there;s transcripts at around 50% of the comments
<ericwood>
bolivar: those are instance variables; they'll be available anywhere inside an instance of a class
<bolivar>
ah... my book says "object variables (also known as instance variables)". So instance variable is the correct term?
<Hanmac_>
bolivar: if you define the methods inside a class the method is accessavle to all instances of the class, instance variables you define in this modules are useable on the object in each method the object has
niklasb has joined #ruby
<bean>
bolivar: yes. What book are you using?
<frem>
bean: do we have a way of knowing what was in the print queue? it just looked like a log showing the time something was printed.
<JonnieCache>
Xeago: i have no idea what this printer spool business refers to. must rmember to check it out later
<ericwood>
bolivar: I've never heard the term "object variable" ever, so I think instance variable is more proper :P
<bolivar>
Beginning Ruby: From Novice to Professional (by Peter Cooper)
<bean>
frem: yes, there were several things that people found.
<Xeago>
JonnieCache: there were documents
<Xeago>
and they were retrieved
* bean
has never been a fan of books for learning programming
kil0byt__ has quit [Remote host closed the connection]
dustint_ has joined #ruby
willob has joined #ruby
<JonnieCache>
Xeago: oh so was his site back up as an open dir with postscript files in it or something? its not clear
<JonnieCache>
i never actually looked at the domain
Nisstyre has quit [Ping timeout: 276 seconds]
<Xeago>
HP PCL thingyes
<Xeago>
thingys*
<Xeago>
or thingies
<Xeago>
my english is lacking me
dustint has quit [Ping timeout: 240 seconds]
<ericwood>
well, regardless, this fills me with hope because I assumed the worst
<JonnieCache>
tbh ive never been a big _why fan. i mean his prodigious coding output and love for his work was obv amazing
SCommette has joined #ruby
<ericwood>
parts of the Poignant Guide almost made him sound depressed and I was afraid of him doing something extreme :(
<JonnieCache>
but his comics and self-concious cookiness never worked for me
<JonnieCache>
but yeah its good that hes apparently ok
<ericwood>
I really love his demeanor and overall committment to programming as art
krz has joined #ruby
jgarvey has joined #ruby
<ericwood>
he was a happy dude, and he wanted to spread the happy
ryannielson has joined #ruby
joshman_ has joined #ruby
haxrbyte has quit [Ping timeout: 248 seconds]
<JonnieCache>
yeah im not saying he doesnt deserve the praise for his work in the community, just that his antics never really amused me. but thats probably because im a bitter miserable englishman
<ericwood>
oh, yeah, definitely
<ericwood>
you british people and your bitterness
<ericwood>
it's okay, though, I'm a huge fan of Downton Abbey :D
<workmad3>
we've made being miserable into an art
<tobiasvl>
what's this, i turn my head away from the monitor for ten minutes and _why is back from the dead?
<regedarek>
Hi, is better way in ruby to achieve this: "past_event".split('_').map {|w| w.capitalize}.join(" ")
<ericwood>
I think that's about as succinct as it gets without being sloppy
<JonnieCache>
ericwood: just as long as you know its about as "historical" as the average US renaissance fair
jthomp has joined #ruby
<ericwood>
it seems pretty accurate
nateberkopec has joined #ruby
<JonnieCache>
haha
<ericwood>
what's inaccurate?
<Donkeycoder>
this rabbitmq is killing me -.- one more day and i replace it with redis pub/sub ....
<JonnieCache>
erm the fact that the first world war is over in a week and nobody seems to notice
<ericwood>
JonnieCache: well, they didn't show you the whole thing, but they definitely talk about time passing
* ericwood
just finished season 2 last night
sayan has joined #ruby
sayan has quit [Changing host]
sayan has joined #ruby
<JonnieCache>
they use all sorts of modern phrases all the time as well but i guess thats forgivable
<ericwood>
I want that lifestyle
cina_ has joined #ruby
<JonnieCache>
ericwood: WWI was a massive trauma that basically destroyed britain's entire national psyche
shadow_fox has quit [Ping timeout: 240 seconds]
cina has quit [Ping timeout: 246 seconds]
<ericwood>
so y'all weren't bitter before then?
<JonnieCache>
WWI is the reason why nobody here believes in god
<ericwood>
well, I can understand that
sailias has quit [Quit: Leaving.]
<JonnieCache>
im not kidding thats basically true
<ericwood>
oh yeah, no, I can believe it
<JonnieCache>
and in downton they just gloss over it haha. but its an entertainment show so im not going to get upset about it :)
<ericwood>
WWII fucked Japan up pretty bad, too
carloslopes has quit [Remote host closed the connection]
Nisstyre has joined #ruby
<JonnieCache>
yeah that was so recent as well
gyre008 has joined #ruby
jrist-bbs is now known as jrist
kayloos has quit [Quit: kayloos]
rakl has quit [Quit: sleeping]
sailias has joined #ruby
xclite has joined #ruby
gyre007 has quit [Ping timeout: 256 seconds]
Jackneill has quit [Remote host closed the connection]
kayloos has joined #ruby
<mjolk>
I'm trying to use Net::SSH to verify a public key and I'm having a hell of a time with it. I keep getting 'Could not parse PKey' errors
kayloos has quit [Client Quit]
chussenot has quit [Quit: chussenot]
<mjolk>
I've googled. but I can't find anything related. The key exists as specified by 'keys'
banisterfiend has quit [Remote host closed the connection]
jenrzzz has joined #ruby
goodman1 has quit [Excess Flood]
goodman1 has joined #ruby
eldariof has quit [Ping timeout: 260 seconds]
Guest25886 has joined #ruby
gnaritas has joined #ruby
fteem has quit [Read error: No route to host]
fteem has joined #ruby
bradhe has joined #ruby
cdt_ has quit [Quit: Ex-Chat]
amaya_the has quit [Quit: ChatZilla 0.9.89 [Firefox 17.0.1/20121128204232]]
cdt has joined #ruby
<Xeago>
I would like to get rid of oh-my-zsh, and roll my own zsh config
<Xeago>
any tips?
sayan has quit [Read error: Connection reset by peer]
<mjolk>
never mind, figured it out. error is a misnomer
<mjolk>
how is that ruby related xeago?
krz has quit [Quit: Leaving]
coder_neo has quit [Ping timeout: 244 seconds]
<hoelzro>
Xeago: start with an empty config and build on it until you have what you need
<hoelzro>
what I did is port over my bash config
thatguycraig has left #ruby [#ruby]
<Xeago>
I kinda want to keep my current oh-my-zsh things
<Xeago>
there is a ton of shit that gets done during the load of oh-my-zsh
<hoelzro>
probably not the best way to use all of zsh's power, but I figured that getting comfortable is step #1
<JonnieCache>
Xeago: try prezto, the fork of omz that isnt a mess
<mjolk>
then learn shell scripting and rip out what you don't want from zsh
<hoelzro>
Xeago: if you miss something from oh-my-zsh, copy it over
<Xeago>
JonnieCache: tried that, still a mess
<JonnieCache>
Xeago: if only because its easier to rip apart than omz
<Xeago>
launches zsh multiple times
<JonnieCache>
does it
<JonnieCache>
its mostly fine for me
<Xeago>
yea, 4 times for me
wermel has quit [Remote host closed the connection]
<JonnieCache>
what nested in each other you mean
Gues_____ has joined #ruby
Gues_____ is now known as RubNoob
gnaritas has left #ruby [#ruby]
<Xeago>
during load yes, not neccesarily nested but reinvocations
<Xeago>
without reasoning
coder_neo has joined #ruby
<JonnieCache>
hmm how could i check that
<RubNoob>
Hello, is anyone familiar with calling another coffeescript template from within a coffeescript template? (i.e. render 'another_coffeescript')
<JonnieCache>
Xeago: i see a couple of bash instances flicker in the box there
<Xeago>
yuck :3
<Xeago>
you using rvm?
shadow_fox has joined #ruby
<Xeago>
I think that has a dependency on bash
<JonnieCache>
Xeago: i assume thats because im executing scripts in my .zshrc which have bash shebangs in them
moshee has quit [Ping timeout: 264 seconds]
hackerdude has joined #ruby
<JonnieCache>
yeah unfortunately at work everyone uses rvm
<Xeago>
most likely yes
moshee has joined #ruby
moshee has joined #ruby
moshee has quit [Changing host]
<Xeago>
I am getting away with rbenv
pavilionXP has quit [Quit: Forget progress by proxy. Land on your own moon.]
<JonnieCache>
it doesnt bother me tbh opening a shell still only takes <0.5s
<ericwood>
rvm works fine in zsh for me
<JonnieCache>
and i rarely need to open new shells anyway
<Xeago>
JonnieCache: it takes longer for me :\
<ericwood>
well, sometimes it's a tad bit slow
<Xeago>
up to sometimes 10 seconds
jrist is now known as jrist-doc
osaut has joined #ruby
Hanmac_ has quit [Quit: Page closed]
<Xeago>
memory is tightly constrained and so are diskreads
<ericwood>
yeah, I've experienced that
<zph>
No trouble using RVM in zsh here. Did have trouble about a 1.5 yrs ago but might have been old version of ZSH (or bleeding edge ZSH which also caused trouble)
timonv has joined #ruby
ezra has quit [Remote host closed the connection]
baroquebobcat has joined #ruby
<Xeago>
on a debian system I installed a looong time ago, I didn't install bash, rvm failed
chussenot has joined #ruby
<jsaak>
thx Hanmac_
<Xeago>
never figured out why, until I started doing ruby
carloslopes has joined #ruby
csgui has quit [Quit: csgui]
<mjolk>
can someone point me in the right direction for doing ssh fingerprinting using ruby?
<mjolk>
i was thinking of doing it via net::ssh, but i can't get it to just spit out the fingerprint
<JonnieCache>
Xeago: i do have a swag computer at this job :)
haxrbyte has quit [Ping timeout: 246 seconds]
<JonnieCache>
Xeago: which actual zsh are you using btw? the osx default one is old and busted
<banisterfiend>
JonnieCache: retina?
<banisterfiend>
i think i've asked u that before an dthe answer was no..
<JonnieCache>
yeah
haxrbyte has joined #ruby
<JonnieCache>
its just a quadcore i5 with 8gb ram and an ssd
bradhe has quit [Ping timeout: 252 seconds]
baphled has quit [Ping timeout: 255 seconds]
<JonnieCache>
but thats by far the fastest computer ive ever had regular access to and it is excellent
cina_ has quit [Ping timeout: 246 seconds]
<bean>
LOL, customer I just emailed about the rails vulnerability was basically like "yeah, we're aware, but we'll update when we can"
<bean>
jesus
<bean>
people are ASKING to get hacked
<banisterfiend>
JonnieCache: what size is the ssd?
Fraeon has quit [Remote host closed the connection]
<banisterfiend>
JonnieCache: is that an ivybridge or sandybridge processor?
jojosiao has joined #ruby
macmartine has joined #ruby
coder_neo has quit [Ping timeout: 265 seconds]
<Xeago>
JonnieCache: both the one from osx and brew, but usually osx's
<apeiros_>
MrPunkin: and for next time, "some errors" is a horribly bad excuse for the exception you've got…
<MrPunkin>
apeiros_: it was saying "Invalid date"
emanu has joined #ruby
<MrPunkin>
it was the wrong formatting string though
pavilionXP has joined #ruby
<MrPunkin>
I had month / date reversed
<apeiros_>
MrPunkin: yes. next time you paste that. including your input.
MrPunkin has left #ruby [#ruby]
nwertman has quit [Read error: Connection reset by peer]
<apeiros_>
it's annoying having to pull that out of your nose :-p
grzywacz has joined #ruby
wallerdev has joined #ruby
<Xeago>
sigh
<Xeago>
he didn't even stay
<apeiros_>
sometimes I ponder blacklists
<apeiros_>
hm, or actually…
* apeiros_
should reactivate butler
<apeiros_>
there's some nice things I could do
dmerrick has joined #ruby
<Xeago>
rofl xD
jgrevich has joined #ruby
hoelzro is now known as hoelzro|away
PragCypher has quit [Read error: Connection reset by peer]
<apeiros_>
like… mark people who fail to provide a proper explanation twice. when that person asks a question, the bot automatically reminds him of basic problem description.
<ericwood>
or people who ask to ask questions
<apeiros_>
marking could be done automatically by triggering the canned info message for a person
benlieb has quit [Read error: Connection reset by peer]
<apeiros_>
mhm, a bayesian filter for automated canned replies
benlieb has joined #ruby
<ericwood>
in another channel I'm in we have ~ask, which just triggers a canned response about etiquette
<JonnieCache>
just get the bot to answer the questions
<JonnieCache>
and we can just drink cocktails
nwertman has joined #ruby
<ericwood>
make it so
bradhe has quit [Read error: Connection reset by peer]
generalissimo has quit [Remote host closed the connection]
<ericwood>
damn, JRuby, you slow
bradhe has joined #ruby
<Donkeycoder>
or send em over there: => telnet bofh.jeffballard.us 666
<ericwood>
starting up is, at least...
camidoo has joined #ruby
brianpWins has joined #ruby
<griffindy>
ericwood ideally once it's up it hums a long
<JonnieCache>
something like if the edit difference for any line ending in a question mark and the top result when searching for that phrase on stackoverflow is less than n, kick that person with the url of the SO question as the message
RagingDave has joined #ruby
<griffindy>
but TDD can be a PITA
<ericwood>
griffindy: if only I didn't have to keep restarting the rails server :'(
PragCypher has joined #ruby
breakingthings has quit []
Kuifje has joined #ruby
Kuifje has joined #ruby
Kuifje has quit [Changing host]
<griffindy>
ericwood agreed
<ericwood>
JVM nomnomnoms RAM
chussenot has quit [Quit: chussenot]
<ericwood>
"oh, hey, you aren't using that? mind if I borrow it?"
<apeiros_>
it asks first?
<ericwood>
no, it's quite rude
<mjolk>
I'm trying to test deploy keys using bitbucket.org for the sake of scripting checks for the RSA authenticity confirmation step of making a new SSH connection ('RSA key fingerprint is 97:8c:1b:f2:6f:14:6b:5c:3b:ec:aa:46:46:46:00:00'). This requires making a connection with 'ssh -T' to disable pseudo-tty allocation. I see that there's a Net::SSH::HostKeyError fingerprint() method, but I'm not 100% sure of how to approach this prolbme.
timonv has quit [Remote host closed the connection]
<ericwood>
havenn: hmm, interesting, I'll check that out
<apeiros_>
havenn: ooooh, I'll have to see whether that works for me on my synology ds411 too (20s jruby startup time…)
goodman1 has quit [Ping timeout: 244 seconds]
<griffindy>
isn't spork also supposed to alleviate some of the JVM startup time?
<ericwood>
hah, mine can be upwards of a minute from starting to page load
<ericwood>
longer in some cases
<ericwood>
it's a huge rails app, though
<JonnieCache>
theres some new and clever solution to jvm launching, cant remember what it is
<mjolk>
Thoughts, feelings? I basically need to start a non-interactive ssh session that I know will get rejected, but compare the fingerprint to a variable and then store the known host
<JonnieCache>
you should definitely look for it, it seemed very clever
<ericwood>
JonnieCache: it keeps it running in the background, iirc
bradhe has quit [Ping timeout: 244 seconds]
cipheram has joined #ruby
Jell` has quit [Ping timeout: 244 seconds]
jerius has joined #ruby
mercwithamouth has quit [Ping timeout: 252 seconds]
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
emanu has quit [Quit: emanu]
wendallsan has joined #ruby
<Xeago>
ericwood: still using Alfred?
jpfuentes2 has joined #ruby
atno has joined #ruby
<ericwood>
always
<ericwood>
I could stand to make better use of it, but I launch everything with it
<Xeago>
you feel spotlight lacks as a launcher or that alfred is faster?
mikecmpbll has joined #ruby
<ericwood>
alfred is much faster imho
<Xeago>
anyone here on 10.8 tho?
<ericwood>
I am
<Xeago>
did you get rid of notification center's icon?
<ericwood>
the thing about alfred is it learns based on your past decisions
<ericwood>
the built-in calculator is also awesome
<mjolk>
is my question not interesting?
<ericwood>
nah, I left it
ThaDick has quit [Quit: zzzZZZ ...]
<ericwood>
mjolk: sorry, I'm not qualified to answer it :\
<mjolk>
:(
<Xeago>
I freaking hate the icon taking spotlight
<mjolk>
just want to make sure i didn't make a channel-specific faux pas
<Xeago>
sorry I missed it mjolk, mind repeatng?
danneu has quit [Quit: WeeChat 0.3.8]
<ericwood>
mjolk: this may not be the best choice of channels for asking it, but I can't think of any better ones :\
<Xeago>
ah the ssh stuff
<mjolk>
yeah
joeycarmello has joined #ruby
<Xeago>
isn't there -N or soemthing?
<mjolk>
in net/ssh?
<Xeago>
h,,
williamcotton has joined #ruby
<Xeago>
sorry no idea
jjbohn has joined #ruby
<Xeago>
apeiros_: sc2 tonight?
<mjolk>
if i provide the Net::SSH::KeyFactory with the pub/priv key, it tries to allocate a TTY and then just vomits all over itself
<Xeago>
apeiros_: I practiced some more, btw anyone else for sc2 hit me up
ThaDick has joined #ruby
carloslopes has joined #ruby
<mjolk>
no worries Xeago, i appreciate you reading it anyway
<apeiros_>
ctcp time is supposed to return the local time
vlad_sta_ has quit [Read error: Connection reset by peer]
<Xeago>
well it obviously misses out timezones in the response
<apeiros_>
if everybody's client returned utc, all you'd know is how much off their computer's clock is…
buscon has quit [Quit: Leaving]
<apeiros_>
well, 17:00+0100 == 16:00+0000
<Xeago>
so it is the correct time, even locally, just represented with the wrong timezone
<apeiros_>
no
vlad_starkov has joined #ruby
<Xeago>
CTCP-reply TIME from apeiros_ : 2013-01-10 17:31:53 +0000
<apeiros_>
yes, which is wrong
<Xeago>
that is the correct time, wrong time zone
<apeiros_>
and doesn't tell you anything
<Xeago>
tells me what time it is?
<apeiros_>
lol
<apeiros_>
you don't need to ask my computer for that, you have your own :-p
<Xeago>
I am quite used to type date to see if my hunger is valid
roadt has quit [Ping timeout: 260 seconds]
gridaphobe has joined #ruby
<Xeago>
only thing that is wrong with it is that it doesn't also convey the timezone you are based in
eldariof has joined #ruby
artOfWar has joined #ruby
<apeiros_>
again, ctcp time's purpose is to find the local time of another user. not what time we have (since that's globally the same, everywhere on the world it's now 17:35 in GMT)
<apeiros_>
well, if it conveyed timezone, it'd display 18:35:00+0100, not 17:35:00+0100
<Xeago>
ill see if I can hack into limechat
<apeiros_>
man, rails sure takes long to install…
hashpuppy has quit [Read error: Connection reset by peer]
Elhu has quit [Quit: Computer has gone to sleep.]
<Xeago>
or 17:35:00 GMT — Location elsewhere derive your own timezone
hashpuppy has joined #ruby
hashpuppy has quit [Changing host]
hashpuppy has joined #ruby
hashpuppy has quit [Client Quit]
ElorTegle has joined #ruby
jenrzzz has quit [Ping timeout: 246 seconds]
tjbiddle has joined #ruby
robotmay has joined #ruby
rakl has quit [Quit: sleeping]
tjbiddle has quit [Remote host closed the connection]
shadow_fox has left #ruby [#ruby]
whitedawg has quit [Quit: Leaving.]
tps_ has joined #ruby
vlad_starkov has quit [Ping timeout: 255 seconds]
Pip has quit [Ping timeout: 276 seconds]
tjbiddle has joined #ruby
zigomir has joined #ruby
woolite64 has quit [Quit: Leaving]
GoGoGarrett has joined #ruby
kil0byte has joined #ruby
woolite64 has joined #ruby
callenb has left #ruby [#ruby]
gridaphobe has quit [Remote host closed the connection]
williamcotton has quit [Quit: williamcotton]
<Xeago>
It does NSString* text = [[NSDate date] description];
mercwithamouth has joined #ruby
gridaphobe has joined #ruby
cdt has quit [Quit: Ex-Chat]
maxmanders has quit [Quit: Computer has gone to sleep.]
Daman has quit [Read error: Connection reset by peer]
GoGoGarr_ has joined #ruby
buibex has quit [Remote host closed the connection]
<mjolk>
anyone know how to make Net::SSH spit out the fingerprint for the host machine it connected to?
sandGorgon has joined #ruby
llaskin has joined #ruby
jblack has joined #ruby
dwu1 has joined #ruby
<llaskin>
did string#scan change in 1.9.3?
<Xeago>
apeiros_: what is the correct format for the time in irc?
GoGoGarrett has quit [Ping timeout: 248 seconds]
pyrocommie has joined #ruby
kuranai_off is now known as kuranai
<Xeago>
seems we should use descriptionWithLocale instead
squidBits has joined #ruby
mahmoudimus has joined #ruby
pyr0commie has quit [Ping timeout: 252 seconds]
ThaDick has quit [Quit: zzzZZZ ...]
squidBits has quit [Read error: Connection reset by peer]
squidBits has joined #ruby
keanehsiao has quit [Quit: keanehsiao]
DrShoggoth has joined #ruby
c0rn has joined #ruby
kuranai has left #ruby [#ruby]
pyrocommie has quit [Ping timeout: 252 seconds]
samphippen has quit [Quit: Computer has gone to sleep.]
yshh has joined #ruby
benlieb has quit [Quit: benlieb]
breakingthings has quit []
<llaskin>
https://gist.github.com/4504229 seems that scan functionality changed in 1.9.3 Can someone suggest a way to write a better regex?
billy_ran_away has quit [Ping timeout: 244 seconds]
llaskin has quit [Changing host]
llaskin has joined #ruby
wendallsan has quit [Ping timeout: 256 seconds]
tcurdt has quit [Client Quit]
cardoni has joined #ruby
dmiller1 has quit [Ping timeout: 246 seconds]
<blazes816>
llaskin: you can't change that behavior with a different regex, but you do a.match(/a(\d*)_/).captures.first
<blazes816>
a bit more semantical
<sandGorgon>
is anybody using rbenv in production to run cron jobs (using ruby scripts) ? I'm not sure if I have to have rbenv in my bash -lc scripts (which seem weird) or there is a way to use bundle exec to run the scripts without hitting bash
GoGoGarrett has joined #ruby
sn0wb1rd has joined #ruby
zommi has quit [Quit: Leaving.]
ngoldman has joined #ruby
dmiller1 has joined #ruby
zigomir has quit [Quit: zigomir]
green_leaf has quit [Quit: Leaving]
billy_ran_away has joined #ruby
kil0byte has quit [Ping timeout: 276 seconds]
_md has quit [Quit: Leaving...]
Daman has joined #ruby
Daman has quit [Changing host]
Daman has joined #ruby
Daman has quit [Excess Flood]
Vainoharhainen has quit [Quit: Leaving...]
RagingDave has quit [Read error: Connection reset by peer]
pskosinski has quit [Read error: Connection reset by peer]
pskosinski_ has joined #ruby
pyrocommie has joined #ruby
spinagon has quit [*.net *.split]
wermel has quit [*.net *.split]
jeffreybaird has quit [*.net *.split]
jgarvey has quit [*.net *.split]
xargoon has quit [*.net *.split]
jonahR has quit [*.net *.split]
Guest9041 has quit [*.net *.split]
bitZero__ has quit [*.net *.split]
locriani has quit [*.net *.split]
TomRone has quit [*.net *.split]
tris has quit [*.net *.split]
akl has quit [*.net *.split]
alanp has quit [*.net *.split]
dross has quit [*.net *.split]
`Kevin has quit [*.net *.split]
hemanth_ has quit [*.net *.split]
bigkevmcd has quit [*.net *.split]
alexspeller has quit [*.net *.split]
BadLarry has quit [*.net *.split]
awarner_ has quit [*.net *.split]
Spaceghost|cloud has quit [*.net *.split]
davidcelis has quit [*.net *.split]
Norrin has quit [*.net *.split]
cristian has quit [*.net *.split]
wedgeV has quit [*.net *.split]
aquagrunty has quit [*.net *.split]
Eiam has quit [*.net *.split]
dominikh has quit [*.net *.split]
maetthew has quit [*.net *.split]
fcoury_ has quit [*.net *.split]
jhowarth__ has quit [*.net *.split]
spanx___ has quit [*.net *.split]
z has quit [*.net *.split]
thorncp has quit [*.net *.split]
ddv has quit [*.net *.split]
TheMoonMaster has quit [*.net *.split]
shadewind has quit [*.net *.split]
Pip has joined #ruby
dross has joined #ruby
wedgeV has joined #ruby
z has joined #ruby
dross has quit [Changing host]
dross has joined #ruby
aquagrunty has joined #ruby
alanp has joined #ruby
maetthew has joined #ruby
bitZero__ has joined #ruby
cristian has joined #ruby
akl has joined #ruby
akl has joined #ruby
akl has quit [Changing host]
BadLarry has joined #ruby
TomRone has joined #ruby
shadewind has joined #ruby
wermel has joined #ruby
hemanth_ has joined #ruby
Guest9041 has joined #ruby
bigkevmcd has joined #ruby
davidcelis has joined #ruby
ossareh has quit [Excess Flood]
thorncp has joined #ruby
pskosinski_ is now known as pskosinski
tris has joined #ruby
jgarvey has joined #ruby
locriani has joined #ruby
xargoon has joined #ruby
TwN has joined #ruby
z is now known as Guest2324
awarner has joined #ruby
jhowarth__ has joined #ruby
dotemacs has joined #ruby
spanx___ has joined #ruby
<TwN>
test
dominikh has joined #ruby
TheMoonMaster has joined #ruby
Spaceghost|cloud has joined #ruby
<Xeago>
CTCP-reply TIME from TwN : Thursday, January 10, 2013 7:02:50 PM Central European Time
<Xeago>
is that a better ctcp reply?
pyr0commie has quit [Ping timeout: 252 seconds]
benlieb has joined #ruby
Norrin has joined #ruby
fcoury_ has joined #ruby
karl_____ has quit [Ping timeout: 245 seconds]
ossareh has joined #ruby
<apeiros_>
yes
cina has quit [Ping timeout: 256 seconds]
<apeiros_>
not sure it's correct, though. I'd have to check whether there are specs.
<TwN>
just hte inclusion of that data not the format
GoGoGarr_ has joined #ruby
Guest27501 has joined #ruby
gordon1775 has joined #ruby
<TwN>
"and sometimes the timezone"
Shadow_S has joined #ruby
<Guest27501>
ddd
<TwN>
this is a 1line fix, will send a patch during the commute home
<TwN>
or sc2?
<TwN>
:d
<TwN>
because it apparently is 1900
<TwN>
or was it 8?
<apeiros_>
it was 8
<TwN>
nayways, I'm going home now
<apeiros_>
and I just notice that I missed my train
<apeiros_>
so +30 :(
<TwN>
same here :\
<apeiros_>
damn time
<apeiros_>
y u so fast!?!?
<TwN>
how long is your commute?
GoGoGarrett has quit [Ping timeout: 255 seconds]
<apeiros_>
~20min, +10min shopping
<TwN>
bummer
<TwN>
mine is 90mins
Guest27501 has quit [Client Quit]
<apeiros_>
ouch
Pip has quit [Read error: Operation timed out]
<TwN>
cya!
rakl has joined #ruby
<apeiros_>
cya :)
TwN has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
Guest27501 has joined #ruby
nomenkun has joined #ruby
pyr0commie has joined #ruby
zigomir has joined #ruby
pyrocommie has quit [Ping timeout: 252 seconds]
Hanmac_ has joined #ruby
mneorr has joined #ruby
a_a_g has quit [Read error: Connection reset by peer]
DaltonUS has joined #ruby
a_a_g has joined #ruby
workmad3 has quit [Ping timeout: 248 seconds]
mahmoudi_ has joined #ruby
nomenkun has quit [Ping timeout: 252 seconds]
timmow has quit [Quit: is having a nap]
shevy has quit [Ping timeout: 255 seconds]
<Guest27501>
ss
<gordon1775>
hi. how would i design a REST web service to allow 10,000 current connections and enable users to check out "data" exclusively and vote on it and then release that data so another user can vote on it, yes or no, until a max_votes limit is reached? It has to be transactional.
mahmoudimus has quit [Ping timeout: 248 seconds]
joofsh has quit [Remote host closed the connection]
atno has quit [Read error: Connection reset by peer]
shtirlic has joined #ruby
atno has joined #ruby
slainer68 has quit [Remote host closed the connection]
<Hanmac_>
mjolk i know there may be nothing on line 5, i say you should and print command to it so you could look that it realy enter the begin on line 4
<mjolk>
yeah
slainer68 has joined #ruby
<mjolk>
it has the values up to that point
<mjolk>
refactoring
<mjolk>
i'll post a working example
rakl has quit [Quit: sleeping]
bluOxigen has joined #ruby
dr_bob has quit [Read error: Connection reset by peer]
sandGorgon has quit [Ping timeout: 256 seconds]
<Hanmac_>
mjolk compare your two pasties and look at the location of ":password => PASS,"
rakl has joined #ruby
gordon1775 has quit [Read error: No route to host]
jimeh has quit [Quit: Computer has gone to sleep.]
osaut has joined #ruby
Guest27501 has quit []
nomenkun has joined #ruby
gordon1775 has joined #ruby
Pip has joined #ruby
<mjolk>
OH. thanks hanmac
<mjolk>
Hanmac_ even
nwertman has joined #ruby
<mjolk>
i found it weird that it wouldn't even try to connect though - running a tail -f /var/log/auth.log on the other host
osaut has quit [Client Quit]
wreckimnaked has quit [Quit: WeeChat 0.3.9]
bolivar has joined #ruby
browndawg has quit [Quit: Leaving.]
shevy has joined #ruby
jdripper has quit [Quit: Leaving.]
<Hanmac_>
in short you need ":password => ssh_pass," in your other pastie
arietis has joined #ruby
<mjolk>
yeah, it wasn't even attempting a connection, which was the annoying part
AsgardBSD has joined #ruby
ChampS666 has quit [Ping timeout: 252 seconds]
<AsgardBSD>
Hi
<mjolk>
Hi
<AsgardBSD>
Some people remember me? (well, maybe on the name of Asgard20032, or Alex20032)
<AsgardBSD>
I came here few day ago
<AsgardBSD>
Anyway, i wanted to learn ruby, and now I was wondering, what does people recommand to install for ruby
arturaz has quit [Ping timeout: 256 seconds]
<AsgardBSD>
Currently under Linux Mint
<AsgardBSD>
The haskell has the Haskell Platform, that include everything we need to get started
a_a_g has quit [Read error: Connection reset by peer]
a_a_g has joined #ruby
<Hanmac_>
Asgard 1) install ruby-full package because under debianoid systems the -dev package are not installed as default 1a) take care that your sytem ruby is more recent ... 1.8 is an bad idea, you can change it with update-alternatives
withnale has quit [Quit: Terminated with extreme prejudice - dircproxy 1.2.0]
<Hanmac_>
ok then i think everything is okay (you could skip the part with update alternatives)
chriskk has joined #ruby
carloslopes has quit [Remote host closed the connection]
twoism has joined #ruby
tommyvyo has joined #ruby
friskd has quit [Quit: friskd]
jtharris has quit [Quit: WeeChat 0.3.9.2]
maus has joined #ruby
shtirlic has quit [Remote host closed the connection]
zigomir has quit [Quit: zigomir]
<AsgardBSD>
update alternative??
cirwin has joined #ruby
cirwin has left #ruby [#ruby]
Xeago has joined #ruby
yxhuvud2 has joined #ruby
<Hanmac_>
its for switching default versions ... like when the system java is java6 and you co-install package is java7 you can switch it on the fly to java7 and back
cina has joined #ruby
hybris has quit [Quit: Leaving]
<AsgardBSD>
Well, Ruby 1.8 is not installed on my system
TomRone has quit [Quit: Peace Out]
jlwestsr has joined #ruby
<Hanmac_>
thats why i said you dont need it
<AsgardBSD>
Well, what learning ressource do you recommand?
zigomir has joined #ruby
kenneth has joined #ruby
yxhuvud has quit [Ping timeout: 248 seconds]
benlieb has quit [Read error: Connection reset by peer]
shtirlic has joined #ruby
benlieb has joined #ruby
elaptics is now known as elaptics`away
breaking_ has joined #ruby
breakingthings has quit [Disconnected by services]
breaking_ is now known as breakingthings
gridaphobe has quit [Ping timeout: 246 seconds]
rippa has joined #ruby
Shadow_S has quit [Quit: Computer has gone to sleep.]
maus has quit [Quit: leaving]
SCommette has quit [Quit: SCommette]
zigomir has quit [Quit: zigomir]
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
a_a_g has quit [Read error: Connection reset by peer]
maxmanders has joined #ruby
a_a_g has joined #ruby
tenmilestereo has joined #ruby
adkron has joined #ruby
banisterfiend has joined #ruby
osaut has joined #ruby
rjfranco has joined #ruby
AsgardBSD has quit [Remote host closed the connection]
bluenemo has joined #ruby
Xeago_ has joined #ruby
Xeago is now known as Guest54234
Guest54234 has quit [Killed (hubbard.freenode.net (Nickname regained by services))]
Xeago_ is now known as Xeago
bluenemo has quit [Changing host]
bluenemo has joined #ruby
Rym has joined #ruby
richardjortega has quit [Quit: richardjortega]
apeiros_ has joined #ruby
apeiros_ has quit [Remote host closed the connection]
apeiros_ has joined #ruby
tatsuya_o has quit [Remote host closed the connection]
yshh has quit [Remote host closed the connection]
carloslopes has joined #ruby
karl____ has joined #ruby
<karl____>
is there someone experienced with nokogiri i could PM for a moment?
inokenty has quit [Remote host closed the connection]
<apeiros_>
I've got a bit of experience with noko, but no PM
ananthakumaran has quit [Quit: Leaving.]
vlad_starkov has quit [Read error: Connection reset by peer]
<karl____>
ok, i'm trying to make sure i understand how noko works. I'll paste my example and how i think it works; please tell me if my understanding is incorrect
<karl____>
i have an XML doc i'm parsing with noko in SAX mode, the structure is <a><b><c><d></d></c></b></a>
cr3 has joined #ruby
vlad_starkov has joined #ruby
benlieb has quit [Quit: benlieb]
<karl____>
i have start_element and end_element methods for d
csgui has quit [Quit: csgui]
<karl____>
when nokogiri parses and hits <d>, it will execute my start_element code for d.
aaronmacy has joined #ruby
Xeago_ has joined #ruby
Xeago has quit [Killed (wright.freenode.net (Nickname regained by services))]
Xeago_ is now known as Xeago
<karl____>
Then as soon as it finishes start_element d, it will hit </d> and execute my end_element code for d
<karl____>
is that accurate?
AudreyJean has joined #ruby
cdt has joined #ruby
<apeiros_>
I think you can only have a generic "start_element" callback, not one specifically for d
_46bit has joined #ruby
<apeiros_>
you can test within that start_element for whether the tag is actually <d>
<apeiros_>
other than that, yes, I think the description is accurate
AudreyJean has left #ruby [#ruby]
_46bit has left #ruby [#ruby]
<karl____>
apeiros_: well, I have a generic start_element and end_element, both of which do a "case" on the "name" parameter to check for which tag it is in
Fraeon has joined #ruby
<karl____>
apeiros_: thank you
csgui has joined #ruby
TomRone has joined #ruby
cyplo has joined #ruby
csgui has quit [Client Quit]
walbert has joined #ruby
* apeiros_
wonders whether processors[tagname].call or send(:"process_#{tag_name}") would be faster
<Hanmac_>
hm i should look into the SAX mode, i currently parsed my xml files with many xpaths
cableray has joined #ruby
<karl____>
apeiros_: if I have an initialize method that creates a @state hash, and in my start_element section for d assign a value to @state[:foo], is there an obvious reason why @state[:foo] is not available in end_element?
<karl____>
Hanmac_: it's good if you're doing really big xml files
clooth has quit [Quit: clooth]
<karl____>
much faster
<apeiros_>
karl____: don't know, might be that noko parses <foo/> as end_element only
vipaca has joined #ruby
_nitti has quit [Remote host closed the connection]
<apeiros_>
no obvious reason otherwise
<karl____>
apeiros_: thank you
vipaca is now known as Guest18603
<Hanmac_>
hm than my 1000x1000 maps are not big enough :P
<apeiros_>
o0
codezombie has joined #ruby
Xeago has quit [Read error: Connection reset by peer]
Xeago has joined #ruby
grieve has quit []
GoGoGarrett has joined #ruby
mafolz has quit [Remote host closed the connection]
GoGoGarr_ has quit [Ping timeout: 246 seconds]
<karl____>
Hanmac_: the xml files i'm parsing are 50mb
carloslopes has quit [Remote host closed the connection]
Xeago has quit [Read error: Connection reset by peer]
kpshek has joined #ruby
`Kevin has joined #ruby
malkomalko has joined #ruby
jeffreybaird has joined #ruby
SCommette has joined #ruby
toekutr has joined #ruby
Xeago has joined #ruby
breakingthings is now known as drawringthings
wermel has quit [Remote host closed the connection]
yshh has joined #ruby
thillux has joined #ruby
drawringthings is now known as breakingthings
staafl_alt has quit [Ping timeout: 265 seconds]
BoomCow has joined #ruby
m104 has quit [Quit: Bye!]
Coolhand|laptop has quit [Remote host closed the connection]
ViPi has quit [Quit: Computer has gone to sleep.]
jenrzzz_ has joined #ruby
Guest18603 has quit [Changing host]
Guest18603 has joined #ruby
Xeago_ has joined #ruby
Xeago has quit [Killed (kornbluth.freenode.net (Nickname regained by services))]
Xeago_ is now known as Xeago
jtharris has joined #ruby
baphled has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
thorncp has quit [Ping timeout: 260 seconds]
lolcathost has joined #ruby
ebouchut has joined #ruby
jenrzzz has quit [Ping timeout: 255 seconds]
philcrissman has quit [Remote host closed the connection]
uris has joined #ruby
friskd has joined #ruby
friskd has quit [Remote host closed the connection]
razibog has joined #ruby
friskd has joined #ruby
<mjolk>
is anyone familiar with Net::SSH
GoGoGarrett has quit [Ping timeout: 256 seconds]
Xeago has quit [Ping timeout: 248 seconds]
cina has quit [Ping timeout: 248 seconds]
<mjolk>
i want to get it to give me the fingerprint it sees, even if it doesn't error
thorncp has joined #ruby
skepti has joined #ruby
akl_ has joined #ruby
<Hanmac_>
karl____ if my maps are this size i will call you back :D
<Hanmac_>
hm i am looking for an binary tree gem ... "rbtree" looks a bit "ugly"
GoGoGarrett has joined #ruby
SCommette has quit [Quit: SCommette]
jenrzzz_ has quit [Ping timeout: 246 seconds]
dross has quit [Quit: leaving]
dross has joined #ruby
Dann2 has joined #ruby
piotr__ has joined #ruby
skepti has quit [Quit: Leaving]
Dann1 has quit [Ping timeout: 252 seconds]
piotr_ has quit [Ping timeout: 256 seconds]
karasawa has quit [Ping timeout: 248 seconds]
itsdavem has joined #ruby
thorncp has quit [Ping timeout: 264 seconds]
thorncp has joined #ruby
SCommette has joined #ruby
philcrissman has joined #ruby
jlwestsr has quit [Quit: Ex-Chat]
nwertman has quit [Quit: leaving]
froginvasion has joined #ruby
carloslopes has joined #ruby
<froginvasion>
hi all
arkiver has joined #ruby
<froginvasion>
ive got a question surrounding eigenclasses/virtual classes and the object model of ruby
<froginvasion>
so, according to some sources the following is true
<froginvasion>
Object is an instance of its metaclass which in turn is an instance of Class
<arkiver>
Can anyone suggest a good book for learning OOP with ruby ?
Stormpath has joined #ruby
<froginvasion>
then; assume we have a class Foo and an instance of that class
<froginvasion>
what is true in that case if you were to draw the relations?
itsdavem has quit [Remote host closed the connection]
jonathanwallace1 has joined #ruby
bluOxigen has quit [Ping timeout: 260 seconds]
nimred has quit [Quit: leaving]
<banisterfiend>
froginvasion: "what is true" ?
<banisterfiend>
froginvasion: that's a slightly vague question
<froginvasion>
well.. its because i cant wrap my head around. what i mean is
reset has joined #ruby
<froginvasion>
if you create a regular class. then what is it an instance of?
main has joined #ruby
<banisterfiend>
froginvasion: its own metaclass
jonathanwallace has quit [Ping timeout: 256 seconds]
kenneth has quit [Quit: kenneth]
<banisterfiend>
i assume you're talking about things on a low (implementation) level
<banisterfiend>
like the direct klass pointer value
<mjolk>
How would I spit out the key fingerprint in Net::SSH without an error occurring?
<froginvasion>
lol heftig
_46bit has left #ruby [#ruby]
<froginvasion>
banisterfriend one more:
<Hanmac_>
there are singletonclasses all the way down :P
<froginvasion>
say you extend an object of Foo; that creates a virtual class that inherits from Foo's metaclass
<froginvasion>
for instance
<froginvasion>
f = Foo.new
<froginvasion>
then f is an instance of its metaclass once again
a_a_g has quit [Quit: Leaving.]
<froginvasion>
correct?
Pip has quit [Ping timeout: 248 seconds]
<heftig>
metaclasses don't exist until you try to access them
cina has joined #ruby
<banisterfiend>
heftig: that's not true in the case of class metaclasses, those are built at class creation tiem
Uranio has quit [Quit: WeeChat 0.3.8]
yxhuvud has joined #ruby
<heftig>
banisterfiend: do they need to exist for some reason?
<froginvasion>
banisterfriend is correct i believe; but object metaclasses dont exist before..
jds_ has joined #ruby
<froginvasion>
before extension; at least thats what ive read..
kirun has joined #ruby
<froginvasion>
you can never be sure if the internet is right though
<Hanmac_>
true,false,nil are also have metaclassess by default
Proshot is now known as statarb3
slainer68 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
<froginvasion>
so what is foo an instance of before it is extended? of Foo, or Foo metaclass?
<heftig>
i suppose for the whole super arrangement?
<banisterfiend>
heftig: i think so, i dont remember the details right now.
bolivar has left #ruby [#ruby]
yxhuvud2 has quit [Ping timeout: 248 seconds]
malkomalko has quit [Remote host closed the connection]
<banisterfiend>
froginvasion: of Foo
<drinkspiller>
Hello, friends. I have a few gems in my Gemfile. I removed the Gemfile.lock so it would be recreated and then run bundle install. All the gems scroll by saying they are installed, but none of them show up when listing with gem list. Any idea why the supposedly installed gems don't list? Here is the output from my session: http://grab.by/iUgQ
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
artOfWar_ has quit [Read error: Connection reset by peer]
artOfWar has joined #ruby
<froginvasion>
banisterfriend: alright that makes sense, now one last one if you dont mind before all my questions are resolved
<banisterfiend>
froginvasion: after you extend a module on 'foo' you 1. create the metaclass of 'foo' 2. include the module into that metaclass 3. the superclass of the module is set to Foo
<heftig>
on another note, building firefox takes fucking forever. and i've had to build 18.0 once already
<banisterfiend>
froginvasion: superlass of the 'included' module (which is not the same thing a the mdule :)
yshh has quit [Remote host closed the connection]
cina has quit [Ping timeout: 240 seconds]
<froginvasion>
and 4. metaclass 'foo' extends from Foos metaclass
<banisterfiend>
froginvasion: no..why?
AlbireoX has quit [Remote host closed the connection]
nicobrevin1 has quit [Ping timeout: 246 seconds]
<banisterfiend>
froginvasion: you're using the word 'extends' in a weird way
<banisterfiend>
froginvasion: what do u mean by extends? it's usually meant 'a module is mixed into the metaclass'
jds_ has quit [Ping timeout: 244 seconds]
<mjolk>
Net::SSH doesn't bother to check for matching fingerprints
cina has joined #ruby
<mjolk>
so annoyed
AlbireoX has joined #ruby
emocakes has quit [Quit: emocakes]
<froginvasion>
well, metaclass hierarchy follows regular hierarchy, they are mirrored right? what i mean i, when the metaclass is created, it extends from Foo's metaclass
<froginvasion>
regardless of any modules mixed in
<banisterfiend>
froginvasion: stop using the words 'extends'
<froginvasion>
inherits then
<banisterfiend>
it's just confusing, it has a precise meaning in ruby terminology
<apeiros_>
(Object#extend, namely)
<froginvasion>
inherits is a better naming for expressing inheritence?
itsdavem has quit [Ping timeout: 276 seconds]
<banisterfiend>
froginvasion: no the metaclass of foo inherits from Foo not Foo's metaclass
<froginvasion>
alright. just makes no sense at first sight; a meta class inheriting from a regular class
<froginvasion>
it makes sense and at the same time it doesnt
arkiver has quit [Ping timeout: 246 seconds]
szck has joined #ruby
Virunga has quit [Ping timeout: 246 seconds]
clooth has joined #ruby
aaronmacy has quit [Quit: Leaving.]
Virunga has joined #ruby
<banisterfiend>
froginvasion: just think about method resolution order, and it makes sense
<froginvasion>
exactly then it does
reset has quit [Quit: Leaving...]
bluOxigen has joined #ruby
<froginvasion>
alright, i think i got it :)
<froginvasion>
at least it makes more sense now..
<froginvasion>
thanks banisterfiend!
<banisterfiend>
np
geekbri has quit [Remote host closed the connection]
<froginvasion>
really appreciate it because it was kind of confusing ;p
mahmoudi_ has quit [Ping timeout: 246 seconds]
zastern has joined #ruby
<banisterfiend>
yeah it's pretty confusing when u first get into it
mahmoudimus has joined #ruby
<cr3>
how can I make a module support accessing elements like a hash, ie Foo[:bar]? I tried def self.[](name).. but I still get undefined error
tatsuya_o has joined #ruby
fred909 has joined #ruby
<apeiros_>
cr3: that should work. paste code?
karasawa has quit [Ping timeout: 244 seconds]
rjfranco has quit [Ping timeout: 248 seconds]
Xeago has joined #ruby
speakingcode has joined #ruby
timonv_ has joined #ruby
timonv has quit [Read error: Connection reset by peer]
<speakingcode>
is there a way to do a map but providing two arguments: key AND value
<speakingcode>
similar to each { |key, value| }
<cr3>
apeiros_: you're right, I just prepared a pastebin and it works. problems must be elsewhere
cobragoa_ has quit [Remote host closed the connection]
<Hanmac_>
speakingcode, map can do it too if the each supports this
n1x has joined #ruby
<speakingcode>
i'm calling it on a hash, so each should yeah?
SCommette has joined #ruby
ViPi has joined #ruby
kpshek has quit []
<Hanmac_>
yeah
kpshek has joined #ruby
_nitti has joined #ruby
vlad_starkov has joined #ruby
carloslopes has quit [Remote host closed the connection]
reset has joined #ruby
philcrissman has quit [Remote host closed the connection]
<tjbiddle>
Could someone explain why this craps out on me? (Rails+Rspec) - http://pastie.org/5663863 - I tried a few variations with things like project = double('project') but it keeps tripping up where I don't want it to.
beilabs_ has quit [Ping timeout: 255 seconds]
rippa has quit [Ping timeout: 260 seconds]
<Hanmac_>
tjbiddle: #rubyonrails
noxoc has quit [Quit: noxoc]
kjellski has joined #ruby
jjbohn is now known as jjbohn|afk
philcrissman has joined #ruby
froginvasion has quit [Remote host closed the connection]
_nitti_ has joined #ruby
jonathanwallace1 has quit [Read error: No route to host]
_nitti has quit [Ping timeout: 276 seconds]
benlieb has joined #ruby
carloslopes has joined #ruby
thillux_ has joined #ruby
Guest2324 has quit [Changing host]
Guest2324 has joined #ruby
Guest2324 is now known as z
jonathanwallace1 has joined #ruby
Goles has quit [Quit: Computer has gone to sleep.]
thillux has quit [Ping timeout: 244 seconds]
buibex has joined #ruby
pcarrier has joined #ruby
timonv_ has quit [Remote host closed the connection]
itsdavem has joined #ruby
timonv has joined #ruby
clooth has quit [Quit: clooth]
moshee has quit [Ping timeout: 255 seconds]
Pip has quit [Quit: Leaving]
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
atmosx has quit [Quit: leaving]
nomenkun has quit [Remote host closed the connection]
hackerdude has quit [Remote host closed the connection]
jduan1981 has joined #ruby
pcarrier has quit []
elico has quit [Ping timeout: 246 seconds]
vital101 has joined #ruby
nomenkun has joined #ruby
jds_ has joined #ruby
buibex has quit [Remote host closed the connection]
tatsuya__ has joined #ruby
elico has joined #ruby
Coolhand|laptop has joined #ruby
snearch has joined #ruby
kenneth has joined #ruby
nemesit has joined #ruby
elico has quit [Remote host closed the connection]
vital101 has quit [Remote host closed the connection]
buibex has joined #ruby
uprate6 has joined #ruby
ryanf has joined #ruby
twoism has quit [Read error: Connection reset by peer]
twoism has joined #ruby
otters has quit [Ping timeout: 252 seconds]
jenrzzz has quit [Ping timeout: 255 seconds]
yxhuvud has joined #ruby
mneorr has quit [Remote host closed the connection]
mneorr has joined #ruby
<karl____>
it's not normal for all code execution to end after a begin->end block, is it?
sepp2k1 has quit [Remote host closed the connection]
akl_ has quit [Ping timeout: 240 seconds]
yxhuvud2 has quit [Ping timeout: 255 seconds]
buibex has quit [Ping timeout: 248 seconds]
mark_locklear has quit [Remote host closed the connection]
Coolhand|laptop has quit [Ping timeout: 256 seconds]
itsdavem has quit [Remote host closed the connection]
icco has quit [Read error: Connection reset by peer]
daniel_- has joined #ruby
daniel_- has quit [Changing host]
daniel_- has joined #ruby
cina_ has quit [Quit: leaving]
icco has joined #ruby
Goles has quit [Quit: Computer has gone to sleep.]
jean-louis has joined #ruby
jthomp has quit [Quit: jthomp]
peregrine81 has joined #ruby
sailias has quit [Read error: Connection reset by peer]
jeffreybaird has joined #ruby
robotmay has quit [Remote host closed the connection]
jean-louis has left #ruby [#ruby]
DrShoggoth has quit [Ping timeout: 276 seconds]
graft has joined #ruby
graft has quit [Changing host]
graft has joined #ruby
alvaro_o has quit [Quit: Ex-Chat]
karasawa has joined #ruby
katzekintosh has quit [Quit: Leaving]
hadees has joined #ruby
Dann1 has quit [Quit: Dann1]
jean-louis has joined #ruby
<hadees>
how would you loop through an array until you found what you are looking for?
<apeiros_>
Array#find
v0n has quit [Ping timeout: 248 seconds]
jonathanwallace1 has quit [Ping timeout: 252 seconds]
<hadees>
apeiros_: sorry i should have been more specific :) I need to check each object in the array for photo? and return the first one that has it as true
c3vin has quit [Ping timeout: 240 seconds]
<apeiros_>
hadees: ok, I see. I repeat then: Array#find
Rym has quit [Quit: Rym]
jonathanwallace1 has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
karasawa has quit [Ping timeout: 244 seconds]
<hadees>
apeiros_: ah it was that easy thx
voodoofish430 has joined #ruby
workmad3 has quit [Ping timeout: 240 seconds]
voodoofish430 has quit [Read error: Connection reset by peer]
voodoofish430 has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
<reactormonk>
apeiros_, \o/ for people not reading the doc
SCommette has quit [Quit: SCommette]
maletor has joined #ruby
<apeiros_>
\o/ \o/ for people not reading the doc after having been told the right solution :)
SCommette has joined #ruby
_huoxito has joined #ruby
tps_ has quit [Quit: tps_]
arya_ has quit [Ping timeout: 240 seconds]
tommyvyo has quit [Ping timeout: 276 seconds]
mmitchell has quit [Remote host closed the connection]
arya_ has joined #ruby
xemu has joined #ruby
tenmilestereo has quit [Quit: Leaving]
grzywacz has quit [Quit: :wq]
kpshek has quit []
ryanjh has joined #ruby
_nitti has quit [Remote host closed the connection]
Morkel has quit [Quit: Morkel]
mockra has quit [Remote host closed the connection]
cjs226 has quit []
snearch has quit [Quit: Verlassend]
<ericwood>
high five! o/
reppard has quit [Ping timeout: 246 seconds]
_nitti has joined #ruby
jonathanwallace1 has quit [Ping timeout: 256 seconds]
ewnd9 has joined #ruby
<mjolk>
can someone suggest an SSH module that's _not_ Net::SSH ?
mengu has quit [Quit: This computer has gone to sleep]
asobrasil has left #ruby [#ruby]
jeffreybaird has quit [Quit: jeffreybaird]
F1skr has quit [Quit: WeeChat 0.3.9.2]
wmoxam has quit [Remote host closed the connection]
yxhuvud has quit [Ping timeout: 256 seconds]
Spami has quit [Quit: This computer has gone to sleep]
atmosx has joined #ruby
asteve has quit [Quit: Computer has gone to sleep.]
willob has quit [Quit: Leaving.]
thone has joined #ruby
<atmosx>
hello
Mon_Ouie has quit [Ping timeout: 248 seconds]
<atmosx>
I'm a sinatra basic auth and I'm a little bit confused with the syntax, https://gist.github.com/4506515 how can I add multiple logins in this scenario?
buibex has joined #ruby
<atmosx>
except maybe a nested loop
<atmosx>
tha goes through a list of username/pass
Guest18603 has quit [Quit: Leaving...]
lolcathost has quit [Ping timeout: 240 seconds]
skcin7 has quit [Quit: Computer has gone to sleep.]
arya_ has quit [Ping timeout: 244 seconds]
breakingthings has quit []
blacktulip has quit [Remote host closed the connection]