[gambit-list] [PATCH 6/6] makefile.in: remove sub-paths from $(REMOTE) for git remote update
Christian Jaeger
chrjae at gmail.com
Fri Apr 30 10:54:19 EDT 2010
For example, my set up has the original Gambit master branch in
origin/origin/master, which I'm doing with the following rule in
.git/config:
[remote "origin"]
url = /usr/src/gambc-v4_4_3-devel/.git
fetch = +refs/remotes/origin/*:refs/remotes/origin/origin/*
So I need to set REMOTE to origin/origin; but to update origin/origin
we need to call "git remote update origin".
Seems messy? But I don't see how to do this cleaner.
---
makefile.in | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/makefile.in b/makefile.in
index 44e720a..ce50ee4 100644
--- a/makefile.in
+++ b/makefile.in
@@ -146,7 +146,7 @@ push: fake_target
pull: fake_target
@if test "$(RC)" = "$(GIT)"; then \
$(GIT) rev-parse $(REMOTE)/master > /dev/null 2>&1 || { echo "WARNING: branch '$(REMOTE)/master' does not seem to exist; set the REMOTE environment variable to the name of the correct remote if it is not 'origin'"; }; \
- $(GIT) remote update $(REMOTE); \
+ $(GIT) remote update "`echo "$(REMOTE)"| sed 's/\/.*//'`"; \
else \
$(HG) pull; \
fi
--
1.7.0.3
More information about the Gambit-list
mailing list