From goodrich at fas.harvard.edu  Wed Jan 23 19:45:22 2008
From: goodrich at fas.harvard.edu (goodrich at fas.harvard.edu)
Date: Wed, 23 Jan 2008 19:45:22 +0100 (CET)
Subject: [Rd] [wishlist,
	patch] Removing .bzr/ directory when calling R CMD build (PR#10625)
Message-ID: <20080123184522.41FB0283462B@mail.pubhealth.ku.dk>

Full_Name: Ben Goodrich
Version: 2.6.1
OS: Debian
Submission from: (NULL) (128.103.222.166)


bzr is another version control system and adds a .bzr folder to the top-level
directory of a package, similar to .svn and .git for subversion and git
respectively. However, while R CMD build removes directories called .svn, .git,
and some others, it does not remove .bzr . As a result, the .bzr folder is
unnecessarily included in the cleanly built package and there are accurate but
unnecessary warnings that say certain subdirectories of the .bzr directory are
empty. I believe the following patch, which is lightly tested with R-devel, is
sufficient to remove the .bzr folder and prevent these warnings. It does not,
however, remove the .bzrignore file (if it exists) but perhaps it should be
augmented to do so.

--- src/scripts/build.in        2008-01-23 11:42:47.000000000 -0500
+++ build.in    2008-01-23 11:45:02.000000000 -0500
@@ -215,6 +215,7 @@
        print EXCLUDE "$File::Find::name\n" if(-d $_ && /^\.svn$/);
        print EXCLUDE "$File::Find::name\n" if(-d $_ && /^\.arch-ids$/);
        print EXCLUDE "$File::Find::name\n" if(-d $_ && /^\.git$/);
+       print EXCLUDE "$File::Find::name\n" if(-d $_ && /^\.bzr$/);
        ## Windows DLL resource file
        push(@exclude_patterns, "^src/" . $pkgname . "_res\\.rc");
        my $filename = $File::Find::name;



[Rd] [wishlist, patch] Removing .bzr/ directory when calling R CMD build (PR#10625)
goodrich at fas.harvard.edu