Update git_commit

This commit is contained in:
vijay 2025-06-10 01:58:06 +00:00
parent af7a0e0458
commit c9505e1bdd

View File

@ -1,7 +1,6 @@
#!/bin/bash #!/bin/bash
# bash <(curl -s https://git.technozone.com.au/vijay/Scripts/branch/main/git_commit) && rm -f git_commit # bash <(curl -s https://git.technozone.com.au/vijay/Scripts/branch/main/git_commit) && rm -f git_commit
# Prompt for the Gitea repository URL # Prompt for the Gitea repository URL
read -p "Enter your Gitea repository URL: " GITEA_URL read -p "Enter your Gitea repository URL: " GITEA_URL
@ -45,10 +44,10 @@ git commit -m "$commit_message"
# Push changes # Push changes
if [ -z "$GIT_TOKEN" ]; then if [ -z "$GIT_TOKEN" ]; then
echo "Pushing changes using username and password..." echo "Pushing changes using username and password..."
git push "$GITEA_URL" --username "$username" --password "$password" git push "https://$username:$password@$GITEA_URL"
else else
echo "Pushing changes using token..." echo "Pushing changes using token..."
git push "$GITEA_URL" git push "$GITEA_URL"
fi fi
echo "Changes pushed successfully." echo "Changes pushed successfully."