Merge lp:~a-j-buxton/phablet-tools/download-only into lp:phablet-tools
Proposed by
Alistair Buxton
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Ricardo Salveti | ||||
Approved revision: | 68 | ||||
Merged at revision: | 64 | ||||
Proposed branch: | lp:~a-j-buxton/phablet-tools/download-only | ||||
Merge into: | lp:phablet-tools | ||||
Diff against target: |
93 lines (+30/-22) 1 file modified
phablet-flash (+30/-22) |
||||
To merge this branch: | bzr merge lp:~a-j-buxton/phablet-tools/download-only | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
PS Jenkins bot | continuous-integration | Approve | |
Ricardo Salveti (community) | Approve | ||
Review via email:
|
Commit message
Adds an option to only download image files and skip device flashing.
Description of the change
Adds an option to only download image files and skip device flashing. If device is connected it will be autodetected as normal, but free space check is not done. If no device is connected, -d can be used to select a target device as normal.
To post a comment you must log in.
24 + '--download',
Would you mind using --download-only instead? This is just to make it easier for people when only reading the arg list.
37 - device = validate_ device( adb, args.device) device( adb, args.device)
38 + if args.download:
39 + device = detect_device(adb, args.device)
40 + else:
41 + device = validate_
I'd suggest to always call detect_device and remove it from validate_device. Also move validate_device a bit bellow in the code, to call it only in case we're actually flashing the device (bellow line 59, for example).