Skip to content

Expandable aliases with cursor placement

Notifications You must be signed in to change notification settings

IlanCosman/zsh-abbr

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 

Repository files navigation

zsh-abbr

A Fish shell-like abbr command for Zsh with extended cursor placement functionality.

Installation

  1. Clone the repository into the Oh My Zsh custom plugins folder:

    git clone https://github.com/IlanCosman/zsh-abbr $ZSH_CUSTOM/plugins/zsh-abbr
  2. Add zsh-abbr to the plugins array in your zshrc:

    plugins=(... zsh-abbr)

Examples

abbr syu "sudo pacman -Syu"

Space will expand syu into sudo pacman -Syu. Enter will expand and then run the command.

abbr gca "git commit -am '^'"

Use a ^ to determine where the cursor will be placed after expansion.

abbr s "sudo ^"

Note: Using a ^ will cause Enter to only expand the command, not run it.

About

Expandable aliases with cursor placement

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages