Skip to content

v1.0.4

Choose a tag to compare

@github-actions github-actions released this 07 Jul 18:38
· 23 commits to main since this release

Gitok supercharges your Git workflow with 35+ custom commands and aliases designed to make Git operations faster and more intuitive.

✨ Key Features

πŸ”§ Core Git Operations

  • commit "message" - Stage all changes and commit with message
  • push - Push to current branch with safety checks
  • pushall - Push to all configured remotes with rebase
  • pull - Pull with automatic rebase
  • status - Enhanced git status display

🌿 Branch Management

  • branch <name> - Create and switch to new branch
  • checkout <name> - Switch to existing branch
  • branches - List all branches with details
  • deletebranch <name> - Safely delete branch

πŸ“ˆ Advanced Features

  • unpush - Safely undo last push (with confirmation)
  • squashlast [N] - Squash last N commits
  • graphlog - Beautiful commit history visualization
  • makeignore <type> - Generate .gitignore templates

πŸ› οΈ Productivity Tools

  • gitcheatsheet - Interactive command reference
  • gitok --update - Auto-update to latest version
  • gitok --version - Show version information
  • Safety confirmations for destructive operations

πŸ“¦ Installation

🐧 Linux & macOS

bash <(curl -sL https://raw.githubusercontent.com/okwareddevnest/gitok/main/install.sh)

πŸͺŸ Windows Users

Option 1: WSL (Recommended)

wsl bash -c "curl -sL https://raw.githubusercontent.com/okwareddevnest/gitok/main/install.sh | bash"

Option 2: Git Bash

bash <(curl -sL https://raw.githubusercontent.com/okwareddevnest/gitok/main/install.sh)

Option 3: PowerShell (Run as Administrator)

iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/okwareddevnest/gitok/main/install-windows.ps1'))

Option 4: Download & Run Batch File
Download: install-windows.bat

βœ… Verify Installation

# Restart your terminal or run:
source ~/.bashrc  # or source ~/.zshrc

# Test installation
gitok --version
gitcheatsheet

πŸ”„ Updates

# Auto-update to latest version
gitok --update

# Check current version
gitok --version

πŸš€ Quick Start

# Initialize repo and make first commit
init
commit "Initial commit"

# Create feature branch
branch feature/awesome-feature
commit "Add awesome feature"

# Push to all remotes
pushall

# View commit history
graphlog

# See all commands
gitcheatsheet

πŸ“‹ Complete Command List

Repository Management

  • init - Initialize Git repository
  • clone <url> - Clone repository
  • status - Show repository status

Staging & Commits

  • addall - Stage all changes
  • commit "message" - Stage all and commit
  • commitonly "message" - Commit staged changes only
  • amendmsg "message" - Amend last commit message

Push & Pull Operations

  • push - Push current branch
  • pushall - Push to all remotes
  • pushnew - Push new branch to remote
  • pull - Pull with rebase
  • unpush - Undo last push (⚠️ destructive)
  • trackremote - Set upstream tracking

Branch Operations

  • branch <name> - Create and switch to branch
  • checkout <name> - Switch to branch
  • branches - List all branches
  • deletebranch <name> - Delete branch safely
  • deletebranchf <name> - Force delete branch

History & Logs

  • graphlog - Graphical commit history
  • last - Show last commit
  • logfull - Detailed commit history
  • diff - Show changes

Undo & Reset

  • resetsoft - Soft reset to last commit
  • resethard - Hard reset to last commit
  • revertlast - Revert last commit
  • unstage - Unstage changes
  • restore <file> - Restore file

Stash Operations

  • stash - Stash current changes
  • pop - Pop latest stash

Cleanup & Tools

  • clean - Clean untracked files
  • tracked - Show tracked files
  • remotes - Show remote repositories
  • squashlast [N] - Squash last N commits

File Management

  • ignore <pattern> - Add to .gitignore
  • makeignore <type> - Generate .gitignore template

Help & Information

  • gitcheatsheet - Interactive command reference
  • gitok --help - Show help
  • gitok --version - Show version
  • gitok --update - Update to latest version

πŸ”§ Technical Features

  • Cross-platform support (Linux, macOS, Windows)
  • Automatic shell detection (bash, zsh, fish)
  • Intelligent installation with profile configuration
  • Auto-update system with GitHub API integration
  • Safety confirmations for destructive operations
  • Colorized output for better readability
  • CI/CD integration with automated testing

πŸ›‘οΈ Safety Features

  • Confirmation prompts for destructive operations
  • Automatic backups before major changes
  • Dry-run options for testing commands
  • Comprehensive error handling

πŸ“š Documentation

🀝 Support


⭐ Star this repo if Gitok boosts your Git productivity!

Created with ❀️ by Dedan Okware