From jftucker at gmail.com Thu Nov 12 10:15:04 2009 From: jftucker at gmail.com (James Tucker) Date: Thu, 12 Nov 2009 15:15:04 +0000 Subject: [Rake-devel] Task Aliases Message-ID: <77BFDDD2-756E-4BDD-B86B-BDB3C5279EED@gmail.com> Hey folks, I couldn't find a native way to do this, but sometimes it's desirable to make for example, deploy commands much shorter. http://gist.github.com/232966 If this idea is liked, I can reproduce as a patch against rake. Kind regards, James Tucker From nbeyer at gmail.com Mon Nov 16 23:10:56 2009 From: nbeyer at gmail.com (Nathan Beyer) Date: Mon, 16 Nov 2009 22:10:56 -0600 Subject: [Rake-devel] including .specification files (or other "dot" files) in Rake Package on Linux/Mac OS X In-Reply-To: <3b3f27c60911162002ob67262fs74be549745589f6e@mail.gmail.com> References: <3b3f27c60911151334s6b9a6574m63732ab89e6968f6@mail.gmail.com> <3b3f27c60911162002ob67262fs74be549745589f6e@mail.gmail.com> Message-ID: <3b3f27c60911162010i2ce6ff9egcd877992f120f625@mail.gmail.com> I've found that my instantiation of the Rake Package task for packaging up a Rails app isn't including the '.specification' files in the '/vendor/gems/**/*' pattern. I've recreated this on Linux and Mac OS X. It seems the issue is that the files, which are copied from their origin to the target folder, are missing the files. I'm guessing this is because of the underlying copy commands, but haven't dug into it yet. Has anyone else run into this? Is there anyway to get Rake to pickup '.specification' or any other "dot" files? From assaf at labnotes.org Tue Nov 17 01:16:06 2009 From: assaf at labnotes.org (Assaf Arkin) Date: Mon, 16 Nov 2009 22:16:06 -0800 Subject: [Rake-devel] including .specification files (or other "dot" files) in Rake Package on Linux/Mac OS X In-Reply-To: <3b3f27c60911162010i2ce6ff9egcd877992f120f625@mail.gmail.com> References: <3b3f27c60911151334s6b9a6574m63732ab89e6968f6@mail.gmail.com> <3b3f27c60911162002ob67262fs74be549745589f6e@mail.gmail.com> <3b3f27c60911162010i2ce6ff9egcd877992f120f625@mail.gmail.com> Message-ID: <5037b6e40911162216x124d1fbbs854b9d201e3d7ad5@mail.gmail.com> On Mon, Nov 16, 2009 at 8:10 PM, Nathan Beyer wrote: > I've found that my instantiation of the Rake Package task for > packaging up a Rails app isn't including the '.specification' files in > the '/vendor/gems/**/*' pattern. I've recreated this on Linux and Mac > OS X. > > It seems the issue is that the files, which are copied from their > origin to the target folder, are missing the files. I'm guessing this > is because of the underlying copy commands, but haven't dug into it > yet. > FileList (also Dir.glob, File.fnmatch) does not match dot files when you use the pattern "*". That's by design, dot files are hidden, so the default behavior is to not match them. You can use the option File::FNM_DOTMATCH, or change the pattern to match "{.*,*}". Assaf Arkin *Blogging at** **labnotes.org* * * * * > > Has anyone else run into this? Is there anyway to get Rake to pickup > '.specification' or any other "dot" files? > _______________________________________________ > Rake-devel mailing list > Rake-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rake-devel > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nbeyer at gmail.com Tue Nov 17 23:07:35 2009 From: nbeyer at gmail.com (Nathan Beyer) Date: Tue, 17 Nov 2009 22:07:35 -0600 Subject: [Rake-devel] including .specification files (or other "dot" files) in Rake Package on Linux/Mac OS X In-Reply-To: <5037b6e40911162216x124d1fbbs854b9d201e3d7ad5@mail.gmail.com> References: <3b3f27c60911151334s6b9a6574m63732ab89e6968f6@mail.gmail.com> <3b3f27c60911162002ob67262fs74be549745589f6e@mail.gmail.com> <3b3f27c60911162010i2ce6ff9egcd877992f120f625@mail.gmail.com> <5037b6e40911162216x124d1fbbs854b9d201e3d7ad5@mail.gmail.com> Message-ID: <3b3f27c60911172007o76242838v566071d74f653ee9@mail.gmail.com> On Tue, Nov 17, 2009 at 12:16 AM, Assaf Arkin wrote: > On Mon, Nov 16, 2009 at 8:10 PM, Nathan Beyer wrote: >> >> I've found that my instantiation of the Rake Package task for >> packaging up a Rails app isn't including the '.specification' files in >> the '/vendor/gems/**/*' pattern. I've recreated this on Linux and Mac >> OS X. >> >> It seems the issue is that the files, which are copied from their >> origin to the target folder, are missing the files. I'm guessing this >> is because of the underlying copy commands, but haven't dug into it >> yet. > > FileList (also Dir.glob, File.fnmatch) does not match dot files when you use > the pattern "*". ?That's by design, dot files are hidden, so the default > behavior is to not match them. ?You can use the option?File::FNM_DOTMATCH, > or change the pattern to match "{.*,*}". I assumed it was default behavior, i just didn't know how to get it changed in this case. Is the use of curly braces in the FileList [] method documented somewhere, I haven't seen that before? Is "{.*,*}" the same as two separate patterns ".*" and "*" in the same FileList[]? Thanks for the help. -Nathan > Assaf Arkin > Blogging at labnotes.org > >> >> Has anyone else run into this? Is there anyway to get Rake to pickup >> '.specification' or any other "dot" files? >> _______________________________________________ >> Rake-devel mailing list >> Rake-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/rake-devel > > > _______________________________________________ > Rake-devel mailing list > Rake-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rake-devel > From assaf at labnotes.org Wed Nov 18 03:34:41 2009 From: assaf at labnotes.org (Assaf Arkin) Date: Wed, 18 Nov 2009 00:34:41 -0800 Subject: [Rake-devel] including .specification files (or other "dot" files) in Rake Package on Linux/Mac OS X In-Reply-To: <3b3f27c60911172007o76242838v566071d74f653ee9@mail.gmail.com> References: <3b3f27c60911151334s6b9a6574m63732ab89e6968f6@mail.gmail.com> <3b3f27c60911162002ob67262fs74be549745589f6e@mail.gmail.com> <3b3f27c60911162010i2ce6ff9egcd877992f120f625@mail.gmail.com> <5037b6e40911162216x124d1fbbs854b9d201e3d7ad5@mail.gmail.com> <3b3f27c60911172007o76242838v566071d74f653ee9@mail.gmail.com> Message-ID: <90F5F18F-C02F-4408-ACAB-2D62148BFEF5@labnotes.org> On Nov 17, 2009, at 8:07 PM, Nathan Beyer wrote: > On Tue, Nov 17, 2009 at 12:16 AM, Assaf Arkin wrote: >> On Mon, Nov 16, 2009 at 8:10 PM, Nathan Beyer wrote: >>> >>> I've found that my instantiation of the Rake Package task for >>> packaging up a Rails app isn't including the '.specification' files in >>> the '/vendor/gems/**/*' pattern. I've recreated this on Linux and Mac >>> OS X. >>> >>> It seems the issue is that the files, which are copied from their >>> origin to the target folder, are missing the files. I'm guessing this >>> is because of the underlying copy commands, but haven't dug into it >>> yet. >> >> FileList (also Dir.glob, File.fnmatch) does not match dot files when you use >> the pattern "*". That's by design, dot files are hidden, so the default >> behavior is to not match them. You can use the option File::FNM_DOTMATCH, >> or change the pattern to match "{.*,*}". > > I assumed it was default behavior, i just didn't know how to get it > changed in this case. > > Is the use of curly braces in the FileList [] method documented > somewhere, I haven't seen that before? Is "{.*,*}" the same as two > separate patterns ".*" and "*" in the same FileList[]? FileList uses Dir.glob to find files (to include and exclude), and so supports all the same patterns: http://ruby-doc.org/core/classes/Dir.html#M002322 Assaf > > Thanks for the help. > -Nathan > >> Assaf Arkin >> Blogging at labnotes.org >> >>> >>> Has anyone else run into this? Is there anyway to get Rake to pickup >>> '.specification' or any other "dot" files? >>> _______________________________________________ >>> Rake-devel mailing list >>> Rake-devel at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/rake-devel >> >> >> _______________________________________________ >> Rake-devel mailing list >> Rake-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/rake-devel >> > _______________________________________________ > Rake-devel mailing list > Rake-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rake-devel