From 5d6f427da7c43e805a2d4a3c668e5c7bf30080af Mon Sep 17 00:00:00 2001 From: Zhongwei Li Date: Sun, 30 Nov 2025 09:07:52 +0800 Subject: [PATCH] Initial commit --- .claude-plugin/plugin.json | 11 +++++++++ README.md | 3 +++ commands/stage-commit-push.md | 30 +++++++++++++++++++++++ plugin.lock.json | 45 +++++++++++++++++++++++++++++++++++ 4 files changed, 89 insertions(+) create mode 100644 .claude-plugin/plugin.json create mode 100644 README.md create mode 100644 commands/stage-commit-push.md create mode 100644 plugin.lock.json diff --git a/.claude-plugin/plugin.json b/.claude-plugin/plugin.json new file mode 100644 index 0000000..9cc2316 --- /dev/null +++ b/.claude-plugin/plugin.json @@ -0,0 +1,11 @@ +{ + "name": "git-github-operations", + "description": "Git & Github Operations - Streamlined git and GitHub workflow commands", + "version": "1.0.0", + "author": { + "name": "Tobey Forsman" + }, + "commands": [ + "./commands" + ] +} \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..214e045 --- /dev/null +++ b/README.md @@ -0,0 +1,3 @@ +# git-github-operations + +Git & Github Operations - Streamlined git and GitHub workflow commands diff --git a/commands/stage-commit-push.md b/commands/stage-commit-push.md new file mode 100644 index 0000000..b89d580 --- /dev/null +++ b/commands/stage-commit-push.md @@ -0,0 +1,30 @@ +# Stage, Commit, and Push + +You are helping the user perform a complete git workflow: staging changes, creating a commit, and pushing to the remote repository. + +## Instructions + +1. **Check git status**: Run `git status` to see what changes exist +2. **Stage changes**: + - Ask the user which files to stage, or if they want to stage all changes + - Use `git add` to stage the selected files +3. **Create commit**: + - Review the staged changes with `git diff --cached` + - Ask the user for a commit message, or draft one based on the changes + - Create the commit with `git commit -m "message"` +4. **Push changes**: + - Check the current branch with `git branch --show-current` + - Push to the remote with `git push` (or `git push -u origin ` if not tracking) + - Confirm the push was successful + +## Important Notes and Guidelines + +- Always verify what branch you're on before pushing +- Each commit should represent a single logical change +- If there are many small changes, group them into 2-4 meaningful commits +- Always show the user what changes will be committed before creating the commit +- If there are no changes to commit, inform the user +- Commit messages should be concise but descriptive (1-2 lines) +- If there are merge conflicts or issues, report them to the user +- If the push fails (e.g., diverged branches), explain the issue and suggest solutions +- Be careful with force pushes - only suggest if explicitly requested and after warning diff --git a/plugin.lock.json b/plugin.lock.json new file mode 100644 index 0000000..726c14c --- /dev/null +++ b/plugin.lock.json @@ -0,0 +1,45 @@ +{ + "$schema": "internal://schemas/plugin.lock.v1.json", + "pluginId": "gh:yebot/rad-cc-plugins:plugins/git-github-operations", + "normalized": { + "repo": null, + "ref": "refs/tags/v20251128.0", + "commit": "d508155fb47300886d2585b94419cee181eca4c7", + "treeHash": "64552c56cb4d2030ee0e0d35f7993eceaee4dfaa26c3f3b16338ac64818af8cb", + "generatedAt": "2025-11-28T10:29:09.981275Z", + "toolVersion": "publish_plugins.py@0.2.0" + }, + "origin": { + "remote": "git@github.com:zhongweili/42plugin-data.git", + "branch": "master", + "commit": "aa1497ed0949fd50e99e70d6324a29c5b34f9390", + "repoRoot": "/Users/zhongweili/projects/openmind/42plugin-data" + }, + "manifest": { + "name": "git-github-operations", + "description": "Git & Github Operations - Streamlined git and GitHub workflow commands", + "version": "1.0.0" + }, + "content": { + "files": [ + { + "path": "README.md", + "sha256": "2728a463ace31ef8e6cf2a4543d2dd8b1e0bce36f136aab1d1e126c6f37738e8" + }, + { + "path": ".claude-plugin/plugin.json", + "sha256": "226184b80434ecb6425982c7611cdc44d804d3042d93c0014baa9874d6b1ed96" + }, + { + "path": "commands/stage-commit-push.md", + "sha256": "8f022bf0bfbfec7679c13246c1ba7c30fd0c914d5bfb4e5e0dbcb995104c3552" + } + ], + "dirSha256": "64552c56cb4d2030ee0e0d35f7993eceaee4dfaa26c3f3b16338ac64818af8cb" + }, + "security": { + "scannedAt": null, + "scannerVersion": null, + "flags": [] + } +} \ No newline at end of file