Merge lp:~zeller-benjamin/qtcreator-plugin-ubuntu/1362439 into lp:qtcreator-plugin-ubuntu

Proposed by Benjamin Zeller
Status: Rejected
Rejected by: Zoltan Balogh
Proposed branch: lp:~zeller-benjamin/qtcreator-plugin-ubuntu/1362439
Merge into: lp:qtcreator-plugin-ubuntu
Diff against target: 227 lines (+0/-212)
2 files modified
share/qtcreator/ubuntu/menu.json (+0/-11)
share/qtcreator/ubuntu/scripts/local_get_cordova_runtime (+0/-201)
To merge this branch: bzr merge lp:~zeller-benjamin/qtcreator-plugin-ubuntu/1362439
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Approve
Maxim Ermilov Pending
Zoltan Balogh Pending
Review via email: mp+234666@code.launchpad.net

Commit message

support for using cordova api from unity-webapps-qml was deprecated,
remove unused menu item and script

Description of the change

support for using cordova api from unity-webapps-qml was deprecated,
remove unused menu item and script:

<zaspire> zbenjamin: we deprecated support for using cordova api from unity-webapps-qml. So best solution would be removing any mention about cordova from qtcreator-plugin-ubuntu
<zbenjamin> zaspire: ah ok, so we can remove that item from the menu.json
<zaspire> zbenjamin: it will be great ;)

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
David Barth (dbarth) wrote :

This is a correct change, yes. But do not apply that change until the rest of the plan is implemented. I will hold on approving this branch for now, to avoid this being merged in by mistake <grin> ;)

Unmerged revisions

286. By Benjamin Zeller

support for using cordova api from unity-webapps-qml was deprecated,
remove unused menu item and script

285. By Benjamin Zeller

Merge

284. By Benjamin Zeller

