本文へスキップ
Skillpedia
デプロイとクラウド(DevOps)48k · #4740

git-pushing

できること

コードの変更を、GitHub などのリモートリポジトリに安全かつ整理された形で保存するツールです。コミットメッセージを決まった形式にそろえるので、何が変更されたのかが理解しやすくなります。

使う場面

  • ✓GitHub や GitLab に作業内容を保存したいとき。
  • ✓コードの作業が一区切りつき、共有したくなったとき。
  • ✓「プッシュ」や「保存」を明示的に依頼したいとき。

スキルのリンク

https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/git-pushing/SKILL.md

コピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。

使い方

いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。

貼り付け用メッセージ

このスキルを使って手伝ってください:https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/git-pushing/SKILL.md このリンクのSKILL.mdファイルを読んで、私の作業でその指示に従ってください。
こういうスキルを、AIが自分で見つけてくれたら?無料のSkillpedia MCPをインストール。1行で、作業の前に15,000+のスキルから探してくれます。1分でインストール →

AIへの頼み方の例

“変更を GitHub にプッシュしてもいいですか?”

毎週5つの新しいスキル。1分で読めます。

仕組み

このツールは、本当に正しいファイルだけをプッシュしようとしているかを確認し、何をしたかを表す統一されたメッセージを作成します。そのうえで、すべてをリモートリポジトリに送信します。

技術的な内容(元のSKILL.md)

作者による元のテキスト(英語)をGitHubからそのまま表示しています。

Git Push Workflow

Stage only intended changes, create a conventional commit, and push to the remote branch.

When to Use

Automatically activate when the user:

  • Explicitly asks to push changes ("push this", "commit and push")
  • Mentions saving work to remote ("save to github", "push to remote")
  • Completes a feature and wants to share it
  • Says phrases like "let's push this up" or "commit these changes"

Safety Gates

Before staging, inspect git status --short --branch, confirm the intended files, and fetch the upstream branch when a concurrent push is plausible. Do not absorb unrelated dirty files.

Read repository policy before choosing the destination branch. If main or master is protected, or the repository defines a maintainer command such as merge:batch, create or use a topic branch and finish through the required pull-request checks. A user request to “push to main” describes the desired final state; it does not authorize bypassing server-side protection. Never keep retrying a direct push after a protected-branch rejection.

The helper requires an empty live index and a conventional commit message before it stages anything. It locks the live index, builds and validates the commit in an isolated temporary index, rejects -- without paths, and atomically updates the branch only if its parent is unchanged.

The helper honors branch.<name>.pushRemote, remote.pushDefault, and the branch's configured upstream, in that order. For a new branch without those settings, it requires origin and establishes origin/<branch>. It rejects detached HEAD and invalid remote configurations before staging.

Do not use this skill for a maintainer merge batch, canonical synchronization, versioned repository release, tag publication, or a repository with an explicit merge:batch, release:prepare, or release:publish workflow. Use that repository's maintainer/release flow instead; it owns pull-request evidence, protected-branch checks, generated files, tags, and publication verification.

Workflow

Use the helper only after the safety gates pass. Resolve the installed directory that contains this SKILL.md and substitute its absolute path for <skill-directory> below; do not assume the current working directory is the catalog repository. With no paths the helper stages all current changes, so use that form only when every dirty file belongs to the requested commit:

bash "<skill-directory>/scripts/smart_commit.sh"

With custom message:

bash "<skill-directory>/scripts/smart_commit.sh" "feat: add feature"

To stage only named files, pass them after --:

bash "<skill-directory>/scripts/smart_commit.sh" "fix: scope change" -- path/to/file

The helper handles isolated staging, commit creation, and push; it does not replace validation, release tooling, or a rebase required by an advanced upstream branch.

Limitations

  • The helper currently requires Git's files ref backend; it rejects reftable repositories before creating a commit because their refs cannot use the filesystem lock protocol.
  • Use this skill only when the task clearly matches the scope described above.
  • Do not treat the output as a substitute for environment-specific validation, testing, or expert review.
  • Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.
よくある質問

「コミット」とは何ですか?

ある時点でのコードのスナップショットを、変更内容の説明とともに記録するものです。プロジェクトの履歴を追跡するのに役立ちます。

「プッシュ」とは何ですか?

これらの「コミット」(コードのスナップショット)を、自分のパソコンから GitHub などの共有リポジトリに送る操作です。他の人が見られるようになり、バックアップにもなります。

コミットメッセージを統一するのはなぜですか?

「feat: ログイン機能を追加」のように統一されたメッセージがあると、変更の種類と目的をすばやく把握できます。それによって、共同作業やコードの保守がしやすくなります。

詳細

作者による元の説明

Safely stage, commit, and push intended git changes with conventional commit messages. Use for ordinary non-release pushes when explicitly asked to push, save work remotely, or share a completed change.

repo: sickn33/agentic-awesome-skills

人気

GitHubのスター
48k
ランキング
#4740
ライセンス
MIT
更新日
2026/10/15

このスキルは役に立ちますか?

0

ログイン して投票しましょう。

コメント

  • …

このリポジトリの他のスキル

似ているスキル