Merge lp:~larryprice/libertine/fix-welcome-view into lp:libertine

Proposed by Larry Price
Status: Merged
Approved by: Christopher Townsend
Approved revision: 279
Merged at revision: 294
Proposed branch: lp:~larryprice/libertine/fix-welcome-view
Merge into: lp:libertine
Diff against target: 106 lines (+20/-22)
5 files modified
libertine/ContainerConfigList.cpp (+2/-2)
libertine/qml/ContainerOptionsDialog.qml (+1/-0)
libertine/qml/ContainersView.qml (+0/-4)
libertine/qml/WelcomeView.qml (+2/-2)
tools/libertine-container-manager (+15/-14)
To merge this branch: bzr merge lp:~larryprice/libertine/fix-welcome-view
Reviewer Review Type Date Requested Status
Christopher Townsend Approve
Libertine CI Bot continuous-integration Approve
Review via email: mp+303612@code.launchpad.net

Commit message

Creating the first container moves user to ContainersView screen.

Description of the change

After initializing a create, user should be automatically pushed forward to Containers View.

To post a comment you must log in.
Revision history for this message
Libertine CI Bot (libertine-ci-bot) wrote :

PASSED: Continuous integration, rev:279
https://jenkins.canonical.com/libertine/job/lp-libertine-ci/106/
Executed test runs:
    SUCCESS: https://jenkins.canonical.com/libertine/job/build/298
    SUCCESS: https://jenkins.canonical.com/libertine/job/test-0-autopkgtest/label=amd64,release=vivid+overlay,testname=default/247
    SUCCESS: https://jenkins.canonical.com/libertine/job/test-0-autopkgtest/label=amd64,release=xenial+overlay,testname=default/247
    SUCCESS: https://jenkins.canonical.com/libertine/job/test-0-autopkgtest/label=amd64,release=yakkety,testname=default/247
    SUCCESS: https://jenkins.canonical.com/libertine/job/test-0-autopkgtest/label=i386,release=vivid+overlay,testname=default/247
    SUCCESS: https://jenkins.canonical.com/libertine/job/test-0-autopkgtest/label=i386,release=xenial+overlay,testname=default/247
    SUCCESS: https://jenkins.canonical.com/libertine/job/test-0-autopkgtest/label=i386,release=yakkety,testname=default/247
    None: https://jenkins.canonical.com/libertine/job/lp-generic-update-mp/223/console
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-0-fetch/300
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-1-sourcepkg/release=vivid+overlay/284
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-1-sourcepkg/release=xenial+overlay/284
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-1-sourcepkg/release=yakkety/284
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=amd64,release=vivid+overlay/277
        deb: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=amd64,release=vivid+overlay/277/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=amd64,release=xenial+overlay/277
        deb: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=amd64,release=xenial+overlay/277/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=amd64,release=yakkety/277
        deb: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=amd64,release=yakkety/277/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=i386,release=vivid+overlay/277
        deb: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=i386,release=vivid+overlay/277/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=i386,release=xenial+overlay/277
        deb: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=i386,release=xenial+overlay/277/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=i386,release=yakkety/277
        deb: https://jenkins.canonical.com/libertine/job/build-2-binpkg/arch=i386,release=yakkety/277/artifact/output/*zip*/output.zip

Click here to trigger a rebuild:
https://jenkins.canonical.com/libertine/job/lp-libertine-ci/106/rebuild

review: Approve (continuous-integration)
Revision history for this message
Christopher Townsend (townsend) wrote :

