]> code.delx.au - gnu-emacs/blobdiff - admin/update_autogen
Merge from emacs-24
[gnu-emacs] / admin / update_autogen
index 8b0ae67028a459a836f78d815bd59cc4bbaa817d..4c4f52e2d2d82f0b8270bc970773baa28830bc1e 100755 (executable)
@@ -47,7 +47,9 @@ cd $PD
 cd ../
 [ -d admin ] || die "Could not locate admin directory"
 
-if [ -d .git ]; then
+if [ -d .bzr ]; then
+    vcs=bzr
+elif [ -d .git ]; then
     vcs=git
 else
     die "Cannot determine vcs"
@@ -303,6 +305,9 @@ EOF
 
     modified=$(status $basegen) || die
 
+    ## bzr status output is always relative to top-level, not PWD.
+    [ "$vcs" = "bzr" ] && cd $oldpwd
+
     commit "generated" $modified || die "commit error"
 
     exit 0
@@ -374,7 +379,11 @@ echo "Checking status of loaddef files..."
 ## It probably would be fine to just check+commit lisp/, since
 ## making autoloads should not effect any other files.  But better
 ## safe than sorry.
-modified=$(status $genfiles $ldefs_out) || die
+modified=$(status $genfiles ${ldefs_out#lisp/}) || die
+
+
+## bzr status output is always relative to top-level, not PWD.
+[ "$vcs" = "bzr" ] && cd ../
 
 
 commit "loaddefs" $modified || die "commit error"