Coverage for mfutil/cli_tools/get_full_hostname.py: 0%
13 statements
« prev ^ index » next coverage.py v7.6.1, created at 2024-11-13 15:33 +0000
« prev ^ index » next coverage.py v7.6.1, created at 2024-11-13 15:33 +0000
1import argparse
2import sys
3from mfutil.net import get_full_hostname
5DESCRIPTION = "returns the 'full' hostname (with network domain)"
8def main():
9 parser = argparse.ArgumentParser(description=DESCRIPTION)
10 parser.parse_args()
11 res = get_full_hostname()
12 if res is not None:
13 print(res)
14 else:
15 sys.exit(1)
18if __name__ == '__main__':
19 main()