MCPcopy Create free account
hub / github.com/apache/solr / main

Function main

dev-tools/scripts/buildAndPushRelease.py:371–424  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

369
370
371def main():
372 check_cmdline_tools()
373
374 c = parse_config()
375 gpg_home = None
376
377 if c.sign:
378 sys.stdout.flush()
379 c.key_id = c.sign
380 check_key_in_keys(c.key_id, c.local_keys)
381 if c.gpg_home is not None:
382 print("Using custom gpg-home: %s" % c.gpg_home)
383 gpg_home = c.gpg_home
384 if c.sign_method_gradle:
385 if gpg_home is None:
386 resolved_gpg_home = resolve_gpghome()
387 if resolved_gpg_home is not None:
388 print("Resolved gpg home to %s" % resolved_gpg_home)
389 gpg_home = resolved_gpg_home
390 else:
391 print("WARN: Could not locate your gpg secret keyring, and --gpg-home not specified.")
392 print(" Falling back to location configured in gradle.properties.")
393 print(" See 'gradlew helpPublishing' for details.")
394 gpg_home = None
395 if c.gpg_pass_noprompt:
396 print("Will not prompt for gpg password. Make sure your signing setup supports this.")
397 c.key_password = None
398 else:
399 import getpass
400 c.key_password = getpass.getpass('Enter GPG keystore password: ')
401 else:
402 c.key_id = None
403 c.key_password = None
404
405 if c.prepare:
406 prepare(c.root, c.version, c.pause_before_sign, c.mf_username, c.key_id, c.key_password, gpg_home=gpg_home, sign_gradle=c.sign_method_gradle)
407 else:
408 os.chdir(c.root)
409
410 if c.push_local:
411 url = pushLocal(c.version, c.root, c.rc_num, c.push_local)
412 else:
413 url = None
414
415 if url is not None:
416 print(' URL: %s' % url)
417 print('Next run the smoker tester:')
418 p = re.compile(".*/")
419 m = p.match(sys.argv[0])
420 if not c.sign:
421 signed = "--not-signed"
422 else:
423 signed = ""
424 print('%s -u %ssmokeTestRelease.py %s %s' % (sys.executable, m.group(), signed, url))
425
426if __name__ == '__main__':
427 try:

Callers 1

Calls 8

check_cmdline_toolsFunction · 0.85
check_key_in_keysFunction · 0.85
resolve_gpghomeFunction · 0.85
prepareFunction · 0.85
pushLocalFunction · 0.85
parse_configFunction · 0.70
flushMethod · 0.45
matchMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…