.static/css | ||
completions | ||
extensions | ||
lib | ||
prompts | ||
.gitignore | ||
LICENSE | ||
ohmy.ksh | ||
README.org |
ohmyksh
About
Have your cake and eat it too!
ohmyksh
is a framework for expanding OpenBSD's ksh. It offers:
Completions
Extensions
Name | Description |
---|---|
fonts | Load fonts from common locations. |
fzf | - |
git-prompt | A port of git-prompt for KSH. |
got | Adds PS1 support for got, as well as a few helper functions. |
k | A tool to quickly change directories. |
keychain | Wrapper for Funtoo's Keychain utility. |
nocolor | Disable terminal color options for many tools. |
openbsd | A set of tools for working with the OpenBSD source trees. |
pkgup | Utility to speed up OpenBSD' pkg_add(1). |
Prompts
Name | Example | Extensions used |
---|---|---|
q | qbit@litr[0]:~$ |
git-prompt, got |
plain | litr:~/src/ohmyksh/prompts$ |
- |
og-openbsd | $ |
- |
9 | % |
- |
Example usage
# ohmyksh needs to know where it lives, so we tell it via this env var:
OHMYKSH_DIR=${HOME}/src/ohmyksh
# Now we can load everything up!
. ${OHMYKSH_DIR}/ohmy.ksh
# All the paths we use (in order!)
set -A my_paths -- \
/usr/ports/infrastructure/bin \
~/bin \
~/go/bin \
/usr/local/plan9/bin
paths "${my_paths[@]}"
# Load our various extensions
load_extension fonts
load_extension k
load_extension nocolor
load_extension openbsd
# Load handy completions for various things
load_completion ssh
load_completion vmd
load_completion rc
load_completion gopass
load_completion git
alias vi=vim
# the q prompt auto-loads the git-prompt extension
set_prompt q