Files
davila7--claude-code-templates/cli-tool/components/skills/development/git-pushing/scripts/smart_commit.sh
T
wehub-resource-sync bb5c75ce05
Component Security Validation / Security Audit (push) Has been cancelled
Deploy to Cloudflare Pages / deploy (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 12:38:58 +08:00

20 lines
374 B
Bash

#!/bin/bash
set -e
# Default commit message if none provided
MESSAGE="${1:-chore: update code}"
# Add all changes
git add .
# Commit with the provided message
git commit -m "$MESSAGE"
# Get current branch name
BRANCH=$(git rev-parse --abbrev-ref HEAD)
# Push to remote, setting upstream if needed
git push -u origin "$BRANCH"
echo "✅ Successfully pushed to $BRANCH"