如何在启动时删除终端中的“空白空间?

问题描述 投票:0回答:1

我将iterm2与oh-my-zsh(macOS)一起使用,我想在第一行(现在是第五行)上启动“终端代码”。您能告诉我,我该怎么做?

“终端顶部和提示的呈现之间的空白线

这是我的~/.zshrc

export ZSH=/Users/ivbutsykin/.oh-my-zsh
ZSH_THEME="powerlevel9k/powerlevel9k"
POWERLEVEL9K_PROMPT_ADD_NEWLINE=true

plugins=(
 zsh-autosuggestions
)

source $ZSH/oh-my-zsh.sh
test -e "${HOME}/.iterm2_shell_integration.zsh" && source "${HOME}/.iterm2_shell_integration.zsh"

local user_symbol="$"
if [[ $(print -P "%#") =~ "#" ]]; then
  user_symbol = "#"
fi

POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX="%{%B%F{black}%K{yellow}%} $user_symbol%{%b%f%k%F{yellow}%} %{%f%}"
POWERLEVEL9K_VCS_MODIFIED_BACKGROUND='red'
echo -e "\033]6;1;bg;red;brightness;18\a"
echo -e "\033]6;1;bg;green;brightness;26\a"
echo -e "\033]6;1;bg;blue;brightness;33\a"

我将iterm2与oh-my-zsh(macOS)一起使用,我想在第一行(现在是第五行)上启动“终端代码”。您能告诉我,我该怎么做?这是我的〜/ .zshrc:export ZSH = / Users / ivbutsykin / .oh -...

macos iterm2 oh-my-zsh
1个回答
0
投票

您可以通过将echo -e替换为echo -ne来摆脱3个空行。要摆脱剩余的空行,您需要升级到powerlevel10k。

© www.soinside.com 2019 - 2024. All rights reserved.