Skip to content

Latest commit

 

History

55 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🎨 Git Palette for VS Code

Quick access to common Git commands directly from VS Code with a convenient keyboard shortcut.

Git Palette Demo

✨ Features

  • 🚀 Access Git commands with a single keyboard shortcut
  • 🔍 Smart Fuzzy Search to quickly find commands
  • 🔄 See incoming and outgoing commit counts beside Sync
  • ❌ Cancel an active sync from its progress notification
  • 📋 Review complete output from commands with installed Git hooks
  • ⏸️ Prevent overlapping Sync actions while VS Code Git is busy
  • 💻 User-friendly command interface
  • 📦 Available commands:
    • Add - Stage changes
    • Commit - Record changes
    • Commit Amend - Update previous commit
    • Clone - Clone repositories
    • Pull - Get remote changes
    • Push - Send local changes
    • Sync - Pull then push, with incoming and outgoing commit counts
    • Rename Branch - Change current branch name

🚀 Usage

⌨️ Keyboard Shortcut (Recommended)

  1. Press Cmd+Shift+G (Mac) or Ctrl+Shift+G (Windows/Linux)
  2. Type to search commands with fuzzy matching:
    • Type amend to find "Commit Amend"
    • Type push or upload to find "Push"
    • Type rename to find "Rename Branch"

🔍 Command Palette

Press Cmd+Shift+P (Mac) or Ctrl+Shift+P (Windows/Linux) and type "Git Palette"

📋 Git Hooks Output

Commit, amend, edit-message, push, force-push, pull, sync, and clone actions stream stdout and stderr when a relevant executable local hook is installed. Repositories containing only sample hooks do not open the output view. Git Palette opens a focused readonly editor before the Git command starts and appends raw output as it arrives. Each command begins with a concise [timestamp] hook-name: git command header. Run Git Palette: Show Git Hooks Output to reopen the latest output.

Only the latest completed operation is retained for the current extension session. Git does not identify which output lines came from hooks, so the view can also contain ordinary Git progress, warnings, and remote messages.

The existing Git Palette: Toggle Git Hooks command keeps Git's standard --no-verify behavior. It bypasses supported verification hooks, but hooks that Git does not suppress can still run and appear in the output.

📦 Local Installation

  1. Install dependencies and build the extension:
    bun install
    bun run build
  2. Package the extension:
    bun run package
  3. Install the generated .vsix file:
    code --install-extension ./git-palette-0.1.0.vsix --force
    Or in VS Code: Extensions sidebar → ... menu → Install from VSIX... → select the file.
  4. Reload VS Code to activate the extension.

📋 Requirements

  • Git installed and in your PATH

⚙️ Configuration

  • git-palette.autoAddFiles: Automatically add all files when committing (default: true)
  • git-palette.alwaysAddAllChanges: Add all changes when using Git Add (true) or prompt for files (false)
  • git-palette.showNotifications: Show result notifications for Git Palette commands (default: true)
  • git-palette.showSyncNotifications: Show cancellable progress and result notifications for Git Sync (default: true)
  • git-palette.showGitHooksOutput: Capture and show output from commands with relevant executable local hooks (default: true). Disabling it also disables the manual output command.
  • git-palette.showGitHooksOutputTimestamps: Include ISO timestamps in Git hooks output headers (default: true)

💡 Examples

Renaming a Branch

  1. Press Cmd+Shift+G (Mac) or Ctrl+Shift+G (Windows/Linux)
  2. Type "rename" to find the "Rename Branch" command
  3. Enter the new branch name in the input box
  4. The current branch will be renamed to the new name

🛠️ Development

  1. Install dependencies:
    bun install
  2. Build the extension:
    bun run build
  3. Open this project in VS Code and press F5 to build and launch the Extension Development Host.

🤝 Contributing

Contributions are welcome! Feel free to submit a PR or open an issue.

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

About

VSCode extension

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages