npm.io
1.0.0 • Published 3d agoCLI

@sidx1scr-apps/gittooljs

Licence
MIT
Version
1.0.0
Deps
0
Size
23 kB
Vulns
0
Weekly
0

gittooljs

Making Git simple.

gittooljs is a lightweight, zero-dependency Node.js CLI tool that beautifully simplifies your Git workflow. It is a JavaScript port of the original Go-based gittool.

Enjoy a gorgeous, true-color UI, automated GitHub integration, and streamlined commands that save you time!

Looking for the Go version? If you prefer the original, compiled Go version of gittool, you can install it via Homebrew:

brew tap sidx1-scratch/tap
brew trust sidx1-scratch/tap
brew install sidx1-scratch/gittool

Installation

Install globally via npm:

npm install -g @sidx1scr-apps/gittooljs

Usage

Run the tool by simply typing gittool in your terminal.

gittool <command>
Available Commands
  • gittool init Initialize a brand new local repository and switch to a main branch automatically.

  • gittool repo add <url> Link a remote GitHub/GitLab repo. It automatically configures SSH connections (converting HTTPS URLs seamlessly).

  • gittool repo new [name] Create a new private GitHub repository, link it, and push your code instantly. (Requires the gh CLI)

  • gittool status Get a beautiful, color-coded overview of your file changes, branch name, and sync status with the remote repository.

  • gittool branches Display a visually pleasing list of all local and remote branches, highlighting the one you are currently on.

  • gittool save [-m] Automatically stage all changes, generate a formatted commit message (with timestamp and changed files), and push to main. Use the -m flag to open your $EDITOR and write a custom message on top of the auto-generated one.

  • gittool sync Perform a safe git pull --rebase followed by a git push to keep everything perfectly in sync.

  • gittool log View a beautifully formatted, compact commit log with relative timestamps and authors.

  • gittool pr Instantly create a Pull Request for your current branch with a single command. (Requires the gh CLI)

  • gittool oops Forgot a file? Just git add it and run this command to seamlessly amend your last commit without needing to edit the message.

  • gittool undo A safe soft-reset that undoes your last commit but keeps all your file changes staged and ready to be re-committed.

Features

  • Zero dependencies! Everything is built using standard Node.js libraries.
  • Beautiful UI: Custom true-color output, animated spinners, and clean ASCII boxes.
  • Automatic SSH Configuration: Prompts and auto-translates URLs to keep your auth simple.
  • GitHub CLI Integration: Optional commands like repo new and pr leverage the official gh CLI for powerful automation.