def upload(self, possible_firmwares):
        firmware = _firmware_to_upload(self.bii, possible_firmwares)
        self.bii.user_io.out.writeln('Uploading...')

        build_command = 'make' if sys.platform != 'win32' else 'mingw32-make'
        if OSInfo.is_linux():
            build_command = "sudo %s" % build_command
        build_command = "%s %s-upload" % (build_command, firmware)
        self._execute_upload_command(build_command)
Does the commit itself and resets the dirty flag.
dataset/ETHPy150Open biicode/client/dev/hardware/arduino/arduino.py/Arduino.upload--crossover with--dataset/ETHPy150Open AppScale/appscale/AppServer/lib/django-1.5/django/db/transaction.py/commit