Merge lp:~sergiusens/ubuntu-qtcreator-plugins/phablet-flash-new-syntax into lp:ubuntu-qtcreator-plugins

Proposed by Sergio Schvezov on 2013-08-09
Status: Needs review
Proposed branch: lp:~sergiusens/ubuntu-qtcreator-plugins/phablet-flash-new-syntax
Merge into: lp:ubuntu-qtcreator-plugins
Diff against target: 53 lines (+15/-4)
3 files modified
ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/device_flashdaily (+5/-2)
ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/device_flashdaily_bootstrap (+4/-2)
ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/functions.inc (+6/-0)
To merge this branch: bzr merge lp:~sergiusens/ubuntu-qtcreator-plugins/phablet-flash-new-syntax
Reviewer Review Type Date Requested Status
Ubuntu SDK team 2013-08-09 Pending
Review via email: mp+179317@code.launchpad.net

Commit message

Contemplating phablet-flash's new syntax

Description of the change

This is to take into account:
https://code.launchpad.net/~sergiusens/phablet-tools/flash_change/+merge/177927

I've added a check into the functions to verify the tool syntax to use.
I did not update the help though since the aforementioned MR should be merged Fri.

To post a comment you must log in.

Unmerged revisions

269. By Sergio Schvezov on 2013-08-09

phablet-flash new syntax.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/device_flashdaily'
2--- ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/device_flashdaily 2013-06-25 16:28:00 +0000
3+++ ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/device_flashdaily 2013-08-09 04:04:13 +0000
4@@ -30,8 +30,11 @@
5 echo ${DEVICE_HARDWARE}
6 echo
7 echo " In order to flash your device, you must do it manually:"
8- echo " phablet-flash -s ${SERIALNUMBER} -d ${IMAGE_HARDWARE}"
9+ echo " phablet-flash cdimage-touch -s ${SERIALNUMBER} -d ${IMAGE_HARDWARE}"
10 echo
11+elif [[ phablet_tools_new_syntax ]]; then
12+ x-terminal-emulator -e "bash -ic 'phablet-flash cdimage-touch -s ${SERIALNUMBER}'"
13 else
14 x-terminal-emulator -e "bash -ic 'phablet-flash -s ${SERIALNUMBER}'"
15-fi
16\ No newline at end of file
17+else
18+fi
19
20=== modified file 'ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/device_flashdaily_bootstrap'
21--- ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/device_flashdaily_bootstrap 2013-06-25 16:28:00 +0000
22+++ ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/device_flashdaily_bootstrap 2013-08-09 04:04:13 +0000
23@@ -30,8 +30,10 @@
24 echo ${DEVICE_HARDWARE}
25 echo
26 echo " In order to flash your device, you must do it manually:"
27- echo " phablet-flash -s ${SERIALNUMBER} -d ${IMAGE_HARDWARE} -b"
28+ echo " phablet-flash cdimage-touch -s ${SERIALNUMBER} -d ${IMAGE_HARDWARE} -b"
29 echo
30+elif [[ phablet_tools_new_syntax ]]; then
31+ x-terminal-emulator -e "bash -ic 'phablet-flash cdimage-touch -s ${SERIALNUMBER}' -b"
32 else
33 x-terminal-emulator -e "bash -ic 'phablet-flash -s ${SERIALNUMBER}' -b"
34-fi
35\ No newline at end of file
36+fi
37
38=== modified file 'ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/functions.inc'
39--- ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/functions.inc 2013-07-25 09:24:30 +0000
40+++ ubuntu-qtcreator-plugins-common/share/qtcreator/ubuntu/scripts/functions.inc 2013-08-09 04:04:13 +0000
41@@ -64,6 +64,12 @@
42 adb_shell "su ${USERNAME} -c \"$@\""
43 }
44
45+function phablet_tools_new_syntax {
46+ installed_version=$(dpkg-query --show --showformat '${Version}' phablet-tools)
47+ dpkg --compare-versions $installed_version ge 1.0
48+ echo $?
49+}
50+
51 function ubuntu_stamp {
52 adb_shell cat /system/*ubuntu_stamp
53 }

Subscribers

People subscribed via source and target branches