1

On my new mac machine, I could not do autocomplete for Git when I hit Tab.

So I thought to modify the terminal and found certain things on this link.

I may have messed when I installed iTerm2, Oh-My-ZSH, and Solarised Dark. So now I have nice looking terminal and git autocompletion works.

But in the terminal, the user name, machine name etc does not appear, like it is the in above link.

enter image description here.

The colour scheme is also not great.

Can someone please help me, possibly step-by-step, on how to show these things like in this image enter image description here

I am very new to Mac and please assume that I know very little about how it works.

1 Answer 1

2

Everything you're asking has more to do with the shell than with iTerm. There are numerous tutorials on how to set up your PROMPT variable (I use a modified version of this one). Since you're using Oh-my-zsh, try looking through the themes page. There are a variety of styles available (I began with the af-magic prompt). Once you find a prompt you like, feel free to copy the source from the .oh-my-zsh/themes folder to .oh-my-zsh/custom/themes and modify the custom version. Details on custom plugins and themes are available here.

2
  • 1
    Note that Oh-my-zsh will look in custom/ and custom/themes/ for files named $ZSH_THEME.zsh-theme if you set the ZSH_THEME variable in your .zshrc, so you could name a theme af-magic_mod.zsh-theme, place it in the custom folder, and set your theme to ZSH_THEME=af-magic_mod, just the same way you'd set any of the included themes. Commented Feb 29, 2016 at 21:38
  • This worked just like I wanted. But I did not have to copy or move any theme files. All I did was open /zshrc file and set the theme to ZSH_THEME = ys.
    – chintan s
    Commented Feb 29, 2016 at 22:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .