launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #25625
[Merge] ~cjwatson/txpkgupload:py3-switch into txpkgupload:master
Colin Watson has proposed merging ~cjwatson/txpkgupload:py3-switch into txpkgupload:master with ~cjwatson/txpkgupload:tox-py35 as a prerequisite.
Commit message:
Switch to Python 3
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
For more details, see:
https://code.launchpad.net/~cjwatson/txpkgupload/+git/txpkgupload/+merge/393564
--
Your team Launchpad code reviewers is requested to review the proposed merge of ~cjwatson/txpkgupload:py3-switch into txpkgupload:master.
diff --git a/Makefile b/Makefile
index 0814851..dc8d75b 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
# Copyright 2005-2015 Canonical Ltd. This software is licensed under the
# GNU Affero General Public License version 3 (see the file LICENSE).
-PYTHON = python
+PYTHON = python3
ENV = $(CURDIR)/env
diff --git a/dependencies-devel.txt b/dependencies-devel.txt
index 717290e..5f4f7c8 100644
--- a/dependencies-devel.txt
+++ b/dependencies-devel.txt
@@ -3,7 +3,7 @@ git
libffi-dev
libssl-dev
make
-python
-python-dev
+python3
+python3-dev
tox
virtualenv
diff --git a/scripts/update-version-info.sh b/scripts/update-version-info.sh
index 54e777e..d6492fe 100755
--- a/scripts/update-version-info.sh
+++ b/scripts/update-version-info.sh
@@ -22,9 +22,7 @@ branch_nick="$(git rev-parse --abbrev-ref HEAD | sed "s/'/\\\\'/g")"
revision_id="$(git rev-parse HEAD)"
date="$(git show -s --format=%ci HEAD)"
cat > $newfile <<EOF
-#! /usr/bin/env python
-
-from __future__ import print_function
+#! /usr/bin/env python3
version_info = {
'branch_nick': u'$branch_nick',
@@ -36,7 +34,7 @@ if __name__ == '__main__':
print('revision id: %(revision_id)s' % version_info)
EOF
-revision_id=$(python $newfile | sed -n 's/^revision id: //p')
+revision_id=$(python3 $newfile | sed -n 's/^revision id: //p')
if ! [ -f version-info.py ]; then
echo "Creating version-info.py at revision $revision_id"
mv ${newfile} version-info.py
diff --git a/setup.py b/setup.py
index c52a978..59c603a 100755
--- a/setup.py
+++ b/setup.py
@@ -1,4 +1,4 @@
-#!/usr/bin/env python
+#!/usr/bin/env python3
# Copyright 2009-2015 Canonical Ltd. All rights reserved.
#