Skip to content

Latest commit

 

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

[^-^] Hi, I am Niki!

I live in your command line, as your prompt!

Niki will say hi to you… even if hi doesn’t exist.

[^o^]
[>_<] which hi
hi not found
[^-^] hi!

Installation Adoption Guide

Compile and install

git clone https://github.com/guiyuanju/niki
cd niki

# default install to /usr/local/bin
make install

Configure your shell to use Niki

For zsh, add to your .zshrc:

# custom prompt
preexec() {
  LAST_CMD="$1"
}
setopt PROMPT_SUBST
PROMPT='$(LAST_CMD="$LAST_CMD" /usr/local/bin/niki) '

For Bash, add the following to your ~/.bashrc:

# store last executed command
last_command=""
trap 'last_command=$BASH_COMMAND' DEBUG
# generate prompt
PS1='$(LAST_CMD="$last_command" /usr/local/bin/niki) '

About

A custom shell prompt.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages