File tree Expand file tree Collapse file tree 1 file changed +29
-0
lines changed Expand file tree Collapse file tree 1 file changed +29
-0
lines changed Original file line number Diff line number Diff line change @@ -491,6 +491,35 @@ def command_release_announcement_email():
491
491
Do you have all of of these setup? (y/n): """ % (PREFS_FILE , json .dumps (prefs , indent = 2 ))):
492
492
fail ("Please try again once you have all the prerequisites ready." )
493
493
494
+ apache_id = sanitize_input ("Please enter your apache-id: " )
495
+
496
+ print ("Begin to check if you have met all the pre-requisites for the release process" )
497
+
498
+ try :
499
+ test_maven = cmd_output ("mvn -v" )
500
+ if "Apache Maven" in test_maven :
501
+ print ("Pre-requisite met: You have maven cli in place" )
502
+ else :
503
+ fail ("Pre-requisite not met: You need to install maven CLI" )
504
+ except Exception as e :
505
+ fail (f"Pre-requisite not met: Unable to check if maven cli is installed. Error: { e } " )
506
+
507
+ try :
508
+ test_sftp = subprocess .run (f"sftp { apache_id } @home.apache.org" .split ())
509
+ if test_sftp .returncode != 0 :
510
+ fail ("Pre-requisite not met: Cannot establish sftp connection. Please check your apache-id and ssh keys." )
511
+ print ("Pre-requisite met: sftp connection is successful" )
512
+ except Exception as e :
513
+ fail (f"Pre-requisite not met: Unable to check if sftp connection is successful. Error: { e } " )
514
+
515
+ try :
516
+ test_svn = cmd_output ("svn --version" )
517
+ if "svn" in test_svn :
518
+ print ("Pre-requisite met: You have svn cli in place" )
519
+ else :
520
+ fail ("Pre-requisite not met: You need to install svn cli" )
521
+ except Exception as e :
522
+ fail (f"Pre-requisite not met: Unable to check if svn cli is installed. Error: { e } " )
494
523
495
524
starting_branch = cmd_output ('git rev-parse --abbrev-ref HEAD' )
496
525
You can’t perform that action at this time.
0 commit comments