Skip to content

Mommy is here to support you when running commands <3

Notifications You must be signed in to change notification settings

catuhana/zsh-mommy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 

Repository files navigation

ZSH Mommy~ ❤️

Inspired from Gankra/cargo-mommy, made for your shell! ❤️

Mommy is here to support you when you're running commands~

Installation

Manually

Clone the Git repository

git clone https://github.com/catuhana/zsh-mommy

and source it to your .zshrc

echo 'source "${(q-)PWD}/zsh-mommy/zsh-mommy.zsh"' >>${ZDOTDIR:-$HOME}/.zshrc

and then reload your shell for mommy! ❤️

Plugin Frameworks

Oh My ZSH

Clone the Git repository to ~/.oh-my-zsh/custom

git clone https://github.com/catuhana/zsh-mommy ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-mommy

and add it to your plugins array in .zshrc

plugins=(zsh-mommy)

Zim

Add zmodule catuhana/zsh-mommy to your .zimrc and run zimfw install

zgen/zplugin

Add zgen/zplugin load catuhana/zsh-mommy to your .zshrc

Antigen

Add antigen bundle catuhana/zsh-mommy to your .zshrc

Customisation

To customise the plugin, you can edit variables the plugin uses after the plugin is loaded.

For example, to append or change new pronouns or affectionate terms, you can add:

ZSH_MOMMY_AFFECTIONATE_TERM+=(cat cutie)
ZSH_MOMMY_MOMMYS_ROLE=(owner)

Or if you want it to be for your current shell only, you can define them with export.

Add Your Own Responses

If you have more response ideas for mommy, or if there's a response you want to remove, you can update ZSH_MOMMY_POSITIVE_RESPONSES or ZSH_MOMMY_POSITIVE_RESPONSES arrays.

Tip

I would appreciate if you contribute your own responses to mommy! Just make sure that they fit the theme of current responses.

Current response arrays:

  • ZSH_MOMMY_POSITIVE_RESPONSES - positive responses after a successful command
  • ZSH_MOMMY_NEGATIVE_RESPONSES - negative responses after an unsuccessful command

Add Prefix or Suffix to Responses

If you'd like mommy to be more cheerful, you can add emojis or text before or after mommy's actual responses.

  • ZSH_MOMMY_RESPONSES_PREFIX - prefix before mommy's actual response (default: `` (empty string))
  • ZSH_MOMMY_RESPONSES_SUFFIX - suffix after mommy's actual response (default: ❤️)

Coloured Responses

If you want mommy to be more colourful, you can set ZSH_MOMMY_COLOURED_RESPONSES to true or 1, which is the default. The colour of the response is also customisable.

If your shell doesn't appear to be supporting colours by the plugin, you can set ZSH_MOMMY_FORCE_COLOURED_RESPONSES to true for forcing mommy to colour her responses.

  • ZSH_MOMMY_COLOURED_RESPONSES - make mommy more colourful (default: true)
  • ZSH_MOMMY_RESPONSE_COLOUR - decide what colour mommy should use (default: (255 179 204))
  • ZSH_MOMMY_FORCE_COLOURED_RESPONSES - force mommy to add colours to her response (default: false)

Terms, Pronouns and Roles

  • ZSH_MOMMY_AFFECTIONATE_TERM - what mommy calls you (default: (girl))
  • ZSH_MOMMY_MOMMYS_PRONOUN - what mommy will use as their pronouns (default: (her))
  • ZSH_MOMMY_MOMMYS_ROLE - the role of mommy (default: (mommy))

When to Run Mommy

If you want mommy to response on demand instead, you can set ZSH_MOMMY_RUN_AFTER_EVERY_COMMAND variable to false or 0 before the plugin is loaded. This will create a new function named mommy, which accepts your normal command input and runs them.

mommy vim ~/.zshrc
mommy git push -f

About

Mommy is here to support you when running commands <3

Topics

Resources

Stars

Watchers

Forks

Languages