mahmoudimus has quit [Read error: No route to host]
CreativeEmbassy has quit [Quit: Computer has gone to sleep.]
lethjakman_lapto has quit [Ping timeout: 260 seconds]
yshh has joined #ruby
carloslopes has quit [Ping timeout: 276 seconds]
chico_chicote has quit [Ping timeout: 272 seconds]
CreativeEmbassy has joined #ruby
gyre007 has joined #ruby
thufir_ has joined #ruby
arya has joined #ruby
j^2 has quit [Quit: for i in `/names` ; do adios $i; done]
pewter_tao has joined #ruby
yshh has quit [Ping timeout: 260 seconds]
h4mz1d has quit [Ping timeout: 255 seconds]
adeponte has quit [Remote host closed the connection]
<pewter_tao>
if I have a ruby script which calls a bunch of other ruby script's functions, and each function doesn't have teh same exit code - what's the exit code at the end of the ruby script?
wargasm has quit [Ping timeout: 276 seconds]
predator417 has joined #ruby
stringoO has quit [Quit: stringoO]
caveat- has quit [Read error: Operation timed out]
xardas has quit [Ping timeout: 255 seconds]
arya has quit [Ping timeout: 248 seconds]
artOfWar has quit [Remote host closed the connection]
gyre007 has quit [Ping timeout: 256 seconds]
PanPan has joined #ruby
predator117 has quit [Ping timeout: 255 seconds]
jonathanwallace has joined #ruby
PanPan has quit [Ping timeout: 244 seconds]
QaDeS has quit [Quit: Ex-Chat]
TheFuzzball has quit [Quit: Computer has gone to sleep.]
dmiller has joined #ruby
yshh has joined #ruby
tcstar has quit [Ping timeout: 272 seconds]
yshh has quit [Remote host closed the connection]
tcstar has joined #ruby
monkegjinni has quit [Remote host closed the connection]
IceDragon has joined #ruby
banisterfiend is now known as banister`sleep
stopbit has quit [Quit: Leaving]
horofox has joined #ruby
Skelz0r has quit [Read error: Operation timed out]
<nilobject>
Mattix: Huh? You're not making much sense. What, exactly, do you want to do?
<pcarrier>
nilobject: I have to feed it with strings though, not objects :(
<pcarrier>
nilobject: so I'd have to serialize by hand.
<pcarrier>
I guess.
<pcarrier>
s/by hand/explicitely/
punknology has joined #ruby
punknology has quit [Max SendQ exceeded]
chrishough has quit [Quit: chrishough]
<nilobject>
pcarrier: Yeah, you'll need to define your own ordering. That's easy enough to do, though: my_hash.to_a.sort{|a,b| a[0] <=> b[0]}.inspect
punknology has joined #ruby
punknology has quit [Max SendQ exceeded]
<pcarrier>
nilobject: I don't want ordering!?
hbpoison has joined #ruby
generalissimo has joined #ruby
punknology has joined #ruby
punknology has quit [Max SendQ exceeded]
<pcarrier>
nilobject: god this is annoying. I can't have a reproductible hash for my objects made of strings, hashes, arrays?
daniel_hinojosa has quit [Ping timeout: 260 seconds]
<Mattix>
nilobject, I was looking for a lib to download documents on the Internet using a ruby script (something like curl in other languages). I found some good libraries, but I wonder if there's one that automatically fills some common HTTP headers like User-Agent
banister`sleep has quit [Read error: Connection reset by peer]
banister`sleep has joined #ruby
joshman_ has quit [Quit: Computer has gone to sleep.]
apeiros_ has joined #ruby
end_guy has quit [Ping timeout: 276 seconds]
end_guy has joined #ruby
sqrel has quit [Read error: Operation timed out]
segv- has quit [Quit: segv-]
ferdev is now known as ferdev|away
SilverKey has joined #ruby
yacks has joined #ruby
jonahR has joined #ruby
LiquidInsect has quit [Ping timeout: 255 seconds]
ckrailo has quit [Ping timeout: 276 seconds]
lancepantz_ is now known as lancepantz
thone has joined #ruby
nari has joined #ruby
sambio has quit []
Spooner has quit [Ping timeout: 244 seconds]
arya has quit [Ping timeout: 244 seconds]
BoomCow has joined #ruby
v0n has joined #ruby
Virunga has quit [Remote host closed the connection]
carloslopes has joined #ruby
apeiros_ has quit [Ping timeout: 252 seconds]
thone_ has quit [Ping timeout: 255 seconds]
pandawarrior has joined #ruby
EPIK has left #ruby [#ruby]
EPIK has joined #ruby
mattbl has joined #ruby
<breakingthings>
Do stdlib classes take precedence over ones in the current namespace? I'm trying to call my IO class but it's erroring out, trying to call stdlib's IO
<breakingthings>
I don't have to always namespace my calls, right?
etcetera has quit []
slackfan has left #ruby [#ruby]
maletor has quit [Quit: Computer has gone to sleep.]
chrisja has quit [Quit: leaving]
jaygen has quit [Remote host closed the connection]
jaygen has joined #ruby
<firefux>
IO is not a stdlib class
BrindleFly has quit [Quit: BrindleFly]
reset has quit [Quit: Leaving...]
NiteRain has quit [Ping timeout: 246 seconds]
zyrex has joined #ruby
jaygen has quit [Ping timeout: 252 seconds]
BrindleFly has joined #ruby
Demux has joined #ruby
reset has joined #ruby
BrindleFly has quit [Client Quit]
lancepantz is now known as lancepantz_
nilobject has quit [Quit: nilobject]
skattyadz has quit [Quit: skattyadz]
maletor has joined #ruby
dankest has joined #ruby
dmiller has quit [Ping timeout: 244 seconds]
Hanmac has joined #ruby
generalissimo has quit [Remote host closed the connection]
mlr has joined #ruby
generalissimo has joined #ruby
Hanmac2 has quit [Ping timeout: 260 seconds]
chendo_ has quit [Ping timeout: 256 seconds]
mmitchell has joined #ruby
bradhe has joined #ruby
chendo_ has joined #ruby
sn0wb1rd has quit [Quit: sn0wb1rd]
unix has joined #ruby
lusory has joined #ruby
Nisstyre-laptop has joined #ruby
meoblast001 has joined #ruby
SilverKey has quit [Quit: "Sleep now."]
RORgasm has quit [Ping timeout: 272 seconds]
t-mart has joined #ruby
niklasb has quit [Ping timeout: 244 seconds]
Voodoofish430 has quit [Quit: Leaving.]
<breakingthings>
So… I can't require a file from within my gem… what gives? I've seen ruby projects on github do the same thing...
joeycarmello has joined #ruby
chendo_ has quit [Ping timeout: 240 seconds]
<breakingthings>
would it have anything to do with running the script as an executable from the command prompt?
maletor has quit [Quit: Computer has gone to sleep.]
chendo_ has joined #ruby
ephemerian has quit [Quit: Leaving.]
rupee has quit [Ping timeout: 256 seconds]
jrajav has joined #ruby
jaygen has joined #ruby
radic has quit [Ping timeout: 248 seconds]
justsee has joined #ruby
joofsh has quit [Remote host closed the connection]
zyrex has quit [Quit: ChatZilla 0.9.90 [Firefox 18.0/20130107224926]]
PanPan has joined #ruby
mockra has quit [Read error: Connection reset by peer]
generalissimo has quit [Ping timeout: 272 seconds]
tcstar has joined #ruby
Slivka has quit [Ping timeout: 272 seconds]
tish has joined #ruby
c0rn has quit [Quit: Computer has gone to sleep.]
c0rn has joined #ruby
gtc has joined #ruby
PanPan has quit [Ping timeout: 276 seconds]
dankest has quit [Quit: Leaving...]
elux has joined #ruby
bradhe has quit [Remote host closed the connection]
demet8 has quit [Quit: demet8]
jkarayusuf has joined #ruby
crackfu has joined #ruby
cloaked1 has joined #ruby
MartinCleaver has joined #ruby
MartinCleaver has quit [Changing host]
MartinCleaver has joined #ruby
<cloaked1>
New to ruby. Any reason why in an each loop iterating over an associative array that the type of value in the hash would throw a "TypeError"?
<cloaked1>
Why would Ruby care?
twshelton has joined #ruby
adamdecaf has joined #ruby
<Gate>
cloaked1: some more details would help. What, exactly is throwing a TypeError?
<Gate>
Can you pastebin or gist your code?
joofsh has joined #ruby
<cloaked1>
sec
<cloaked1>
have to scrub it a bit
<Gate>
no problem
demet8 has joined #ruby
damienbrz has joined #ruby
nfk has quit [Quit: yawn]
ahokaomaeha has joined #ruby
cupakromer has joined #ruby
<Gate>
So to explain TypeError while you are scrubbing, Ruby is duck typed, not weakly typed. So if you do `"foo" + 3` it throws an error. Or if you try [1,2,3]["foo"] it will throw the same type of exception, a TypeError
jkarayusuf has left #ruby [#ruby]
alunduil has joined #ruby
CreativeEmbassy has joined #ruby
pdamer has joined #ruby
hbpoison has quit [Ping timeout: 252 seconds]
CreativeEmbassy has quit [Client Quit]
jekotia has quit [Quit: ChatZilla 0.9.90-rdmsoft [XULRunner 18.0.2/20130201065344]]
jaygen has quit [Remote host closed the connection]
damienbrz has quit [Remote host closed the connection]
<alunduil>
What's the current best practice for package layout and build system creation? Is it still jeweler or something else?
<cloaked1>
its throwing TypeError while in the each statement of that code...specifically after the first each gets hit.
<cloaked1>
Gate: and it's triggering on 488 I think...but why on earth does it care?
joofsh has quit [Remote host closed the connection]
yacks has quit [Ping timeout: 272 seconds]
carloslopes has joined #ruby
allaire has quit []
<Gate>
cloaked1: well, I'm still not sure what is throwing the error or why yet...
<lectrick>
Is there something like "each" but which looks at the block's arity and gives it that many from the enumerable that it is being called on?
<cloaked1>
exactly! :)
<Gate>
cloaked1: Ah, I think I see what is happening
<cloaked1>
so the best I can tell you is that the error is getting thrown in the same place as line 16
jaygen has quit [Ping timeout: 252 seconds]
yacks has joined #ruby
<cloaked1>
oh good. anything would help at this point. I have no idea why Ruby would care.
adkron has quit [Ping timeout: 276 seconds]
lethjakman_lapto has joined #ruby
adkron has joined #ruby
damienbrz has joined #ruby
<Gate>
:/ nevermind, that would be a NoMethodError
rodayo has joined #ruby
<Gate>
cloaked1: what does the rest of the error message say?
<Gate>
such as "TypeError: can't convert String into Integer" ?
<cloaked1>
yeah
tvw has quit [Ping timeout: 260 seconds]
<cloaked1>
that's it
<lectrick>
nvm it's each_slice that i'm looking for, more or less
sn0wb1rd has joined #ruby
<cloaked1>
so I know it has something to do with the 488
<cloaked1>
but as far as I can tell, I'm not doing anything that Ruby should care whether 488 is an integer or a string. It's the value in the hash...not the key.
Junkyardhands has joined #ruby
h4mz1d has joined #ruby
<rodayo>
Scenario: i'm on win8, and i want to make a rails website. storage isn't required for website but it needs to read data from a SQL Server database. what are my options for getting access to that db, without introducing weird dependencies
lethjakman_lapto has quit [Client Quit]
CreativeEmbassy has joined #ruby
horofox has quit [Quit: horofox]
<rodayo>
Feel free to answer but i just realized there's an RoR channel and i asked the folks there
horofox has joined #ruby
<cloaked1>
hmm...almost to my stop, Gate, so I may have to disconnect in a few...
firefux has left #ruby [#ruby]
others is now known as otters
<Gate>
cloaked1: hm, I don't know but I also don't use InfraDB, perhaps your store is expecting specific types?
<cloaked1>
I checked that...but good idea.
<cloaked1>
I thoght the same thing
ebobby has quit [Quit: leaving]
<cloaked1>
I think I figured it out
<cloaked1>
it's happening in a few different places in the code...from different input
twoism has quit [Remote host closed the connection]
<cloaked1>
the input that it barfs on (the XML values) all have something in common
<cloaked1>
they are surrounded in quotes.
sepp2k1 has quit [Read error: Connection reset by peer]
<cloaked1>
gtg though. thx!
<Gate>
GL
[diecast] has joined #ruby
<[diecast]>
how can i escape curly brackets in erb templates?
horofox has quit [Client Quit]
twshelton has quit [Quit: Computer has gone to sleep.]
dhruvasagar has joined #ruby
alvaro_o has quit [Quit: Ex-Chat]
elux has quit [Quit: Leaving...]
pkrnj has joined #ruby
cloaked1 has quit [Ping timeout: 245 seconds]
NiteRain has joined #ruby
endzyme has joined #ruby
Hanmac1 has joined #ruby
Hanmac has quit [Ping timeout: 276 seconds]
cableray has quit [Quit: cableray]
Junkyardhands has quit [Remote host closed the connection]
krz has joined #ruby
tian has joined #ruby
CreativeEmbassy has quit [Quit: Computer has gone to sleep.]
Es0teric has joined #ruby
jonahR has quit [Quit: jonahR]
CreativeEmbassy has joined #ruby
Banistergalaxy has quit [Ping timeout: 256 seconds]
tomzx_mac has joined #ruby
bobbobbins has joined #ruby
cableray has joined #ruby
mattbl has quit [Quit: This computer has gone to sleep]
<bobbobbins>
hey, I'm trying to install ruby for the first time, and it looks like a version came preinstalled on my server(linux) so i got the latest version of ruby and compiled it from source, but when i do ruby -v it still shows the old version, can someone help me out here and tell me what I'm missing?
jpcamara_ has joined #ruby
jonahR has joined #ruby
mmitchell has quit [Remote host closed the connection]
kayloos has quit [Quit: kayloos]
endzyme has quit [Read error: Connection reset by peer]
endzyme has joined #ruby
chico_ch` has quit [Read error: Connection reset by peer]
carloslopes has quit [Remote host closed the connection]
jpcamara has quit [Ping timeout: 272 seconds]
jpcamara_ is now known as jpcamara
snuglepuss has quit [Remote host closed the connection]
drago757 has quit [Quit: drago757]
hogeo has quit [Remote host closed the connection]
CreativeEmbassy has quit [Quit: Computer has gone to sleep.]
hogeo has joined #ruby
tcstar has quit [Ping timeout: 244 seconds]
tian has quit [Quit: tian]
mattbl has joined #ruby
PanPan has joined #ruby
dallasm has joined #ruby
twoism has joined #ruby
junkbot1231234 has joined #ruby
kayloos has joined #ruby
kayloos has quit [Remote host closed the connection]
<junkbot1231234>
ruby n00b here, and I have a question that may be more postgres related than ruby.
generalissimo has joined #ruby
<junkbot1231234>
I'm saving a bunch of text from nokogiri into a table, data type text, and it's working just fine but when I return it it's all one huge chunk of text, the new lines are stripped out. Any tips?
hogeo has quit [Ping timeout: 255 seconds]
mattbl has quit [Client Quit]
PanPan has quit [Ping timeout: 244 seconds]
[diecast] has left #ruby [#ruby]
twoism has quit [Remote host closed the connection]
adkron has quit [Ping timeout: 252 seconds]
demet8 has quit [Quit: demet8]
twoism has joined #ruby
glennt has left #ruby [#ruby]
adkron has joined #ruby
junkbot1231234 is now known as ninjanoise
ninjanoise has quit [Changing host]
ninjanoise has joined #ruby
jeremywrowe has quit [Quit: jeremywrowe]
bobbobbins has left #ruby [#ruby]
hbpoison has joined #ruby
thams has joined #ruby
twoism has quit [Ping timeout: 272 seconds]
thufir_ has quit [Quit: Leaving.]
crazedpsyc is now known as Getly
Getly is now known as crazedpsyc
jonahR has quit [Quit: jonahR]
CreativeEmbassy has joined #ruby
xemu has joined #ruby
unix has quit [Ping timeout: 260 seconds]
tish has quit [Quit: Leaving.]
ninjanoise has quit [Remote host closed the connection]
pandawarrior has quit [Quit: Leaving.]
rafacv has quit [Quit: Leaving.]
twshelton has joined #ruby
rodayo has quit [Quit: Page closed]
bradhe has joined #ruby
apok has quit [Quit: apok]
CreativeEmbassy has quit [Quit: Computer has gone to sleep.]
twoism has joined #ruby
wmoxam has joined #ruby
CreativeEmbassy has joined #ruby
miskander has quit [Quit: miskander]
a_a_g1 has joined #ruby
h4mz1d has quit [Ping timeout: 252 seconds]
ananthakumaran has joined #ruby
pac1 has quit [Quit: I got it one line of code at a time]
sulaiman has left #ruby ["Leaving"]
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
CreativeEmbassy has quit [Quit: Computer has gone to sleep.]
nkts_ has joined #ruby
objectivemo_ has joined #ruby
CreativeEmbassy has joined #ruby
Myk267 has quit [Read error: Connection reset by peer]
greenarrow has quit [Read error: Operation timed out]
miskander has joined #ruby
Marius has quit [Ping timeout: 240 seconds]
j^2 has joined #ruby
objectivemo has quit [Ping timeout: 248 seconds]
objectivemo_ is now known as objectivemo
greenarrow has joined #ruby
adkron has quit [Ping timeout: 264 seconds]
fcoury has quit [Write error: Broken pipe]
blooberr has quit [Read error: Operation timed out]
twoism has quit [Ping timeout: 255 seconds]
blooberr has joined #ruby
cool has quit [Read error: Operation timed out]
pkondzior__ has quit [Ping timeout: 248 seconds]
cam` has quit [Ping timeout: 245 seconds]
cool has joined #ruby
fcoury has joined #ruby
karnowski has quit [Ping timeout: 245 seconds]
z has quit [Ping timeout: 252 seconds]
adamdecaf has quit [Ping timeout: 272 seconds]
Guest85414 has quit [Ping timeout: 240 seconds]
c0rn has quit [Quit: Computer has gone to sleep.]
z has joined #ruby
z is now known as Guest91581
<t-mart>
uncommenting extensions in in ext/Setup before a build designates those extensions to be statically linked, right? so, if i don't uncomment, they'll by dynamically linked or not included in the build?
chaosis has joined #ruby
octoberry has joined #ruby
j^2 has quit [Quit: for i in `/names` ; do adios $i; done]
__BigO__ has joined #ruby
CreativeEmbassy has quit [Quit: Computer has gone to sleep.]
jrajav has quit [Quit: I tend to be neutral about apples]
CreativeEmbassy has joined #ruby
hogeo has joined #ruby
bubblehead has quit [Remote host closed the connection]
tjbiddle has joined #ruby
horofox has joined #ruby
dallasm has quit [Remote host closed the connection]
<sicen>
anyone have any examples of useful ruby api wrappers?
<chrishough>
how's the tap room tonight?
<chrishough>
busy?
<sicen>
i'm trying to create a wrapper for my local transit system but i have no idea how detailed and simple i should go
twoism has quit [Ping timeout: 252 seconds]
Takehiro has joined #ruby
damienbrz has quit [Remote host closed the connection]
reset has quit [Ping timeout: 244 seconds]
verysoftoiletppr has quit []
KRF has quit [Read error: Operation timed out]
apeiros_ has quit [Ping timeout: 256 seconds]
KRF has joined #ruby
<t-mart>
sicen: sounds like you need to sit down and think about the exact problem you're trying to solve
<t-mart>
pretend you're a user: what would you want?
_br_ has quit [Ping timeout: 245 seconds]
verysoftoiletppr has joined #ruby
chrishough has quit [Quit: chrishough]
_br_ has joined #ruby
twshelton has quit [Quit: Computer has gone to sleep.]
daniel_hinojosa has joined #ruby
<sicen>
there are a ton of different things you could do with it
tish has quit [Quit: Leaving.]
<sicen>
it's like i could built out a specific use or create something generic, but with doing something generic it might not even be useful to anyone
<breakingthings>
which is exactly why you should sit back and take a minute to think of the possible uses
damienbrz has joined #ruby
mahmoudimus has quit [Quit: Computer has gone to sleep.]
vikhyat has joined #ruby
cableray has quit [Quit: cableray]
endzyme has quit [Remote host closed the connection]
mockra has joined #ruby
meoblast001 has quit [Read error: Connection reset by peer]
jfredee has joined #ruby
miskander has quit [Quit: miskander]
dankest has joined #ruby
twshelton has joined #ruby
divout has joined #ruby
MartinCleaver has quit [Quit: MartinCleaver]
__BigO__ has quit [Remote host closed the connection]
endzyme has joined #ruby
awarner has quit [Ping timeout: 256 seconds]
adamdecaf has quit [Remote host closed the connection]
luckyruby has quit [Remote host closed the connection]
breakingthings has quit [Remote host closed the connection]
breakingthings has joined #ruby
tjbiddle has quit [Quit: tjbiddle]
arya has joined #ruby
awarner has joined #ruby
Al___ has joined #ruby
cableray has joined #ruby
Matip has joined #ruby
twshelton has quit [Quit: Computer has gone to sleep.]
CreativeEmbassy has quit [Quit: Computer has gone to sleep.]
garbagecollectio has joined #ruby
arya has quit [Ping timeout: 248 seconds]
<vabenjamin>
can you write test cases to check values within methods that are never returned
baroquebobcat has joined #ruby
cupakromer has quit []
jfredee has quit [Remote host closed the connection]
Mattix has quit [Ping timeout: 276 seconds]
<sicen>
not that i know of
<sicen>
just break it up into smaller methods
apok has quit [Quit: apok]
<sicen>
or return an array of all the values?
<sicen>
and just grab the one you need and test the rest
<sicen>
that's probably a terrible solution
<vabenjamin>
its a bit difficult because im parsing various parts of a file
tcstar has joined #ruby
<vabenjamin>
so if i split up the method i have to open the file multiple times i think
<sicen>
just keep passing the hot potato
<breakingthings>
isn't the entire point of testing merely to test the public api
<vabenjamin>
i can write a test unit for a method that is only called by another method?
<breakingthings>
if it's public, yes.
<sicen>
you can write a test for anything baby
<vabenjamin>
f it ill just scratch the test unit then and print to console
<vabenjamin>
to debug
<breakingthings>
how it's called doesn't matter, tests assert against return values and mocks.
<vabenjamin>
its a weird case
<breakingthings>
sounds like you're missing a major approach in structuring your api
<vabenjamin>
i have a method that parses a file and sends parsed data to another method
<breakingthings>
which is probably the most confusing part of it all so i probably didn't offer some revelation here but still
<vabenjamin>
and this method itself is hidden from the public api
<breakingthings>
what does that other method do
<vabenjamin>
its a classifier
<vabenjamin>
im writing a machine learning gem for Ruby
<vabenjamin>
so iight now im writing the parser method to read an input file of data
baroquebobcat has quit [Quit: baroquebobcat]
<vabenjamin>
and it passes a bunch of different data fields to another method that handles the machine learning classifier
<breakingthings>
as in, turns the parsed data into a ruby class?
<breakingthings>
or...
<vabenjamin>
no it never realls becomes a class, its all modules =\
<breakingthings>
alright
<vabenjamin>
im probably better off just printing to console just to check if its parsing correctly and then deleting my puts
chrishough has joined #ruby
PanPan has joined #ruby
<breakingthings>
well it sounds like your file parse is largely a "convenience" (though it might be the only way you call this) to accomplish the other functionality
<breakingthings>
it wouldn't really hurt to expose the second method to the public api of that class and test it on it's own.
octoberry has quit [Ping timeout: 272 seconds]
arya has joined #ruby
sicen has quit [Remote host closed the connection]
jeremywrowe has joined #ruby
<breakingthings>
then if somehow you come across some magic that you decide you want to allow for a new input method you can have another method that calls this classifier method and all is happy and good because you have tested the classifier as it's own unit so you know it works
hbpoison has quit [Ping timeout: 260 seconds]
<breakingthings>
theoretically, that is.
<vabenjamin>
so I use my parser to extract a bunch of parameters from the file and actually dont use the Ruby return function to pass it to another method, i explicitely call the method and pass the parsed data as part of the method parameters
robbyoconnor has joined #ruby
octoberry has joined #ruby
<vabenjamin>
i didnt think of a better way to handle it
rippa has joined #ruby
<vabenjamin>
because i dont want to read the file multiple times
<breakingthings>
right
<breakingthings>
so what I would think you should do
a_a_g1 has quit [Ping timeout: 244 seconds]
<breakingthings>
is test the file-reading method, it's final assertion being that it calls the other method
Slivka has joined #ruby
<breakingthings>
and then test the classifier method on it's own
<breakingthings>
that's fine
<breakingthings>
it doesn't have to outright return anything but you can segment it to test it's individual functionality instead of hacking about with trying to find out what happens in the other function because of this function
a_a_g has joined #ruby
<vabenjamin>
btw I have noticed many in Ruby do not use try\catch statements
<vabenjamin>
I come from Java land - what's the convention here
<eval-in>
breakingthings: Output: "/tmp/execpad-a0aa6ecd7ff0/source-a0aa6ecd7ff0:1:in `block in <main>': undefined local variable or method `newhash' for main:Object (NameError)\n\tfrom /tmp/execpad-a0aa6ecd7ff0/source-a0aa6ecd7ff0:1:in ` ..." (http://eval.in/10848)
<breakingthings>
wups.
moos3 has quit [Quit: Computer has gone to sleep.]
karnowski has joined #ruby
<vabenjamin>
but i dont feel ruby has good gui tools
mockra has quit [Remote host closed the connection]
<nataraj>
i think so about C++, but is QtRuby good?
<breakingthings>
Only problem is :"zip code"
<vabenjamin>
ive never used it
mattbl has joined #ruby
<vabenjamin>
I know QT is gaining momentum though
hashmal has quit [Quit: Computer has gone to sleep.]
<vabenjamin>
I believe ubuntu is going to rewrite their desktop manager in QT
<ablemike>
breakingthings: thanks ... i am familiar with to_sym and etc.
<ablemike>
better example would be "Zip Code" to :zip
<vabenjamin>
with qt*
damienbrz has quit [Remote host closed the connection]
<nataraj>
well, Qt is good, has all the stuff for large projects
<ablemike>
and "Some Stupid Private Key" to :private_key
<chichou>
or gsub space with underscore
<ablemike>
i am trying to clean up fields from an external API
<ablemike>
theres like 25 fields
<ablemike>
so it's almost like I want to make a translation
dawkirst has joined #ruby
<vabenjamin>
i would think you would be fine with qt ruby
<ablemike>
i guess i am looking for a way to template the conversion of these keys elegantly
<vabenjamin>
mostly because I feel c++ would be overkill
<vabenjamin>
but if you are doing anything computationally heavy then c+=
Mon_Ouie has joined #ruby
<nataraj>
was trying to run "Kaya" on ruby1.9.3p385
hukl has joined #ruby
<breakingthings>
ablemike: probably going to be messy no matter what you do. maybe you could set up a hash of the keys they give you against the keys you want and map via that.
<ablemike>
yeah
<ablemike>
module here i come
<nataraj>
but seems it is for 1.8. any tool to convert the code to run on 1.9?
<nataraj>
"Kaya" is a Qt based frontend to gnuchess
kenneth has joined #ruby
dhruvasagar has quit [Ping timeout: 276 seconds]
breakingthings has quit []
codecop has joined #ruby
kenneth has quit [Client Quit]
Cooler_ has quit [Ping timeout: 248 seconds]
mattbl has quit [Quit: This computer has gone to sleep]
Cooler_ has joined #ruby
nga4 has joined #ruby
Jackneill has joined #ruby
Retistic has quit [Quit: Retistic]
JohnBat26 has joined #ruby
pierre1_ has quit [Read error: Connection reset by peer]
decoponio has joined #ruby
hbpoison has quit [Ping timeout: 252 seconds]
spaceships has quit [Quit: leaving]
Yakko has quit [Remote host closed the connection]
zzing has quit [Quit: Computer has gone to sleep.]
browndawg has joined #ruby
endzyme has joined #ruby
dallasm has quit [Remote host closed the connection]
Jackneill has quit [Quit: Leaving]
PanPan has joined #ruby
arya has quit [Ping timeout: 252 seconds]
eindoofus has quit [Quit: Leaving]
xbayrockx has joined #ruby
xbayrockx is now known as wf2f
PanPan has quit [Ping timeout: 252 seconds]
eindoofus has joined #ruby
<eindoofus>
Hi, I was considering getting this book but I wanted to make sure it's not too outdated: "Programming Ruby 1.9: The Pragmatic Programmers' Guide"
arya has joined #ruby
c0rn has quit [Quit: Computer has gone to sleep.]
browndawg has quit [Quit: Leaving.]
browndawg has joined #ruby
dmiller has quit [Ping timeout: 252 seconds]
lazyguru has left #ruby [#ruby]
<eindoofus>
*chirp chirp* :(
__BigO__ has joined #ruby
thams has quit [Quit: thams]
jeremywrowe has quit [Quit: jeremywrowe]
bradleyprice has quit [Remote host closed the connection]
savage- has quit [Quit: savage-]
BizarreCake has joined #ruby
browndawg has quit [Client Quit]
browndawg has joined #ruby
frewsxcv has joined #ruby
<nga4>
ruby 2.0 is coming out but fundamentally you'd be in good shape
endzyme has quit [Remote host closed the connection]
SCommette has joined #ruby
bean__ has quit [Quit: Computer has gone to sleep.]
Al___ has quit [Quit: Al___]
<eindoofus>
thanks nga4
<frewsxcv>
ah, a block?
<nga4>
frewsxcv: yeah a block you can yeild on I think
BoomCow has quit [Quit: This computer has gone to sleep]
browndawg has quit [Quit: Leaving.]
browndawg has joined #ruby
bedouin is now known as delqn
vabenjamin has left #ruby [#ruby]
vabenjamin has joined #ruby
apeiros_ has joined #ruby
browndawg has left #ruby [#ruby]
<vabenjamin>
hello apeiros)
<vabenjamin>
apeiros_ rather
qubit has quit [Ping timeout: 260 seconds]
apeiros has joined #ruby
Hanmac has joined #ruby
<vabenjamin>
blegh mmy project is starting to look ugly
apeiros_ has quit [Read error: Connection reset by peer]
qubit has joined #ruby
hukl has joined #ruby
hukl has quit [Remote host closed the connection]
BizarreCake has quit [Quit: Leaving]
generalissimo has quit [Remote host closed the connection]
hbpoison has joined #ruby
macmartine has joined #ruby
nilobject has quit [Quit: nilobject]
apeiros has quit [Remote host closed the connection]
Mon_Ouie has quit [Ping timeout: 260 seconds]
pyrac has quit [Quit: pyrac]
ryanf has quit [Ping timeout: 240 seconds]
Takehiro_ has quit [Remote host closed the connection]
macq has quit [Ping timeout: 244 seconds]
dmiller has joined #ruby
Takehiro has joined #ruby
qubit has quit [Ping timeout: 276 seconds]
macq has joined #ruby
eindoofus has quit [Quit: Leaving]
braoru has joined #ruby
frewsxcv has left #ruby ["Leaving"]
mahmoudimus has joined #ruby
yewton has quit [Excess Flood]
yewton has joined #ruby
gosshedd has joined #ruby
dmiller has quit [Ping timeout: 256 seconds]
dankest has quit [Quit: Leaving...]
browndawg has joined #ruby
dankest has joined #ruby
Takehiro has quit [Ping timeout: 252 seconds]
wf2f has quit []
mattbl has joined #ruby
vlad_starkov has joined #ruby
dhruvasagar has joined #ruby
nomenkun has joined #ruby
zzing has joined #ruby
heftig has quit [Quit: Quitting]
a_a_g has quit [Ping timeout: 240 seconds]
chrishough has quit [Quit: chrishough]
jblack has joined #ruby
qubit has joined #ruby
andikr has joined #ruby
mockra has joined #ruby
workmad3 has joined #ruby
Takehiro has joined #ruby
carraroj has joined #ruby
zzing has quit [Ping timeout: 244 seconds]
nomenkun has quit [Ping timeout: 260 seconds]
whowantstolivefo has joined #ruby
arya_ has joined #ruby
arya has quit [Ping timeout: 256 seconds]
banjara has joined #ruby
qubit has quit [Ping timeout: 260 seconds]
mockra has quit [Ping timeout: 276 seconds]
mattbl has quit [Quit: This computer has gone to sleep]
heftig has joined #ruby
browndawg has quit [Read error: Operation timed out]
SeySayux has joined #ruby
Villadelfia has joined #ruby
arya_ has quit [Ping timeout: 244 seconds]
dankest has quit [Quit: Leaving...]
SCommette has quit [Quit: SCommette]
gosshedd has quit [Ping timeout: 255 seconds]
qubit has joined #ruby
PanPan has joined #ruby
ukd1 has quit [Quit: leaving]
Hanmac has quit [Ping timeout: 256 seconds]
PanPan has quit [Read error: Connection reset by peer]
QaDeS has joined #ruby
PanPan has joined #ruby
Elhu has joined #ruby
__BigO__ has quit [Remote host closed the connection]
Hanmac has joined #ruby
arya has joined #ruby
kodeart has left #ruby [#ruby]
swindsor has joined #ruby
macmartine has quit [Ping timeout: 252 seconds]
vlad_starkov has quit [Remote host closed the connection]
monkegjinni has joined #ruby
SolidResolve has quit [Read error: Operation timed out]
timonv has joined #ruby
passbe has quit [Quit: WeeChat 0.3.9.2]
browndawg has joined #ruby
aganov has joined #ruby
Morkel has joined #ruby
<aedornm>
wow... poor Living Social. Wonder what that means for Hungry Academy
locriani has quit [Ping timeout: 252 seconds]
carraroj has quit [Ping timeout: 248 seconds]
ryanf has joined #ruby
<Hanmac>
Amnesia still looking for good multiline way?
<Amnesia>
Hanmac: yep
<Amnesia>
used str <<
<Amnesia>
but that's ugly imo
<Hanmac>
Amnesia you could look after HereDoc ... <<ABC and after the big string "ABC" at one new line
carraroj has joined #ruby
machty has joined #ruby
swindsor has quit [Quit: leaving]
<Amnesia>
Hanmac: *googles*
<machty>
need help with this: https://gist.github.com/machty/5002975 it can't find the reference to 'base'. i'm not sure how to write this without running into WARNING: redefining constant
<aedornm>
and <<-ABC if "ABC" won't be the first thing on the last line, and <<'ABC' if you don't want string interpolation. Yay HereDocs.
verysoftoiletppr has quit []
arya has quit [Ping timeout: 255 seconds]
verysoftoiletppr has joined #ruby
goganchic has joined #ruby
<Hanmac>
multible heredocs are freaky ... i never used them but normal one can be helpfull for gemspec description
<Amnesia>
sweet, ty
hemanth has joined #ruby
k610 has joined #ruby
k610 has quit [Client Quit]
brianpWins has joined #ruby
<Hanmac>
machty, why does it shows "redefining constant" for you?
<machty>
Hanmac: ususally in these cases i would do BASE_DIR, but at least in rails apps i would see these warnings pop up, which make me feel this approach is incorrect, or not idempotent at least
<machty>
even though the way i'm doing it is idempotent
arya has joined #ruby
aib has joined #ruby
<Hanmac>
löl its freaky how rails interfers with simple code :P
joeycarmello has quit [Remote host closed the connection]
rippa has quit [Ping timeout: 240 seconds]
qubit has quit [Ping timeout: 260 seconds]
a_a_g has joined #ruby
pyrac has joined #ruby
<aib>
[I have no idea what I'm doing] I installed a bunch of gems in my project's gems/ directory using bundler. now I'm trying to run ./gems/bin/padrino and it's looking for other gems, but only in /var/lib/gems. what's the proper way to define a gem directory for a project? I used "bundle config path ./gems" for bundler, but I guess I need to do more
goganchic has quit []
<aib>
is this even the right place?
filipe has joined #ruby
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
<Hanmac>
aib you may look at GEM_HOME
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
alx- has joined #ruby
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
browndawg has quit [Ping timeout: 260 seconds]
<aedornm>
Coding needs a 'share' button, too.
mafolz has joined #ruby
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
qubit has joined #ruby
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
saimaz has quit [Read error: Connection reset by peer]
saimaz has joined #ruby
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
dmiller has joined #ruby
banjara has quit [Quit: Leaving.]
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
mercwithamouth has quit [Ping timeout: 252 seconds]
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
<Amnesia>
Hanmac: that does screw up the indention:)
<Amnesia>
cause I need to start at the beginning of the line after a \n
emergion has joined #ruby
<aib>
Hanmac: excellent, thanks. instead of "./gems/bin/padrino xxx" I do "GEM_HOME=./gems ./gems/bin/padrino xxx" -- does that sound fine?
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
Elhu has quit [Quit: Computer has gone to sleep.]
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
<Hanmac>
aib i dont know i never used it
SolidResolve has joined #ruby
SolidResolve has quit [Max SendQ exceeded]
<aib>
kk
<Hanmac>
Amnesia didnt heredoc makes automaticly line breaks?
nomenkun_ has quit [Read error: Connection reset by peer]
<Hanmac>
shevy: of if you want with index: array.each_cons(3).find.with_index {|_,i| i==3 - 2 } #=> ["index2.html", "index3.html", "index4.html"]
lkba has joined #ruby
nomenkun has joined #ruby
monkegjinni has joined #ruby
dmiller has quit [Ping timeout: 252 seconds]
DuoSRX has quit [Remote host closed the connection]
joeycarmello has quit [Ping timeout: 255 seconds]
ryanf has quit [Quit: leaving]
NiteRain has quit [Ping timeout: 246 seconds]
arya has quit [Ping timeout: 248 seconds]
toekutr has quit [Remote host closed the connection]
lmg_ has joined #ruby
Liothen has joined #ruby
monkegjinni has quit [Remote host closed the connection]
saimaz has quit [Remote host closed the connection]
<Hanmac>
shevy oh its array.each_cons(3).find.with_index {|_,i| i==3 - 1 } #=> ["index3.html", "index4.html", "index5.html"] the - value depends on the item you cant to compare
oposomme has joined #ruby
arya has joined #ruby
chussenot has joined #ruby
blaxter has joined #ruby
vabenjamin has left #ruby [#ruby]
Retistic has joined #ruby
postmodern has quit [Quit: Leaving]
zzing has joined #ruby
ferdev|away is now known as ferdev
sebkomianos has joined #ruby
arya has quit [Ping timeout: 248 seconds]
Kadma has joined #ruby
ferdev has quit [Quit: Leaving...]
Bry8Star has quit [Remote host closed the connection]
paolooo has quit [Quit: Page closed]
tish has joined #ruby
monkegjinni has joined #ruby
slainer68 has joined #ruby
codespectator has quit [Quit: Computer has gone to sleep.]
keymone has joined #ruby
hbpoison has quit [Ping timeout: 252 seconds]
arturaz has joined #ruby
DuoSRX has joined #ruby
vikhyat has quit [Remote host closed the connection]
Vainoharhainen has joined #ruby
nomenkun has quit [Ping timeout: 244 seconds]
Kadma has quit [Remote host closed the connection]
Al___ has joined #ruby
elaptics`away is now known as elaptics
kevinfagan has quit [Quit: Leaving...]
niklasb has joined #ruby
Onii-san has quit [Ping timeout: 276 seconds]
tish has left #ruby [#ruby]
segv has joined #ruby
sonda has joined #ruby
poikon_work has joined #ruby
poikon has quit [Read error: Connection reset by peer]
bw_ has joined #ruby
Onii-san has joined #ruby
pyrac has quit [Read error: Connection reset by peer]
pyrac_ has joined #ruby
vikhyat has joined #ruby
monkegjinni has quit [Remote host closed the connection]
noop has quit [Ping timeout: 252 seconds]
ctp has joined #ruby
hoelzro|away is now known as hoelzro
gregorg has joined #ruby
gregorg has joined #ruby
timonv has joined #ruby
mlr has joined #ruby
Retistic has quit [Quit: Retistic]
ferdev has joined #ruby
codespectator has joined #ruby
codespectator has quit [Max SendQ exceeded]
codespectator has joined #ruby
thufir_ has joined #ruby
TikiTDO has joined #ruby
<TikiTDO>
Can someone explain why `("a" * 10_000).match(/a.*?b/)` runs so insanely slow?
ctp has quit [Ping timeout: 260 seconds]
<hoelzro>
TikiTDO: backtracking, I'd guess
<TikiTDO>
hoelzro, I thought so as well, but it does it even when I turn atomic grouping on
<Hanmac>
TikiTDO not for mes .. what is your ruby version??
<Hanmac>
hm i tested it with 1.9.3p194 and 2.0.0dev ... both are less than 2sec
mahmoudimus has quit [Quit: Computer has gone to sleep.]
nkts_ has quit []
<TikiTDO>
I tested it in nodejs and it's 200ms, I wrote my own state machine for 20ms, but in native re it runs around a second
gosshedd has joined #ruby
<apeiros_>
TikiTDO: might be that the way oniguruma is implemented, that regex does 10k*~5k = 50M comparisons
hbpoison has joined #ruby
<Hanmac>
okay its a little bit more than one second ... but for an interpreted language its still okay
<apeiros_>
but since regex engines are rather complex right now, might be anything
<apeiros_>
Hanmac: regex is native
<Hanmac>
i think its still okay
<TikiTDO>
Hanmac, I imagine this would be pretty important of any sort of validation type gem. I actually hit it while writing a json validator
mlr has quit [Ping timeout: 256 seconds]
sk87 has joined #ruby
hbpoison has quit [Read error: Connection reset by peer]
<TikiTDO>
Also regarding interpreted. I wrote a state machine in ruby that did much the same with a each_char iterator, I doubt you could blame it there even if it wasn't native
spider-mario has joined #ruby
gyre007 has joined #ruby
lmg_ has quit [Ping timeout: 256 seconds]
<Hanmac>
i tryed: /(a*)?b/ and was very faster: #=> 0.000000 0.000000 0.000000 ( 0.000293)
<apeiros_>
TikiTDO: a well written hand tuned state machine will outperform a regex any time. a regex does not know your intent. it has to do quite a lot more than what you might think it does.
<apeiros_>
that's not the same query, though @ Hanmac
hbpoison has joined #ruby
noop has joined #ruby
<TikiTDO>
apeiros_, of course, that's why I wouldn't expect it to pull off identical timing, but just blaming it on interpreted vs compiled even though it runs 5x faster even in js seems like ignoring the problem
mlr has joined #ruby
monkegjinni has joined #ruby
<apeiros_>
TikiTDO: as said, regex is native. this is not a native vs. interpreted issue.
<TikiTDO>
apeiros_, fair enough, I'm just in the middle of coding, so I'm answering questions as I read them ^.^
<apeiros_>
js' regex engine is *much* simpler than ruby's. it's pathological cases can/will be different than ruby's
<apeiros_>
*its
casheew has quit [Read error: Connection reset by peer]
wargasm has quit [Ping timeout: 252 seconds]
casheew has joined #ruby
<TikiTDO>
So should I just focus on my own state machine and only use re for the simpler cases, or is this something that might be addressed?
timmow has joined #ruby
timmow has quit [Remote host closed the connection]
nomenkun has joined #ruby
dmiller has joined #ruby
schaerli has joined #ruby
Hanmac has quit [Quit: Leaving.]
timmow has joined #ruby
beiter has joined #ruby
timmow has quit [Read error: Connection reset by peer]
<apeiros_>
TikiTDO: you can bring it up in the mailing list. I suspect it's expected behavior, but you might get more insight, and maybe better tips at how to improve your regex.
razibog has joined #ruby
dmiller has quit [Ping timeout: 248 seconds]
lkba has quit [Ping timeout: 264 seconds]
<TikiTDO>
apeiros_, I'll do that. Unfortunately I don't think there's much that can be done to improve my regex in this case. I'm doing lexical analysis, so the expressions themselves are a few characters long at worst
Nisstyre-laptop has quit [Ping timeout: 255 seconds]
nfk has joined #ruby
whitedawg has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
timmow has joined #ruby
<apeiros_>
TikiTDO: you'd be surprised
gestahlt has joined #ruby
kevinfagan has joined #ruby
<TikiTDO>
apeiros_, I've been doing compilers for years now. While I'm not infallible, I doubt I'd make an order-of-magnitude type mistake unless I'm really not paying attention
TobiasRaeder has joined #ruby
<gestahlt>
Self confidence?
casheew has quit [Read error: Connection reset by peer]
casheew has joined #ruby
<shevy>
experience
<apeiros_>
well, you did not know why that regex takes so long. this tells me that while you may be an experienced coder, you don't know all about regexen
<TikiTDO>
In this case I'm searching for /(?<=!\\)"/
<shevy>
TikiTDO you were just called a noob, you can't let this sit!!!
ctp has joined #ruby
<TikiTDO>
apeiros_, correction. I know that this regex should not take too long, but didn't want to be insulting when saying it
<gestahlt>
apeiros_: i think coding goes hand in hand with regexping. Im also coding stuff and i need regexes like every day
<apeiros_>
gestahlt: using and really understanding them are two *very* different things
<gestahlt>
apeiros_: Understanding them on what level?
zzing has quit [Ping timeout: 260 seconds]
cableray has quit [Quit: cableray]
<gestahlt>
apeiros_: What they do or how they do it?
<apeiros_>
on the level of understanding why ("a" * 10_000).match(/a.*?b/) is slow on a particular regex engine
lmg_ has joined #ruby
<TikiTDO>
apeiros_, one of the very first things necessary for compilers is to learn language design, and regular languages are among the first type of language you learn to implement
vlad_starkov has joined #ruby
<apeiros_>
TikiTDO: *sob*, you're missing the point. but I have no interest in that discussion.
<gestahlt>
Hm, i read up on this matter a while ago.
<gestahlt>
Thats a good question, why is it slow?
<TikiTDO>
Fair enough. I did my part. If you're not interested in adressing an issue then I will happily implement my own workaround and carry on
<gestahlt>
Is it engine specific?
<apeiros_>
TikiTDO: I can't address the issue. that's why I referred you to the ML
<gestahlt>
Ah you implemented it
<apeiros_>
gestahlt: yes, it is engine specific.
<apeiros_>
different engines optimize differently.
<gestahlt>
apeiros_: Interesting. Is there source to it?
<apeiros_>
gestahlt: the book "Mastering Regular Expressions" goes into details, I can recommend it
zzing has joined #ruby
ctp has quit [Ping timeout: 248 seconds]
Inoperable has joined #ruby
Inoperable has quit [Client Quit]
samphippen has joined #ruby
nomenkun has quit [Remote host closed the connection]
<gestahlt>
apeiros_: Is that a similar issue like how to optimize db queries? I mean with ruby you can implement a number of methods to make your queries smarter. We had a lot of refactoring for ActiveRecords lately and we gained a lot of perfomance when we asked for the same stuff differently
<apeiros_>
gestahlt: e.g. a thompson NFA would probably take only milliseconds for this. but a pure thompson NFA can't do all that an engine like oniguruma can
<apeiros_>
gestahlt: no, it's more similar to how different DB systems will have different performance characteristics for the same query
<apeiros_>
and depending on the DB system, you might want to change the structuring of the query
nomenkun has joined #ruby
<apeiros_>
but things like that is only needed in pathological cases
<gestahlt>
apeiros_: Ah i understand. This is also an interesting issue. We will switch our dbs soon, and we are also kinda afraid that our smarter queries wont be so smart with different engines
browndawg has joined #ruby
browndawg has quit [Max SendQ exceeded]
<shevy>
hah... I did not know that 1.0e3 is 1000.0
browndawg has joined #ruby
maxmanders has quit [Quit: Computer has gone to sleep.]
<gestahlt>
Its really crazy sometimes.. i think as soon you are working with different platforms you can expect big pain in the but. Simple example here is IE vs rest
<shevy>
just ignore IE
oposomme is now known as oposomme|away
<gestahlt>
While every browser has its quirks (like chrome with the glow of textfields which is completly unwanted)
lmg_ has quit [Ping timeout: 256 seconds]
DuoSRX has quit [Read error: Connection reset by peer]
<gestahlt>
shevy: we can not. BUT i told our customer that we wont support anything below 8 and thats about it. If he wants IE7, IE6 support he has to look for someone masochistic and we clearly wont do it.
pandawarrior has joined #ruby
maxmanders has joined #ruby
<macq>
even microsoft do not support ie6 now
Xeago has joined #ruby
soc42 has joined #ruby
beiter_ has joined #ruby
<JonnieCache>
nobody supports msie<8 now
beiter has quit [Read error: Connection reset by peer]
beiter_ is now known as beiter
pandawarrior has left #ruby [#ruby]
<JonnieCache>
of course some people will take on any work
<JonnieCache>
but nobody i know works with ie7 anymore
rippa has joined #ruby
zzing has quit [Ping timeout: 244 seconds]
TobiasRaeder has quit [Ping timeout: 255 seconds]
DrCode has quit [Ping timeout: 276 seconds]
TikiTDO has left #ruby ["Leaving"]
nari has joined #ruby
maasha has joined #ruby
<maasha>
hashbang problem
<maasha>
#!/usr/bin/env ruby -w works nicely on Mac. Not on linux. What can I do to enable warnings? (I insist on using env ruby)
dawkirst has quit [Ping timeout: 276 seconds]
<gestahlt>
JonnieCache: I know too many ppl working with IE7
hbpoison has quit [Ping timeout: 248 seconds]
justme1 has joined #ruby
<JonnieCache>
i suppose if youre selling stuff to be run behind corporate firewalls its common
hbpoison has joined #ruby
Es0teric has quit [Quit: Computer has gone to sleep.]
Ethan has quit [Ping timeout: 248 seconds]
quazimodo has quit [Ping timeout: 256 seconds]
F1skr has joined #ruby
hogeo has quit [Remote host closed the connection]
slainer68 has quit [Remote host closed the connection]
ctp has joined #ruby
Neomex has joined #ruby
AntiTyping has quit [Quit: AntiTyping]
Neomex has quit [Client Quit]
s3m73x has quit [Ping timeout: 248 seconds]
noop has quit [Ping timeout: 256 seconds]
ctp has quit [Ping timeout: 245 seconds]
s3m73x has joined #ruby
zzing has joined #ruby
daniel_-_ has joined #ruby
baotrungtn has joined #ruby
<baotrungtn>
hi guys
reset has joined #ruby
<baotrungtn>
anyone here?
lkba has joined #ruby
<gestahlt>
No, all dead
<shevy>
maasha I always run ruby directly
cdt has joined #ruby
<shevy>
my shebang is "#!/System/Executables/ruby -w", maasha try to see if it works without "env"
<gestahlt>
I always have to giggle when i hear the term "shebang"
<maasha>
shevy: the systems ruby is 1.8
<maasha>
I need my own 1.9
<shevy>
maasha ???
zzing has quit [Ping timeout: 256 seconds]
<shevy>
maasha pass the path to the binary there
<shevy>
on my system, /System/Executables/ruby is a symlink to the ruby version in use
monkegjinni has quit [Remote host closed the connection]
<shevy>
that's why I don't need /usr/bin/env
ctp has joined #ruby
<maasha>
shevy: not sure that works on Linux. No /System/
<shevy>
sure it works on linux, I use that scheme since many years ;) if it works without env then you will at least know that env misbehaves, and not ruby itself
<macq>
maasha, what exactly doens't work on linux? You getting wrong ruby version or what?
<maasha>
shevy: on our production server there is no /System - and that is a Debian stable installation.
<shevy>
maasha where are all the "ruby" binaries on your system exactly?
<shevy>
you said you have two versions
noop has joined #ruby
<shevy>
so you must have two different ruby. where are they exactly?
Ethan has joined #ruby
<maasha>
macq: /usr/bin/ruby is this systems. And then I have one in ~/install/bin
keymone has quit [Quit: keymone]
<shevy>
and ~/install/bin is in $PATH?
<maasha>
And I am not going to hard code that path :o)
<maasha>
shevy: yes
<gestahlt>
code hard but not hard code
<shevy>
hmmmm
<maasha>
gestahlt: bleh :o)
<shevy>
maasha could you paste the output of echo $PATH
workmad3 has joined #ruby
zzing has joined #ruby
<jblack>
you could fix this, and a handful of other problems, by running mkfs -t ext3..... :P
<maasha>
shevy: /bin/env is just right for this normally - I just wonder how to enable warnings then. In Perl there is the same problem with perl -w, but then you can just go `use warnings;`
dmiller has joined #ruby
fuzai has joined #ruby
<fuzai>
http://pastie.org/6279489 < - it claims that user doesn't exist, but I know it's being created to even get there. when I enter { } does the scope kill the variable before it?
<shevy>
fuzai is there ever a magic bullet to code one writes on his or her own? ;P
<fuzai>
sure, it's the code that actually does what we desire
<maasha>
shevy: ah, thanks
<shevy>
yeah but you pasted a snippet
baotrungtn has left #ruby [#ruby]
<shevy>
nobody knows where there error is exactly, nobody knows what the dataset of botData is, all we know is that you try to call .user method on a normal string object
<fuzai>
the exact error line is the line i put a less then sign infront of
carraroj has quit [Quit: Konversation terminated!]
zzing has quit [Ping timeout: 264 seconds]
cyro has joined #ruby
svandiepen has quit [Remote host closed the connection]
baotrungtn has joined #ruby
<cyro>
when is it preferable to use a native ruby float over a BigDecimal?
<shevy>
event['pre_text'] returns a string I guess
<shevy>
and you try to call the method .user on that string
<fuzai>
all three of them should be stings
<fuzai>
strings
seich- has joined #ruby
<shevy>
which does not exist. so the question is why do you call method .user on such strings?
deadalus has joined #ruby
tvw has joined #ruby
<fuzai>
so say("#{event['pre_text'] #{user.name} #{event['post_text']}")
<shevy>
what are you doing
<maasha>
shevy: I think the conclusion is that one needs to set: export RUBYOPT=-w
Ethan has quit [Quit: "The destruction of balance constitutes leaping forward and such destruction is better than balance. Imbalance and headache are good things." - Mao]
<shevy>
maasha cool, that sounds simple enough
atno has joined #ruby
<shevy>
I was shocked to read this: "The shebang line has never been specified as part of POSIX, SUS, LSB or any other specification."
<fuzai>
i'm trying to respond on an event with the username that triggered it
<shevy>
fuzai I mean in the code you pasted just now
<fuzai>
the same thing i was trying before hand
BrindleFly has joined #ruby
<shevy>
say("#{event['pre_text'] #{user.name} #{event['post_text']}") <-- is this valid code? to me it looks as if you forgot a }
pyrac_ has quit [Read error: Connection reset by peer]
<fuzai>
to join three strings together correctly
<fuzai>
yea it seems i did
<maasha>
shevy: it works, so be it.
<shevy>
joining three strings together: string1+string2+string3
pyrac has joined #ruby
lewellyn has left #ruby ["too many channels again. back later."]
<fuzai>
ohhh i think my php is leaking over in my brain
svandiepen has joined #ruby
<fuzai>
i got . for string concat somewhere
<shevy>
yeah I begin so too, the . you use seemed as if you want concatenate
<shevy>
in ruby the . is normally a call to a method on an object
Virunga has joined #ruby
<shevy>
"abc".size
reset has quit [Quit: Leaving...]
<fuzai>
yea
<fuzai>
i'm seeing how that could conuse ruby now
<shevy>
the #{} you will only need if you do interpolate in "" double quoted strings
<shevy>
x = 'hello'; y = "#{x} world" <--- this would be a "hello world" concatenation
<maasha>
shevy: It would be nice ruby had a way to enable warnings within the code - like perl's `use warnings;`
<fuzai>
"#{a}#{b}#{c}" = a+b+c ?
<shevy>
maasha yeah. you could file an issue request at the bug tracker, often the core team listens to input :)
<shevy>
fuzai yeah
<fuzai>
thats where i was screwing up
<fuzai>
ty
<shevy>
it tries to turn an object into string form
<shevy>
if you would use this however:
<shevy>
a+b+c
<shevy>
and b would be a number, and a and c a string, it would not work
<shevy>
with "#{a}#{b}#{c}" it would always work
<shevy>
or if they are all string objects already, then it would also work
<shevy>
fuzai you could also use the << method call on strings
<shevy>
x = '' # empty string here
<shevy>
x << 'Hello'
<shevy>
x << ' World'
<shevy>
# x would now be "Hello World"
<workmad3>
fuzai: "#{a}#{b}#{c}" would be closest to a.to_s + b.to_s + c.to_s
<workmad3>
fuzai: but the second one would create more intermediate strings than interpolation
<fuzai>
should you always be using .to_* even if you can assume the data type is always a string?
<macq>
or a hardcore ['a', 'b', 'c'].join
<shevy>
maasha I will file an issue request for you ;)
mengu has joined #ruby
<workmad3>
fuzai: if you know they're always stringy, then you don't need the .to_s
<workmad3>
fuzai: however, #{} will call .to_s
<fuzai>
ok cool
<fuzai>
i didn't know that thanks
<workmad3>
fuzai: which is why I said it's closest to that ;)
nkr has joined #ruby
carraroj has joined #ruby
Rizzle has quit [Read error: Connection reset by peer]
vikhyat has quit [Remote host closed the connection]
krz has quit [Quit: krz]
<shevy>
yeah even a few characters shorter
<shevy>
a.to_s+b.to_s
mengu_ has joined #ruby
<shevy>
"#{a}#{b}"
<shevy>
but
<shevy>
a+b
<shevy>
would be even shorter!!!
<maasha>
shevy: thanks
mengu has quit [Ping timeout: 252 seconds]
vikhyat has joined #ruby
<shevy>
maasha I am gonna hawk-eye on whether the ruby team responds to that or not :D
nkr has quit [Ping timeout: 244 seconds]
<maasha>
shevy: the argument "but it works in Perl" should be good ...
<shevy>
ohhh
<shevy>
that reminds me
<shevy>
can you disable warnings in perl at run time too?
<shevy>
like:
<shevy>
enable warnings
<shevy>
lots of perl code
<shevy>
disable warnings
<shevy>
lots of more perl code but you dont care if there are warnings here
<shevy>
hoelzro, perl warning system beats ruby warning system :(
Kuifje has joined #ruby
Kuifje has quit [Changing host]
Kuifje has joined #ruby
F1skr has quit [Quit: WeeChat 0.4.0]
<maasha>
shevy: yes, you can enable and disable warnings according to type.
beiter has quit [Ping timeout: 240 seconds]
<shevy>
cooool
<maasha>
shevy: but I am not sure you can do it at run time - only compile time.
<maasha>
shevy: I can e.g. disable deep recursion warnings.
LouisRoR has joined #ruby
skattyadz has joined #ruby
dEPy has joined #ruby
<dEPy>
Hi
<dEPy>
I have 2 service classes, 1 is TaskService the other is RedisTaskService
<dEPy>
I want TaskService to delegate calls to some methods to RedisTaskService.
<dEPy>
I implementing method_missing in TaskService and doing stuff there a good aproach?
<dEPy>
I fell it's dirty.
hbpoison has quit [Ping timeout: 256 seconds]
<dEPy>
Cause if in future I would like to delegate calls also to some another class....
monkegjinni has joined #ruby
<heftig>
dEPy: delegate.rb
skattyadz has quit [Client Quit]
Shrink has quit [Ping timeout: 246 seconds]
bluOxigen has joined #ruby
Slivka has quit [Read error: Operation timed out]
occupant has quit [Read error: Connection reset by peer]
occupant has joined #ruby
Virunga has quit [Remote host closed the connection]
Criztian has joined #ruby
zoonfafer has joined #ruby
ddv has quit [Ping timeout: 240 seconds]
yshh has quit [Remote host closed the connection]
ddv has joined #ruby
Ethan has joined #ruby
bluOxigen has quit [Ping timeout: 272 seconds]
Virunga has joined #ruby
`brendan has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
inao_ has quit [Quit: Leaving...]
kofno has quit [Remote host closed the connection]
divout has quit [Remote host closed the connection]
Mekkis has joined #ruby
<hoelzro>
\o/
<hoelzro>
you can do it at runtime as well maasha
joshman_ has joined #ruby
<hoelzro>
see ${^WARNING_BITS}
skum has joined #ruby
taoru has joined #ruby
dEPy has quit []
Vainoharhainen has quit [Ping timeout: 240 seconds]
dmiller has joined #ruby
monkegjinni has quit [Remote host closed the connection]
<alexhanh>
any compass users? why the heck does compass want to know where my javascript files are located at?
dmiller has quit [Ping timeout: 256 seconds]
Shrink has joined #ruby
Shrink has quit [Changing host]
Shrink has joined #ruby
machty_ has quit [Quit: machty_]
beiter has joined #ruby
filipe has joined #ruby
a_a_g1 has joined #ruby
jpfuentes2 has joined #ruby
oposomme|away has quit [Quit: Leaving...]
moos3 has joined #ruby
robbyoconnor has quit [Ping timeout: 272 seconds]
noop has quit [Remote host closed the connection]
rippa has quit [Read error: Connection reset by peer]
rippa has joined #ruby
hybris has joined #ruby
angusiguess has joined #ruby
krandi has joined #ruby
twshelton has joined #ruby
andikr has quit [Ping timeout: 248 seconds]
monkegjinni has joined #ruby
fermion has joined #ruby
rippa has quit [Ping timeout: 240 seconds]
monkegjinni has quit [Remote host closed the connection]
monkegjinni has joined #ruby
wmoxam has joined #ruby
blacktulip has joined #ruby
carloslopes has joined #ruby
drago757 has joined #ruby
atmosx has joined #ruby
<atmosx>
hello
Mon_Ouie has joined #ruby
Guest91581 has quit [Changing host]
Guest91581 has joined #ruby
Guest91581 is now known as z
ashu has joined #ruby
Xeago has quit [Remote host closed the connection]
<ashu>
hi.........
a_a_g1 has quit [Quit: Leaving.]
<atmosx>
….
neurone-1337 has quit [Read error: Operation timed out]
<fuzai>
is there something like a noop in ruby? if t == 1; puts "1"; elsif t == 2; noop; else puts "x"; end ?
chussenot has quit [Quit: chussenot]
<fuzai>
no op
<Mon_Ouie>
Putting nothing in there is a noop
<Mon_Ouie>
'nil' is the same
drago757 has quit [Ping timeout: 260 seconds]
sepp2k has joined #ruby
<fuzai>
ok
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
jpfuentes2 has joined #ruby
daniel_- has joined #ruby
daniel_- has quit [Changing host]
daniel_- has joined #ruby
yshh has joined #ruby
taoru has quit [Remote host closed the connection]
Mon_Ouie has quit [Quit: WeeChat 0.4.0]
Monie has quit [Read error: Connection reset by peer]
angusiguess has quit [Ping timeout: 256 seconds]
neurone-1337 has joined #ruby
justme1 has left #ruby [#ruby]
kristofers has joined #ruby
krz has joined #ruby
rlb3 has joined #ruby
a_a_g has joined #ruby
m3pow has quit [Read error: Connection reset by peer]
monkegjinni has quit [Remote host closed the connection]
Elhu has quit [Quit: Computer has gone to sleep.]
Xeago has joined #ruby
monkegjinni has joined #ruby
tish has joined #ruby
maycon has quit [Remote host closed the connection]
wmoxam has quit [Ping timeout: 252 seconds]
vikhyat has quit [Remote host closed the connection]
monkegjinni has quit [Remote host closed the connection]
v0n has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
<ashu>
hi........
monkegjinni has joined #ruby
Udom0 has joined #ruby
enroxorz-work has joined #ruby
pavilionXP has quit [Read error: Connection reset by peer]
cyro has left #ruby [#ruby]
pdamer has joined #ruby
drago757 has joined #ruby
<Dwarf>
Does anyone have the xchat plugin for ruby that works with ruby 1.9?
alx- has quit [Ping timeout: 260 seconds]
oposomme has joined #ruby
pyrac has quit [Read error: Connection reset by peer]
pyrac_ has joined #ruby
pdamer has quit [Quit: pdamer]
<tom221>
i/ws 17
yshh has quit [Remote host closed the connection]
krandi has quit [Quit: No Ping reply in 180 seconds.]
andikr has joined #ruby
drago757 has quit [Read error: Connection reset by peer]
drago757_ has joined #ruby
girija has joined #ruby
ashu has quit [Ping timeout: 252 seconds]
Elhu has joined #ruby
banister`sleep has quit [Ping timeout: 252 seconds]
dkannan has joined #ruby
yshh has joined #ruby
dmiller has joined #ruby
nari has quit [Ping timeout: 252 seconds]
sepp2k has quit [Remote host closed the connection]
drago757_ has quit [Ping timeout: 260 seconds]
v0n has quit [Ping timeout: 260 seconds]
hbpoison has joined #ruby
sepp2k has joined #ruby
robustus has quit [Read error: Connection reset by peer]
oposomme has quit [Quit: Leaving...]
s3m73x has quit [Ping timeout: 248 seconds]
slainer68 has joined #ruby
banister`sleep has joined #ruby
zzing has joined #ruby
<fuzai>
anyone here familiar with json? "response": "I\'ll be happy to skip this.", is erroring out because of the escaped single quote. Does anyone know the proper way to deal with a single quote in a json line?
dmiller has quit [Ping timeout: 255 seconds]
tomaw has quit [Ping timeout: 624 seconds]
vikhyat has joined #ruby
angusiguess has joined #ruby
dustint has joined #ruby
ryanw_ has joined #ruby
workmad3 has quit [Ping timeout: 256 seconds]
vikhyat has quit [Remote host closed the connection]
atmosx has quit [Quit: And so the story goes…]
slainer6_ has joined #ruby
robustus has joined #ruby
kumarat9pm has joined #ruby
<fuzai>
nm i think i figured it out
workmad3 has joined #ruby
jpcamara has joined #ruby
ryanw_ is now known as brum
ffranz has joined #ruby
mark_locklear has joined #ruby
brum is now known as rsic
slainer68 has quit [Ping timeout: 260 seconds]
rsic has quit [Remote host closed the connection]
moos3 has quit [Quit: Computer has gone to sleep.]
<Dwarf>
fuzai mind sharing the solution?
<fuzai>
no problem, it turns out that the single quote doesn't need to be escaped
statarb3 has joined #ruby
<fuzai>
only the double quote to make valid json
gtuckerkellogg has joined #ruby
garbagecollectio has joined #ruby
otherj has joined #ruby
tomaw has joined #ruby
chussenot has joined #ruby
Blue_Ice has quit [Ping timeout: 252 seconds]
baotrung_ has joined #ruby
Blue_Ice has joined #ruby
Blue_Ice has quit [Changing host]
Blue_Ice has joined #ruby
girija has quit [Ping timeout: 260 seconds]
kumarat9pm has quit [Quit: Leaving.]
segv- has joined #ruby
baotrungtn has quit [Ping timeout: 256 seconds]
lingon has joined #ruby
ferdev is now known as ferdev|away
PragCypher has joined #ruby
moos3 has joined #ruby
kristofers has quit []
BrindleFly has quit [Quit: BrindleFly]
slainer68 has joined #ruby
maasha has quit [Quit: Page closed]
monkegjinni has quit [Remote host closed the connection]
slainer6_ has quit [Ping timeout: 240 seconds]
s3m73x has joined #ruby
<JonnieCache>
anyone here got experience with big java projects?
gtc has quit [Quit: kill -9 gtc]
<Hanmac1>
jonniecache, i think you are in the wrong channel ...
alunduil has quit [Quit: Leaving]
whitedawg has quit [Quit: Leaving.]
<JonnieCache>
i know but theres no way im going into the java channel
soc42 has quit [Remote host closed the connection]
<JonnieCache>
i vaguely remembered a regular here saying they used to be a corporate java dev
girija has joined #ruby
elux has joined #ruby
otherj_ has joined #ruby
zyrex has joined #ruby
PanPan has quit [Remote host closed the connection]
emergion has quit [Quit: Computer has gone to sleep.]
hbpoison has joined #ruby
<Hanmac>
my irb is currently still addon free
hbpoison has quit [Read error: Connection reset by peer]
baotrung_ has left #ruby [#ruby]
samphippen has joined #ruby
<JonnieCache>
organic repl
jtharris has joined #ruby
bluenemo has joined #ruby
bluenemo has quit [Changing host]
bluenemo has joined #ruby
ananthakumaran has quit [Quit: Leaving.]
Skelz0r has quit [Ping timeout: 260 seconds]
<clocKwize>
I didn't know irb had plugins
<banister`sleep>
zyrex: there's no learning curve to pry, it behaves just like irb from the beginning, but gives you some cool things in addition
twshelton has joined #ruby
schaerli has quit [Remote host closed the connection]
tomzx_mac has quit [Ping timeout: 260 seconds]
<banister`sleep>
clocKwize: they're not official :) just some guy who bundled up some stuff in a gem and asks you to require it in your .irbrc
_bart has joined #ruby
<banister`sleep>
but they dont look bad
<clocKwize>
not as good as pry ;)
hbpoison has joined #ruby
<banister`sleep>
pry stuff wasn't possible with just gem additions to irb, i required a rewrite
<banister`sleep>
it*
solidoodlesuppor has joined #ruby
unix has joined #ruby
dmiller has joined #ruby
m3pow has joined #ruby
<zyrex>
clocKwize: i mean is add ons :)
<clocKwize>
:)
<Hanmac>
last time i saw an app/gem that requires pry depency :P
dmonjo_ has joined #ruby
Skelz0r has joined #ruby
dmiller has quit [Ping timeout: 260 seconds]
jerius has joined #ruby
dmonjo has quit [Ping timeout: 276 seconds]
<banister`sleep>
Hanmac: what do u mean
JonnieCache has quit [Quit: Reconnecting]
a_a_g has quit [Quit: Leaving.]
JonnieCache has joined #ruby
<Hanmac>
i mean i saw an gem that lists pry and rails in his gem file
<banister`sleep>
Hanmac: as a development dependency?
<banister`sleep>
or runtime?
<Hanmac>
i dont know ... i hope only devel
<banister`sleep>
hehe
quazimodo has quit [Remote host closed the connection]
hbpoison has quit [Ping timeout: 256 seconds]
<banister`sleep>
Hanmac: i know a guy who used pry in production, He set up a pry-remote server, and it was triggered when an exceptioned happened, emailed him at 3am waking him up, and he connected and fixed the bug :)
<banister`sleep>
not recommended
<banister`sleep>
but pretty cool
slainer6_ has quit [Ping timeout: 260 seconds]
seoaqua has quit [Ping timeout: 240 seconds]
gtc has joined #ruby
kumarat9pm has quit [Quit: Leaving.]
_nitti has joined #ruby
tcstar has quit [Ping timeout: 252 seconds]
thams has joined #ruby
slainer68 has joined #ruby
skattyadz has joined #ruby
justsee has quit [Quit: Leaving...]
philcrissman has joined #ruby
PanPan has joined #ruby
<JonnieCache>
thats basically a l33ter version of better errors isnt it
monkegjinni has quit [Remote host closed the connection]
<JonnieCache>
i approve
Vert has joined #ruby
vlad_starkov has joined #ruby
dhruvasagar has quit [Ping timeout: 248 seconds]
atyz has joined #ruby
Jackneill has joined #ruby
monkegjinni has joined #ruby
Jackneill has quit [Changing host]
Jackneill has joined #ruby
s3m73x has quit [Ping timeout: 248 seconds]
BlankVerse_ has joined #ruby
BlankVerse_ has quit [Quit: BlankVerse_]
banister`sleep has quit [Ping timeout: 272 seconds]
theRoUS has joined #ruby
end_guy has quit [Ping timeout: 276 seconds]
CreativeEmbassy has joined #ruby
DaltonUS has joined #ruby
DaltonUS has quit [Client Quit]
BrindleFly has joined #ruby
brain_shim has quit [Ping timeout: 272 seconds]
end_guy has joined #ruby
otherj has quit []
jlebrech has joined #ruby
zyrex has quit [Ping timeout: 255 seconds]
<shevy>
Hanmac I think some people are only trolling on the forum
enebo has joined #ruby
znode has joined #ruby
Jackneill has quit [Remote host closed the connection]
PanPan has quit [Ping timeout: 255 seconds]
kx has quit [Read error: No route to host]
PragCypher has quit [Remote host closed the connection]
arya has joined #ruby
Jackneill has joined #ruby
machty has joined #ruby
mmitchell has joined #ruby
jrajav has joined #ruby
sebkomianos has joined #ruby
BrindleFly_ has joined #ruby
adkron has joined #ruby
casheew has quit [Read error: Connection reset by peer]
casheew has joined #ruby
ddv has quit [Ping timeout: 240 seconds]
BrindleFly has quit [Ping timeout: 252 seconds]
BrindleFly_ is now known as BrindleFly
<shevy>
hmmm
<shevy>
when you guys want to create a .html file from scratch
<shevy>
do you use some library or something?
ddv has joined #ruby
<shevy>
right now I just append to a string, then store it into a .html file ... but this is kinda awful
<heftig>
er, well, not that question specifically, but nokogiri has a builder
<shevy>
hmm
codecop has quit [Remote host closed the connection]
banister`sleep has joined #ruby
<shevy>
aha that one I suppose Nokogiri::HTML::Builder
pyrac_ has quit [Read error: Connection reset by peer]
pyrac has joined #ruby
MartinCleaver has joined #ruby
MartinCleaver has quit [Changing host]
MartinCleaver has joined #ruby
breakingthings has joined #ruby
axl_ has joined #ruby
<Xeago>
there are also some other DSL stuff thingies
<Xeago>
that allow you to do html do { head { }; body { div { p { "derp" } } } }
<Xeago>
strip the do
<clocKwize>
html { head ; body { p { "I'm awesome!" } } }
adman65 has joined #ruby
Pufferfo_ has joined #ruby
ananthakumaran has joined #ruby
Pufferfood has quit [Read error: Connection reset by peer]
zzing has quit [Ping timeout: 264 seconds]
adkron has quit [Ping timeout: 256 seconds]
fenak has joined #ruby
adkron_ has joined #ruby
v0n has joined #ruby
<shevy>
Xeago hmm but does this return a string or can I save it to a file?
<tobiasvl>
"or"?
<JonnieCache>
shevy: you probably want erb templates
kumarat9pm has joined #ruby
kumarat9pm has quit [Max SendQ exceeded]
<shevy>
tobiasvl yes at least one of these, I have to generate a linked list of .html pages
<tobiasvl>
well strings can be saved to files
<tobiasvl>
was my point
kumarat9pm has joined #ruby
kumarat9pm has quit [Max SendQ exceeded]
imami|afk is now known as banseljaj
Udom0 has quit [Quit: Leaving.]
s3m73x has joined #ruby
<shevy>
clocKwize hmm from where is that example?
kumarat9pm has joined #ruby
dkannan has quit [Quit: dkannan]
kumarat9pm has quit [Max SendQ exceeded]
thams has quit [Quit: thams]
mercwithamouth has joined #ruby
adkron has joined #ruby
beiter has quit [Ping timeout: 260 seconds]
schaerli has joined #ruby
nomenkun has quit [Remote host closed the connection]
ffranz has quit [Quit: Leaving]
wmoxam has quit [Ping timeout: 260 seconds]
aqabiz has quit [Quit: aqabiz]
jgarvey has joined #ruby
<Xeago>
shevy: does that matter?
<Xeago>
I think the gem from which I learned that from can has additional methods on the html part
<Xeago>
and it returns the html 'object' itself, and you can call to_s/to_str on that
<shevy>
Xeago it matters if I want to use something!!!
ffranz has joined #ruby
ffranz has quit [Client Quit]
hybris has quit [Read error: Connection reset by peer]
<shevy>
you cant just display pseudocode and no gem works :P
<shevy>
"the gem" whaaaaat gem!
beiter has joined #ruby
<shevy>
alright alright, I will write me one
<Xeago>
shevy: just a sec
dmiller has joined #ruby
miskander has joined #ruby
zyrex has joined #ruby
ffranz has joined #ruby
dmerrick has joined #ruby
zzing has joined #ruby
frem has joined #ruby
<jsaak>
shevy there is one called "builder"
hybris has joined #ruby
<shevy>
ok
<Xeago>
markaby
<jsaak>
not this syntax
<Xeago>
is the one I am referring to
<shevy>
Successfully installed builder-3.1.4
<shevy>
Successfully installed markaby-0.7.2
ablemike has quit [Remote host closed the connection]
h4mz1d has joined #ruby
stopbit has joined #ruby
adkron has quit [Ping timeout: 240 seconds]
znode has quit [Remote host closed the connection]
adkron_ has quit [Ping timeout: 276 seconds]
jekotia has joined #ruby
wmoxam has joined #ruby
monkegjinni has quit [Remote host closed the connection]
pavilionXP has joined #ruby
dmiller has quit [Ping timeout: 264 seconds]
Doc_X has joined #ruby
spaceships has joined #ruby
rippa has joined #ruby
gyre008 has joined #ruby
gyre008 has quit [Remote host closed the connection]
zzing has quit [Remote host closed the connection]
gyre008 has joined #ruby
h4mz1d has quit [Ping timeout: 260 seconds]
zzing has joined #ruby
interactionjaxsn has joined #ruby
Mon_Ouie has joined #ruby
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby
jonahR has joined #ruby
ffranz1 has joined #ruby
gyre007 has quit [Ping timeout: 260 seconds]
hashmal has joined #ruby
maycon has joined #ruby
maycon has quit [Changing host]
maycon has joined #ruby
twshelton has quit [Quit: Computer has gone to sleep.]
philcrissman has quit [Remote host closed the connection]
zzing has quit [Ping timeout: 248 seconds]
clj_newb has joined #ruby
clj_newb has left #ruby [#ruby]
sie has joined #ruby
<sie>
Is it possible to catch/override the def call?
ffranz2 has joined #ruby
hbpoison has joined #ruby
CreativeEmbassy has quit [Quit: Computer has gone to sleep.]
ffranz has quit [Read error: No route to host]
<hoelzro>
sie: yes
<hoelzro>
well, catch
zzing has joined #ruby
<hoelzro>
Module#method_added
<hoelzro>
(and friends)
ffranz1 has quit [Ping timeout: 256 seconds]
<sie>
Ooh, sweet.
thams has joined #ruby
gyre007 has joined #ruby
vlad_starkov has quit [Ping timeout: 260 seconds]
gtc has quit [Quit: kill -9 gtc]
zzing has quit [Ping timeout: 252 seconds]
hbpoison has quit [Ping timeout: 264 seconds]
gyre007 has quit [Remote host closed the connection]
F1skr has joined #ruby
SCommette has joined #ruby
whitedawg has joined #ruby
gyre007 has joined #ruby
hbpoison has joined #ruby
uris has joined #ruby
SCommette has quit [Client Quit]
monkegjinni has joined #ruby
forrest has joined #ruby
gyre008 has quit [Ping timeout: 260 seconds]
pavilionXP has quit [Quit: Forget progress by proxy. Land on your own moon.]
atyz has quit [Quit: Leaving...]
hashpuppy has joined #ruby
tcstar has joined #ruby
dcunited001 has joined #ruby
Takehiro has quit [Remote host closed the connection]
kold has joined #ruby
endzyme has joined #ruby
<hashpuppy>
why do I get "uninitialized class variable" when I reference @@my_var inside class << self; def get(x); @@my_var[x]; end; end, but it's fine when i don't have class << self and use def self.get(x)
__BigO__ has joined #ruby
zyrex has quit [Ping timeout: 255 seconds]
hbpoison has quit [Ping timeout: 264 seconds]
gtuckerkellogg has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
hbpoison has joined #ruby
Takehiro has joined #ruby
<ohcibi>
hi, i'm scping two files with rakes sh command.. the second file (which is not empty) get transferred with 0 bytes, which dont happens when i execute the scp command by hand... whats wrong?
jrajav has quit [Quit: phunq, sandwich store loop, WHAT NO UNIVERSE]
<Hanmac>
hashpuppy i think you should use only @ and not @@ , class instance variables are moslty better
samphipp_ has joined #ruby
banister`sleep is now known as banisterfiend
rgsteele has joined #ruby
thufir_ has quit [Quit: Leaving.]
puppeh has quit [Read error: Connection reset by peer]
ffranz2 has quit [Quit: Leaving]
puppeh has joined #ruby
tish has joined #ruby
atyz has joined #ruby
PanPan has joined #ruby
andikr has quit [Remote host closed the connection]
clocKwize_ has joined #ruby
clocKwize has quit [Read error: Connection reset by peer]
clocKwize_ is now known as clocKwize
geekbri has joined #ruby
samphippen has quit [Ping timeout: 244 seconds]
samphipp_ is now known as samphippen
octoberry has joined #ruby
crankycoder has quit [Quit: leaving]
ffranz has joined #ruby
jlast has joined #ruby
crankycoder has joined #ruby
adkron has joined #ruby
adkron_ has joined #ruby
crankycoder has quit [Client Quit]
pskosinski has quit [Ping timeout: 260 seconds]
<jpcamara>
anyone have any ruby profiler recommendations that are more interactive? I've been on and off with ruby for the last couple years, and have been full-time ruby for the last few months. i was a jvm/java guy before this and tools like jvisualvm and jprofiler have really slick analytics and real-time info on jvm profiling
crankycoder has joined #ruby
<jpcamara>
is there anything similar for ruby? best I seem to be able to find revolves around profiling dumps
PanPan has quit [Ping timeout: 256 seconds]
hbpoison has quit [Ping timeout: 264 seconds]
jonathanwallace1 has joined #ruby
_whitelogger has joined #ruby
dmonjo__ has joined #ruby
shippy has joined #ruby
jonathanwallace has quit [Ping timeout: 276 seconds]
<shevy>
the one who wanted to increment all entries in an array by +1
<Hanmac>
hm no ... its good that he is not on irc
schaerli has quit [Remote host closed the connection]
girija has joined #ruby
Es0teric has quit [Client Quit]
<shevy>
but the guy on IRC almost asked the same, he even had the same array structure
bubblehead has quit [Remote host closed the connection]
<shevy>
he also settled for recursion
<shevy>
can this be really coincidence? I am gonna watch him
<shevy>
I mean with a nick like "Love U Ruby"
x0F has quit [Disconnected by services]
x0F_ has joined #ruby
banisterfiend has joined #ruby
x0F_ is now known as x0F
Alir3z4 has joined #ruby
<ddd>
he uses like 3 different names, Love U Ruby is just one
waxjar has quit [Ping timeout: 245 seconds]
apok has joined #ruby
<shevy>
hehe
<ddd>
me, Robert, Hans and someone else all got into his ass on the ML for his insane amount of 'every little freakin question that hits your brain' question list to the ML
thomasfedb has quit [Ping timeout: 252 seconds]
zzing has quit [Ping timeout: 240 seconds]
<shevy>
yeah, he is a time vampire... tries to steal time from people
Alir3z4 has left #ruby [#ruby]
tagrudev has quit [Quit: Me = Awesome]
<shevy>
this is like evolution of trolls, they become smarter
<Hanmac>
shevy ... he is one of the grey man? oO
yacks has quit [Quit: Leaving]
<apeiros_>
or the devolution of noobs
<shevy>
naaaaah the grey men were just a nice anti-smoking idea
nathanstitt has joined #ruby
mando has joined #ruby
<shevy>
"if you smoke, you lose time of your life"
<ddd>
he doesn't take even the minimalistic amount of time to even *try* to understand what is happening (like with the << operator or the splat) nevermind google info about it, ect
<apeiros_>
heh, momo
<shevy>
:)
<shevy>
ddd yeah... there was someone like him before, from greece
<shevy>
he annoyed the mailing list for a long time
<apeiros_>
reads a bit like lazarus - coming back from the dead…
mlr has quit [Ping timeout: 276 seconds]
<ddd>
exactly my thought
techhelp has joined #ruby
<shevy>
I don't understand how people got time for this... sure a few times it may be fun to provoke reactions, but in the long run, should he not do something better with his time?
zzing has joined #ruby
miskander has joined #ruby
aganov has quit [Quit: aganov]
buibex has joined #ruby
<whitequark>
shevy: mentally ill
philcrissman has joined #ruby
filipe has quit [Remote host closed the connection]
main has quit [Ping timeout: 255 seconds]
jgrevich has joined #ruby
pyrac has quit [Read error: Connection reset by peer]
pyrac_ has joined #ruby
miskander has quit [Client Quit]
<banisterfiend>
whitequark: im impressed by his familiarity with a huge number of langauges/frameworks though :)
<banisterfiend>
he does manage to get moderately passed 'noob' on each one :))
filipe has joined #ruby
anonymuse has joined #ruby
geekbri has quit [Remote host closed the connection]
a_a_g has quit [Quit: Leaving.]
waxjar has joined #ruby
adkron_ has quit [Ping timeout: 260 seconds]
adkron__ has quit [Ping timeout: 260 seconds]
angusiguess has quit [Ping timeout: 276 seconds]
statarb3 has quit [Quit: Leaving]
CraHan is now known as CraHan|out
thomasfedb has joined #ruby
thomasfedb has quit [Changing host]
thomasfedb has joined #ruby
io_syl has quit [Quit: Computer has gone to sleep.]
timonv has quit [Remote host closed the connection]
devinus has joined #ruby
<devinus>
anybody know if there's a way to do a quick regex test on a string w/o matching?
<tobiasvl>
what do you want to do then?
<workmad3>
devinus: what do you mean by 'without matching'?
<tobiasvl>
if you don't want to know whether or not the regex matched ...
adkron_ has joined #ruby
<macq>
if str =~ /regex/
<devinus>
won't that give the # of matches?
<macq>
# ?
zzing has quit [Ping timeout: 264 seconds]
apeiros_ has quit [Remote host closed the connection]
<workmad3>
devinus: no
<workmad3>
devinus: it'll return the index of a match, or nil if no match
<devinus>
i see, thanks
baroquebobcat has joined #ruby
<devinus>
is it idiomatic to use the 'then' keyword if you want to keep an if on a single line?
girija has quit [Ping timeout: 252 seconds]
<devinus>
e.g. exists = if path =~ /^\/proxy/ then true end
<macq>
exists = !!(path =~ /.../)
joshman_ has quit [Ping timeout: 272 seconds]
Baughn has joined #ruby
<macq>
if you need boolean value ofcourse
mattbl has joined #ruby
buibex has quit [Remote host closed the connection]
adkron__ has joined #ruby
<Baughn>
When I run rake on ember.js, I get this error: "/home/svein/.bundler/ruby/1.8/ember-dev-659bf4c415f8/lib/tasks/uploads.rake:5: undefined (?...) sequence: /(?<name>.+)\t(?<url>.+) \((?<type>.+)\)$/". I've been told that this is due to it needing ruby 1.9.3. However, /usr/bin/ruby is in fact 1.9.3..
<macq>
and you probably want to use \A instead of ^
<Baughn>
Judging by the 1.8 in that path, it's selecting 1.8 based on something else
joshman_ has joined #ruby
etcetera has joined #ruby
<Hanmac>
Baughn its because of bundler
<idl0r>
has ruby something like pointers, to iterate over a string and point to the next char until the end of string? like "for (;; *string++) printf("%c\n", *string);"
<tobiasvl>
idl0r: if you explain exactly what you want, maybe we can still help
<shevy>
:D
<shevy>
He wants chocolate.
Umren has joined #ruby
<idl0r>
i just had chocolate :P
zzing has joined #ruby
mlr_ has joined #ruby
anannie has quit [Ping timeout: 240 seconds]
blf has joined #ruby
lolmaus has joined #ruby
<blf>
Would it be unintuitive to require the writer of a callback to provide locks within the callback method if the method is to be called from within a thread?
Squarepy has joined #ruby
khismetix has joined #ruby
pyrac_ has quit [Ping timeout: 260 seconds]
Squarepy has quit [Changing host]
Squarepy has joined #ruby
<blf>
I could lock around the entire callback from within the thread, but it seems like more efficient locking could be performed by the method itself.
JohnBat26 has quit [Ping timeout: 240 seconds]
gosshedd has quit [Ping timeout: 264 seconds]
cableray has joined #ruby
<whitequark>
blf: always assume that your library is used by a complete moron
<whitequark>
i.e. opt-in anything nontrivial
<blf>
whitequark: That's what I figured. So lock the entire callback :)
<workmad3>
blf: lock the callback, but provide a way to disable the lock with an option maybe?
<workmad3>
blf: so that users who know what they're doing can provide a more efficient locking, or no locking if they know they don't need it
<macq>
blf: how about two methods - one with lock around and one without? Or even Module.with_lock_on(obj) {|obj| }
<blf>
workmad3: Hm.. That actually sounds pretty nice. I think I may go that route.
<workmad3>
blf: then it's 'method_with_callback(foo, lock: false) do ... end'
zzing has quit [Ping timeout: 252 seconds]
lolmaus has quit []
* blf
likes :)
<blf>
Thanks
aedornv has joined #ruby
carloslopes has quit [Remote host closed the connection]
ozgura has quit [Remote host closed the connection]
bubblehead has joined #ruby
hbpoison has quit [Ping timeout: 276 seconds]
j^2 has quit [Quit: for i in `/names` ; do adios $i; done]
zzing has joined #ruby
j^2 has joined #ruby
j^2 has quit [Client Quit]
BadLarry has quit [Quit: quitting]
<banisterfiend>
anyone here good with jquery?
<banisterfiend>
workmad3: u?
<idl0r>
tobiasvl: well... in short: i want the previous processed characters to be "removed" from the string
miskander has joined #ruby
nomenkun has joined #ruby
mengu_ has quit [Quit: Leaving]
lingon has quit [Ping timeout: 245 seconds]
cantonic has joined #ruby
ffranz has quit [Ping timeout: 244 seconds]
heftig has quit [Quit: Quitting]
BadLarry has joined #ruby
the_mentat has quit [Quit: Computer has gone to sleep.]
pdamer has quit [Quit: pdamer]
heftig has joined #ruby
dallasm has joined #ruby
drago757 has quit [Quit: drago757]
chimkan has quit [Quit: chimkan]
zzing has quit [Ping timeout: 260 seconds]
robbyoconnor has joined #ruby
ffranz has joined #ruby
bubblehead has quit [Ping timeout: 252 seconds]
rawler has quit [Read error: Operation timed out]
<idl0r>
but that's probably not enough :/
<idl0r>
too much to explain
<idl0r>
i'll try to split the string into an array for now
nkr has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
j^2 has joined #ruby
sayan has quit [Read error: Connection reset by peer]
philcrissman has quit [Remote host closed the connection]
hemanth has quit [Read error: Connection reset by peer]
hemanth has joined #ruby
codespectator has quit [Quit: Computer has gone to sleep.]
Morkel has quit [Quit: Morkel]
zzing has joined #ruby
S1kx has joined #ruby
arturaz has quit [Ping timeout: 248 seconds]
jerikl has quit [Quit: jerikl]
Vert has quit [Ping timeout: 252 seconds]
chichou has quit [Remote host closed the connection]
bubblehead has joined #ruby
anderse has quit [Quit: anderse]
verysoftoiletppr has quit []
alvaro_o has joined #ruby
_nitti has quit [Remote host closed the connection]
Al____ has joined #ruby
sn0wb1rd has quit [Quit: sn0wb1rd]
bradleyprice has joined #ruby
axl_ has quit [Quit: axl_]
sebkomianos has joined #ruby
zzing has quit [Ping timeout: 240 seconds]
baustin has left #ruby ["Leaving"]
_nitti has joined #ruby
cantonic has quit [Quit: cantonic]
hemanth has quit [Read error: Connection reset by peer]
Al___ has quit [Ping timeout: 260 seconds]
mephux has quit [Excess Flood]
hemanth has joined #ruby
adkron_ has quit [Ping timeout: 260 seconds]
tylersmith has joined #ruby
adkron__ has quit [Ping timeout: 252 seconds]
zigomir has left #ruby [#ruby]
CreativeEmbassy has joined #ruby
zigomir has joined #ruby
Elhu has quit [Quit: Computer has gone to sleep.]
arya_ has joined #ruby
Al____ has quit [Ping timeout: 276 seconds]
<shevy>
idl0r you should write a method
nga4 has quit [Ping timeout: 260 seconds]
mephux has joined #ruby
<shevy>
then keep a copy on your main string and work on that
codespectator has joined #ruby
gestahlt has quit [Read error: Connection reset by peer]
<shevy>
to chop off the first character of that string, you can do: string[0,1] = ''
goraxe has joined #ruby
Elhu has joined #ruby
jrajav has joined #ruby
lupinstein has joined #ruby
arya has quit [Ping timeout: 248 seconds]
rawler has joined #ruby
gestahlt has joined #ruby
hrr has joined #ruby
<macq>
idl0r: what you trying to do with that string?
Elhu has quit [Client Quit]
beiter has quit [Quit: beiter]
<macq>
removing characters - sounds like you trying to write C code using ruby...
pyreal has joined #ruby
hoelzro is now known as hoelzro|away
gestahlt has quit [Client Quit]
samphippen has joined #ruby
<idl0r>
macq: i usually write C, yeah. in this case i need a enhanced chmod function that supports the powerful symbolic modes, for some puppet stuff
mafolz has quit [Remote host closed the connection]
hbpoison has joined #ruby
<idl0r>
it's basically my first time with ruby
<idl0r>
i can show you the result when i am done with it, may be useful for others as well
angusiguess has joined #ruby
hrr has quit [Quit: hrr]
<idl0r>
perhaps even for ruby core but i guess i could then write it in C as well
<JonnieCache>
idl0r: are you just trying to remove chars from a string?
nomenkun has quit [Remote host closed the connection]
<JonnieCache>
sorry i havent read the whole convo
jonathanwallace has joined #ruby
Rizzle has joined #ruby
casheew has quit [Read error: Connection reset by peer]
casheew has joined #ruby
cantonic has joined #ruby
zzing has joined #ruby
<idl0r>
JonnieCache: yes and no. i was just looking for the ruby equivalent of e.g. "for (;; *string++) printf("%c\n", *string);" where "string" would be e.g. "string[1,-1]" after the first iteration
zigomir has quit [Quit: zigomir]
khismetix has quit [Ping timeout: 252 seconds]
Slivka has joined #ruby
<JonnieCache>
well you can literally call string[1,-1] in ruby
<JonnieCache>
which might do what you want, im not sure
alex__c2022 has quit [Read error: No route to host]
Es0teric has joined #ruby
BoomCow has joined #ruby
<JonnieCache>
basically, youre being too low level. the ruby way is to look through the plentiful utility methods on modules like Enumerable and find one that does what you want
whitedawg has quit [Quit: Leaving.]
sayan has joined #ruby
Elhu has joined #ruby
Es0teric has quit [Client Quit]
<JonnieCache>
or obviously you can compose them. theyre written with that in mind
nomenkun has joined #ruby
Matip has quit [Read error: Connection reset by peer]
<banisterfiend>
JonnieCache: string.each_char { |i| puts i }
<banisterfiend>
oops
<banisterfiend>
wrong guy
dallasm has left #ruby [#ruby]
<banisterfiend>
idl0r: ^
Matip has joined #ruby
devinus has quit [Quit: devintorr.es]
philcrissman has joined #ruby
alex__c2022 has joined #ruby
Al__ has joined #ruby
bradhe has quit [Remote host closed the connection]
dr_bob has joined #ruby
lethjakman has joined #ruby
francisfish has quit [Remote host closed the connection]
LBRapid has joined #ruby
<lethjakman>
is there a good gui gem for ruby besides shoes?
alex__c2022 has quit [Read error: Connection reset by peer]
alex__c2022_ has joined #ruby
slainer6_ has quit [Ping timeout: 260 seconds]
<Hanmac>
lethjakman what kind of gui? webbased, or system-based?
<lethjakman>
system based
zzing has quit [Ping timeout: 252 seconds]
Voodoofish430 has joined #ruby
<Hanmac>
wxwidgets has two gems ... wxRuby and rwx ... last one is newer
slainer68 has joined #ruby
<lethjakman>
Hanmac: hm, that's interesting. I've heard of wxruby but not rwx
maletor has joined #ruby
<lethjakman>
has wxwidgets gotten any better? last I used it it was pretty buggy
cantonic has quit [Quit: cantonic]
alex__c2022_ has quit [Read error: No route to host]
arya_ has quit [Ping timeout: 248 seconds]
<Hanmac>
yeah it does better
peteyg has quit [Ping timeout: 252 seconds]
alex__c2022 has joined #ruby
alx- has joined #ruby
<Hanmac>
i was pissed off by wxRuby so i made rwx
mlr_ has left #ruby [#ruby]
mjanssen has joined #ruby
<banisterfiend>
Hanmac: have you released any gems?
PanPan has joined #ruby
<Hanmac>
banister a few
<lethjakman>
Hanmac: I'll have to try rwx
angusigu1ss has joined #ruby
dr_bob has left #ruby [#ruby]
<Hanmac>
lethjakman you can ping me when you got questions
alex__c2022 has quit [Read error: No route to host]
<lethjakman>
thank you!
<lethjakman>
it's appreciated
maligree has joined #ruby
Es0teric has joined #ruby
zzing has joined #ruby
angusiguess has quit [Ping timeout: 264 seconds]
rlb3 has quit [Quit: rlb3]
arya has joined #ruby
cschneid has joined #ruby
<lethjakman>
also, I was wondering if there was a good way to bundle ruby applications together, kinda like OSX .app's?
mockra has joined #ruby
artOfWar has joined #ruby
axl_ has joined #ruby
PanPan has quit [Ping timeout: 264 seconds]
philcrissman has quit [Remote host closed the connection]
ozgura has joined #ruby
fenak has quit [Ping timeout: 245 seconds]
pyrac has joined #ruby
<jrabbit>
For osx?
<jrabbit>
or like it?
<jrabbit>
Gems.
mahmoudimus has joined #ruby
philcrissman has joined #ruby
Monie has joined #ruby
<lethjakman>
Hanmac: I'm not finding your gem on rubygems, how would I install it/where would I find it?
alex__c2022 has joined #ruby
buibex has quit [Remote host closed the connection]
ozgura has quit [Remote host closed the connection]
<lethjakman>
jrabbit: cross platform.
angusiguess has joined #ruby
<lethjakman>
I want a way to bundle my dependencies, maybe even something like a .jar or a .exe
carloslopes has joined #ruby
_bart has quit [Quit: _bart]
forrest has quit [Quit: Leaving]
_nitti_ has joined #ruby
alex__c2022_ has joined #ruby
buscon has quit [Quit: Leaving]
Es0teric has quit [Remote host closed the connection]
predator417 has quit [Quit: leaving]
angusigu1ss has quit [Ping timeout: 255 seconds]
alex__c2022_ has quit [Read error: No route to host]
alex__c2022__ has joined #ruby
alex__c2022 has quit [Ping timeout: 252 seconds]
alex__c2022__ is now known as alex__c2022
zzing has quit [Ping timeout: 256 seconds]
_nitti has quit [Ping timeout: 255 seconds]
explodes has joined #ruby
<explodes>
I don't know jack about ruby, but I know I need to get "Curses::Application" on my machine... What do I do?
schaerli has joined #ruby
angusigu1ss has joined #ruby
Cooler_ has quit [Remote host closed the connection]
banisterfiend has quit [Remote host closed the connection]
zzing has joined #ruby
locriani has quit [Ping timeout: 252 seconds]
<explodes>
gem install "Curses::Application" doesn't work
<dmonjo>
getting this erro when calling puts "bbbb",samsung.battery_hours
<dmonjo>
isnt the battery_hours method inheited from the class included?
sk87 has quit [Quit: sk87]
mattbl has quit [Quit: This computer has gone to sleep]
slainer6_ has joined #ruby
slainer68 has quit [Read error: Connection reset by peer]
angusigu1ss has quit [Ping timeout: 248 seconds]
arturaz has joined #ruby
etcetera has quit []
angusiguess has quit [Ping timeout: 248 seconds]
angusiguess has joined #ruby
ffranz1 has joined #ruby
Bry8Star has quit [Ping timeout: 276 seconds]
ffranz1 has quit [Read error: Connection reset by peer]
beiter has joined #ruby
banisterfiend has joined #ruby
Shrink has quit [Ping timeout: 252 seconds]
ffranz1 has joined #ruby
gosshedd has joined #ruby
TomJ has quit [Ping timeout: 248 seconds]
ffranz has quit [Ping timeout: 256 seconds]
dankest has joined #ruby
tomzx_mac has joined #ruby
pdamer has joined #ruby
trietptm has joined #ruby
maxmanders has quit [Quit: Computer has gone to sleep.]
angusigu1ss has joined #ruby
angusiguess has quit [Ping timeout: 264 seconds]
jrajav has quit [Quit: phunq, sandwich store loop, WHAT NO UNIVERSE]
arietis has joined #ruby
<shevy>
do you guys work a lot with Rational?
<shevy>
dmonjo what inheritance please?
skum has quit [Quit: Leaving...]
<shevy>
you can not include a class, you can only include a module
answer_42 has joined #ruby
xardas has joined #ruby
<dmonjo>
ki included a module which in turn has a class
<dmonjo>
i*
predator117 has joined #ruby
<shevy>
yes, so you have one class residing in a namespace (module), and a completely separate class not residing in that module, but including the namespace of that module
banjara has joined #ruby
<trietptm>
Hello everybody, I have this error trace: rake db:create --trace rake aborted! Could not find a JavaScript runtime while trying rake db:create :( , could someone help me to find the root cause : http://pastie.org/6307792
<shevy>
inheritance would work like so: class A; end; class B < A; end
<trietptm>
I have tried to install Node.js, add gem 'therubyracer' to gemfile in the main rails app directory and "bundle install" again but it has no use :( .
Ephexeve_laptop has quit [Quit: leaving]
<dmonjo>
shevy: you mean if module A included Class1 and i include in Class2 moduleA i will not be able to access Class1 ??
baroquebobcat has quit [Quit: baroquebobcat]
<shevy>
dmonjo define "access"
breakingthings has quit []
<shevy>
if you include, you pull in a namespace
<dmonjo>
ModuleA (namespace) includes Class A
<shevy>
yes
<dmonjo>
Now in Class B i include ModuleA
<shevy>
yes
<dmonjo>
will i be able to access Class A methods
ffranz has joined #ruby
<dmonjo>
from Class B
nga4 has joined #ruby
<shevy>
how so? you have not instantianted and you only included the module
mattbl has joined #ruby
ffranz has quit [Read error: Connection reset by peer]
<dmonjo>
Consider i instantiaed in Class B a new instance
<shevy>
basically what you did is you can omit the "Battery::" prefix
<dmonjo>
newinstance = B.new
vlad_starkov has joined #ruby
ffranz1 has quit [Ping timeout: 256 seconds]
<dmonjo>
how can newinstance access the methods defined on Class A
<shevy>
I have really no idea what you mean with "access"
chrishough has quit [Quit: chrishough]
<shevy>
modules are just namespaces in essence really
brianpWins has joined #ruby
<shevy>
when you properly scope to those namespaces, you have "access" to them
arya has joined #ruby
sk87 has joined #ruby
<dmonjo>
shevy: in your example BAR < FOO foo BAR becomes a subclass of foo right
_nitti__ has joined #ruby
<shevy>
yeah
<shevy>
you can use .ancestors to see the chain of "parentage"
gyre007 has quit [Ping timeout: 260 seconds]
<dmonjo>
ok
_nitti_ has quit [Ping timeout: 256 seconds]
Bry8Star has joined #ruby
explodes has quit [Disconnected by services]
alx- has quit [Ping timeout: 276 seconds]
thams has joined #ruby
elico has joined #ruby
skcin7 has joined #ruby
kevinfagan has quit [Quit: Leaving...]
banisterfiend has quit [Remote host closed the connection]
chrisja has joined #ruby
BrindleFly has quit [Quit: BrindleFly]
_nitti has joined #ruby
<shevy>
asciitable.rb:84:in `+': failed to allocate memory (NoMemoryError)
<shevy>
awwwww
<shevy>
I never had this error before :(
pyrac has quit [Quit: pyrac]
Tomasso has joined #ruby
_nitti__ has quit [Ping timeout: 246 seconds]
micah has joined #ruby
lmg_ has quit [Ping timeout: 256 seconds]
dmonjo has quit [Remote host closed the connection]
elico has quit [Remote host closed the connection]
wmoxam has quit [Ping timeout: 252 seconds]
BrianJ has joined #ruby
<shevy>
hmm guys
_nitti has quit [Read error: No route to host]
<shevy>
if I have this:
<shevy>
attr_accessor :data
_nitti has joined #ruby
ffranz has joined #ruby
<shevy>
in order to define an alias to it, the writer part only, I would make this here, right?
<shevy>
alias_method :dataset=, :data=
<shevy>
no dice with alias alone or?
Elhu has quit [Quit: Computer has gone to sleep.]
<arturaz>
alias :dataset= :data=
<shevy>
ohhhhhhhhh
<shevy>
that works!!!
<shevy>
hah!
banisterfiend has joined #ruby
dankest has quit [Quit: Leaving...]
<shevy>
when would one use alias_method though?
<micah>
i have a define that calls something and I want it to return false if that fails, but it ends up spitting an error, how do I get it to just return false? this is what I have: def valid_repo Dir.chdir(@resource.value(:path)){ git_with_identity('rev-parse', '> /dev/null 2>&1')} end
<mjanssen>
Why do you want to put stuff there in the first place?
<shevy>
a youtube client!
<aedornv>
Yeah...
MartinCleaver has quit [Quit: MartinCleaver]
<kalleth>
i want to have a dir on my hdd containing mp3's of the latest 50 uplaods from a youtube channel i follow so i can have a dir on my phone synced to a dir on my PC so i always have the latest tune s;)
<aedornv>
Ruby shows 2250 files in windows/system32, and there's actually 2545 files
<kalleth>
not fragile at all
<kalleth>
lol, aedornv
<shevy>
aedornv it's trying to hide things from the user!
<shevy>
I am glad that on linux I can always do "rm -rf /"
<kalleth>
'glad' :|
<aedornv>
Let's see why...
<kalleth>
i'm breakign a cardinal rule here for me as well
<kalleth>
'do not use ruby on windows'
<shevy>
kalleth yeah, I want to be my own idiot, not have the operating system tell me I am an idiot and then not allowing me to break it :(
<kalleth>
oh, i'm with you
<kalleth>
i just don't want my grandma to be able to do it
<shevy>
my ruby scripts usually work on windows
<kalleth>
because then my phone rings
<shevy>
I have ffmpeg.exe under /Program Files somewhere though
<shevy>
hmm though... it should not matter where ffmpeg.exe is right? just as long as you can call it from .rb files
TomJ has quit [Quit: TomJ]
<kalleth>
well, it must be system32 magic
<kalleth>
as aedornv says
LouisRoR has quit [Ping timeout: 260 seconds]
<aedornv>
neat.. and in Ruby using `dir c:\\windows\\system32` gives 2170 files
ablemike has quit [Remote host closed the connection]
angusigu1ss has quit [Ping timeout: 256 seconds]
schaerli has quit [Remote host closed the connection]
blf has quit [Quit: Page closed]
<kalleth>
aedornv: #include <consistency.h>
stringoO has joined #ruby
generalissimo has quit [Remote host closed the connection]
Jackneill has joined #ruby
Jackneill has quit [Changing host]
Jackneill has joined #ruby
timmow has quit [Remote host closed the connection]
fcoury has joined #ruby
<shevy>
hehe
rismoney has quit []
TomJ has joined #ruby
TomJ has quit [Changing host]
TomJ has joined #ruby
<shevy>
so 3 different results? 2250, 2545, 2170
<shevy>
could depend on the weekday perhaps
the_jeebster has joined #ruby
swex has quit [Remote host closed the connection]
peregrine81 has joined #ruby
<bean__>
guy at work won't upgrade his ruby to 1.9
<bean__>
:|
<bean__>
demands other coworker put in a fix
CrazyDog has joined #ruby
<Todd>
we still run 1.8 in production
peregrine81 has quit [Client Quit]
<the_jeebster>
time to update :)
peregrine81 has joined #ruby
banjara has quit [Quit: Leaving.]
<Todd>
not any time soon
<Todd>
took us roughly 5 years to get to apache 2
<Todd>
legacy perl code ftl
<the_jeebster>
at my last gig we had three ruby apps, one of which was running 1.8
<the_jeebster>
it's always fun switching b/w 1.8 and 1.9, going back and forth between deprecated methods
dankest has joined #ruby
<Todd>
I had the hash argument with a guy the other day
maxmanders has joined #ruby
<Todd>
hash syntax rather
miskander has quit [Quit: miskander]
devinus has joined #ruby
<shevy>
bean__ hehe... I am still on 1.8 myself. my reason is encoding, I absolutely HATE it, it gives me 0 advantage but lots of more work
TomJ has quit [Quit: TomJ]
DDark has joined #ruby
<shevy>
Todd I just ignore the new syntax, this is no big deal
_br_ has quit [Excess Flood]
banjara has joined #ruby
lupinstein has quit [Ping timeout: 260 seconds]
<shevy>
all my code will work on both 1.8 and 1.9
<shevy>
with encoding, I dont get to choose anymore
<Todd>
shevy: well except that we started using it in our automated tests which do run on 1.9.3 and he's running 1.8 on his laptop
angusiguess has joined #ruby
choffstein has joined #ruby
<Todd>
basically if you want to develop on your laptop why are you not running rvm or rbenv?
cdt has quit [Remote host closed the connection]
miskander has joined #ruby
enebo has joined #ruby
twoism has joined #ruby
main has joined #ruby
<shevy>
hmm? who? me?
<shevy>
ah
<shevy>
he
<shevy>
I could not quite work on a laptop myself
wmoxam has joined #ruby
<DDark>
Hey All. I have 2 hashes like >h1 = {"math" => {"key" => "value", "key1" => "value1"}, "science" => nil}< and >h2 = {"math" => {"key" => "value", "key1" => "value2"}, "science" => nil}<. How can I merge both hashes overwriting values when a key exists? Ive tried variant of merge with kas_key?, but with no luck. Any pointers would be appreciated.
<shevy>
I need a big fat keyboard
mark_locklear has quit [Read error: Connection reset by peer]
kiwnix has quit [Ping timeout: 276 seconds]
_br_ has joined #ruby
<shevy>
DDark tried .merge and .update already? and the ! variants of them?
<aedornv>
This is oddly confusing...
<shevy>
aedornv you got a fourth result? :D
hybris has quit [Quit: Leaving]
<DDark>
yeah, but Im having trouble as i keep overwriting all values.
miskander has quit [Client Quit]
<DDark>
I need to keep what is there, and only overwrite when a key is matched with a different value from the new hash
<shevy>
DDark ok so you can only use a custom merge?
<shevy>
I think then you must do so on your own, i.e. eterate over the hash and either build a new one or insert into the first
_br_ has quit [Excess Flood]
<shevy>
*iterate
<shevy>
but perhaps someone else here has an idea, if .merge and .update both won't work for you
<DDark>
would inject be the way to go with that? I was going to attempt it next.
ffranz has quit [Quit: Leaving]
etank is now known as elake
_br_ has joined #ruby
<aedornv>
well, yes actually... but I narrowed it down to 561 specific files that can't be seen. And I'm no mathematical genius, but I'm quite certain 2545-2250 != 561.
zzing has quit [Quit: Computer has gone to sleep.]
_br_ has joined #ruby
jonahR_ has joined #ruby
Morkel has joined #ruby
<DDark>
hmm maybe I just need a break from it :) Ill keep stabbing at it though.
daniel_-_ is now known as daniel_-
daniel_- is now known as Guest6998
ffranz has joined #ruby
Guest6998 has quit [Quit: WeeChat 0.3.9.2]
<kalleth>
muahahaha, it works
daniel_-_ has joined #ruby
<kalleth>
aedornv: lol, a third consistency problem?
miskander has joined #ruby
<kalleth>
part of having used windows for 15 years+ is that you Just Accept when things like this happen ;)
<DDark>
The real hashes look like >{"class2"=>{"k"=>"v2"}}<. That is the one entered by the user. This one >{"class2"=> {"k"=>"v1", "k2"=>"v"}>, "class1"=>nil, "test"=> {"k"=>"v"}>}< is what needs to be updated.
huoxito has joined #ruby
<DDark>
So I should probably iterate of the hash needed update and match the key and set the value with a hash[key] = x?
jonahR has quit [Ping timeout: 260 seconds]
jonahR_ is now known as jonahR
<shevy>
DDark yeah, the simplest and stupidest way to solve it
<kalleth>
awesome
<shevy>
you just build a new hash, with the layout you will need
<kalleth>
i've basically reimplmented spotify radio in youtube
<kalleth>
:D
<kalleth>
*in ruby
<kalleth>
using youtube
<DDark>
ok. Thanks for the input. Just didnt want to go down a wrong path.
beiter has joined #ruby
ananthakumaran has quit [Quit: Leaving.]
baba has joined #ruby
apok has joined #ruby
unix has quit [Ping timeout: 248 seconds]
carlyle has joined #ruby
skepti has joined #ruby
octoberry has quit [Ping timeout: 248 seconds]
breakingthings has joined #ruby
sk87 has quit [Quit: Computer has gone to sleep.]
BrindleFly has joined #ruby
Takehiro has quit [Remote host closed the connection]
rgsteele has quit [Remote host closed the connection]
ananthakumaran has joined #ruby
topper has joined #ruby
<topper>
heyo
<topper>
anyone here know about the 1.7.3 jruby security release?
choffstein has quit [Remote host closed the connection]
blaxter has quit [Quit: foo]
ananthakumaran has quit [Client Quit]
<lethjakman>
kalleth: why wouldn't yuo switch to linux or something?
<kalleth>
lethjakman: gamer
swex has joined #ruby
<lethjakman>
kalleth: I tend to dual boot, linux is just so much easier than widows for development
<aedornv>
I see
<kalleth>
lethjakman: i don't like rebooting each time i want to play a game :)
<kalleth>
and i dev on my work laptop generally
<kalleth>
or use VM's
<kalleth>
but if this is a script i want to run nightly, can't really have a vm running each night
<kalleth>
i *could* script the vm boot then run script on vm then shut down, but its 'easier' for a script of this size
<aedornv>
it's 64 bit vs 32 bit command prompts
<lethjakman>
that's true, I just hate working in windows lol
<aedornv>
If you run the 64 bit command prompt, which is the default link when you run from explorer (so \windows\system32 actually redirects to \windows\syswow64) you can't see the files in system32, because of the redirect.
<kalleth>
aedornv: seriously?
<kalleth>
bhahahahahaha
<aedornv>
and vice versa..
<kalleth>
GJ windows
<aedornv>
so uh .. yeah
<lethjakman>
no way....
<lethjakman>
that's the dumbest thing I've ever heard
<kalleth>
aedornv: that's worth a blog article
Choclo has joined #ruby
<kalleth>
or something somewhere showing what you worked out
vikhyat has quit [Remote host closed the connection]
<aedornv>
Only applies on 64 bit systems, of course, but that is pretty ridiculous. The interesting thing is that using "start command prompt with ruby" link actually tosses you into the 64 bit command line shell to run a 32 bit executable.
<lethjakman>
hey, when should I use an @ vs no @? they both look like variables to me, am I wrong?
<aedornv>
Windows makes my head hurt
<Choclo>
depends on the scope
ddv has quit [Changing host]
ddv has joined #ruby
<lethjakman>
what do you mean Choclo
<Hanmac>
lethjakman: @vars are instance variables, without@ are local ones ... local ones die after the scope is closed
<kalleth>
aedornv: please, please write that up somewhere
<Choclo>
@ is an instance variable
<lethjakman>
ahhhh that makes sense
decoponio has quit [Quit: Leaving...]
<lethjakman>
is an instance like a static?
<Choclo>
can only be used within the object
pkrnj has joined #ruby
generalissimo has joined #ruby
<Hanmac>
lethjakman hm i dont think so ... @@ ones with are class variables are like static
<Hanmac>
but @instance variables inside the class itself is more cool
gyre007 has quit [Ping timeout: 256 seconds]
<lethjakman>
Hanmac: couldn't you just declare variables without the @ in the class and it would stay within the scope of the class?
mattbl has quit [Quit: This computer has gone to sleep]
r0bby has quit [Ping timeout: 276 seconds]
<Choclo>
lethjakman: it's messy
Jamone has joined #ruby
<lethjakman>
so if I use a variable with an @ inside of def fname1 it'll be available within def fname2 inside of that same class?
<Hanmac>
yeah
<Hanmac>
(and other methods in the object that called fname1)
colonolGron has joined #ruby
<Choclo>
except the method is private
<Choclo>
*if
<lethjakman>
Hanmac: called it? or have the ability to call it?
PanPan_ has joined #ruby
<Hanmac>
called it
TomJ has joined #ruby
TomJ has quit [Changing host]
TomJ has joined #ruby
<lethjakman>
so I would have to call fname2 within fname1 for that instance variable to exist?
<Hanmac>
like obj.fname1
<DDark>
Yeah h.update(newhash) works, but it drops the existing values and simply overwrites the value passed. How can I keep the old values as well?
freakazoid0223 has joined #ruby
asepior2345234 has joined #ruby
Monie has quit [Ping timeout: 248 seconds]
<lethjakman>
ahhhh, so they'd be comparable to public variables within c++?
<lethjakman>
within a function
<DDark>
so h1={key => value, key1 => value1}, h2 = {key1 => value2}. using update it becomes h2 and doesnt keep the other keys...
<Hanmac>
lethjakman: no obj.fname1 && obj.fname2 works but obj1.fname1 && obj2.fname2 may works not because the @instance variable may not be set in obj2
budmang_ has joined #ruby
ffranz has quit [Ping timeout: 246 seconds]
<aedornv>
kalleth: eh, I don't do any blogging or anything..
mattbl has joined #ruby
budmang has quit [Read error: Operation timed out]
Astral_ has joined #ruby
tcstar has quit [Ping timeout: 264 seconds]
kristofers has joined #ruby
* Hanmac
is from a time where it was called "block"ing and it was called "tetris" :P
<kalleth>
aedornv: you should :)
<kalleth>
would be good for others to know
graft has joined #ruby
gaahrdner has joined #ruby
<kalleth>
might write it up myself then with credit :)
<kalleth>
if you don't mind?
PanPan_ has quit [Ping timeout: 264 seconds]
browndawg has quit [Quit: Leaving.]
<aedornv>
eh, knowledge is everyone's property; credit is overrated.
justme1 has joined #ruby
BrindleFly has quit [Quit: BrindleFly]
mfridh has quit [Read error: Connection reset by peer]
RJ3 has quit [Ping timeout: 256 seconds]
karnowski has quit [Read error: Operation timed out]
anderse has quit [Read error: Operation timed out]
RJ3_ has joined #ruby
kirun has joined #ruby
Astralum has quit [Ping timeout: 256 seconds]
RJ3_ is now known as RJ3
<Hanmac>
the only thing that is similar to a blog i did is my commit history :P
JMcAfreak has left #ruby ["Still here. /msg me if you really really need me."]
adman65 has joined #ruby
anderse has joined #ruby
<justme1>
can I use a instance class variable inside of a class method?
<aedornv>
Hmmm... I like to imagine my commit history reads like a romantic comedy!
<banisterfiend>
justme1: yeah
mfridh has joined #ruby
<justme1>
banisterfiend: why is that?
<banisterfiend>
justme1: because ruby allows it
<justme1>
banisterfiend: but what's the logic behind it? why would it be useful?
razibog has quit [Ping timeout: 252 seconds]
<Hanmac>
justme1 i think that is the only good place where you can use class instance variables
<banisterfiend>
justme1: because a class is just an object, and as it's an object it can have ivars and methods
<banisterfiend>
and just like any object, those ivars are accessible to its methods
<banisterfiend>
justme1: it's possible because it's a necessary consequence of the object model
dross has quit [Ping timeout: 276 seconds]
pyrac has quit [Quit: pyrac]
<justme1>
banisterfiend: but should it be @@?
<Hanmac>
no
<banisterfiend>
justme1: no, it can just be @var
asepior2345234 has quit [Quit: Leaving]
fenak has joined #ruby
<banisterfiend>
justme1: but really, at this point you should probably post a gist because you could just have been using bad terminology
<justme1>
banisterfiend: one sec
Choobie has quit [Remote host closed the connection]
<banisterfiend>
justme1: what's the problem with that code
<banisterfiend>
if this is on ruby 1.9+ it will fail due to the .to_s
Myk267 has joined #ruby
<justme1>
banisterfiend: yeah, I'm aware of 1.9+
<banisterfiend>
you could very easily make it 1.9 safe :)
arya has quit [Ping timeout: 248 seconds]
hashmal is now known as the_meme
<banisterfiend>
justme1: anyway, waht's the issue
<justme1>
banisterfiend: my problem is with @hidden_methods
<justme1>
banisterfiend: from my understanding, it should have been @@hidden_methods
tjwallace has left #ruby [#ruby]
Takehiro has quit [Ping timeout: 240 seconds]
main has quit [Remote host closed the connection]
apeiros_ has joined #ruby
<justme1>
banisterfiend: this is a class method, therefore it should be class "static" variable,with @@
<banisterfiend>
justme1: no, @hidden will work fine (depending on what u want to do)
m3pow has quit [Read error: Connection reset by peer]
<justme1>
banisterfiend: ok, so let me ask you this: when will I want to use @ in class methods?
<banisterfiend>
justme1: @@var is just used when u want both the *class* and instances *and* subclasses and *their* instances to share the variable (which is never really a good idea)
anderse has quit [Quit: anderse]
<banisterfiend>
justme1: when you want to store state on the class itself
<banisterfiend>
just the class
<banisterfiend>
not on instances, not on subclasses, etc
<justme1>
banisterfiend: ok, that's sounds reasonable. so on instances of a class, I can't access this variable?
Catbuntu has joined #ruby
<banisterfiend>
right, you can't
<justme1>
oh
<justme1>
banisterfiend: ok, cool
<banisterfiend>
justme1: but you can trivially expose it, if you want
<justme1>
banisterfiend: thanks
<banisterfiend>
just via a method
<justme1>
hmmm
<justme1>
wait
irving has left #ruby [#ruby]
shevy has joined #ruby
m3pow has joined #ruby
Elhu has joined #ruby
<justme1>
banisterfiend: if I def method @hidden_methods; end and call method on an instance of BlankState, I could get the value of @hidden_methods?
khismeti_ has quit [Quit: Computer has gone to sleep.]
<justme1>
banisterfiend: or you mean self.method @hidden_methods; end
<banisterfiend>
justme1: that's right, you can't get it
<justme1>
banisterfiend: and then I could call this class method
the_meme is now known as hashmal
<banisterfiend>
yes, call teh class method
<justme1>
banisterfiend: ok, I think I got it. Thanks!
the_mentat has quit [Quit: Computer has gone to sleep.]
<justme1>
banisterfiend: btw, theoretically speaking I could have two variables with the same name for the class and the class instances, right?
banisterfiend has quit [Remote host closed the connection]
sebkomianos has quit [Quit: sebkomianos]
banisterfiend has joined #ruby
<banisterfiend>
justme1: yup, they're totally different objects
the_mentat has joined #ruby
<justme1>
banisterfiend: I thought you got disconnected and didn't get a chance to see my last question, but it appears as you did look at it.
<justme1>
that's for now, I'll keep on reading metaprogramming ruby :)
strtok has quit [Ping timeout: 276 seconds]
_nitti has quit [Remote host closed the connection]
mengu has joined #ruby
kold has quit [Remote host closed the connection]
reset has joined #ruby
daniel_-_ is now known as daniel_-
daniel_- has quit [Quit: WeeChat 0.3.9.2]
nomenkun has quit [Remote host closed the connection]
skattyadz has quit [Quit: skattyadz]
timwis has joined #ruby
timonv has joined #ruby
nomenkun has joined #ruby
pavilionXP has quit [Quit: Forget progress by proxy. Land on your own moon.]
justme1 has quit [Quit: Leaving.]
<timwis>
Hey guys, I've never worked in Ruby before. I'm creating a static html/javascript site and I have a config.ru and Gemfile so I can deploy to heroku. It works fine, but I'd like to run it locally. Do I need some kind of .rb file to do that?
Qwak has joined #ruby
timonv_ has joined #ruby
timonv has quit [Read error: Connection reset by peer]
<reactormonk>
timwis, rackup config.ru
thams has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
nomenkun has quit [Ping timeout: 256 seconds]
<timwis>
reactormonk, hm, getting a permission denied error it seems http://codepad.org/4T5wuoKB ... googling to make sure cloud9 doesn't block it
MartinCleaver has joined #ruby
MartinCleaver has joined #ruby
MartinCleaver has quit [Changing host]
<reactormonk>
timwis, rackup -p 3000
<timwis>
oh!
<timwis>
rackup -p $PORT -o $IP
<timwis>
woot! thanks reactormonk!
<timwis>
how do i kill it
<reactormonk>
timwis, you can use that localhost, you know
<timwis>
reactormonk, i'm actually running it "locally" on cloud9
<reactormonk>
timwis, how do you kill a command-line command?
<timwis>
oh, n/m, ctrl+c did it
Qodosh has joined #ruby
<timwis>
sorry, I'm really new to command line stuff
jpcamara has quit [Quit: jpcamara]
sonda has quit [Remote host closed the connection]
<timwis>
i actually use windows :/
<reactormonk>
buuh :-P
<timwis>
but i'm learning!
<reactormonk>
good :-)
enebo has quit [Quit: enebo]
dankest has joined #ruby
AntiTyping has joined #ruby
khismeti_ has joined #ruby
rupee has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
timwis has quit [Quit: Page closed]
apeiros_ has quit [Remote host closed the connection]
timonv_ has quit [Read error: Connection reset by peer]
maligree has quit [Quit: I've had it.]
`p has quit [Quit: Leaving]
mercwithamouth has joined #ruby
AntiTyping has quit [Quit: AntiTyping]
gosshedd has quit [Read error: Operation timed out]
Catbuntu has quit [Quit: RETARDEDS EVERYWHERE]
_nitti has joined #ruby
francisfish has joined #ruby
damrkul333 has joined #ruby
khismeti_ has quit [Quit: Computer has gone to sleep.]
damrkul has quit [Ping timeout: 256 seconds]
<aedornv>
so if they put DRM in HTML5 ... I'm going to assume Linux people will be entirely screwed even further from online content. <insert doom speech here>
<Amnesia>
aedornv: why, you can rip everything
<Hanmac>
aedornv: thats the rule of life ... if something exist it can be copied ...
<aedornv>
Well, point being that for those of us who like to be legal to avoid the rape-you-in-the-ass-MPAA/RIAA-the-world-is-ending-because-of-piracy-lawsuits in the great land of the United States of America, it's a bit of a pain in the ass to try and figure out what works with what implementation of DRM. If it's a web technology, and web tech is really trying to be "cross-platform" then why the hell would anyone want DRM in HTML5? Bes
<aedornv>
ides the corporate mongers who think it actually does something worth while, obviously.
rlb3 has quit [Quit: rlb3]
peregrine81 has quit [Quit: Goodbye.]
swex_ has joined #ruby
swex has quit [Ping timeout: 248 seconds]
jgarvey has quit [Quit: Leaving]
pyreal has quit [Quit: pyreal]
<whitequark>
aedornv: simply continue to use torrents as one could do before
justsee has quit [Quit: Leaving...]
adman65 has quit [Quit: adman65]
<whitequark>
if these people don't want you to pay, they won't get anything.
jrajav has quit [Quit: I tend to be neutral about apples]
Coolhand has quit [Remote host closed the connection]
BoomCow has quit [Quit: Leaving]
Mo0O has quit [Ping timeout: 248 seconds]
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
moshee has quit [Ping timeout: 276 seconds]
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
Mo0O has joined #ruby
jacobw has quit [Quit: WeeChat 0.4.0]
carraroj has quit [Quit: Konversation terminated!]
macq has quit [Ping timeout: 255 seconds]
jacobw has joined #ruby
macq has joined #ruby
reset has joined #ruby
TDJACR has joined #ruby
carloslopes has quit [Remote host closed the connection]
khismeti_ has quit [Quit: Computer has gone to sleep.]
<aedornv>
Oh well, back to testing code.. DRM free.
feedbackloop has quit [Read error: Connection reset by peer]
adkron has quit [Ping timeout: 260 seconds]
chrishough has quit [Quit: chrishough]
feedbackloop has joined #ruby
mattbl is now known as MattRB
Myk267 has quit [Read error: Connection reset by peer]
jpcamara has quit [Quit: jpcamara]
fschuindt has joined #ruby
kiwnix has joined #ruby
kofno has quit [Remote host closed the connection]
brianpWins has quit [Quit: brianpWins]
colonolGron has joined #ruby
Todd has quit [Remote host closed the connection]
gtc has quit [Quit: kill -9 gtc]
lmg_ has joined #ruby
francisfish has quit [Remote host closed the connection]
pyrac has quit [Quit: pyrac]
gaahrdner has quit [Remote host closed the connection]
MattRB has quit [Quit: This computer has gone to sleep]
chrisja has quit [Quit: leaving]
twoism has quit [Remote host closed the connection]
Al__ has joined #ruby
octoberry has joined #ruby
twoism has joined #ruby
Vert has joined #ruby
peteyg has joined #ruby
daniel_- has joined #ruby
chrishough has joined #ruby
gregor3005 has joined #ruby
karnowski has joined #ruby
gregor3005 has left #ruby [#ruby]
bluOxigen has quit [Ping timeout: 256 seconds]
rmartin_ has quit [Remote host closed the connection]
axl_ has quit [Quit: axl_]
sailias has quit [Quit: Leaving.]
hashpuppy has left #ruby [#ruby]
axl_ has joined #ruby
bricker_ has joined #ruby
mando has joined #ruby
Kingy has joined #ruby
bricker has quit [Ping timeout: 264 seconds]
bubblehead has quit [Remote host closed the connection]
Elhu has quit [Quit: Computer has gone to sleep.]
Coolhand has joined #ruby
_nitti has quit [Remote host closed the connection]
brianpWins has joined #ruby
anonymuse has quit [Remote host closed the connection]
txdv has quit [Ping timeout: 245 seconds]
codecop has quit [Remote host closed the connection]
havenwood has quit [Remote host closed the connection]
chrishough has quit [Quit: chrishough]
<shevy>
putting DRM into HTML5 is really a traiterous act by the W3 consortium
jiveturkey has joined #ruby
chrishough has joined #ruby
mephux has quit [Excess Flood]
<shevy>
*traitorous
twshelton has joined #ruby
<whitequark>
shevy: the consortium is composed of representatives from various companies
<shevy>
hmm anyone has an idea ...
<whitequark>
Apple, etc.
<whitequark>
so no, it isn't
<whitequark>
the notion that it serves your best interests is misleading.
carloslopes has joined #ruby
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
<shevy>
but Tim Berners-Lee wasn't working for apple
mephux has joined #ruby
skattyadz has joined #ruby
<shevy>
he is killing his own legacy with that
<whitequark>
shevy: Tim Berners-Lee invented "semantic web"
angusiguess has joined #ruby
arturaz has quit [Read error: Connection reset by peer]
xbayrockx has joined #ruby
xbayrockx is now known as wf2f
<whitequark>
which is utter bullshit if you know anything about how the current web works
<shevy>
"The World Wide Web Consortium (W3C) is the main international standards organization for the World Wide Web (abbreviated WWW or W3). Founded by Tim Berners-Lee at MIT and currently headed by him,[2] the consortium is made up of ..."
<whitequark>
*shrug*
<shevy>
never got semantic web
<shevy>
wasn't that the thing that died quite silently?
<shevy>
or are those the tag clouds hehehe
slainer68 has joined #ruby
Criztian has quit [Remote host closed the connection]
failshell has quit [Remote host closed the connection]
<shevy>
ok
<shevy>
is there a way to permanently restart a .rb script, from bash?
<shevy>
I used to be able to do this via dcop on kde 3
<aedornv>
as in restart it if it stops... forever?
<shevy>
aedornv hmm on quit-event or exit
biff_tannen has quit [Read error: Connection reset by peer]
__BigO__ has quit [Remote host closed the connection]
<shevy>
as if it would be a continually running background process that tries to start again
<shevy>
I forgot why I wanted to have this though
<shevy>
it does not sound very useful as I type this :\
stringoO has quit [Quit: stringoO]
carloslopes has quit [Ping timeout: 264 seconds]
<aedornv>
eh, that would require a monitor of a process, but technically while :; do ruby scrpt.rb; done would restart it if that script stopped
<aedornv>
(assuming said script doesn't daemonize itself)
topper has quit [Quit: Leaving.]
stringoO has joined #ruby
<aedornv>
I guess you could also spawn the script again from within it by trapping SIGINT or other signals too
razibog has joined #ruby
CraHan is now known as CraHan|out
dark_soul has joined #ruby
TheFuzzball has quit [Quit: Leaving...]
dark_soul has left #ruby [#ruby]
hbpoison has quit [Ping timeout: 256 seconds]
hbpoison has joined #ruby
<shevy>
aedornv now that sounds cool
bitpimp has joined #ruby
<shevy>
the ultimate ruby zombie process, too dumb to respond to any SIGs
cupakrom_ has joined #ruby
<whitequark>
aedornv: -9 can't be trapped
<bitpimp>
I have ruby 1.8.7 running on a server and took my rails app offline when the rails exploit appeared; I now need to update rails; what's the quick and dirty? I am only running one rails app.
kirun has quit [Quit: Client exiting]
BrianJ has quit [Quit: Computer has gone to sleep.]
schaerli has quit [Remote host closed the connection]
mmitchell has quit [Remote host closed the connection]
<bitpimp>
what version does 'gem install rails' install by default, or how does it choose?
aedornv has quit [Quit: Leaving]
twshelton has joined #ruby
<shevy>
bitpimp I think there must be a file pointing at the version
<shevy>
by default I would assume always the latest in the main repo
zyrex has joined #ruby
gatopan has joined #ruby
<apok>
bitpimp, shevy: it's whatever rails uploads to rubygems, by policy, the latest version of rails
woolite64__ has joined #ruby
sailias has joined #ruby
pkrnj has quit [Ping timeout: 264 seconds]
zoonfafer has joined #ruby
forrest has quit [Quit: Leaving]
alanp_ has joined #ruby
wmoxam has quit [Ping timeout: 255 seconds]
interactionjaxsn has quit [Remote host closed the connection]
willob has quit [Quit: Leaving.]
sailias has quit [Client Quit]
alanp has quit [Read error: Connection reset by peer]
Monie has joined #ruby
alanp_ is now known as alanp
ebobby has joined #ruby
willob has joined #ruby
ryanw_ has joined #ruby
willob has quit [Max SendQ exceeded]
zul_ has joined #ruby
zul_ has quit [Read error: Connection reset by peer]
woolite64_ has quit [Ping timeout: 276 seconds]
ryanw_ has quit [Remote host closed the connection]
haxrbyte_ has quit [Remote host closed the connection]
willob has joined #ruby
brum has joined #ruby
niklasb has quit [Ping timeout: 255 seconds]
zul_ has joined #ruby
regedarek has quit [Ping timeout: 260 seconds]
zul_ has quit [Client Quit]
zul_ has joined #ruby
nari has joined #ruby
<bitpimp>
shevy, apok ok sweet thx
<zul_>
hi all could you help me in a very stupid thing. I want to assign to a string variable ex a a value that is an html, but when I do it I get an exception due to the escaping
<aces1up>
how would you guys suggest decoding a base64 string that has both base64 encoded data and regular text, and I don't know what the regular text would be as its dynamic..
<aces1up>
otherwise i would strip it out.
jimeh has quit [Quit: Computer has gone to sleep.]
<zul_>
thanks a lot brum
<zul_>
it work :)))
pandawarrior1 has joined #ruby
ckrailo has joined #ruby
sepp2k has quit [Remote host closed the connection]
haxrbyte has joined #ruby
<zul_>
thanks all, bye
topper has joined #ruby
octoberry has quit [Ping timeout: 264 seconds]
zul_ has quit [Quit: Ex-Chat]
frem has quit [Quit: Computer has gone to sleep.]
paolooo has quit [Quit: Page closed]
paolooo has joined #ruby
onlinenickid has joined #ruby
_br_ has quit [Excess Flood]
techhelp has quit [Quit: This computer has gone to sleep]
_br_ has joined #ruby
horofox has quit [Quit: horofox]
mjanssen has quit [Quit: Bye]
geggam_wk has quit [Remote host closed the connection]
topper has left #ruby [#ruby]
dmerrick has quit [Quit: dmerrick]
alx- has quit [Ping timeout: 248 seconds]
niklasb has joined #ruby
_br_ has quit [Excess Flood]
pavilionXP has quit [Ping timeout: 256 seconds]
_br_ has joined #ruby
TheFuzzball has quit [Quit: Computer has gone to sleep.]
trietptm has quit [Quit: Page closed]
axl_ has quit [Quit: axl_]
maxmanders has quit [Quit: Computer has gone to sleep.]
emmanuelux has joined #ruby
tcstar has quit [Ping timeout: 248 seconds]
apeiros_ has joined #ruby
chendo_ has quit [Ping timeout: 255 seconds]
NemesisD has joined #ruby
alx- has joined #ruby
zoonfafer has quit [Ping timeout: 264 seconds]
chendo_ has joined #ruby
chendo_ has quit [Changing host]
chendo_ has joined #ruby
apeiros_ has quit [Ping timeout: 248 seconds]
tylersmith has joined #ruby
pskosinski has quit [Ping timeout: 260 seconds]
jonahR has quit [Quit: jonahR]
alx- has quit [Ping timeout: 276 seconds]
jonahR has joined #ruby
onlinenickid has quit [Quit: Nettalk6 - www.ntalk.de]