Revision 4220c336 snf-cyclades-app/synnefo/quotas/management/commands/enforce-resources-cyclades.py

b/snf-cyclades-app/synnefo/quotas/management/commands/enforce-resources-cyclades.py
75 75
    )
76 76

  
77 77
    def confirm(self):
78
        self.stderr.write("Confirm? [y/N] ")
78
        self.stdout.write("Confirm? [y/N] ")
79 79
        response = raw_input()
80 80
        if string.lower(response) not in ['y', 'yes']:
81
            self.stdout.write("Aborted.\n")
81
            self.stderr.write("Aborted.\n")
82 82
            exit()
83 83

  
84 84
    def get_handlers(self, resources):
......
169 169
            return
170 170

  
171 171
        headers = ("#", "User", "Source", "Resource", "Limit", "Usage")
172
        pprint_table(self.stderr, overlimit, headers,
172
        pprint_table(self.stdout, overlimit, headers,
173 173
                     options["output_format"], title="Violations")
174 174

  
175 175
        if any(actions.values()):
176
            write("\n")
176
            self.stdout.write("\n")
177 177
            if fix:
178 178
                if dangerous and not force:
179 179
                    write("You are enforcing resources that may permanently "
......
185 185
            headers = ("Type", "ID", "State", "Backend", "Action", "Violation")
186 186
            if fix:
187 187
                headers += ("Result",)
188
            pprint_table(self.stderr, log, headers,
188
            pprint_table(self.stdout, log, headers,
189 189
                         options["output_format"], title=title)

Also available in: Unified diff