mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-10-16 11:40:46 +00:00
Compare commits
3 commits
532959a342
...
082879c989
Author | SHA1 | Date | |
---|---|---|---|
|
082879c989 | ||
|
367e9381df | ||
|
b053f89de0 |
2 changed files with 3 additions and 2 deletions
|
@ -163,7 +163,7 @@ function git_current_branch() {
|
|||
}
|
||||
|
||||
# Outputs the name of the previously checked out branch
|
||||
# Usage example: git pull origin $(git_current_branch)
|
||||
# Usage example: git pull origin $(git_previous_branch)
|
||||
# rev-parse --symbolic-full-name @{-1} only prints if it is a branch
|
||||
function git_previous_branch() {
|
||||
local ref
|
||||
|
|
|
@ -22,7 +22,8 @@ function title {
|
|||
print -Pn "\e]1;${1:q}\a" # set tab name
|
||||
;;
|
||||
screen*|tmux*)
|
||||
print -Pn "\ek${1:q}\e\\" # set screen hardstatus
|
||||
print -Pn "\e]2;${2:q}\e\\" # set tmux pane title
|
||||
print -Pn "\ek${1:q}\e\\" # set screen hardstatus/tmux window name if `allow-rename` is on
|
||||
;;
|
||||
*)
|
||||
if [[ "$TERM_PROGRAM" == "iTerm.app" ]]; then
|
||||
|
|
Loading…
Reference in a new issue