Skip to content

ZaikoXander/amnesia

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

amnesia logo

amnesia

Fuzzy search and checkout Git branches from your terminal

amnesia is a shell utility for quickly searching and checking out Git branches using the power of fzf. It streamlines your workflow by making branch navigation fast and interactive.

Leia em português

Features

  • 🔍 Fuzzy search for local branches
  • 🚀 Fast checkout with a single command
  • 📝 Print branch names without switching
  • 🖱️ Interactive branch selection
  • 🏠 Quickly return to the default branch

Requirements

  • fzf (must be in your $PATH)
  • git

Installation (at the moment)

  1. Install fzf dependency

    sudo apt install fzf
  2. Clone the repository:

    git clone https://github.com/ZaikoXander/amnesia.git
  3. Source the script in your shell config:

    # For bash:
    echo 'source /path/to/amnesia/index.sh' >> ~/.bashrc
    # For zsh:
    echo 'source /path/to/amnesia/index.sh' >> ~/.zshrc
  4. Reload your shell:

    source ~/.bashrc   # or
    source ~/.zshrc

Usage

Command Description
amn <branch> Fuzzy-search and checkout a branch
amni Interactively select and checkout a branch
amnb <branch> Print matching branch name (no checkout)
amnbi Interactively select and print branch name
amn Checkout the default branch (main/master)

Examples

  • Checkout a branch by name:
    amn feature/login
  • Interactively select a branch to checkout:
    amni
  • Print a matching branch name:
    amnb fix/typo
  • Interactively print a branch name:
    amnbi
  • Checkout the default branch:
    amn

Contributing

Contributions are welcome! Please open issues or submit pull requests to improve features, fix bugs, or enhance documentation.


Made with ❤️ by ZaikoXander

About

amnesia: Fuzzy search and checkout Git branches from your terminal

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages