default=DEFAULT_CATREL, help=("Uploads to a specified named catalog. " "Note that the server side only allows to upload to a limited " "set of catalogs.")) options, args = parser.parse_args() if options.debug: logging.basicConfig(level=logging.DEBUG) else: logging.basicConfig(level=logging.INFO) logging.debug("args: %s", args) hostname = socket.gethostname() if not hostname.startswith('login'): logging.warning("This script is meant to be run on the login host.") os_release = options.os_release if os_release: os_release = struct_util.OsReleaseToLong(os_release) if not args: parser.print_usage() sys.exit(1) # Check the file set. fc = file_set_checker.FileSetChecker() error_tags = fc.CheckFiles(args) if error_tags: print "There is a problem with the presented file list." for error_tag in error_tags: print "*", error_tag if options.filename_check: sys.exit(1) else:
def testShort(self): self.assertEqual("SunOS5.9", struct_util.OsReleaseToLong("5.9"))