Make sure the .ssh directory has the right owner and permissions

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'share/qtcreator/ubuntu/menu.json'
2--- share/qtcreator/ubuntu/menu.json 2014-08-19 09:50:02 +0000
3+++ share/qtcreator/ubuntu/menu.json 2014-09-15 11:07:30 +0000
4@@ -300,17 +300,6 @@
5 ]
6 },
7 {
8- "name": "Add Cordova runtime to HTML5 project",
9- "id": "Ubuntu.Menu.DownloadCordovaRuntime",
10- "workingDirectory": "%0/..",
11- "projectRequired": true,
12- "ubuntuHtmlProjectRequired": true,
13- "saveRequired": true,
14- "actions": [
15- "%SCRIPTDIRECTORY%/local_get_cordova_runtime %FOLDERNAME%"
16- ]
17- },
18- {
19 "name": "GPG",
20 "id": "Ubuntu.Menu.gpg",
21 "submenu": [
22
23=== removed file 'share/qtcreator/ubuntu/scripts/local_get_cordova_runtime'
24--- share/qtcreator/ubuntu/scripts/local_get_cordova_runtime 2014-02-25 16:23:39 +0000
25+++ share/qtcreator/ubuntu/scripts/local_get_cordova_runtime 1970-01-01 00:00:00 +0000
26@@ -1,201 +0,0 @@
27-#!/bin/bash
28-# Copyright 2014 Canonical Ltd.
29-#
30-# This program is free software; you can redistribute it and/or modify
31-# it under the terms of the GNU Lesser General Public License as published by
32-# the Free Software Foundation; version 2.1.
33-#
34-# This program is distributed in the hope that it will be useful,
35-# but WITHOUT ANY WARRANTY; without even the implied warranty of
36-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
37-# GNU Lesser General Public License for more details.
38-#
39-# You should have received a copy of the GNU Lesser General Public License
40-# along with this program. If not, see <http://www.gnu.org/licenses/>.
41-#
42-# Author: David Barth <david.barth@canonical.com>
43-
44-SCRIPTPATH=`dirname $0`
45-
46-CORDOVA_PACKAGE="ubuntu-html5-platform-3.4-dev"
47-PAYLOAD_DIR="usr/share/ubuntu-html5-platform-3.4/"
48-CORDOVA_CACHE=${HOME}/.cache/ubuntu-html5-platform
49-DOWNLOAD_DIR=${CORDOVA_CACHE}/download
50-
51-# based on the blog post of Andreas Olsson
52-# http://blog.bogosity.se/2012/11/03/fully-using-apt-get-download/
53-setup_apt_conf () {
54- mkdir -p ${DOWNLOAD_DIR}/apt/{apt.conf.d,preferences.d,trusted.gpg.d,cache/lists/partial}
55- touch ${DOWNLOAD_DIR}/apt/status
56- ln -s /usr/share/keyrings/debian-archive-keyring.gpg \
57- ${DOWNLOAD_DIR}/apt/trusted.gpg.d/
58- ln -s /usr/share/keyrings/ubuntu-archive-keyring.gpg \
59- ${DOWNLOAD_DIR}/apt/trusted.gpg.d/
60- apt-key --keyring ${DOWNLOAD_DIR}/apt/trusted.gpg.d/ppa.gpg adv \
61- --keyserver keyserver.ubuntu.com --recv-keys C7122F9B 1>/dev/null
62- echo
63-
64- cat > ${DOWNLOAD_DIR}/apt/downloader.conf <<EOF
65-Dir::Cache "${DOWNLOAD_DIR}/apt/cache";
66-Dir::Etc "${DOWNLOAD_DIR}/apt";
67-Dir::State::Lists "${DOWNLOAD_DIR}/apt/cache/lists";
68-Dir::State::status "${DOWNLOAD_DIR}/apt/status";
69-Acquire::Languages "none";
70-EOF
71-}
72-
73-setup_apt_conf_for_release () {
74- RELEASE=$1
75- ARCH=$2
76-
77- [ -z "$RELEASE" ] && exit "setup_apt_conf_for_release"
78-
79- # echo "Apt::Architecture \"${ARCH}\";" >> \
80- # ${DOWNLOAD_DIR}/apt/downloader.conf
81-
82- if [ "$ARCH" == "armhf" ]; then
83- cat > ${DOWNLOAD_DIR}/apt/sources.list <<EOF
84-# Do not use the archive for now
85-# deb http://ports.ubuntu.com/ubuntu-ports/ ${RELEASE} main restricted universe
86-# deb http://ports.ubuntu.com/ubuntu-ports/ ${RELEASE}-updates main restricted universe
87-# deb http://ports.ubuntu.com/ubuntu-ports/ ${RELEASE}-security main restricted universe
88-
89-# use the SDK PPA instead
90-deb http://ppa.launchpad.net/ubuntu-sdk-team/ppa/ubuntu ${RELEASE} main
91-EOF
92- else
93- cat > ${DOWNLOAD_DIR}/apt/sources.list <<EOF
94-# Do not use the archive for now
95-# deb http://archive.ubuntu.com/ubuntu ${RELEASE} main restricted universe
96-# deb http://archive.ubuntu.com/ubuntu ${RELEASE}-updates main restricted universe
97-# deb http://security.ubuntu.com/ubuntu ${RELEASE}-security main restricted universe
98-# deb http://ppa.launchpad.net/ubuntu-sdk-team/ppa/ubuntu ${RELEASE} main
99-
100-# use the SDK PPA instead
101-deb http://ppa.launchpad.net/ubuntu-sdk-team/ppa/ubuntu ${RELEASE} main
102-EOF
103- fi
104-
105- APT_CONFIG=${DOWNLOAD_DIR}/apt/downloader.conf apt-get -qq update
106-}
107-
108-download_arch () {
109- ARCH2=$1
110- ARCH3=$2
111- RELEASE=$3
112-
113- [ -z "$ARCH2" -o -z "$ARCH3" ] && exit "download_arch"
114- LOCAL_ARCH=`apt-config dump | grep "APT::Architecture " | cut -d\" -f2`
115-
116- echo "Downloading runtime platform files for $ARCH2"
117- if [ -z "$RELEASE" -o "$RELEASE" == "`lsb_release -c | cut -f 2`" ]; then
118- RELEASE=`lsb_release -c | cut -f 2`
119- else
120- echo "(specifically from release $RELEASE)"
121- fi
122-
123- setup_apt_conf_for_release $RELEASE # $ARCH2
124- URI=`APT_CONFIG=${DOWNLOAD_DIR}/apt/downloader.conf apt-get -qq download --print-uris ${CORDOVA_PACKAGE} | grep ^\' | cut -d\' -f2`
125- PACKAGE_FILENAME=`APT_CONFIG=${DOWNLOAD_DIR}/apt/downloader.conf apt-get -qq download --print-uris ${CORDOVA_PACKAGE} | grep ^\' | cut -d\ -f2 | sed "s/_${LOCAL_ARCH}.deb$/_${ARCH2}.deb/"`
126-
127- if [ $? -eq 1 ]; then
128- exit "$CORDOVA_PACKAGE not found ($URI)"
129- fi
130-
131- echo $PACKAGE_FILENAME
132-
133- mkdir -p ${CORDOVA_CACHE}/lib/${ARCH3}
134-
135- (
136- cd /tmp
137- wget -q `echo $URI | sed "s/_${LOCAL_ARCH}.deb$/_${ARCH2}.deb/"`
138-
139- # plain extraction since the packages are already configured w/ arch specific install paths
140- dpkg-deb -x ${PACKAGE_FILENAME} ${CORDOVA_CACHE}/download
141-
142- rm -f ${PACKAGE_FILENAME}
143- )
144-
145- echo
146-}
147-
148-install_arch () {
149- ARCH3=$1
150-
151- [ -z "$ARCH3" ] && exit "install_arch"
152-
153- mkdir -p ${CORDOVA_CACHE}/lib/${ARCH3}
154- mkdir -p ${CORDOVA_CACHE}/www/cordova
155-
156- rm -rf ${CORDOVA_CACHE}/download/${PAYLOAD_DIR}/${ARCH3}/cordova-ubuntu
157-
158- cp -Rf ${CORDOVA_CACHE}/download/${PAYLOAD_DIR}/${ARCH3}/CordovaUbuntu.?.? ${CORDOVA_CACHE}/lib/${ARCH3}
159- cp -Rf ${CORDOVA_CACHE}/download/${PAYLOAD_DIR}/${ARCH3}/qml ${CORDOVA_CACHE}
160- cp -Rf ${CORDOVA_CACHE}/download/${PAYLOAD_DIR}/${ARCH3}/www/plugins ${CORDOVA_CACHE}/www/cordova
161- cp -Rf ${CORDOVA_CACHE}/download/${PAYLOAD_DIR}/${ARCH3}/www/cordova.js ${CORDOVA_CACHE}/www/cordova
162- cp -Rf ${CORDOVA_CACHE}/download/${PAYLOAD_DIR}/${ARCH3}/www/cordova_plugins.js ${CORDOVA_CACHE}/www/cordova
163-
164- cp ${CORDOVA_CACHE}/download/${PAYLOAD_DIR}/${ARCH3}/www/libcoreplugins.so ${CORDOVA_CACHE}/www/libcoreplugins-${ARCH3}.so
165-
166- rm -rf ${CORDOVA_CACHE}/download/${PAYLOAD_DIR}/${ARCH3}
167-}
168-
169-copy_to_project () {
170-
171- if [ -d ${PROJECTPATH}/www ]; then
172- echo "Copying runtime platform files to ${PROJECTPATH}"
173-
174- cp -Rf ${CORDOVA_CACHE}/lib ${PROJECTPATH}
175- cp -Rf ${CORDOVA_CACHE}/qml ${PROJECTPATH}
176- cp -Rf ${CORDOVA_CACHE}/www ${PROJECTPATH}
177-
178- # find ${PROJECTPATH}/www
179- else
180- echo "No www/ subfolder in ${PROJECTPATH} to install the runtime"
181- return 1
182- fi
183-}
184-
185-
186-SKIP_DOWNLOAD=0
187-
188-if [ "$1" == "-h" -o "$1" == "--help" ]; then
189- echo "Usage: $SCRIPTPATH [-n] [project_path]"
190- exit
191-fi
192-
193-if [ "$1" == "-n" ]; then
194- SKIP_DOWNLOAD=1
195- PROJECTPATH=`pwd`/$2
196-else
197- PROJECTPATH=`pwd`/$1
198-fi
199-
200-if [ -x /usr/bin/nm-tool ]; then
201- if [ `nm-tool | grep State|cut -f2 -d' '` != "connected" ]; then
202- echo "No network link detected, skipping the download step..."
203- echo
204- SKIP_DOWNLOAD=1
205- fi
206-fi
207-
208-if [ $SKIP_DOWNLOAD -eq 0 ]; then
209- echo
210- echo "Trying to download a pre-built Cordova runtime..."
211- echo
212-
213- rm -rf ${CORDOVA_CACHE}
214-
215- setup_apt_conf
216-
217- download_arch "i386" "i386-linux-gnu"
218- install_arch "i386-linux-gnu"
219- download_arch "amd64" "x86_64-linux-gnu"
220- install_arch "x86_64-linux-gnu"
221- download_arch "armhf" "arm-linux-gnueabihf" trusty
222- install_arch "arm-linux-gnueabihf"
223-
224- rm -rf ${CORDOVA_CACHE}/download/apt
225-fi
226-
227-copy_to_project

Subscribers

People subscribed via source and target branches