Don't run post_emerge() when --pretend is enabled.
authorZac Medico <zmedico@gentoo.org>
Mon, 26 Jun 2006 02:27:48 +0000 (02:27 -0000)
committerZac Medico <zmedico@gentoo.org>
Mon, 26 Jun 2006 02:27:48 +0000 (02:27 -0000)
svn path=/main/trunk/; revision=3662

bin/emerge

index d75a5b6034fb1e7b8251c9ca05872aa36d960237..2712a93a00a1dd43e80daf0784cbcb6bb0313371 100755 (executable)
@@ -3321,7 +3321,8 @@ def action_build(myopts, myaction, myfiles):
                        portage.writemsg_stdout(colorize("WARN", "WARNING:")
                                + " AUTOCLEAN is disabled.  This can cause serious"
                                + " problems due to overlapping packages.\n")
-       post_emerge(settings, info_mtimes, 0)
+       if "--pretend" not in myopts:
+               post_emerge(settings, info_mtimes, 0)
 
 def parse_opts(tmpcmdline):
        myaction=None
@@ -3685,8 +3686,9 @@ if __name__ == "__main__":
                vartree = trees[settings["ROOT"]]["vartree"]
                if 1 == unmerge(settings, myopts, vartree, myaction, myfiles,
                        raise_on_missing=False):
-                       post_emerge(settings, info_mtimes, 0)
-       
+                       if "--pretend" not in myopts:
+                               post_emerge(settings, info_mtimes, 0)
+
        elif "depclean"==myaction:
                action_depclean(myopts)
        # "update", "system", or just process files: