ToolPal

Git 명령어 생성기

포괄적인 Git 명령어 참조 및 생성기입니다. 카테고리별로 필터링하고, 원하는 작업으로 검색하고, 매개변수를 입력하여 바로 실행할 수 있는 명령어를 복사하세요.

git init

Initialize a new Git repository in the current directory.

basic
git clone <url>

Clone a remote repository into a new local directory.

basic
git status

Show the working tree status — staged, unstaged, and untracked files.

basic
git add .

Stage all changed and new files in the current directory.

basic
git add <file>

Stage a specific file for the next commit.

basic
git commit -m "<message>"

Create a new commit with a message describing the changes.

basic
git log --oneline

Display the commit history in a compact one-line format.

basic
git diff

Show unstaged changes between your working tree and the index.

basic
git diff --staged

Show changes between the index (staged) and the last commit.

basic
git branch

List all local branches. The current branch is marked with an asterisk.

branching
git branch <branch>

Create a new branch without switching to it.

branching
git checkout <branch>

Switch to an existing branch.

branching
git checkout -b <branch>

Create a new branch and switch to it immediately.

branching
git switch -c <branch>

Create and switch to a new branch (modern alternative to checkout -b).

branching
git merge <branch>

Merge the specified branch into the current branch.

branching
git rebase <branch>

Reapply commits on top of another branch, creating a linear history.

branching
git branch -d <branch>

Delete a local branch (safe — only if fully merged).

branching
git tag <name>

Create a lightweight tag at the current commit.

branching
git remote add origin <url>

Add a remote named 'origin' pointing to the given URL.

remote
git remote -v

List all configured remotes with their fetch and push URLs.

remote
git fetch origin

Download objects and refs from the remote without merging.

remote
git pull origin <branch>

Fetch and integrate changes from the remote branch.

remote
git push origin <branch>

Push the local branch to the remote repository.

remote
git push -u origin <branch>

Push and set the upstream tracking so future pushes only need 'git push'.

remote
git cherry-pick <commit>

Apply the changes introduced by a specific commit onto the current branch.

remote
git reset --soft HEAD~1

Undo the last commit but keep changes staged.

undo
git reset HEAD~1

Undo the last commit and unstage changes (default mixed mode).

undo
git reset --hard HEAD~1

Undo the last commit and discard all changes permanently.

undo
git revert <commit>

Create a new commit that undoes the changes from a specific commit.

undo
git restore <file>

Discard changes in the working tree for a specific file.

undo
git restore --staged <file>

Unstage a file while keeping the working tree changes.

undo
git commit --amend -m "<message>"

Modify the most recent commit message (before pushing).

undo
git stash

Temporarily save uncommitted changes to the stash stack.

stash
git stash push -m "<message>"

Stash changes with a descriptive message.

stash
git stash list

List all stashed changesets.

stash
git stash pop

Apply the most recent stash and remove it from the stash stack.

stash
git stash apply stash@{<index>}

Apply a specific stash entry without removing it from the stack.

stash
git stash drop stash@{<index>}

Remove a specific stash entry from the stash list.

stash
git log --oneline --graph --all

Display a visual ASCII graph of the branch history.

advanced
git bisect start

Begin a binary search to find the commit that introduced a bug.

advanced
git blame <file>

Show what revision and author last modified each line of a file.

advanced
git reflog

Show a log of all HEAD movements — useful for recovering lost commits.

advanced
git clean -fd

Remove untracked files and directories from the working tree.

advanced
git submodule add <url> <path>

Add another repository as a submodule at the given path.

advanced
git worktree add <path> <branch>

Check out a branch into a new working tree directory.

advanced

사용 방법

포괄적인 Git 명령어 참조 및 생성기입니다. 카테고리별로 필터링하고, 원하는 작업으로 검색하고, 매개변수를 입력하여 바로 실행할 수 있는 명령어를 복사하세요.

  1. 1상단의 카테고리 탭으로 명령어를 필터링하세요 — 기본, 브랜치, 원격, 되돌리기, 스태시, 고급 중에서 선택하거나 '전체'를 유지하면 모든 명령어가 표시됩니다.
  2. 2검색 상자에 명령어 이름이나 설명을 입력하여 필터링하세요. 예를 들어 'merge'나 '커밋 취소'를 입력하면 관련 명령어를 빠르게 찾을 수 있습니다.
  3. 3필요한 명령어를 찾으세요. 각 카드는 전체 명령어 구문, 설명, 카테고리 배지를 보여줍니다.
  4. 4명령어에 <branch>나 <message> 같은 파라미터가 있는 경우 카드의 텍스트 입력에 채워 넣으세요 — 명령어가 실시간으로 업데이트됩니다.
  5. 5카드의 '복사' 버튼을 클릭하여 실행 준비된 명령어를 클립보드에 복사하고 터미널에 붙여넣으세요.

주요 기능

  • 45개 이상의 git 명령어 — 기본, 브랜치, 원격, 되돌리기, 스태시, 고급 카테고리 포함
  • 실시간 파라미터 대체 — 브랜치 이름, 파일 경로, 커밋 해시를 입력하고 실행 준비된 명령어 복사
  • 전문 검색 — 구문뿐만 아니라 이름이나 설명으로 명령어 찾기
  • 카테고리 필터링 — 현재 작업과 관련된 명령어에만 집중
  • 설치 불필요 — 브라우저에서 완전히 실행, 인터넷 없이도 빠른 참고로 사용 가능

자주 묻는 질문

더 알아보기