mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-01-23 02:35:38 +01:00
asd
This commit is contained in:
parent
73024e8f08
commit
702d23c98f
3 changed files with 26 additions and 3 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
|
@ -1,6 +1,3 @@
|
||||||
# custom files
|
|
||||||
custom/
|
|
||||||
|
|
||||||
# temp files directories
|
# temp files directories
|
||||||
cache/
|
cache/
|
||||||
log/
|
log/
|
||||||
|
|
|
||||||
19
custom/plugins/arc/arc.plugin.zsh
Normal file
19
custom/plugins/arc/arc.plugin.zsh
Normal file
|
|
@ -0,0 +1,19 @@
|
||||||
|
function arc_prompt_info() {
|
||||||
|
arcStatus=$(arc status 2>/dev/null)
|
||||||
|
arcBranch=$(echo $arcStatus | sed -n 's/^On branch \(.*\)$/\1/p')
|
||||||
|
arcStatus=$([ -z "$(arc status --short 2>/dev/null)" ] && echo "true" || echo "false")
|
||||||
|
arcBranchPrefix="${ARC_BRANCH_PREFIX:-}"
|
||||||
|
arcBranchSuffix="${ARC_BRANCH_SUFFIX:-}"
|
||||||
|
arcBranchOutput=""
|
||||||
|
if [[ -n "$arcBranch" ]]; then
|
||||||
|
arcBranchOutput=" $arcBranchPrefix$arcBranch"
|
||||||
|
if [[ "$arcStatus" == "true" ]]; then
|
||||||
|
arcBranchOutput+="${ARC_PROMPT_CLEAN:-}"
|
||||||
|
else
|
||||||
|
arcBranchOutput+="${ARC_PROMPT_DIRTY:-}"
|
||||||
|
fi
|
||||||
|
arcBranchOutput+="$arcBranchSuffix"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo $arcBranchOutput
|
||||||
|
}
|
||||||
7
custom/themes/cbist.zsh-theme
Normal file
7
custom/themes/cbist.zsh-theme
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
PROMPT='%B%F{1}[%D{%Y-%m-%d %H:%M:%S}]%b%F{226} %~%f$(arc_prompt_info): '
|
||||||
|
|
||||||
|
ARC_BRANCH_PREFIX="%{$fg_bold[blue]%}("
|
||||||
|
ARC_BRANCH_SUFFIX="%{$fg_bold[blue])%f%b%}"
|
||||||
|
ARC_PROMPT_DIRTY=" %{$fg[red]%}✗%f"
|
||||||
|
ARC_PROMPT_CLEAN=" %{$fg[green]%}✔%f"
|
||||||
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue