1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-10-26 16:40:29 +01:00

36735: add ~/.zcalcrc handling to zcalc

This commit is contained in:
Peter Stephenson 2015-10-01 15:55:01 +01:00
parent 8bf72dd65b
commit 196e6a0ec0
3 changed files with 14 additions and 0 deletions

View file

@ -120,6 +120,10 @@ autoload -Uz zmathfuncdef
float PI E
(( PI = 4 * atan(1), E = exp(1) ))
if [[ -f "${ZDOTDIR:-$HOME}/.zcalcrc" ]]; then
. "${ZDOTDIR:-$HOME}/.zcalcrc" || return 1
fi
# Process command line
while [[ -n $1 && $1 = -(|[#-]*|f|e) ]]; do
optlist=${1[2,-1]}