Merge lp:~dobey/ubuntuone-client/fix-due-nonsense into lp:ubuntuone-client

Proposed by dobey
Status: Merged
Approved by: dobey
Approved revision: 1402
Merged at revision: 1401
Proposed branch: lp:~dobey/ubuntuone-client/fix-due-nonsense
Merge into: lp:ubuntuone-client
Diff against target: 29 lines (+8/-10)
1 file modified
setup.py (+8/-10)
To merge this branch: bzr merge lp:~dobey/ubuntuone-client/fix-due-nonsense
Reviewer Review Type Date Requested Status
Mike McCracken (community) Approve
Review via email: mp+168702@code.launchpad.net

Commit message

Simplify the removal of packages which shouldn't be installed.
Also remove data files which shouldn't be installed.

To post a comment you must log in.
1402. By dobey

Fix pep8 issue.

Revision history for this message
Mike McCracken (mikemc) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'setup.py'
--- setup.py 2013-06-10 22:06:01 +0000
+++ setup.py 2013-06-11 15:28:41 +0000
@@ -96,17 +96,15 @@
9696
97 # Remove the contrib and tests packages from the packages list97 # Remove the contrib and tests packages from the packages list
98 # as they are not meant to be installed to the system.98 # as they are not meant to be installed to the system.
99 i = 099 pkgs = [x for x in self.distribution.packages if not (
100 for pkg in self.distribution.packages:100 x.startswith('contrib') or x.startswith('tests'))]
101 print("Checking %s" % pkg)101 self.distribution.packages = pkgs
102 if pkg.startswith('contrib'):
103 print('Removing %s' % pkg)
104 self.distribution.packages.pop(i)
105 if pkg.startswith('tests'):
106 print("Removing %s" % pkg)
107 self.distribution.packages.pop(i)
108102
109 i += 1103 # Remove the input and dev files from the data files list,
104 # as they are not meant to be installed.
105 data_files = [x for x in self.distribution.data_files if not (
106 x[1][0].endswith('.in') or x[1][0].endswith('-dev.conf'))]
107 self.distribution.data_files = data_files
110108
111 # Get just the prefix value, without the root109 # Get just the prefix value, without the root
112 prefix = self.install_data.replace(110 prefix = self.install_data.replace(

Subscribers

People subscribed via source and target branches