Package: svn-buildpackage Version: 0.6.14 Severity: wishlist Tags: patch Hi,
after some discussion on IRC about the usefulness of a --no-branches option, I implemented this patch, which adds the --no-branches option to svn-inject. The original idea came up in the pkg-ruby-extras project, which uses a build system that pulls in upstream sources using a different script. The `branches' subdirectory is not needed in their repository layout. The patch is relatively small, but may need some cleaning up. Cheers, Thierry -- System Information: Debian Release: testing/unstable APT prefers unstable APT policy: (500, 'unstable'), (1, 'experimental') Architecture: i386 (i686) Shell: /bin/sh linked to /bin/bash Kernel: Linux 2.6.14-fglrx-alsa Locale: LANG=en_IE.UTF-8, LC_CTYPE=en_IE.UTF-8 (charmap=UTF-8) Versions of packages svn-buildpackage depends on: ii devscripts 2.9.10 Scripts to make the life of a Debi ii libsvn-core-perl 1.2.3dfsg1-3 perl bindings for Subversion (aka. ii perl 5.8.7-10 Larry Wall's Practical Extraction ii subversion 1.2.3dfsg1-3 advanced version control system (a ii subversion-tools 1.2.3dfsg1-3 assorted tools related to Subversi svn-buildpackage recommends no packages. -- no debconf information
diff -Nur svn-buildpackage-0.6.14.orig/svn-inject svn-buildpackage-0.6.14/svn-inject --- svn-buildpackage-0.6.14.orig/svn-inject 2005-10-13 21:29:24.000000000 +0200 +++ svn-buildpackage-0.6.14/svn-inject 2006-01-02 01:50:36.000000000 +0100 @@ -49,6 +49,7 @@ my $opt_dolike; my $opt_addtar; #my $opt_trackmode; +my $opt_no_branches; # parse Command line %options = ( @@ -61,7 +62,8 @@ "o" => \$opt_onlychanged, # "u=s" => \$opt_trackmode, "add-tar" => \$opt_addtar, - "c=i" => \$opt_checkout + "c=i" => \$opt_checkout, + "no-branches" => \$opt_no_branches ); &help unless ( GetOptions(%options)); @@ -173,7 +175,7 @@ chdir $tempdir; # preparing a package tree that will be inserted into repository later -if($dscOrig) { +if($dscOrig && !$opt_no_branches) { # prepare the upstream source withecho "mkdir", "-p", "$package/branches/upstream"; chdir "$package/branches/upstream"; @@ -227,20 +229,25 @@ # Final tree prepation before commit, preconfiguring already mkdir "$package/tags"; $SDCommon::c{"tagsUrl"}="$opt_svnurl/$package/tags"; -$SDCommon::c{"upsCurrentUrl"}="$opt_svnurl/$package/branches/upstream/current"; -$SDCommon::c{"upsTagUrl"}="$opt_svnurl/$package/branches/upstream"; + +if (!$opt_no_branches) { + $SDCommon::c{"upsCurrentUrl"}="$opt_svnurl/$package/branches/upstream/current"; + $SDCommon::c{"upsTagUrl"}="$opt_svnurl/$package/branches/upstream"; +} # go, go, go withecho "svn $SVN_QUIET import -m\"$scriptname Installing original source of $package\" $package $opt_svnurl/$package"; # for non-native: create the trunk copy from the source and modify it if($dscOrig) { - withecho("svn", "-m", "$scriptname Tagging upstream source version of $package", "copy", - "$opt_svnurl/$package/branches/upstream/current", - "$opt_svnurl/$package/branches/upstream/$upsVersion", $SVN_QUIET); - withecho("svn", "-m", "$scriptname Forking $package source to Trunk", "copy", - "$opt_svnurl/$package/branches/upstream/current", - "$opt_svnurl/$package/trunk", $SVN_QUIET); + if (!$opt_no_branches) { + withecho("svn", "-m", "$scriptname Tagging upstream source version of $package", "copy", + "$opt_svnurl/$package/branches/upstream/current", + "$opt_svnurl/$package/branches/upstream/$upsVersion", $SVN_QUIET); + withecho("svn", "-m", "$scriptname Forking $package source to Trunk", "copy", + "$opt_svnurl/$package/branches/upstream/current", + "$opt_svnurl/$package/trunk", $SVN_QUIET); + } mkdir "tmp"; chdir "tmp"; withecho "dpkg-source -x $opt_dsc";
signature.asc
Description: Digital signature