chiark / gitweb /
Check bottom and invariants
[stgit] / stgit / commands / unapplied.py
index cbac0524e11f6ce8c63009695c91419d4d97e79c..d5bb43e3004f1b7aabd71dacaf1319703e440415 100644 (file)
@@ -21,6 +21,7 @@ from optparse import OptionParser, make_option
 
 from stgit.commands.common import *
 from stgit.utils import *
 
 from stgit.commands.common import *
 from stgit.utils import *
+from stgit.out import *
 from stgit import stack, git
 
 
 from stgit import stack, git
 
 
@@ -30,6 +31,7 @@ usage = """%prog [options]
 List the patches from the series which are not pushed onto the stack.
 They are listed in the reverse order in which they were popped."""
 
 List the patches from the series which are not pushed onto the stack.
 They are listed in the reverse order in which they were popped."""
 
+directory = DirectoryHasRepository()
 options = [make_option('-b', '--branch',
                        help = 'use BRANCH instead of the default one'),
            make_option('-c', '--count',
 options = [make_option('-b', '--branch',
                        help = 'use BRANCH instead of the default one'),
            make_option('-c', '--count',
@@ -46,7 +48,7 @@ def func(parser, options, args):
     unapplied = crt_series.get_unapplied()
 
     if options.count:
     unapplied = crt_series.get_unapplied()
 
     if options.count:
-        print len(unapplied)
+        out.stdout(len(unapplied))
     else:
         for p in unapplied:
     else:
         for p in unapplied:
-            print p
+            out.stdout(p)