49 from gettext
import gettext
as _
56 bugreport = xorn.config.PACKAGE_BUGREPORT
66 if sys.argv[0].startswith(
'/'):
67 return os.path.basename(sys.argv[0])
89 program_short_name = os.path.basename(
argv0())
111 sys.stderr.write(_(
"%s: %s\n") % (program_short_name, message))
112 sys.stderr.write(_(
"Try `%s --help' for more information.\n")
122 sys.stdout.write(
"%s\n" % xorn.config.PACKAGE_STRING)
123 sys.stdout.write(_(
"Copyright (C) 2016 Roland Lutz\n"))
124 sys.stdout.write(
"\n")
126 "This program is free software; you can redistribute it and/or\n"
127 "modify it under the terms of the GNU General Public License\n"
128 "as published by the Free Software Foundation; either version 2\n"
129 "of the License, or (at your option) any later version.\n"))
130 sys.stdout.write(
"\n")
132 "This program is distributed in the hope that it will be useful,\n"
133 "but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
134 "MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n"
135 "GNU General Public License for more details.\n"))
def core_version
Print core version.
def invalid_arguments
Print an argument error message to sys.stdout and exit.
def argv0
Return the value of argv[0].