]> git.madduck.net Git - code/myrepos.git/commitdiff

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

Support bzr checkouts, which are updated with "bzr update", and to which bzr automati...
authorJoey Hess <joey@kitenet.net>
Tue, 27 Sep 2011 21:38:18 +0000 (17:38 -0400)
committerJoey Hess <joey@kitenet.net>
Tue, 27 Sep 2011 21:38:18 +0000 (17:38 -0400)
debian/changelog
mr

index 766b8da3223401c218e82034f1aeb02c1c8d3b56..5199ab4640db3c18cfaccf9b628b30295b789ed3 100644 (file)
@@ -1,4 +1,4 @@
-mr (1.05) UNRELEASED; urgency=low
+mr (1.05) unstable; urgency=low
 
   * Avoid using sed -r in git-fake-bare, for OSX portability.
   * git-fake-bare: handle fake bare repositories with core.bare not set
@@ -9,8 +9,10 @@ mr (1.05) UNRELEASED; urgency=low
   * Allow untrusted mrconfig files to set parameters to true/false.
     So skip=true or deleted=true canbe used in an untrusted mrconfig file.
   * Also allow order=N in an untrusted mrconfig file.
+  * Support bzr checkouts, which are updated with "bzr update",
+    and to which bzr automatically pushes commits. Closes: #643589
 
- -- Joey Hess <joeyh@debian.org>  Fri, 05 Aug 2011 13:29:21 -0400
+ -- Joey Hess <joeyh@debian.org>  Tue, 27 Sep 2011 17:28:35 -0400
 
 mr (1.04) unstable; urgency=low
 
diff --git a/mr b/mr
index d5424caa2eed10a3ff23d1fe81d58bf5060b7b25..10a547f1ec979ff508a74b175e2d07a09b14a1bd 100755 (executable)
--- a/mr
+++ b/mr
@@ -1688,6 +1688,9 @@ lib =
                        return 0
                fi
        }
+       is_bzr_checkout() {
+               LANG=C bzr info | egrep -q '^Checkout'
+       }
 
 svn_test = test -d "$MR_REPO"/.svn
 git_test = test -d "$MR_REPO"/.git
@@ -1703,7 +1706,12 @@ git_bare_test =
 
 svn_update = svn update "$@"
 git_update = git pull "$@"
-bzr_update = bzr merge --pull "$@"
+bzr_update = 
+       if is_bzr_checkout; then
+               bzr update "$@"
+       else
+               bzr merge --pull "$@"
+       fi
 cvs_update = cvs update "$@"
 hg_update  = hg pull "$@" && hg update "$@"
 darcs_update = darcs pull -a "$@"
@@ -1719,7 +1727,12 @@ fossil_status = fossil changes "$@"
 
 svn_commit = svn commit "$@"
 git_commit = git commit -a "$@" && git push --all
-bzr_commit = bzr commit "$@" && bzr push
+bzr_commit = 
+       if is_bzr_checkout; then
+               bzr commit "$@"
+       else
+               bzr commit "$@" && bzr push
+       fi
 cvs_commit = cvs commit "$@"
 hg_commit  = hg commit -m "$@" && hg push
 darcs_commit = darcs record -a -m "$@" && darcs push -a