简体   繁体   中英

Change ZSH Command Prompt

在此处输入图像描述 在此处输入图像描述

I just recently changed to ZSH from bash and I see this weird command prompt. I'd like to just have a simpler, shorter command prompt without all of this jargon. Please assist...

in macos, find your.zshrc file, open it in a text editor, locate the comment "#Default prompt", modify the line that looks like this:-- "PS1=%n@%m~%&# " (%n is your username; %m is the computer name), save the file (you will be prompted to enter your password to save it), load a new terminal to check out the changes.

I'm using Alacritty and Oh-My-Zsh, I named my terminal in alacritty.yml as below:
window:
title: Terminal Ihsan Praditya
but nothing change, then I found a line in.zshrc, it's:
# Uncomment the following line to disable auto-setting terminal title.
# DISABLE_AUTO_TITLE="true"
then I uncomment the line, restart the terminal, it's shown as below
.zshrc after Oh-My-Zsh on Alacritty

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM