Merge lp:~ericsnowcurrently/landscape-client/fix-1681947-script-shbang into lp:~landscape/landscape-client/trunk

Proposed by Eric Snow
Status: Merged
Approved by: Eric Snow
Approved revision: 1015
Merged at revision: 1016
Proposed branch: lp:~ericsnowcurrently/landscape-client/fix-1681947-script-shbang
Merge into: lp:~landscape/landscape-client/trunk
Diff against target: 49 lines (+18/-9)
1 file modified
setup.py (+18/-9)
To merge this branch: bzr merge lp:~ericsnowcurrently/landscape-client/fix-1681947-script-shbang
Reviewer Review Type Date Requested Status
Simon Poirier (community) Approve
Francis Ginther (community) Approve
🤖 Landscape Builder test results Approve
Review via email: mp+322406@code.launchpad.net

Commit message

Only build the scripts under Python 3.

(fixes lp:1681947)

Description of the change

Only build the scripts under Python 3.

(fixes lp:1681947)

Testing instructions:

make package
head debian/tmp/usr/bin/landscape-client # shbang will be python3

To post a comment you must log in.
Revision history for this message
🤖 Landscape Builder (landscape-builder) :
review: Abstain (executing tests)
Revision history for this message
🤖 Landscape Builder (landscape-builder) wrote :

Command: TRIAL_ARGS=-j4 make ci-check
Result: Success
Revno: 1015
Branch: lp:~ericsnowcurrently/landscape-client/fix-1681947-script-shbang
Jenkins: https://ci.lscape.net/job/latch-test-xenial/3872/

review: Approve (test results)
Revision history for this message
Francis Ginther (fginther) wrote :

Yep, it works.

review: Approve
Revision history for this message
Simon Poirier (simpoir) wrote :

+1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'setup.py'
2--- setup.py 2017-04-06 18:50:19 +0000
3+++ setup.py 2017-04-11 21:35:23 +0000
4@@ -1,12 +1,29 @@
5 #!/usr/bin/python
6
7 from distutils.core import setup
8+import sys
9
10 from landscape import UPSTREAM_VERSION
11
12 from DistUtilsExtra.command import build_extra
13 from DistUtilsExtra.auto import clean_build_tree
14
15+
16+SCRIPTS = []
17+if sys.version_info[0] == 3:
18+ SCRIPTS = [
19+ "scripts/landscape-client",
20+ "scripts/landscape-config",
21+ "scripts/landscape-broker",
22+ "scripts/landscape-manager",
23+ "scripts/landscape-monitor",
24+ "scripts/landscape-package-changer",
25+ "scripts/landscape-package-reporter",
26+ "scripts/landscape-release-upgrader",
27+ "scripts/landscape-sysinfo",
28+ ]
29+
30+
31 setup(name="Landscape Client",
32 version=UPSTREAM_VERSION,
33 description="Landscape Client",
34@@ -23,14 +40,6 @@
35 "landscape.upgraders",
36 "landscape.user",
37 "landscape.lib"],
38- scripts=["scripts/landscape-client",
39- "scripts/landscape-config",
40- "scripts/landscape-broker",
41- "scripts/landscape-manager",
42- "scripts/landscape-monitor",
43- "scripts/landscape-package-changer",
44- "scripts/landscape-package-reporter",
45- "scripts/landscape-release-upgrader",
46- "scripts/landscape-sysinfo"],
47+ scripts=SCRIPTS,
48 cmdclass={"build": build_extra.build_extra,
49 "clean": clean_build_tree})

Subscribers

People subscribed via source and target branches

to all changes: