Signed-off-by: Sverre Rabbelier <srabbelier@xxxxxxxxx> --- These turned out to be quite useful for my git-remote-hg, if desired this patch can move to later in the series, but I figured that it might be useful to someone else already. git_remote_helpers/util.py | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/git_remote_helpers/util.py b/git_remote_helpers/util.py index 7d6adb4..d3ca487 100644 --- a/git_remote_helpers/util.py +++ b/git_remote_helpers/util.py @@ -15,6 +15,10 @@ import subprocess # Whether or not to show debug messages DEBUG = False +def notify(msg, *args): + """Print a message to stderr.""" + print >> sys.stderr, msg % args + def debug (msg, *args): """Print a debug message to stderr when DEBUG is enabled.""" if DEBUG: @@ -24,6 +28,10 @@ def error (msg, *args): """Print an error message to stderr.""" print >> sys.stderr, "ERROR:", msg % args +def warn(msg, *args): + """Print a warning message to stderr.""" + print >> sys.stderr, "warning:", msg % args + def die (msg, *args): """Print as error message to stderr and exit the program.""" error(msg, *args) -- 1.6.5.2.291.gf76a3 -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html