Skip to content

Command watch for zsh that supports alias and completion.

License

Notifications You must be signed in to change notification settings

Thearas/zsh-watch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

WATCH

Simple watch wrapper for zsh that supports alias and completion.

Usage

Just watch <command> <args> (press <Tab> to complete):

# Watch the pods
watch kubectl get pod -n kube-system

# Use alias
watch kgpn kube-system

# With watch flags
watch -c -n1 -d -t kgp

Installation

  1. Install watch (macOS only).

    brew install watch
  2. Add zsh-watch to the plugins array in your zshrc file.

    • Oh-My-Zsh

      git clone https://github.com/Thearas/zsh-watch ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-watch
      
      # In your ~/.zshrc
      plugins=(... zsh-watch)
    • Zinit

      # In your ~/.zshrc
      zinit light Thearas/zsh-watch
    • Zi

      # In your ~/.zshrc
      zi light Thearas/zsh-watch
    • Manual

      git clone https://github.com/Thearas/zsh-watch ~/path/to/zsh-watch
      
      # In your ~/.zshrc
      source ~/path/to/zsh-watch/zsh-watch.plugin.zsh

Use another watch command

Use viddy instead of watch:

# In your ~/.zshrc
export ZSH_WATCH=viddy
export ZSH_WATCH_FLAGS="-t -d -n1 --pty"

About

Command watch for zsh that supports alias and completion.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages