<Xzyx987X>
aha, this is what they wanted you to do in the new version: require 'active_support/time/autoload'
Z33K|Lux has joined #ruby-lang
S2kx has joined #ruby-lang
brushbox1 has joined #ruby-lang
brushbox1 has joined #ruby-lang
achiu has joined #ruby-lang
replore_ has joined #ruby-lang
savage-_ has joined #ruby-lang
sei has joined #ruby-lang
tomzx has joined #ruby-lang
travisjeffery has joined #ruby-lang
crackity_jones has joined #ruby-lang
lsegal has joined #ruby-lang
<Xzyx987X>
ungh, finally got this to work. something tells me the authors of activesupport did not intend it to be used outside of rails
<Xzyx987X>
or at the very least, not that many people have tried
Banistergalaxy has joined #ruby-lang
wmoxam has joined #ruby-lang
shevy has joined #ruby-lang
jfelchner has joined #ruby-lang
seanstickle has joined #ruby-lang
travisjeffery has joined #ruby-lang
<ged>
Given a module object named A::B::C, is there a better way to get the A::B module/class than finding up the constant by name? (e.g., via mod.name.split('::').inject(Object) {...} or whatever).
<ged>
I was hoping Module.nesting[1] would work, but I can't seem to make it return A::B outside of A::B::C itself.
<drbrain>
nesting is not usable like that
Nisstyre has joined #ruby-lang
<ged>
So I noticed. :P
<drbrain>
nesting is the method that looks like "OH AWESOME‼" then you realize that it's almost completely useless
<erikh>
did mysql come with snow leopard server or did you install it some other way?
<erikh>
I'm not seeing it on lion server.
<tevren>
it comes with snow leopard server
<erikh>
hrm. you'd think it'd come with headers, too
<erikh>
do you have locate services running on that box?
<erikh>
try 'locate mysql.h'. does that yield anything?
<slyphon>
locate?
<slyphon>
really?
<slyphon>
on a mac?
<erikh>
locate is faster than find
<erikh>
feh
<erikh>
i don't have the spotlight-fu
<slyphon>
if you're running spotlight on a server, i'm gonna need you to give yourself a wedgie right now
<slyphon>
This. Minute.
<erikh>
well I am, but it's my desktop machine.
<tevren>
gotta build the locate db first
<slyphon>
oh gawd
<slyphon>
don't do that
<bnagy>
just use find
<slyphon>
jsut use find
<erikh>
yeah, just use find at this point.
<erikh>
(locate just uses find to build the locate db)
<erikh>
find / -name mysq.h
<erikh>
err, mysql.h
<slyphon>
#ruby-lang is unanimous
<slyphon>
JUST USE FIND
<bnagy>
I imagine that as being sung in ascending thirds (just use find...just use fiiiiind...)
<slyphon>
bnagy: :D
<bnagy>
find ... 2>/dev/null
<erikh>
for future use, locate is nice because it's faster
<erikh>
but since you don't have a db already, yeah.
<tevren>
results nothing :/
<erikh>
ok. that's not good.
<bnagy>
wait no errors? OSX freaks me out
<erikh>
basically, you have a binary install of mysql.
<erikh>
no headers == no compile == no gem
<tevren>
should i brew mysql?
<bnagy>
sounds like install ports, install proper version of mysql that has headers, maybe :/
<erikh>
what you need to do (and I know, this sucks rocks), is build mysql 5.0.x, gem against that to get the linking correct, and then work with that gem
<erikh>
tevren: is this mysql server critical?
<erikh>
maybe i'm making it a bigger problem than it actually is, but the client version changes at 5.5, which is why the `mysql` gem doesn't play so well with 5.5 and up
<erikh>
(you need `mysql2` in most cases)
<tevren>
erikh: yeah, need it for my db
<erikh>
err, if i said, "upgrade mysql", would that be a possibility/
Sailias has joined #ruby-lang
<erikh>
if not, you need to do what I suggested re: building mysql 5.0.x
<erikh>
biam
<tevren>
i don't want to mess with the system mysql unless i have to, im connecting to a mysql db on another server… do i need to rebuild mysql on the server that's hosting the app?
<erikh>
bbiam
<slyphon>
i wouldn't mess w/ the system mysql
<tevren>
so ports install mysql and run gem mysql against that?
<slyphon>
yeah
<tevren>
kk im going to try that
<slyphon>
that would not be a bad way to go
Joeysomo_ has joined #ruby-lang
<erikh>
agreed
jtoy has joined #ruby-lang
bryancp has joined #ruby-lang
<tevren>
that did it installed the mysql client via port, thanks everyone!
bglusman has joined #ruby-lang
ryanf has joined #ruby-lang
publicvoid has joined #ruby-lang
chimkan has joined #ruby-lang
postmodern has joined #ruby-lang
Xzyx987X has joined #ruby-lang
igotnolegs has joined #ruby-lang
Banistergalaxy has joined #ruby-lang
savage- has joined #ruby-lang
mehulkar has joined #ruby-lang
Nisstyre has joined #ruby-lang
jfelchner has joined #ruby-lang
kish has joined #ruby-lang
wmoxam has joined #ruby-lang
cdnz has joined #ruby-lang
neurodamage has joined #ruby-lang
razer12345 has joined #ruby-lang
<razer12345>
Hi
<razer12345>
What ruby book do you guys recommend for somebody who hasn't been programming in years?
<bnagy>
github.com
<bnagy>
programming books are for tax deductions and people over 60
<shevy>
hehehe
<shevy>
razer12345 pickaxe is ok. but ultimately the only way to program in ruby is to write ruby scripts on your own
<drbrain>
razer12345: if you've programmed before, pickaxe will probably work fine
<razer12345>
I think typing as you read would help more than reading from beginning to end.
<razer12345>
I've programmed before and even have a degree in computer science, but I was never good at programming and thought I didn't get a proper presentation, so I like books that start for a new programmer.
<razer12345>
I got the RubyMine IDE already.
<shevy>
one need not more than notepad for ruby really
<shevy>
irb is also helpful
<razer12345>
Yeah, I heard that ruby needs it less.
<shevy>
afterwards you at least have an idea of the ruby object model
phlipper has joined #ruby-lang
crudson has quit [#ruby-lang]
<mistym>
There's an expanded book version of Learn to Program, too.
<razer12345>
I jumped on the RubyMine IDE because a sale was ending on it, and I the idea of an IDE providing you with variables and methods.
<razer12345>
RubyMine was selling for $50.
<razer12345>
I wouldn't want to pay more than that
<shevy>
well whatever floats your boat
<razer12345>
I wish that my computer science degree program used ruby from beginning to end.
<razer12345>
We learned C and assembly and LISP. It drove me crazy.
<mistym>
Maybe not to "end". You want to learn lower-level programming too. ;)
<mistym>
Lisp, ew. Now I know why you like Ruby - no more parens! ;)
<shevy>
you cant compare ruby to C really
<razer12345>
A year of assembly was totally stupid.
<shevy>
ruby has no pointers for one
<shevy>
it also has less syntax clutter than C
<razer12345>
And we did C++ too
<shevy>
ruby has one thing from C++! the <<
<razer12345>
We did unix programming. No .net or IDE's or API's allowed.
<mistym>
unix++
<razer12345>
They wanted us to understand from a very research kind of level, not very good for actually writing programs for somebody like me who wasn't a very good match for programming.
<mistym>
So out of curiosity, if you weren't interested in the programming side, what were you hoping to do?
<razer12345>
I was hoping to do IT kind of stuff
<shevy>
ok really
<shevy>
ruby is not about programming
<shevy>
ruby is about poetry and if you still think it has anything to do with programming you should program in C!
<hangingclowns>
that's the site i was looking for!
<hangingclowns>
rubular
<hangingclowns>
thanks
<hangingclowns>
i used it before, works like a charm
<any-key>
hangingclowns: we mostly kid about regex, it's a great tool when applied to the right situations
<any-key>
we aren't perl programmers, after all ;)
<hangingclowns>
yeah, i know
<bnagy>
every time you use a regexp God tries to kill a puppy but accidentially wipes them all out because he uses a greedy match
<hangingclowns>
i got pretty far in life without regex
<yxhuvud>
:D
<hangingclowns>
then when I applied for a job they laughed at me cause I don't use regex
<hangingclowns>
well dont know it, at least
<erikh>
hey
<erikh>
some of us are perl programmers
dfr|mac has joined #ruby-lang
<hangingclowns>
seems like just \. is enough to target it
<bnagy>
( distant yelp )
<erikh>
hangingclowns: there's an old book called "mastering regular expressions". it's a good primer and will teach you to think about them in the manner expected
<hangingclowns>
but for some odd reason, it only does it one time?
<hangingclowns>
yes, i have it
<erikh>
ah ok
<erikh>
read it :)
<hangingclowns>
just can't bring myself to read it :(
<hangingclowns>
yeah, it's tough
<seanstickle>
It's not even that old a book
<erikh>
like anything else that's new
<erikh>
seanstickle: feh
<bnagy>
is that the one with the 'valid email' regexp at the back?
<erikh>
bnagy: at the front, or maybe that was the ip address one
<erikh>
yeah, it's a climb for sure
<bnagy>
like 2 pages or something?
<bnagy>
that's an awesome book
<erikh>
that's tchrist's email regexp
<erikh>
so yeah, probably
<erikh>
anyhow, I got sidetracked reading about warren buffet cancer
<erikh>
thanks for that.
<erikh>
now I'm going to bed for real :)
<hangingclowns>
Returns a copy of str with the first occurrence of pattern substituted for the second argument.
<hangingclowns>
isn't there a way to sub it all?
<hangingclowns>
seems kind of pointless
JohnBat26 has joined #ruby-lang
<bnagy>
like some kind of global sub method?
<hangingclowns>
more like if i have account.line.customer string and I want to sub every . with _
<bnagy>
yeah it'd be like String#sub except, like GLOBAL. That would be awesome.
<bnagy>
wonder what they'd call it?
<hangingclowns>
sub_global?
<hangingclowns>
maybe gsub?
<hangingclowns>
wow
<hangingclowns>
i'm retarded, today
<any-key>
geesub
<drbrain>
I'd expect sub_global for PHP
<hangingclowns>
yeah, i thoguht gsub and sub were the same, i forgot they are different methods
<hangingclowns>
my fault
krz has joined #ruby-lang
eltonjohn has joined #ruby-lang
<bnagy>
btw in my lame benchmark tr is like 5x faster than gsub for this
<bnagy>
just sayin :P
<eltonjohn>
Hello; I'm writing a simple command line app; it makes use of some ERB templates. Where, conventionally, should I keep the templates?
<drbrain>
eltonjohn: if they're small I put them in heredocs
<eltonjohn>
ie should I have a top level templates dir? a dir in lib?
<eltonjohn>
drbrain: ah yes, they're very small
<drbrain>
if they're big I put them in, say, lib/my_lib/templates/foo.erb
ryanf has joined #ruby-lang
x0F_ has joined #ruby-lang
<eltonjohn>
yeah they're maybe 12 lines long, x 5 or 6 - maybe a bit long for heredocs. OK, lib/mything/templates sounds great
<eltonjohn>
thanks very much, drbrain
hangingclowns has quit [#ruby-lang]
kitallis has joined #ruby-lang
cdnz has joined #ruby-lang
workmad3 has joined #ruby-lang
CoverSlide has joined #ruby-lang
rolfb has joined #ruby-lang
rippa has joined #ruby-lang
robbyoconnor has joined #ruby-lang
pabloh has joined #ruby-lang
solars has joined #ruby-lang
achiu has joined #ruby-lang
heftig has joined #ruby-lang
stepnem has joined #ruby-lang
deobald_ has joined #ruby-lang
kain has joined #ruby-lang
Hakon|mbp has joined #ruby-lang
toretore has joined #ruby-lang
stepnem has joined #ruby-lang
heftig has joined #ruby-lang
solars has joined #ruby-lang
gnufied has joined #ruby-lang
QaDeS has joined #ruby-lang
rippa has joined #ruby-lang
stepnem has joined #ruby-lang
kyrylo has joined #ruby-lang
stepnem has joined #ruby-lang
ramonmaruko has joined #ruby-lang
solars has joined #ruby-lang
gouthamvel has joined #ruby-lang
gouthamvel has quit [#ruby-lang]
futurechimp has joined #ruby-lang
Banistergalaxy has joined #ruby-lang
Hakon|mbp has joined #ruby-lang
gd_ has joined #ruby-lang
<gd_>
hi all
<gd_>
how can i define and use a class inside a method body? i would like to write inline 'class <methods...> end.new right inside my Rack map run end end
workmad3_ has joined #ruby-lang
francisfish has joined #ruby-lang
<gd_>
hej soahccc bruestest du dich damit mitglied im club zu sein?
deobald_ has joined #ruby-lang
tbuehlmann has joined #ruby-lang
<rippa>
gd_: you can define and use a class inside a method
PhilCK has joined #ruby-lang
<shevy>
gd_ wie kann man nur so schnell zwischen englisch und deutsch wechseln ;)
sidro has joined #ruby-lang
dr0id has joined #ruby-lang
<Defusal>
gotta love waking up and starting work on a project you have used plenty but have not changed anything on in 2 days
<Defusal>
and its broken...
<Defusal>
i don't even know where to start, it's as if the WebSocket server buffers its packets and only sends them when the websocket connection closes, but only 98% of the time
DMKE has joined #ruby-lang
Radium_ has joined #ruby-lang
<gd_>
rippa: sure? >ruby -e 'def foo class bar def baz 23; end end.new end foo'
<rippa>
gd_: bar = Class.new {<...>}
RomyRomy has joined #ruby-lang
<gd_>
rippa: >ruby -e 'def foo Class.new { def baz 23; end } end foo'
<andrewvos>
banister: But nyan-cat breaks my tmux session.
<banister>
andrewvos: hehe
<andrewvos>
banister: After running nyan-cat I don't see my terminal cursor anymore. Should I create an issue?
<banister>
andrewvos: the ones that really rock out my D. are the new show-source ability to show class source, and even monkey-patches: https://gist.github.com/2405083
<banister>
andrewvos: also check out find-method for a ruby-aware grep
<banister>
really awesome
<andrewvos>
cool
<banister>
andrewvos: try: show-source -a String on rbx
<banister>
andrewvos: ^ that code will return all the methods nested under the YourModule namespace that contain the CODE 'x =0'
<andrewvos>
whoa
<andrewvos>
amazing
<banister>
andrewvos: so you can easily find all the callers of a given method by doing, find-method -c your_method_name
<banister>
yeah it's pretty kickass
<andrewvos>
find-method -c to_s
Fullmoon has joined #ruby-lang
<andrewvos>
wow pretty cool
<andrewvos>
That was a bit slow though
<banister>
andrewvos: yeah, it's doing a full text search through every single method, so it's best to heavily constrain it to a particular namespace as much as possible
srbartlett has joined #ruby-lang
<andrewvos>
fair enough
<banister>
andrewvos: in future versions we may add caching to speed things up
<banister>
but it wil be hard to know when the cache is out of date, it's ahard problem
<andrewvos>
not sure how that could be done though
<andrewvos>
yeah exactly
<banister>
andrewvos: well like most of pry, we can get it working in the 80% case
<banister>
andrewvos: simple method definitions in a given namespace are easy to track
<banister>
heavy metaprogramming stuff is more tricky
<andrewvos>
yeah
nahhh has joined #ruby-lang
<banister>
andrewvos: oh i forgot to ask, do u get autosyntax highlighting after u press enter on a line of input?
<andrewvos>
I do
<banister>
:)
<banister>
that's just there to make the girls go 'woo'
<andrewvos>
haha
<andrewvos>
I did "woo"
<banister>
heh heh
rohit has joined #ruby-lang
fgomez has joined #ruby-lang
fgomez has joined #ruby-lang
Guedes0 has joined #ruby-lang
Guedes has joined #ruby-lang
Guedes has joined #ruby-lang
Guedes has joined #ruby-lang
apeiros_ has joined #ruby-lang
Mon_Ouie has joined #ruby-lang
<apeiros_>
drbrain: ping - feature suggestion for rubygems - upon `gem update SOMEGEM`, provide a distinct message when SOMEGEM is not yet installed
<apeiros_>
currently it just states 'nothing to update'
michael_mbp has joined #ruby-lang
<rohit>
apeiros_, Different message when the gem is installed and is latest version or the same?
<michael_mbp>
Hmm, why am I getting an error for *(1..5) ?
<michael_mbp>
ruby 1.9.2-p290
<michael_mbp>
hey rohit
<apeiros_>
rohit: different message when the gem isn't installed at all
<rohit>
michael_mbp, Hello :)
<michael_mbp>
*(1..5) //SyntaxError: unexpected tDOT2, expecting tCOLON2 or '[' or '.'
<apeiros_>
it should say something like "SOMEGEM is not installed" instead of "nothing to update" (of course there's nothing to update if the gem isn't installed in the first place)
<michael_mbp>
very curious
<rohit>
apeiros_, yes but does it show a different message when the gem is installed and no new version exists?
<rohit>
michael_mbp, same here on 1.9.3 - what are you trying to do with that?
<michael_mbp>
it shouldn't do that :)
<michael_mbp>
unless something has changed with the splat operator
<michael_mbp>
it should be the same as (1..5).to_a
<rohit>
apeiros_, Anyway you are right the message should be more descriptive if the gem is not installed. Create an issue on rubygems issue tracker!
<apeiros_>
rohit: no, if the gem is already installed and the newest version is installed, it says the same - "Nothing to update"
<rohit>
apeiros_, Ah ok. Message for former should definitely be "gem not installed, to install do gem install blah"
<apeiros_>
rohit: or just ask "Gem FOO not installed, do you want to install it [Yn]"
<apeiros_>
"yes" clearly as default since the intent obviously is to have the newest version of the specified gem
<MDmalLION>
how do I make it such that the user doesnt have to type the underscroe
<MDmalLION>
also is there a neater way than just having a bunch of methods
datanoise has joined #ruby-lang
<apeiros>
I don't see where the user has to type *the* underscore in that code…
<apeiros>
yes. it's called 'class'.
<apeiros>
part of that bigger thing called "object oriented programming"
thone has joined #ruby-lang
<oddmunds>
MDmalLION: your program will put Gregory House out of his job
<manveru>
oddmunds: and who's gonna break into the patients home?
tjadc has joined #ruby-lang
<MDmalLION>
oddmunds: exactly
MDmalLION has quit [#ruby-lang]
<oddmunds>
Well House seldom does that himself.
<manveru>
but others wouldn't do it if he didn't force them
zmack has joined #ruby-lang
<slyphon>
so
<oddmunds>
actually, breaking into peoples homes is one of the more true things about the series
<slyphon>
is there any way to have a C extension safely call into ruby?
<oddmunds>
only that it's not the surgeons doing it
<rue>
House is such a stupid show. It jumped the lupus in like the 3rd episode.
* apeiros
sees 'C extension' and 'safely' in the same sentence and is completely confused…
<oddmunds>
I like it :)
<slyphon>
apeiros: well, just play along
<slyphon>
it seems like there's no "lock" you can grab
<rue>
What kind of an extension?
<apeiros>
slyphon: rb_funcall or somesuch, no?
<rue>
You can use ^ or the API methods
<slyphon>
well
<rue>
Functions*
<slyphon>
ah, hrm, nvm
<slyphon>
the problem is this extension spawns its own thread
<slyphon>
and the interaction there is challenging
<apeiros>
aha, no experience with that, sry
topaz has joined #ruby-lang
fgomez has joined #ruby-lang
Radium has joined #ruby-lang
<rue>
How about a communication queue or something?
<rue>
Fifo?
<slyphon>
i'm using a pipe to signal
<slyphon>
and rb_thread_wait_fd
<slyphon>
in a loop
<slyphon>
as a way to block waiting for messages
<slyphon>
it's just the shutdown sequence is complicated
<rue>
Do you need to clean up?
diegoviola has joined #ruby-lang
<slyphon>
yeah, it's kind of gross
<slyphon>
it's almost like FTP, there's a synchronous request thread, and a secondary event-delivery thread
<slyphon>
the delivery thread adds events to a queue that's implemented in C, and does the work of converting those events into ruby hashes
<slyphon>
it then writes to the pipe
<slyphon>
that's all outside of any ruby thread
<erikh>
woohoo
<slyphon>
then in a ruby thread, i have a loop that calls into a function that pops from the queue
<erikh>
my service manager isn't launchable, but it's functional now
<slyphon>
but at teardown time, i have to close the main reqeust handle, which will then "do stuff" to ensure the event thread delivers its messages *at some time*
<slyphon>
returns, then i need to wait for those events, then close the queue
<slyphon>
(as far as i can figure it out)
<slyphon>
anyway , i hate C
<shevy>
hehe
<shevy>
I really should collect all quotes from #ruby-lang
<slyphon>
yeah, i'm a big fan of quotefiles
rippa has joined #ruby-lang
<slyphon>
the one from #twisted was brilliant in parts
kitallis has joined #ruby-lang
Taranis has joined #ruby-lang
kaiwren has joined #ruby-lang
slimfit has joined #ruby-lang
cdnz has joined #ruby-lang
rdavila has joined #ruby-lang
gregf has joined #ruby-lang
<oddmunds>
anyone have any tips for making yardoc documentation look nice when printed?
<slyphon>
use a laser printer?
<oddmunds>
it's seems like the nice style sheet is only for display or something
jxie has joined #ruby-lang
<rking>
oddmunds: What does it currently look like when printed?
<rking>
oddmunds: E.g., take a photo or somehow get it to simulate on the screen where we can see it.
<oddmunds>
it looks like the web page without stylesheets applied
<rking>
Oof.
<rking>
That sounds unright.
<oddmunds>
heh, i'm at work where "taking a screenshot" somehow doesn't work.
<oddmunds>
the fault might be the system i'm using.
<oddmunds>
Vista with FF11 and/or IE8
<judofyr>
oddmunds: it probably has media="screen"
<rking>
oddmunds: No. I replicated it with Firefox's "Print to File"
<rking>
judofyr: You are precisely right.
<rking>
oddmunds: I am not sure what the total workaround is, but if you remove that stupid 'media="screen"' from the <link>s for the css, it should work.
<oddmunds>
nice, i was reaching for firebug, but this seems handy
<oddmunds>
judofyr: :D
<judofyr>
;)
<rking>
judofyr: That only works because they already have jquery.js included, right?
<judofyr>
rking: yes
<oddmunds>
i didn't even know you could do js like that. even though i guess that's how bookmarklets work.
<any-key>
yep
<judofyr>
oddmunds: it's a lovely way to write XSS exploits too
<rking>
oddmunds: You should probably bug report this. It looks like someone half-way tried to make the different media work, but didn't actually test it.
<judofyr>
nobody expects the window.location = "javascript:" …
<oddmunds>
i use pentadactyl so could use this all the time
<rking>
oddmunds: :js
<rking>
Pentadactyl has everything you expect it to have, I think.
<oddmunds>
yeah, but i could script stuff to load jquery, couldn't i? for it's handyness.
Swimming_Bird has joined #ruby-lang
<oddmunds>
rking: yeah, the :js thing seems definatly like the way to go :D
<rking>
oddmunds: Actually, if you are using it, you can do this: noremap <leader>P :js $('link').attr('media','')
<oddmunds>
yeah. i think i'd like to actually make, is a command for jumping to an embeded version of vimeo/youtube/etc videos
<rking>
Oh, sorry, forgot the final <cr> to make it the final awesome.
<rking>
oddmunds: But I confirmed that works. (You type \P to make that JS run)
<rking>
oddmunds: By the way, be sure to do :js <Tab>
<oddmunds>
yeah
<rking>
oddmunds: But only do so if you do nut suffer from a weakened heart condition.
<oddmunds>
i tab my way through life :)
michael_mbp has joined #ruby-lang
hagabaka has joined #ruby-lang
hagabaka has joined #ruby-lang
<rking>
Hrm. For some reason :js alert(window.location) is showing up "chrome://browser/content/browser.xul"... like part of Pentadactyl rather than the web page that you're on.
tjadc has joined #ruby-lang
m3nd3s has joined #ruby-lang
imajes has joined #ruby-lang
<rking>
If you could find the right document object, it would be something like :noremap <leader>f :js document.location = 'http://youtube.com/embed/' + something.location.pathname<cr>
<rking>
oddmunds: Apparently the Pentadactyl model at that point is "document" refers to the whole environment... I guess that way you can do tricks on Pentadactyl itself... while "content" is the web page in the current tab.
<rking>
oddmunds: I do not think I would have been as inspired to get that to work if I hadn't had that particular theme music going while I did.
<oddmunds>
hehe
<oddmunds>
it's still going here
<oddmunds>
i should make a pomodoro version that slowly speeds up
<rking>
oddmunds: You'll also want to do :mkpentadactylrc if you like those 2 remaps.
gsav has joined #ruby-lang
<oddmunds>
yeah
<rking>
oddmunds: Cool. I didn't know about the pomodro technique. I used to keep a 5minute hourglass by my monitor for a similar idea.
<oddmunds>
rking: remember the ! on the mkpentadactylrc so you don't have to type it twice
<rking>
oddmunds: Oh. =) I'm still new to it.
Psyche^ has joined #ruby-lang
morozovm has joined #ruby-lang
<naquad>
how do i make ruby gems use system folders instead of user specific? this feature is very buggy, dependencies are still trying to install into sys dirs and of course other users don't have access to installed binaries
<naquad>
ah
<naquad>
found it
<naquad>
in /etc/gemrc
<judofyr>
naquad: GEM_HOME :)
<hagabaka>
using arch linux?
<naquad>
global install
<naquad>
yes
gsav has joined #ruby-lang
<hagabaka>
you could also --no-userinstall or something like that
<naquad>
hagabaka, i've changed /etc/gemrc and that fixed the issue
<naquad>
thanks
tr-808 has joined #ruby-lang
<naquad>
for fscks sake now ruby-debug19 doesn't install :( says can't find rb_method_entry_t.called_id and rb_control_frame_t.method_id in method.h
<naquad>
bad includes...
<naquad>
fixed
achiu has joined #ruby-lang
Defusal has joined #ruby-lang
heftig has joined #ruby-lang
<naquad>
what's a good gem for working with s3?
<naquad>
aws-s3 and s3 throw same error: S3::Error::RequestTimeout: Your socket connection to the server was not read from or written to within the timeout period. Idle connections will be closed.
<naquad>
what's wrong with it?
kiddorails has joined #ruby-lang
newONE has joined #ruby-lang
newONE has quit [#ruby-lang]
newONE_German has joined #ruby-lang
savage- has joined #ruby-lang
Defusal_ has joined #ruby-lang
Defusal_ has joined #ruby-lang
butchanton has joined #ruby-lang
Austin__ has joined #ruby-lang
Radium_ has joined #ruby-lang
Defusal has joined #ruby-lang
z3r00ld has joined #ruby-lang
fvollero has joined #ruby-lang
larsthegeek has joined #ruby-lang
larsthegeek has joined #ruby-lang
dfr|mac has joined #ruby-lang
ridders24 has joined #ruby-lang
gnufied has joined #ruby-lang
fgomez has joined #ruby-lang
z3r00ld has quit [#ruby-lang]
DMKE has joined #ruby-lang
gnufied has joined #ruby-lang
<ridders24>
how can I copy a dir and its contents from one location to another?
<shevy>
ridders24 first require fileutils
<shevy>
then something like
<shevy>
FileUtils.cp_r '/my_songs','/tmp'
<shevy>
or better use your own method, that way you can use that consistently, and change it at a later time if you want to (like pass the verbosity flag to fileutils for instance. or toggle it off again)
<corsican>
require fileutils; Dir["source/dir/*.*"].entries { |f| FileUtils.cp f "dest/dir" }
achiu has joined #ruby-lang
kyrylo has joined #ruby-lang
futurechimp has joined #ruby-lang
<ridders24>
ok cheers guys I'll try those out
<corsican>
if you want it recursive, use FileUtils.cp_r