Fix --oneshot handling from the previous commit.
authorZac Medico <zmedico@gentoo.org>
Tue, 3 Jul 2007 17:49:36 +0000 (17:49 -0000)
committerZac Medico <zmedico@gentoo.org>
Tue, 3 Jul 2007 17:49:36 +0000 (17:49 -0000)
svn path=/main/trunk/; revision=7139

pym/emerge/__init__.py

index 8d34329870647131b9319a436babc18b338318ab..27c1645e6e3dbb1d10c2f2af83f93bfcbb0193fc 100644 (file)
@@ -1551,13 +1551,15 @@ class depgraph(object):
                                                        greedy_atoms.append((myarg, myslot_atom))
                        arg_atoms = greedy_atoms
 
+               oneshot = "--oneshot" in self.myopts
                """ These are used inside self.create() in order to ensure packages
                that happen to match arguments are not incorrectly marked as nomerge."""
                for myarg, myatom in arg_atoms:
                        if myatom in self._args_atoms:
                                continue
                        self._args_atoms.add(myatom)
-                       myfavorites.append(myatom)
+                       if not oneshot:
+                               myfavorites.append(myatom)
                for myarg, myatom in arg_atoms:
                                try:
                                        self.mysd = self.select_dep(myroot, myatom, arg=myarg)