+def creategid(opts, args):
+ global registry
+ auth_cred = get_auth_cred()
+ hrn = args[0]
+ pkey_string = load_publickey_string(args[1])
+ gid = registry.create_gid(auth_cred, hrn, create_uuid(), pkey_string)
+ if (opts.file is not None):
+ gid.save_to_file(opts.file, save_parents=True)
+ else:
+ print "I created your gid, but you did not ask me to save it"
+