banisterfiend has quit [Remote host closed the connection]
mikeric has joined #ruby-lang
dv310p3r has joined #ruby-lang
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
diegoviola has quit [Ping timeout: 252 seconds]
mikeric has quit [Quit: mikeric]
gix has quit [Ping timeout: 244 seconds]
sora_h is now known as s0ra_h
diegoviola has joined #ruby-lang
gix has joined #ruby-lang
plen has joined #ruby-lang
s0ra_h is now known as sora_h
banisterfiend has joined #ruby-lang
lele has quit [Ping timeout: 272 seconds]
retro|cz has joined #ruby-lang
dv310p3r has quit [Ping timeout: 252 seconds]
diegoviola has quit [Read error: Operation timed out]
mistym has joined #ruby-lang
perryh is now known as perry
statim has joined #ruby-lang
<statim>
is it possible to have a gem compile some non-ruby piece of software (./configure… make) during its install process by using the native extensions hook?
nertzy has joined #ruby-lang
diegoviola has joined #ruby-lang
setmeaway has quit [Ping timeout: 244 seconds]
<banisterfiend>
statim: yeah but it's not necessarily easy
dfr|mac has joined #ruby-lang
dfr|mac_ has joined #ruby-lang
dfr|mac has quit [Ping timeout: 255 seconds]
dfr|mac has joined #ruby-lang
dfr|mac has quit [Read error: Connection reset by peer]
fromhet_ has quit [Quit: fromhet_]
dfr|mac has joined #ruby-lang
dfr|mac_ has quit [Read error: Connection reset by peer]
dfr|mac has quit [Read error: Connection reset by peer]
dfr|mac has joined #ruby-lang
Torrieri has joined #ruby-lang
dfr|mac has quit [Read error: Connection reset by peer]
dfr|mac has joined #ruby-lang
dfr|mac_ has joined #ruby-lang
dfr|mac_ has quit [Read error: Connection reset by peer]
dfr|mac__ has joined #ruby-lang
dfr|mac has quit [Ping timeout: 245 seconds]
imperator has joined #ruby-lang
petercooper has quit [Remote host closed the connection]
plen has quit [Ping timeout: 264 seconds]
dfr|mac__ has quit [Read error: Connection reset by peer]
dfr|mac has joined #ruby-lang
dfr|mac has quit [Read error: Connection reset by peer]
dfr|mac has joined #ruby-lang
dfr|mac has quit [Read error: Connection reset by peer]
dfr|mac has joined #ruby-lang
dfr|mac_ has joined #ruby-lang
x0F_ has joined #ruby-lang
dfr|mac has quit [Read error: Connection reset by peer]
x0F has quit [Ping timeout: 246 seconds]
dfr|mac__ has joined #ruby-lang
dfr|mac_ has quit [Ping timeout: 245 seconds]
savage- has joined #ruby-lang
neoesque has joined #ruby-lang
tr-808 has quit [Remote host closed the connection]
jxie has quit [Ping timeout: 264 seconds]
tr-808 has joined #ruby-lang
tr-808_ has joined #ruby-lang
Torrieri has quit [Ping timeout: 244 seconds]
dfr|mac__ has quit [Remote host closed the connection]
banisterfiend has quit [Remote host closed the connection]
t_ has quit [Remote host closed the connection]
dfr|mac has joined #ruby-lang
postmodern has joined #ruby-lang
stardiviner has joined #ruby-lang
diegoviola has quit [Read error: Operation timed out]
stardiviner has quit [Read error: Connection reset by peer]
dfr|mac has quit [Remote host closed the connection]
banisterfiend has joined #ruby-lang
msaffitz has quit [Quit: Computer has gone to sleep.]
woollyams has joined #ruby-lang
diegoviola has joined #ruby-lang
msaffitz has joined #ruby-lang
msaffitz has quit [Client Quit]
macmartine has quit [Quit: macmartine]
Torrieri has joined #ruby-lang
Torrieri has joined #ruby-lang
Torrieri has quit [Changing host]
msaffitz has joined #ruby-lang
ramonmaruko has quit [Remote host closed the connection]
dalekurt has quit [Quit: Zzz...]
hahuang65 has joined #ruby-lang
fbernier has joined #ruby-lang
dalekurt has joined #ruby-lang
ramonmaruko has joined #ruby-lang
stardiviner has joined #ruby-lang
Torrieri has quit [Ping timeout: 246 seconds]
umttumt has joined #ruby-lang
andrewhl has joined #ruby-lang
heftig has quit [Ping timeout: 245 seconds]
srbartlett has quit [Remote host closed the connection]
Raduwen has quit [Quit: Leaving...]
savage- has quit [Remote host closed the connection]
lsegal has joined #ruby-lang
andrewhl has quit [Remote host closed the connection]
slyphon has quit [Ping timeout: 245 seconds]
fbernier has quit [Ping timeout: 245 seconds]
ryanf has joined #ruby-lang
savage- has joined #ruby-lang
macmartine has joined #ruby-lang
imperator has quit [Ping timeout: 250 seconds]
heftig has joined #ruby-lang
macmartine has quit [Quit: macmartine]
macmartine has joined #ruby-lang
macmartine has quit [Read error: Connection reset by peer]
macmartine has joined #ruby-lang
<scientes>
this C extension i am dealing with needs (METHOD) casting on its rb_define_method calls
<scientes>
but this breaks rdoc
<scientes>
what can i do?
<scientes>
"kyotocabinet.cc:975:47: error: invalid conversion from ‘VALUE (*)(VALUE, VALUE) {aka long unsigned int (*)(long unsigned int, long unsigned int)}’ to ‘VALUE (*)(...) {aka long unsigned int (*)(...)}’ [-fpermissive]
<scientes>
/usr/include/ruby-1.9.1/ruby/ruby.h:1084:6: error: initializing argument 3 of ‘void rb_define_method(VALUE, const char*, VALUE (*)(...), int)’ [-fpermissive]
<scientes>
"
postmodern has quit [Quit: Leaving]
<bnagy>
is there still no ffi wrapper for KC?
<scientes>
there is a .idl file, would that be sufficient?
<scientes>
upstream's bindings are certainly native
postmodern has joined #ruby-lang
<scientes>
the bindings also work, its just that the "show source" doesn't work in the docs
<banisterfiend>
bnagy: who's KC? your gf?
<bnagy>
KyotoCabinet
<bnagy>
it's the DB that the TokyoCabinet guy is trying to convince people to move to
<bnagy>
but TC has a really nice FFI lib called oklahoma_mixer, and KC has a really hideous C ext
<scientes>
are c extensions really that hideous?
<scientes>
or do you just not like compiling?
<scientes>
its a thread safe binding
<bnagy>
FFI is easier to modify and plays better with jruby etc
<bnagy>
but mainly I meant that the API is hideous
wallerdev has quit [Quit: wallerdev]
<scientes>
well then write a new FFI lib to it :)
neoesque has quit [Ping timeout: 245 seconds]
<scientes>
using oklahoma_mixer as a guide
<bnagy>
... or just use oklahoma mixer
<scientes>
its obvious from my look at it that the writer of KC doesn't use ruby, by how the docs ended up
<scientes>
but i could be wrong
<bnagy>
it's not that I'm against doing work, but I'm against it when it buys me ~0 benefit
<bnagy>
although thread safety would be nice
<scientes>
(thread safe with ruby1.9 only)
<bnagy>
I browsed the api and didn't see atomic operations etc though?
<bnagy>
but mainly I was just barfing at the examples :(
<scientes>
it has them, through the KyotoCabinet::Visitor
<scientes>
it also misdocuments instance vs class methods
<bnagy>
so you can do a threadsafe get then set, without races?
<scientes>
not sure, but it said it was thread safe
<Asher>
yeah the docs are terrible
<Asher>
and they didn't implement sorting from ruby either
<scientes>
and the kyotocabinet shared lib supports atomics
<scientes>
at thread safety
<bnagy>
hm, ok that's almost worth looking at then
<Asher>
what does non-atomic mean in the context of KC?
<bnagy>
cause I used redis for some stuff like that, but the network interface was so much slower than I needed 4 threads just to break even with TC
* scientes
things bnagy is talking about gcc memory atomicity that kyotocabinet uses
<bnagy>
hang on
<scientes>
but could also be the locking primitives, which work best with hash dbs
<banisterfiend>
Asher: are you jelly that im in linux journal, does it make u mad bro
<ryanf>
haha
<banisterfiend>
Asher is a great trolling target, i've yet to see him take the bait
<banisterfiend>
maybe that makes him a bad trolling target..
<Asher>
i thought they got rid of that a few versions ago
<scientes>
nah, this was the latest version
arooni-mobile has quit [Quit: Leaving]
<scientes>
so noone knows how i can get around rdoc not liking (METHOD) casts?
igotnolegs has quit [Quit: Computer has gone to sleep.]
msaffitz has quit [Quit: Computer has gone to sleep.]
<banisterfiend>
scientes: both rdoc and yard use very simple c parsers (just regexes iirc) so they tend to break on anything that is a little bit unusual, in my experience
<scientes>
thats what i assumed (and feared)
<scientes>
i tried just removing the casts, but it wont build without them
<banisterfiend>
scientes: c++ compiler
<banisterfiend>
?
jd has quit [Read error: Connection reset by peer]
<scientes>
yeah
<banisterfiend>
scientes: hmm
mistym has quit [Remote host closed the connection]
<banisterfiend>
scientes: you may have to document them as stubs in ruby, and when the .so file is loaded it overwrites those methods with the full implementation
<banisterfiend>
i've used that approach before
<scientes>
banisterfiend, yeah that is what already exists, but then you click "view source" and it doesn't tell you anything
<banisterfiend>
scientes: Yeah
<scientes>
which is stupid
<banisterfiend>
scientes: maybe u could do the cast outside the rb_define_method
<banisterfiend>
scientes: and then just pass in the casted function pointer inside the rb_define_method
<banisterfiend>
METHOD hi = (METHOD)your_function_pointer;
<scientes>
thats kinda ugly
<scientes>
but yeah that is probably the only solution that will work with existing rdoc
<scientes>
looks like it already handles those casts
<scientes>
maybe i can use one of those
xtagon has quit [Ping timeout: 246 seconds]
ruurd has joined #ruby-lang
nertzy has quit [Quit: This computer has gone to sleep]
Pip has joined #ruby-lang
zmack has joined #ruby-lang
Pip has quit [Read error: Connection reset by peer]
yxhuvud has joined #ruby-lang
dalekurt has quit [Quit: Zzz...]
lele has joined #ruby-lang
setmeaway has joined #ruby-lang
burgestrand has quit [Quit: Leaving.]
gouthamvel has joined #ruby-lang
gouthamvel has left #ruby-lang [#ruby-lang]
<erikh>
herp
apeiros_ has joined #ruby-lang
VGoff is now known as VGoff_afk
tjadc has quit [Ping timeout: 264 seconds]
srbartlett has joined #ruby-lang
solars has joined #ruby-lang
woollyams has quit [Quit: Computer has gone to sleep.]
savage- has quit [Remote host closed the connection]
setmeaway has quit [Read error: Connection reset by peer]
diegoviola has quit [Ping timeout: 248 seconds]
dhruvasagar has joined #ruby-lang
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
j342 has joined #ruby-lang
j342 has quit [Client Quit]
scientes has quit [Read error: Operation timed out]
mikeric has joined #ruby-lang
ryanf has quit [Ping timeout: 255 seconds]
srbartlett has quit [Remote host closed the connection]
tallship has joined #ruby-lang
qwerxy has joined #ruby-lang
setmeaway has joined #ruby-lang
burgestrand has joined #ruby-lang
diegoviola has joined #ruby-lang
<yorickpeterse>
Are there any resources that compare the technical differences between RVM and rbenv? With RVM getting ever more bloated I'm curious to see if rbenv would be a viable alternative.
perry is now known as perryh_away
<bnagy>
I saw a good one..
<yorickpeterse>
Preferrably a somewhat unbiased source :)
<yorickpeterse>
My main dislike of RVM is that it now comes with rubygems-bundler and quite possibly other crap in the future
<bnagy>
no offense to the rvm guys, but my main dislike has always been that it's not unixlike in any way
<bnagy>
I used it when it was the only viable alternative
NeVeR_ has joined #ruby-lang
<bnagy>
soon as I saw rbenv I was like, ok, right, shims, yes. That's how I would have done it.
<yorickpeterse>
Well, I'm not sure if I agree with the shim approach though
<yorickpeterse>
Though I suppose it's cleaner than overriding `cd`
<bnagy>
then check rbfu :)
<banisterfiend>
bnagy: type 'rvm help' for lulz
<bnagy>
-bash: rvm: command not found
<bnagy>
lulz
<banisterfiend>
the scariest help i've ever seen
<banisterfiend>
bnagy: haha
ohsix has quit [Ping timeout: 244 seconds]
<bnagy>
if you're a unix / security guy coming to rvm, and the very first thing is 'ok now type curl ... | bash ...'
<bnagy>
you go like this: :|
vmoravec has joined #ruby-lang
ohsix has joined #ruby-lang
<banisterfiend>
bnagy: is it easy to upgrade ruby versions in rbenv?
<banisterfiend>
bnagy: and it'll keep the installed gems from the previous version?
<banisterfiend>
so i can upgrade 1.9.3 to the latest patchlevel
<bnagy>
dunno, haven't done so yet
<bnagy>
but I have a jruby head equiv installed
<matled>
banisterfiend: upgrading is easy, but the gems are lost by default. if you know how you can probably copy them over.
<bnagy>
so I just do git pull and ant
tjadc has joined #ruby-lang
NeVeR_ has quit [Remote host closed the connection]
pbjorklund has joined #ruby-lang
pbjorklu1d has quit [Read error: Operation timed out]
kitallis has joined #ruby-lang
judofyr has joined #ruby-lang
gsav has joined #ruby-lang
gsav has quit [Client Quit]
gsav has joined #ruby-lang
cdt has joined #ruby-lang
qwerxy has quit [Quit: offski]
fgomez has quit [Ping timeout: 256 seconds]
jbsan has quit [Quit: jbsan]
<yorickpeterse>
matled: doesn't gems being lost also happen with RVM?
sora_h is now known as s0ra_h
<matled>
yorickpeterse: I've no idea. I don't even now if it is safe to use gems compiled for another release, but probably the api is stable between patchlevels.
mikeric has quit [Quit: mikeric]
kaiwren has joined #ruby-lang
robotmay has joined #ruby-lang
shyouhei has joined #ruby-lang
thone has quit [Ping timeout: 240 seconds]
tomb___ has left #ruby-lang [#ruby-lang]
tomb has joined #ruby-lang
thone has joined #ruby-lang
shevy has joined #ruby-lang
futurechimp has joined #ruby-lang
seoaqua has joined #ruby-lang
gouthamvel has joined #ruby-lang
<seoaqua>
is there a gem to extract the main content ?
<seoaqua>
of a webpage
<yorickpeterse>
seoaqua: define main content
<yorickpeterse>
Also, there's Net::HTTP, HTTParty, Curb and friends for HTTP. Nokogiri for parsing XML/HTML
<yorickpeterse>
Mechanize for dealing with forms and such
banisterfiend` has joined #ruby-lang
<yorickpeterse>
(which is built using Nokogiri)
<seoaqua>
yorickpeterse, if i can define, i can write the gem myself
<yorickpeterse>
seoaqua: Nokogiri::HTML('html goes here').at_css('#main_content_selector_whatever') # not sure if the method was actually called at_css()
<yorickpeterse>
followed by #text() or whatever you need to do with the content
banisterfiend has quit [Ping timeout: 265 seconds]
<seoaqua>
nokogiri will also return the text of channels, related article, top clicked artitle etc
<seoaqua>
i need some tool to extract only the main text
<yorickpeterse>
You'll probably have to do that yourself
<yorickpeterse>
To be more exact, I don't know of any gem that does this for you
<rue>
Hm, actually, that reminds me…brew didn’t want to install rbfu
woollyams has joined #ruby-lang
_ko1 has joined #ruby-lang
<andrewvos>
rue: Didn't want to?
fromhet has quit [*.net *.split]
pbjorklund has quit [*.net *.split]
apeiros_ has quit [*.net *.split]
ramonmaruko has quit [*.net *.split]
x0F_ has quit [*.net *.split]
tofaffy has quit [*.net *.split]
tonni has quit [*.net *.split]
kain has quit [*.net *.split]
Dreamer3 has quit [*.net *.split]
Skif has quit [*.net *.split]
unixabg has quit [*.net *.split]
mortice has quit [*.net *.split]
Tasser has quit [*.net *.split]
Guedes_out has quit [*.net *.split]
threedaymonk has quit [*.net *.split]
tris has quit [*.net *.split]
alindeman has quit [*.net *.split]
mitchty_ has quit [*.net *.split]
bnagy has quit [*.net *.split]
cldwalker has quit [*.net *.split]
vbatts has quit [*.net *.split]
samuelkadolph has quit [*.net *.split]
brownies has quit [*.net *.split]
Ober has quit [*.net *.split]
anacond109 has quit [*.net *.split]
yellow5 has quit [*.net *.split]
thorncp has quit [*.net *.split]
mahlon has quit [*.net *.split]
<rue>
‘No available formula’
<rue>
Might need to up stuff beyond regular selfupdate
<yorickpeterse>
Updated brew?
samuelkadolph has joined #ruby-lang
<Fullmoon>
I think I miss something, is there no easier way to make a new hash with all value of old hash transformed by a function / block without using inject?
tonni has joined #ruby-lang
<yorickpeterse>
new_hash = old_hash # :)
alindeman has joined #ruby-lang
fromhet has joined #ruby-lang
pbjorklund has joined #ruby-lang
apeiros_ has joined #ruby-lang
ramonmaruko has joined #ruby-lang
x0F_ has joined #ruby-lang
tofaffy has joined #ruby-lang
Dreamer3 has joined #ruby-lang
thorncp has joined #ruby-lang
kain has joined #ruby-lang
Skif has joined #ruby-lang
Tasser has joined #ruby-lang
unixabg has joined #ruby-lang
mortice has joined #ruby-lang
threedaymonk has joined #ruby-lang
Guedes_out has joined #ruby-lang
bnagy has joined #ruby-lang
tris has joined #ruby-lang
cldwalker has joined #ruby-lang
mitchty_ has joined #ruby-lang
vbatts has joined #ruby-lang
anacond109 has joined #ruby-lang
Ober has joined #ruby-lang
yellow5 has joined #ruby-lang
mahlon has joined #ruby-lang
judofyr has joined #ruby-lang
Dreamer3 has quit [Max SendQ exceeded]
alindeman is now known as Guest28976
sora_h is now known as s0ra_h
Dreamer3 has joined #ruby-lang
TvL2386 has quit [Quit: Ex-Chat]
perryh_away is now known as perryh
perryh is now known as perryh_away
futurechimp has quit [Ping timeout: 264 seconds]
qwerxy has joined #ruby-lang
perryh_away is now known as perryh
s0ra_h is now known as sora_h
Pip has joined #ruby-lang
Pip has joined #ruby-lang
Pip has quit [Changing host]
futurechimp has joined #ruby-lang
Xae has joined #ruby-lang
<Xae>
Hi guys, question from a newbie. I need to declare 3 arrays, is there anyway to do that in 1 line ? Like array1,array2,array3 = Array.new ?
futurechimp has quit [Quit: This computer has gone to sleep]
diegoviola has quit [Ping timeout: 246 seconds]
woollyams has quit [Quit: Computer has gone to sleep.]
brownies has joined #ruby-lang
Axsuul has joined #ruby-lang
fromhet has quit [Ping timeout: 240 seconds]
woollyams has joined #ruby-lang
gsav has quit [Read error: Connection reset by peer]
gsav has joined #ruby-lang
sora_h is now known as s0ra_h
justinmcp has joined #ruby-lang
tekin has joined #ruby-lang
knu has quit [Remote host closed the connection]
shevy has left #ruby-lang ["I'll be back ... maybe"]
woollyams has quit [Quit: Computer has gone to sleep.]
mssola has joined #ruby-lang
knu has joined #ruby-lang
umttumt has quit [Remote host closed the connection]
voker57 has joined #ruby-lang
voker57 has quit [Changing host]
voker57 has joined #ruby-lang
toretore has joined #ruby-lang
srbartlett has joined #ruby-lang
rolfb has joined #ruby-lang
<sandbags>
afternoon (more or less)
NeVeR_ has joined #ruby-lang
perryh is now known as perryh_away
jbsan has joined #ruby-lang
Zhakj has joined #ruby-lang
<Zhakj>
Hi guys, i'm quite new to Ruby and have a question about Strings. I have a String containing the line "# now = a_value", I would like to be able to retrieve this value in a variable. Is there any proper way to do that ?
s0ra_h is now known as sora_h
<Zhakj>
The String contains many other things, but i'm just interrested by this value
woollyams has joined #ruby-lang
<asio>
Zhakj: without knowing more about the contraint/format of string this should work: string.split('=', 2).last
dfr|mac has quit [Remote host closed the connection]
carloslopes has joined #ruby-lang
dalekurt has joined #ruby-lang
gsav has joined #ruby-lang
tommyvyo has joined #ruby-lang
dabradley has joined #ruby-lang
jbsan has quit [Read error: Connection reset by peer]
jbsan has joined #ruby-lang
yumatov has joined #ruby-lang
bglusman has joined #ruby-lang
dfr|mac has joined #ruby-lang
Taki has joined #ruby-lang
kedare has joined #ruby-lang
ozzloy has joined #ruby-lang
ozzloy has joined #ruby-lang
dfr|mac has quit [Remote host closed the connection]
<Taki>
Hi everyone, is there any simple way in Ruby to list files contained in folders, the exact name of which I don't know ? Indeed, I know that all my folder start with 2012, but then it can be anything (it's generated randomly). How can I list files in such folders ? I tried Dir.foreach("2012*") but the asterix doesn't seem to work
tekin has quit [Quit: Computer has gone to sleep.]
<matled>
something like this would be perfect for me, even though I'd prefer if the default would be not to load the local pryrc
tekin has joined #ruby-lang
<banisterfiend>
matled: thanks ill talk aobut it with the other guys
sailias has quit [Quit: Leaving.]
Fullmoon has quit [Quit: Fullmoon]
tcopp has joined #ruby-lang
cantonic has quit [Ping timeout: 244 seconds]
<matled>
banisterfiend: thanks
coryf has joined #ruby-lang
mtm3 has joined #ruby-lang
wallerdev has joined #ruby-lang
kaiwren has quit [Quit: kaiwren]
postmodern has quit [Quit: Leaving]
<banisterfiend>
matled: which plugins do you use btw
<matled>
oh... plugins are another topic! :)
cantonic has joined #ruby-lang
<matled>
I found your blog post, listing a few. currently I'm using none, but I tried a few
<matled>
one misbehaved and was loaded completely when the cli.rb was loaded
<matled>
I think it is pry-nav
<banisterfiend>
Yeah, unfortunately pry-nav has to do that
<banisterfiend>
because of the way it works
<banisterfiend>
it monkeypatches pry on a very deep level so it has to be loaded really early
davidbalbert has joined #ruby-lang
<banisterfiend>
matled: why did it matter out of interest? i mean what were you doing such that it mattered
lsegal has joined #ruby-lang
lsegal has quit [Client Quit]
<matled>
I tried to disable the addons and test them individually
<matled>
but it didn't work for pry-nav
<banisterfiend>
yeah..
<banisterfiend>
matled: i cant imagine that being a big deal in practice though?
<banisterfiend>
that it's loaded so early
<banisterfiend>
it just means that to disable it you have to uninstall the gem rather than disabling it via .pryrc, which i can see being annoying, but in most cases not that big a deal? (i hope)
<matled>
well, it would be nice to disable a plugin without uninstalling it
<banisterfiend>
Yeah
<banisterfiend>
matled: did u try any other ones?
<matled>
I tried stack explorer, exception explorer, coolline, but didn't really explore all the features
<rking>
Wait, better than uninstalling the gem would be to add a fake pry-nav.rb that lives in a path that youunshift onto $RUBYLIB when you don't want it enabled.
<banisterfiend>
oh ok
<banisterfiend>
rking: r u being a lolcat? :)
<rking>
I'm not trying to be. =)
<banisterfiend>
hehe
<matled>
is pry-nav still alive? it was a bit annoying that pry stopped when typing continue
<banisterfiend>
matled: you mean pry-remote ?
<rking>
I mean that way you could do alias nonav='export RUBY_LIB="~/dir/that/has/fake/pry-nav:$RUBY_LIB"
<banisterfiend>
matled: i never had that issue with pry-nav, so i assume u mean pry-remote ?
<matled>
banisterfiend: oh, I cannot reproduce it now
<banisterfiend>
matled: also check out pry-debugger which uses the debugger gem to implement stepping and breakpoints
ruurd has joined #ruby-lang
umttumt has quit [Remote host closed the connection]
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
dfr|mac has quit [Remote host closed the connection]
apeiros_ has quit [Remote host closed the connection]
judofyr has quit [Remote host closed the connection]
lsegal has joined #ruby-lang
macmartine has joined #ruby-lang
carloslopes has quit [Quit: Leaving.]
robbyoconnor has joined #ruby-lang
bfreeman has quit [Quit: bfreeman]
mtm3 has quit [Remote host closed the connection]
neocoin has quit [Remote host closed the connection]
<andrewvos>
I do believe that is an uppercase V. Or maybe the entire sentence is uppercase.
<andrewvos>
Ok this is interesting. Why does this output the version?
<andrewvos>
man grep | grep "-V"
<andrewvos>
^^
<andrewvos>
This works as expected: man grep | grep "\-\V"
qwerxy has quit [Ping timeout: 244 seconds]
<rue>
Because you’re asking it to?
<andrewvos>
I suppose I am
Nisstyre has joined #ruby-lang
<andrewvos>
Kind of confused though
statim has left #ruby-lang [#ruby-lang]
<andrewvos>
Didn't know parameters could be quoted.
dv310p3r has joined #ruby-lang
<rking>
rue: Yeah, maybe not.
<rue>
The shell handles the quotes
jbsan_ has joined #ruby-lang
jbsan has quit [Ping timeout: 244 seconds]
jbsan_ is now known as jbsan
<rking>
I don't know if "as expected" applies to that.
<rking>
From actual programming languages \something that doesn't have special meaning becomes "something".
<rking>
E.g. ruby -e 'p "\-\V"'
cjs226 has joined #ruby-lang
francisfish has joined #ruby-lang
<rue>
Yeah, well.
<rue>
THIS. IS. SHELL PROGRAMMING.
* rue
kicks you in the pit. skcik
xtagon has joined #ruby-lang
<rking>
But the phrase "works as expected" has reference to the expectations of the programmer.
<rking>
And when it comes to quoting rules, my expecations are that there will be surprises if you're porting any other language's expectations.
<rue>
It’s better not to think of it as actual programmierung
francisfish has quit [Remote host closed the connection]
butchanton has quit [Read error: Connection reset by peer]
butchanton has joined #ruby-lang
<rking>
I also don't know about that. Why not?
<rue>
Because it’s clearly not, you just proved it!
<rking>
It's odd, but it's programming.
<andrewvos>
I still can't understand the difference. In both versions (escaped and non-escaped) I would expect the shell to be passing -V to grep.
<rking>
The second one is passing a backslash a dash a backslash a Vee
<rking>
Which grep is interpreting not as command-line flags, but as the pattern to match.
<rking>
Another way to do it would be grep -- -V
sandbags has quit [Remote host closed the connection]
cantonic has quit [Ping timeout: 248 seconds]
<erikh>
andrewvos: dork
sailias has joined #ruby-lang
<andrewvos>
re: twitter?
jbsan has quit [Read error: Connection reset by peer]
jbsan_ has joined #ruby-lang
<erikh>
andrewvos: no, re: -V
<erikh>
you knew it was loud
<erikh>
YOU GOTTA DOWNCASE
<andrewvos>
hehe
<andrewvos>
I should know by now, yes.
<erikh>
also note that egrep is not the default
<erikh>
that'd be grep -E
<rue>
Ack
<erikh>
ack's great for code
<erikh>
not so much for logfiles
<erikh>
well, grep really isn't great for log files either
<erikh>
I'm nerding out because I'm procrastinating
<erikh>
this task is the most boring thing I've done here yet.
sailias has quit [Client Quit]
<andrewvos>
:Ack <stuff?
<andrewvos>
>
scampbell has quit [Remote host closed the connection]
apeiros_ has joined #ruby-lang
<erikh>
andrewvos: what are you talking about cracker
<erikh>
brew install ack
<erikh>
love the ack
<erikh>
it loves you, after all
<yxhuvud>
erikh: ugh. now you made me remember why I don't like IO#readlines.
<andrewvos>
erikh: I use Ack.vim
<erikh>
yxhuvud: well IO#readlines loads the whole thing into ram too
<erikh>
not exactly webscale
<yxhuvud>
erikh: indeed.
<andrewvos>
I'm kind of inspired to write a webmachine inspired ruby web framework.
andrewhl has joined #ruby-lang
<yxhuvud>
and gzipreader#readlines doesn't buffer enough. it is a sad world when a hand knacked readlines beat the stock one :(
<erikh>
I think it'll buffer a lot more after drbrain's patches
<erikh>
(they give up the GVL)
<yxhuvud>
sounds nice!
<yxhuvud>
wish I wasn't stuck in 1.8 atm though :(
<erikh>
yeah, this'll be a 2.0 feature
<erikh>
he can probably tell you more about it.
scampbell has joined #ruby-lang
<yxhuvud>
no need. The logs will probably not stay in files forever, though a reference to the commit might be interesting.
d3vic3 has joined #ruby-lang
ryanf has joined #ruby-lang
<yxhuvud>
the local C wizard just have to finish his append only db with log rotation and indices first :D
<rue>
There’s a webmachine-ruby already, isn’t there?
<apeiros_>
I want a local C wizard too :(
kain_ has joined #ruby-lang
<yxhuvud>
I kinda wish he'd accept learning something else and patch riak instead though :(
kain has quit [Ping timeout: 240 seconds]
<erikh>
maintaining a patchset can often be more trouble than homegrown
<erikh>
just my experience, at least.
<yxhuvud>
assuming it wasn't accepted upstream, yes
<apeiros_>
erikh: shared experience
<apeiros_>
a sad one, really
imperator has quit [Ping timeout: 240 seconds]
<yxhuvud>
we have experience of that as well. kernel patches to some bsd made upgrading version be .. a bit of work.
<yxhuvud>
like half a year or so
qwerxy has joined #ruby-lang
andrewhl has quit [Read error: Connection reset by peer]
andrewhl has joined #ruby-lang
codewrangler has joined #ruby-lang
coryf has joined #ruby-lang
andrewhl has quit [Remote host closed the connection]
cantonic has joined #ruby-lang
mikkelb has quit [Quit: Lost terminal]
solars has joined #ruby-lang
Carnage\ has quit [Read error: Connection reset by peer]
Carnage\ has joined #ruby-lang
Sambalero has joined #ruby-lang
tenderlove has quit [Remote host closed the connection]
brianritchie has quit [Quit: brianritchie]
butchanton has quit [Ping timeout: 248 seconds]
<deryl>
ok, ok I odn't understand this. I have 2 thor tasks in my gem. I've built my gem and installed it. Next I change to a blank directory and do ruby -r dtf -r thor -e "%x[thor list]" but it tells me there are no thor tasks. shouldn't the inclusion of my gem and thor both show the tasks from the gem and then execute it?
butchanton has joined #ruby-lang
<deryl>
doing thor list with my gem required should show me the thor tasks I created correct? (this works in the source directory of the gem, just not elsewhere even with the gem installed)
<deryl>
so this is obviously an environment configuration issue, i'm just not sure what that would be. my thor tasks are setup tasks which copy files into the CWD
CoverSli1e has quit [Read error: No route to host]
retro|cz has quit [Ping timeout: 265 seconds]
<apeiros_>
deryl: I don't know thor. but you shell out to a new thor process. and that one does not have dtf loaded
<apeiros_>
i.e., -rdtf and -rthor only affects the ruby command you issued yourself. it does in no way affect your %x[] shellout
<deryl>
not sure how to access the Thor task from within the script. never put thought to this before now
nofxx has joined #ruby-lang
zz_wasnotrice is now known as wasnotrice
benanne has quit [Quit: kbai]
mikeric has quit [Quit: mikeric]
jbsan has joined #ruby-lang
tofaffy has quit [Changing host]
tofaffy has joined #ruby-lang
jbsan_ has quit [Ping timeout: 264 seconds]
apeiros_ has quit [Remote host closed the connection]
<yorickpeterse>
Yeah I suppose I could go for that as well
<erikh>
note that it doesn't use the auto stuff
<erikh>
e.g., .rvmrc style
<erikh>
I pretty much loathe that feature
<slyphon>
really?
<slyphon>
i love it
<erikh>
yes.
<slyphon>
i think it's great
<erikh>
don't fuck with my environment without me being involved
<erikh>
imo
tenderlove has joined #ruby-lang
<slyphon>
you are involved, though?
<slyphon>
i mean, it asks for confirmation
<erikh>
well, the way I have it setup is that anytime changes happen, I make them
<erikh>
yeah
pbjorklu1d has joined #ruby-lang
<erikh>
another annoyance
workmad3 has joined #ruby-lang
<slyphon>
i dunno
<erikh>
especially when you're trying ot script stuff
<erikh>
anyhow I need to bail
<erikh>
yorickpeterse: hth
<yorickpeterse>
erikh: thnx for the code
sepp2k has joined #ruby-lang
<slyphon>
erikh: wait wait
nofxx has quit [Ping timeout: 246 seconds]
<slyphon>
where do you put --enable-shared ?
<slyphon>
CONFIGURE_OPTS ?
pbjorklund has quit [Ping timeout: 240 seconds]
qwerxy has quit [Quit: offski]
workmad3 has quit [Ping timeout: 246 seconds]
tr-808 has quit [Remote host closed the connection]
ruurd has joined #ruby-lang
tr-808 has joined #ruby-lang
<erikh>
slyphon: yeah, autoconf time
* slyphon
recompiles
qwerxy has joined #ruby-lang
<drbrain>
you can -funroll-loops and -funroll-all-loops but you can't -femit-frame-pointer as ruby will not work
tenderlo_ has joined #ruby-lang
neocoin has joined #ruby-lang
tenderlove has quit [Ping timeout: 246 seconds]
nofxx has joined #ruby-lang
brunocoelho has joined #ruby-lang
yxhuvud has quit [Ping timeout: 248 seconds]
jperry2 has quit [Ping timeout: 252 seconds]
gsav has quit [Ping timeout: 245 seconds]
neocoin has quit [Remote host closed the connection]
<levifig>
is there any way to find which array/hash a variable belongs to?
x0F_ has joined #ruby-lang
x0F has quit [Disconnected by services]
x0F_ is now known as x0F
robotmay has joined #ruby-lang
msaffitz has quit [Quit: Computer has gone to sleep.]
qwerxy has quit [Quit: offski]
<burgestrand>
Yeah, somewhat, you could iterate over each object in ObjectSpace until you find something that equals to whatever your variable is pointing to
<burgestrand>
But… as you might imagine this is not a good thing to do
<zenspider>
levifig: whatever you're doing is wrong.
dalekurt has quit [Quit: Zzz...]
<levifig>
haha
<levifig>
no no, it's really out of curiosity
imperator has joined #ruby-lang
<zenspider>
it might not belong to a variable. it might belong to multiple. it doesn't even make sense to ask the question you're asking.
<levifig>
not using it programatically :)
qwerxy has joined #ruby-lang
<burgestrand>
not variable, array/hash
<burgestrand>
still, not a good thing to do :p
<levifig>
I know what you mean! It was just to use Ruby as a metaphor for a slide
<levifig>
:p
<levifig>
on a slide*
<levifig>
;)
Guest28976 has left #ruby-lang [#ruby-lang]
fbernier has quit [Ping timeout: 244 seconds]
alindeman has joined #ruby-lang
<zenspider>
so as long as you don't show this slide to anyone, I don't see a problem
JustinCampbell has quit [Remote host closed the connection]
workmad3 has joined #ruby-lang
havenn has joined #ruby-lang
jarib has quit [Excess Flood]
<levifig>
mahaha
<levifig>
thanks man ;)
jarib has joined #ruby-lang
ryanf has quit [Quit: leaving]
gsav has joined #ruby-lang
<rue>
-funroll-all-the-goddamn-loops
robotmay has quit [Remote host closed the connection]