Compare commits

...

3 Commits

Author SHA1 Message Date
Nicole O'Connor
2def06fb51 comment out git unrecognized branch warning 2024-07-19 10:43:00 -07:00
Nicole O'Connor
bc14813bbb fix updates checking for md5sum (instead of cmp) before comparing zshrc for updates 2024-07-02 19:03:13 -07:00
Nicole O'Connor
96c7934a83 fix prompt builder overriding mobile prompts 2024-07-02 18:58:53 -07:00
4 changed files with 18 additions and 20 deletions

View File

@@ -20,5 +20,19 @@ function rprompt_builder () {
print "${result}"
}
PROMPT='$(prompt_builder)'
RPROMPT='$(rprompt_builder)'
if [[ $cols -lt 80 ]]; then
if [[ $(uname -o) == "Android" ]]; then
hostemoji="📞"
else
hostemoji="🖥"
fi
PROMPT="👤%{$fg_bold[white]%}@${hostemoji} %~ %# %{$reset_color%}"
else
PROMPT='$(prompt_builder)'
RPROMPT='$(rprompt_builder)'
fi
TMOUT=60
TRAPALRM () {
zle reset-prompt
}

View File

@@ -10,7 +10,7 @@ function zeesh_update () {
_zshrc_updates_pending=0
if type md5sum &> /dev/null; then
if type cmp &> /dev/null; then
cmp -s ~/.zshrc ~/.local/share/zeesh/zshrc-stub
if [[ $? -eq 1 ]]; then
cp ~/.local/share/zeesh/zshrc-stub ~/.zshrc

View File

@@ -26,7 +26,7 @@ function git_prompt() {
else
branchname=${fullbranchname}
# output a warning to stderr, convenience for maintenance
echo "warning: unrecognized branch type ${branchtype}" >&2
#echo "warning: unrecognized branch type ${branchtype}" >&2
fi
print "%{$fg_bold[yellow]%}${branchname} %{$reset_color%}%{$fg[yellow]%}${commithash}"

View File

@@ -3,22 +3,6 @@ source ~/.local/share/zeesh/base/zeesh.zsh
ticker_message "zeesh: bootstrap"
if [[ $cols -lt 80 ]]; then
if [[ $(uname -o) == "Android" ]]; then
hostemoji="📞"
else
hostemoji="🖥"
fi
PROMPT="👤%{$fg_bold[white]%}@${hostemoji} %~ %# %{$reset_color%}"
#else
# PROMPT="%{$fg_bold[cyan]%}%n%{$fg_bold[white]%}@%{$fg_bold[magenta]%}%m %{$fg_bold[white]%}%~ %# %{$reset_color%}"
# RPROMPT="%(?..%{$fg[red]%}%? )$RPROMPT"
fi
TMOUT=60
TRAPALRM () {
zle reset-prompt
}
source ~/.local/share/zeesh/base/precmd.zsh
source ~/.local/share/zeesh/base/prompt.zsh
source ~/.local/share/zeesh/base/updates.zsh