From f98ca7fa1903e12a4b2c49a70163077b3560dc1d Mon Sep 17 00:00:00 2001 From: Christian Heimes Date: Sun, 16 Aug 2015 19:00:00 +0200 Subject: Py3 modernization: libmodernize.fixes.fix_print Replace print statement with Python 3's print() function. For Python 2 'from __future__ import print_function' turns the print statement into Python 3 compatible print function. See https://www.python.org/dev/peps/pep-3105/ --- .../python/pki/server/deployment/pkiconfig.py | 49 +++++++++++----------- 1 file changed, 25 insertions(+), 24 deletions(-) (limited to 'base/server/python/pki/server/deployment/pkiconfig.py') diff --git a/base/server/python/pki/server/deployment/pkiconfig.py b/base/server/python/pki/server/deployment/pkiconfig.py index 8bca657de..c22698cb6 100644 --- a/base/server/python/pki/server/deployment/pkiconfig.py +++ b/base/server/python/pki/server/deployment/pkiconfig.py @@ -20,6 +20,7 @@ # # PKI Deployment Constants +from __future__ import print_function PKI_DEPLOYMENT_DEFAULT_CLIENT_DIR_PERMISSIONS = 0o0755 PKI_DEPLOYMENT_DEFAULT_DIR_PERMISSIONS = 0o0770 PKI_DEPLOYMENT_DEFAULT_EXE_PERMISSIONS = 0o0770 @@ -127,38 +128,38 @@ def str2bool(string): # 'pki_enable_java_debugger=True' in the appropriate # deployment configuration file. def prepare_for_an_external_java_debugger(instance): - print - print PKI_DEPLOYMENT_INTERRUPT_BANNER - print - print "The following 'JAVA_OPTS' MUST be edited in" - print "'%s':" % instance - print - print " JAVA_OPTS=\"-DRESTEASY_LIB=/usr/share/java/resteasy \"" - print " \"-Xdebug -Xrunjdwp:transport=dt_socket,\"" - print " \"address=8000,server=y,suspend=n \"" - print " \"-Djava.awt.headless=true -Xmx128M\"" - print + print() + print(PKI_DEPLOYMENT_INTERRUPT_BANNER) + print() + print("The following 'JAVA_OPTS' MUST be edited in") + print("'%s':" % instance) + print() + print(" JAVA_OPTS=\"-DRESTEASY_LIB=/usr/share/java/resteasy \"") + print(" \"-Xdebug -Xrunjdwp:transport=dt_socket,\"") + print(" \"address=8000,server=y,suspend=n \"") + print(" \"-Djava.awt.headless=true -Xmx128M\"") + print() raw_input("Enable external java debugger 'JAVA_OPTS' " "and press return to continue . . . ") - print - print PKI_DEPLOYMENT_INTERRUPT_BANNER - print + print() + print(PKI_DEPLOYMENT_INTERRUPT_BANNER) + print() return def wait_to_attach_an_external_java_debugger(): - print - print PKI_DEPLOYMENT_INTERRUPT_BANNER - print - print "Attach the java debugger to this process on the port specified by" - print "the 'address' selected by 'JAVA_OPTS' (e. g. - port 8000) and" - print "set any desired breakpoints" - print + print() + print(PKI_DEPLOYMENT_INTERRUPT_BANNER) + print() + print("Attach the java debugger to this process on the port specified by") + print("the 'address' selected by 'JAVA_OPTS' (e. g. - port 8000) and") + print("set any desired breakpoints") + print() raw_input("Please attach an external java debugger " "and press return to continue . . . ") - print - print PKI_DEPLOYMENT_INTERRUPT_BANNER - print + print() + print(PKI_DEPLOYMENT_INTERRUPT_BANNER) + print() return -- cgit