def run(self):
        """ Run all the git-up stuff. """
        try:
            if self.should_fetch:
                self.fetch()

            self.rebase_all_branches()

            if self.with_bundler():
                self.check_bundler()

            if self.settings['push.auto']:
                self.push()

        except GitError as error:
            self.print_error(error)

            # Used for test cases
            if self.testing:
                raise
            else:  # pragma: no cover
                sys.exit(1)
def run ( self ) : try : if self . should_fetch : self . fetch ( ) self . rebase_all_branches ( ) if self . with_bundler ( ) : self . check_bundler ( ) if self . settings [ 'push.auto' ] : self . push ( ) except GitError as error : self . print_error ( error ) if self . testing : raise else : sys . exit ( 1 )
Run all the git-up stuff.