Initial commit
This commit is contained in:
@@ -132,12 +132,12 @@ def main():
|
||||
# We can try checking current branch name.
|
||||
current_branch = run_command("git rev-parse --abbrev-ref HEAD")
|
||||
if current_branch:
|
||||
if run_command(f"git push -u origin {current_branch}") is None:
|
||||
if run_command(f"git push -u origin {current_branch} -f") is None:
|
||||
print("Push failed.")
|
||||
else:
|
||||
# Fallback if we couldn't get branch name
|
||||
if run_command("git push -u origin master") is None:
|
||||
run_command("git push -u origin main")
|
||||
if run_command("git push -u origin master -f") is None:
|
||||
run_command("git push -u origin main -f")
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
|
||||
Reference in New Issue
Block a user