Remove platform CPP from nativeGen/PPC/CodeGen.hs
[ghc-hetmet.git] / sync-all
index 2d2a2cd..8b41c97 100755 (executable)
--- a/sync-all
+++ b/sync-all
@@ -68,9 +68,6 @@ my $ignore_failure = 0;
 my $checked_out_flag = 0;
 my $get_mode;
 
-# Flags specific to a particular command
-my $local_repo_unnecessary = 0;
-
 my %tags;
 
 # Figure out where to get the other repositories from.
@@ -286,25 +283,25 @@ sub scmall {
             if (-d $localpath) {
                 warning("$localpath already present; omitting")
                     if $localpath ne ".";
+                if ($scm eq "git") {
+                    scm ($localpath, $scm, "config", "core.ignorecase", "true");
+                }
                 next;
             }
-            
-            # The first time round the loop, default the get-mode
-            if ($scm eq "darcs" && not defined($get_mode)) {
-                warning("adding --partial, to override use --complete");
-                $get_mode = "--partial";
-            }
-            
-            # The only command that doesn't need a repo
-            $local_repo_unnecessary = 1;
-            
+
             # Note that we use "." as the path, as $localpath
             # doesn't exist yet.
             if ($scm eq "darcs") {
+                # The first time round the loop, default the get-mode
+                if (not defined($get_mode)) {
+                    warning("adding --partial, to override use --complete");
+                    $get_mode = "--partial";
+                }
                 scm (".", $scm, "get", $get_mode, $path, $localpath, @args);
             }
             else {
                 scm (".", $scm, "clone", $path, $localpath, @args);
+                scm ($localpath, $scm, "config", "core.ignorecase", "true");
             }
             next;
         }
@@ -313,20 +310,14 @@ sub scmall {
             if (-d "$localpath/.git") {
                 die "Found both _darcs and .git in $localpath";
             }
-            else {
-                $scm = "darcs";
-            }
-        }
-        else {
-            if (-d "$localpath/.git") {
-                $scm = "git";
-            }
-            elsif ($tag eq "") {
-                die "Required repo $localpath is missing";
-            }
-            else {
-                message "== $localpath repo not present; skipping";
-            }
+            $scm = "darcs";
+        } elsif (-d "$localpath/.git") {
+            $scm = "git";
+        } elsif ($tag eq "") {
+            die "Required repo $localpath is missing";
+        } else {
+             message "== $localpath repo not present; skipping";
+             next;
         }
 
         # Work out the arguments we should give to the SCM
@@ -375,6 +366,9 @@ sub scmall {
             my @scm_args = ("log", "$branch_name..");
             scm ($localpath, $scm, @scm_args, @args);
         }
+        elsif ($command =~ /^log$/) {
+            scm ($localpath, $scm, "log", @args);
+        }
         elsif ($command =~ /^remote$/) {
             my @scm_args;
             if ($subcommand eq 'add') {
@@ -386,12 +380,22 @@ sub scmall {
             }
             scm ($localpath, $scm, @scm_args, @args);
         }
+        elsif ($command =~ /^checkout$/) {
+            # Not all repos are necessarily branched, so ignore failure
+            $ignore_failure = 1;
+            scm ($localpath, $scm, "checkout", @args)
+                unless $scm eq "darcs";
+        }
         elsif ($command =~ /^grep$/) {
             # Hack around 'git grep' failing if there are no matches
             $ignore_failure = 1;
             scm ($localpath, $scm, "grep", @args)
                 unless $scm eq "darcs";
         }
+        elsif ($command =~ /^clean$/) {
+            scm ($localpath, $scm, "clean", @args)
+                unless $scm eq "darcs";
+        }
         elsif ($command =~ /^reset$/) {
             scm ($localpath, $scm, "reset", @args)
                 unless $scm eq "darcs";
@@ -428,9 +432,12 @@ Supported commands:
  * remote add <branch-name>
  * remote rm <branch-name>
  * remote set-url [--push] <branch-name>
+ * checkout
  * grep
+ * clean
  * reset
  * config
+ * log
 
 Available package-tags are:
 END