Dear all,Here's my attempt at this... I'm working on several other modifications, but wanted to send this through and see it running first. The attached patch works exactly as Jim has requested.
I'm sorry, but I had a little trouble with writing the test mocking for a file in the home directory (if you run the tests you'll see what I mean)... I've updated all other tests to run as expected. I'm going out for a couple of days, but will check emails when i get back.
Also not tested on Windows (although I see no reason why it shouldn't work)
0001-added-system-wide-.rake-functionality.patch
Description: Binary data
Best, -Adam On 30/06/2008, at 11:53 PM, Luis Lavena wrote:
Sorry I came late to this topic...On Mon, Jun 30, 2008 at 3:33 PM, Jim Weirich <[EMAIL PROTECTED]> wrote:On Jun 30, 2008, at 12:41 AM, Adam Salter wrote:chroot is not really the same thing... ie it's not really a standard or normal way of having Rake tasks globally available... ie I can't use it thatway regularly.Rakefile in / does work i guess, but makes me think when i said 'globallyavailable' i really meant 'per-user'. Still no comment from the great and benevolent leader Jim... ;)You forgot the easily distractible :) I have no strong objection to this change. Several points:(1) Only reads .rake if if finds no other Rakefile. This is important because you don't want to accidently put important build functionalityoutside of your project directory.Good, something like Sake does, you put generic tasks that you usualy run for most of your projects (like log:clear) :-)(2) If the command line option is given, then the local Rakefile should beignored. (3) Where are you going to put the .rake file on a windows machine?If home is not defined, then should be HOMEDRIVE + HOMEPATH :-) If there is not HOMEDRIVE+HOMEPATH, that mean is not a user, but a service, then it should look for APPDATA. If no APPDATA there, it should look for ALLUSERSPROFILE(4) Include tests for all changes. I am much more likely to accept patcheswith tests than otherwise.Also, I'm planning on putting a git repository of rake on github in the very near future (meant to do it this weekend but ran out of time). That should make it easier for alternate versions. I'll put an announcement here when Ido.Great news! I'll be able to fork and make all the tests for rake actual pass on Windows and see what other cross-platform bug we found in ruby itself to catch! :-) Thank you Jim for your hard work :-) Regards, -- Luis Lavena AREA 17 -Human beings, who are almost unique in having the ability to learn fromthe experience of others, are also remarkable for their apparent disinclination to do so. Douglas Adams _______________________________________________ Rake-devel mailing list [email protected] http://rubyforge.org/mailman/listinfo/rake-devel
_______________________________________________ Rake-devel mailing list [email protected] http://rubyforge.org/mailman/listinfo/rake-devel
