I have installed oh-my-zsh and Iterm2 but when I change my theme to Agnoster nothing changes. Here's my .zshrc file:
export ZSH=/Users/{username}/.oh-my-zsh
ZSH_THEME="agnoster"
plugins=(
git
)
source $ZSH/oh-my-zsh.sh
But my Iterm2 terminal still looks the same
Edit: echo $SHELL outputs /bin/zsh
Related
fzf ctrl+r doesn't work anymore after I started to use zsh vi-mode. My zshrc file is here:
function zvm_config() {
ZVM_LINE_INIT_MODE=$ZVM_MODE_INSERT
ZVM_VI_INSERT_ESCAPE_BINDKEY=jk
}
source /opt/homebrew/opt/zplug/init.zsh
zplug "jeffreytse/zsh-vi-mode"
# Install plugins if there are plugins that have not been installed
if ! zplug check --verbose; then
printf "Install? [y/N]: "
if read -q; then
echo; zplug install
fi
fi
# Then, source plugins and add commands to $PATH
zplug load --verbose
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
If I separately run source ~/.fzf.zsh then it will work.
fzf keybindings seem to conflict with vi-mode. As mentioned here, Loading the fzf key bindings after loading the vi-mode plugin is one way to work around this issue. In my case, I was using oh-my-zsh and adding the fzf plugin after vi-mode in the plugins list fixed the issue.
According to the hint, I download the file
https://raw.githubusercontent.com/tmuxinator/tmuxinator/master/completion/tmuxinator.zsh
into /usr/local/share/zsh/site-functions/_tmuxinator(file path), but the autocompletion not work.
Then I source the file like below in ~/.zshrc, it is also not work.
. /usr/local/share/zsh/site-functions/_tmuxinator
My config environments are:
zsh: zsh 5.8 (x86_64-suse-linux-gnu)
tmuxinator: tmuxinator 2.0.1
And I use oh-my-zsh as my zsh environment and rbenv to install tmuxinator.
The fpath environment variable in my system is:
/home/run/.oh-my-zsh/plugins/git /home/run/.oh-my-zsh/functions /home/run/.oh-my-zsh/completions /usr/local/share/zsh/site-functions /usr/share/zsh/site-functions /usr/share/zsh//functions/Calendar /usr/share/zsh//functions/Chpwd /usr/share/zsh//functions/Completion /usr/share/zsh//functions/Completion/Base /usr/share/zsh//functions/Completion/Linux /usr/share/zsh//functions/Completion/Unix /usr/share/zsh//functions/Completion/X /usr/share/zsh//functions/Completion/Zsh /usr/share/zsh//functions/Completion/openSUSE /usr/share/zsh//functions/Exceptions /usr/share/zsh//functions/MIME /usr/share/zsh//functions/Math /usr/share/zsh//functions/Misc /usr/share/zsh//functions/Newuser /usr/share/zsh//functions/Prompts /usr/share/zsh//functions/TCP /usr/share/zsh//functions/VCS_Info /usr/share/zsh//functions/VCS_Info/Backends /usr/share/zsh//functions/Zftp /usr/share/zsh//functions/Zle /etc/zsh_completion.d
which includes the directory /usr/local/share/zsh/site-functions.
You may have to force rebuild zcompdump:
rm -f ~/.zcompdump; compinit
ZSH shell shows Git prompt status (master [?]) even if a directory isn't a git directory.
What could be the problem? Thanks in advance.
My .zshrc file:
export PATH=$HOME/bin:/usr/local/bin:$PATH
export ZSH=/Users/m3rkus/.oh-my-zsh
ZSH_THEME="spaceship"
plugins=(git)
source $ZSH/oh-my-zsh.sh
One of the higher level folder has probably a .git folder in it.
You can use #Adaephon suggested command to find where it is:
git rev-parse --show-toplevel
I have the following line in my .zpreztorc file:
zstyle ':prezto:module:prompt' theme 'paradox'
And when I type prompt -c in my terminal it returns:
Current prompt theme is:
paradox
But the theme itself is not loaded. Only after I type run prompt paradox does the theme actually display. Is there anything else I need to add to any configuration file to make sure the theme actually loads when I start my terminal. I'm using iTerm2 and I already have powerline installed properly.
There have been issues in the past with presto's prompt setting; IMO it is best to add to the theme to your .zshrc:
promptinit
prompt paradox
if you are using prezto add
$ echo "prompt paradox" >> ~/.zshrc
$ source ~/.zshrc
if you are using yadr
$ echo "prompt paradox" >> ~/.zsh.after/prompt.zsh
$ source ~/.zshrc
I used for years in openSuSE the:
#compdef w
_files -W ~/work -/
function to auto-complete the directory names in my ~/work dir.
It does not work in Ubuntu zsh -v 4.3.11, when I hit TAB after w I got directories from my home directory.
What's different in Ubuntu?
Nevermind I found cdpath variable. I added in my config file
cdpath=( /usr ~ ~/work )
and it works :) Just cd somechar Tab. No more compdef functions.