diff options
author | Alexander Sulfrian <alexander@sulfrian.net> | 2013-06-06 20:45:46 +0200 |
---|---|---|
committer | Alexander Sulfrian <alexander@sulfrian.net> | 2013-06-06 23:30:48 +0200 |
commit | cc886cbacd737e8e353d30c5de40fd94d23df8e0 (patch) | |
tree | a216f8168d3ad72c86bb78cc088e0a6d2dd03d12 /hostinfo-checks | |
parent | 170f29cb034470560ca66b05d39a4e0961a6536e (diff) | |
download | hostinfo-maintainer-cc886cbacd737e8e353d30c5de40fd94d23df8e0.tar.gz hostinfo-maintainer-cc886cbacd737e8e353d30c5de40fd94d23df8e0.tar.bz2 hostinfo-maintainer-cc886cbacd737e8e353d30c5de40fd94d23df8e0.zip |
add basename to version output
Diffstat (limited to 'hostinfo-checks')
-rwxr-xr-x | hostinfo-checks | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/hostinfo-checks b/hostinfo-checks index 019892b..d37b7d5 100755 --- a/hostinfo-checks +++ b/hostinfo-checks @@ -77,8 +77,8 @@ class MaintainersContext(nagiosplugin.Context): def print_version(): try: import version - ver = version.get_git_version() - print(" %s" % ver) + self = os.path.basename(sys.argv[0]) + print("%s %s" % (self, version.get_git_version())) except: sys.stderr.write('Unable to identify the version information.\n') sys.exit(nagiosplugin.Unknown.code) |