here problem. using agnoster theme in zsh. looks great in iterm looks in terminal.

in other words looks ugly. interested in 2 kinds of solutions:
have different zsh themes terminal , iterm. can use agnoster iterm , other theme terminal. (for example:
robbyrusselllooks fine in terminal haveagnosteriterm ,robbyrussellterminal.make modifications
agnosterlooks fine in terminal.
i got work, apparently missing whitespace in if condition, rendered useless. here how looks in zshrc
if [ "$term_program" = "apple_terminal" ]; zsh_theme="robbyrussell" else zsh_theme="agnoster" fi
terminal , iterm set environmental variable term_program.
terminal : apple_terminal
iterm : iterm
if use pathfinder's terminal, term_program unset.
open oh-my-zsh configuration , use following construction:
ohmythemes=( # favourite themes ) [ "$term_program" = "iterm" ] && ohmythemes+=agnoster zsh_theme=${ohmythemes[(($random % ${#ohmythemes} + 1))]} # chooses theme among favourite randomly as far know zsh, assume know least bit of shell scripting , can adjust code.
related question : get terminal application name shell
Comments
Post a Comment