Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


that's one solution ... the other to compare the DIR and RAWBUILDDIR


Am 19.01.2011 23:43, schrieb Norbert Thiebaud:
On Wed, Jan 19, 2011 at 4:36 PM, Bircher Florian <florian.bi@gmx.net> wrote:
ahh, yes: once upon a time bootstrap was a cloned git repo like the
other... but now there is no need for links since the dubsdirectory of
bootstrap are already there.
in this case you want to exclude the case where REPO='bootstrap"
around for for link $(ls) loop

Norbert
 
From 2de7b9f7339ebb290e791ab199cdddadc96baebf Mon Sep 17 00:00:00 2001
From: Florian Bircher <florian.bi@gmx.net>
Date: Thu, 20 Jan 2011 00:15:36 +0100
Subject: [PATCH] git warpper: forcing the recreation of symlinks

---
 g |   17 ++++++++++-------
 1 files changed, 10 insertions(+), 7 deletions(-)

diff --git a/g b/g
index 2f6fcd4..4d143c3 100755
--- a/g
+++ b/g
@@ -233,13 +233,16 @@ for REPO in $DIRS ; do
 
             case "$COMMAND" in
                 pull|clone)
-                    # update links
-                    for link in $(ls) ; do
-                        if [ ! -e "$RAWBUILDDIR/$link" ] ; then
-                            echo "Creating missing link $link"
-                            ln -s "$DIR/$link" "$RAWBUILDDIR/$link"
-                        fi
-                    done
+                    # Only update the Links when your not in main-repo (bootstrap)
+                                       if [ "$RAWBUILDDIR" != "$DIR" ] ; then
+                                               # update links
+                                               for link in $(ls) ; do
+                                                       if [ ! -e "$RAWBUILDDIR/$link" ] ; then
+                                                               echo "Creating missing link $link"
+                                                               ln -sf "$DIR/$link" 
"$RAWBUILDDIR/$link"
+                                                       fi
+                                               done
+                                       fi
                     ;;
                 status)
                     # git status returns error in some versions, clear that
-- 
1.7.3.3


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.