LGTM, +1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'libertine/ContainerConfigList.cpp'
2--- libertine/ContainerConfigList.cpp 2016-06-07 18:45:30 +0000
3+++ libertine/ContainerConfigList.cpp 2016-08-22 18:24:14 +0000
4@@ -506,6 +506,7 @@
5 load_config()
6 {
7 QFile config_file(config_->containers_config_file_name());
8+ flock(config_file.handle(), LOCK_EX);
9
10 if (config_file.exists())
11 {
12@@ -517,9 +518,7 @@
13 {
14 QJsonParseError parse_error;
15
16- flock(config_file.handle(), LOCK_EX);
17 QJsonDocument json = QJsonDocument::fromJson(config_file.readAll(), &parse_error);
18- flock(config_file.handle(), LOCK_UN);
19
20 if (parse_error.error)
21 {
22@@ -543,4 +542,5 @@
23 }
24 }
25 }
26+ flock(config_file.handle(), LOCK_UN);
27 }
28
29=== modified file 'libertine/qml/ContainerOptionsDialog.qml'
30--- libertine/qml/ContainerOptionsDialog.qml 2016-07-15 18:39:58 +0000
31+++ libertine/qml/ContainerOptionsDialog.qml 2016-08-22 18:24:14 +0000
32@@ -79,6 +79,7 @@
33 width: (parent.width - parent.spacing) / 2
34 onClicked: {
35 createContainer()
36+ welcomeView.createInitialized()
37 PopupUtils.close(containerOptionsDialog)
38 }
39 }
40
41=== modified file 'libertine/qml/ContainersView.qml'
42--- libertine/qml/ContainersView.qml 2016-08-15 15:59:56 +0000
43+++ libertine/qml/ContainersView.qml 2016-08-22 18:24:14 +0000
44@@ -146,8 +146,4 @@
45 mainView.error(i18n.tr("Container Unavailable"), i18n.tr("This container has been destroyed and is no longer valid. You have been returned to the containers overview."))
46 }
47 }
48-
49- function showPasswordDialog(enableMultiarch, containerName) {
50- PopupUtils.open(Qt.resolvedUrl("ContainerPasswordDialog.qml"), null, {"enableMultiarch": enableMultiarch, "containerName": containerName})
51- }
52 }
53
54=== modified file 'libertine/qml/WelcomeView.qml'
55--- libertine/qml/WelcomeView.qml 2016-07-15 18:39:58 +0000
56+++ libertine/qml/WelcomeView.qml 2016-08-22 18:24:14 +0000
57@@ -72,7 +72,7 @@
58 }
59 }
60
61- function showPasswordDialog(enableMultiarch, containerName) {
62- PopupUtils.open(Qt.resolvedUrl("ContainerPasswordDialog.qml"), null, {"enableMultiarch": enableMultiarch, "containerName": containerName})
63+ function createInitialized() {
64+ pageStack.push(Qt.resolvedUrl("ContainersView.qml"))
65 }
66 }
67
68=== modified file 'tools/libertine-container-manager'
69--- tools/libertine-container-manager 2016-07-29 17:58:15 +0000
70+++ tools/libertine-container-manager 2016-08-22 18:24:14 +0000
71@@ -274,20 +274,21 @@
72 self.containers_config.merge_container_config_files(args.file)
73
74 def fix_integrity(self, args):
75- for container in self.containers_config.container_list['containerList']:
76- if 'installStatus' not in container or container['installStatus'] != 'ready':
77- self.destroy_container_by_id(container['id'])
78- continue
79- LibertineContainer(container['id']).exec_command('dpkg --configure -a')
80-
81- for package in container['installedApps']:
82- if package['appStatus'] != 'installed':
83- self.remove_package_by_name(container['id'], package['packageName'])
84-
85- if 'extraArchives' in container:
86- for archive in container['extraArchives']:
87- if archive['archiveStatus'] != 'installed':
88- self.delete_archive_by_name(container['id'], archive['archiveName'])
89+ if 'containerList' in self.containers_config.container_list:
90+ for container in self.containers_config.container_list['containerList']:
91+ if 'installStatus' not in container or container['installStatus'] != 'ready':
92+ self.destroy_container_by_id(container['id'])
93+ continue
94+ LibertineContainer(container['id']).exec_command('dpkg --configure -a')
95+
96+ for package in container['installedApps']:
97+ if package['appStatus'] != 'installed':
98+ self.remove_package_by_name(container['id'], package['packageName'])
99+
100+ if 'extraArchives' in container:
101+ for archive in container['extraArchives']:
102+ if archive['archiveStatus'] != 'installed':
103+ self.delete_archive_by_name(container['id'], archive['archiveName'])
104
105 def set_default(self, args):
106 if args.clear:

Subscribers

People subscribed via source and target branches