Questions tagged [oh-my-zsh]

oh-my-zsh is an addon to zsh that adds additional functions, autocomplete helpers and themes.

Filter by
Sorted by
Tagged with
1 vote
0 answers
10 views

define hierarchy of history files for ZSH

My zsh syncs history across terminals. Sometimes this is useful. But many times I just need the last command ran on a specific terminal. So I'd like to have two history files in use by each terminal ...
user avatar
0 votes
1 answer
22 views

zsh in tabby separate history for each tab

I want to keep history separated for each tab (even for split windows within one tab). I therefore found a solution to add these two lines after source $ZSH/oh-my-zsh.sh: source $ZSH/oh-my-zsh.sh ...
user avatar
  • 101
1 vote
3 answers
45 views

How to get a shorter Path prompt in powerline10k / zsh?

everyone! In my iterm2 (with zsh, oh-my.zsh and powerline2) terminal if I go to certain directories I have a prompt like this: $ pokemon/electric/pichu/pikachu/raichu I'd like to have a shorter, but ...
user avatar
  • 11
0 votes
1 answer
16 views

opening default path for root user

It may be trivial what I say, but I need to change the default opening path that OH My ZSH has. since no matter where I preposition myself in a file path (example: /home/username/Downloads/owt), when ...
user avatar
0 votes
1 answer
38 views

Variable Scope in ZSH: How to access global variables from within function?

I have an ever-expanding .zshrc file that was getting out of hand so I decided to try to fix it by breaking it into modular files and sourcing each of them. This works for the most part, but I seem ...
user avatar
  • 113
0 votes
0 answers
14 views

Zsh sourced multiple times on startup

Whenever I open my iterms2 terminal on my Mac I see that zsh get's sourced multiple times. I would like to find out where this happens. What steps could I take to investigate this?
user avatar
  • 101
0 votes
0 answers
18 views

ZSH not showing the arrow key in CentOS7

I got the exact same problem like this post: zsh prompt isn't showing the arrow key due to font issues. According to this answer it's because I've not installed the required fonts. The commands I ...
user avatar
0 votes
0 answers
17 views

What triggers the j-k keys to scroll through prev/next commands and how do I properly get out of this mode (without ctlr-c)?

I've been using zsh with oh-my-zsh for several months now with vi commands. Frequently, the command line seems to "lock up" and become unresponsive to input. I chalked it up to some kind of ...
user avatar
  • 445
0 votes
0 answers
20 views

command `ll` with wildcard matching is not working as expected [duplicate]

I am using mac with oh my zsh installed current omz version ➜ omz version [02/28/22 | 18:49:04] ...
user avatar
  • 1
0 votes
0 answers
22 views

How do I get the tab key to complete commands?

I've got various tab completion plugins installed for oh-my-zsh, including (as it seems) a history plugin. For example, when I type LS I get the following: Is there a key I can hit to make it ...
user avatar
  • 1
0 votes
0 answers
41 views

Setting the color of history/tab completions

I was wondering how I would go about changing the color of the history/tab completions to a grey color instead of white. For some reason, it sometimes appears as white instead of grey sometimes. Below ...
user avatar
1 vote
0 answers
35 views

How to fix .zsh_history opening up every time I start the terminal

I tried to delete my zsh history following this answer by @WebEpic. The issue is that now, every time I open my terminal, the .zsh_history opens via Vim. I need to quit it using :qa then it would go ...
user avatar
  • 111
4 votes
1 answer
487 views

How to overwrite aliases in my shell (Oh My Zsh)?

I would like to alias my ls command, but there is a previously defined alias for it which I believe gets invoked first before my definition! I am using .zshrc to define my alias, and here is what I ...
user avatar
  • 43
2 votes
0 answers
52 views

Preview Oh My Zsh completion

I would like to preview what, if anything, would be completed using oh-my-zsh suggestions. In other words, a visual indicator that pressing TAB will insert what I think it will. in different color (...
user avatar
0 votes
1 answer
39 views

How do I get zsh-navigation-tools to show in the default shell colors instead of using its own theme?

I have a terminal with a white background: I enabled the zsh-navigation-tools plugin in Oh My Zsh. In n-list.conf I've set the color scheme to black on white: # Main color pair (foreground/background)...
user avatar
0 votes
0 answers
192 views

Shift + arrow keys adding characters to terminal instead of selecting text

I am running macos monterey (Version 12.0.1 (21A559)). I am using zsh, on iterm 2. With omz installed, and powerlevel10k theme installed. Recently I noticed that I cannot select text in terminal using ...
user avatar
1 vote
1 answer
131 views

Oh-my-zsh "take" command - Is there an equivalent in Fish?

Oh-my-zsh has the take command which creates a directory and enters into it in one step. Is there an equivalent command for the fish shell? I do know that I can do it with mkdir newDir && cd ...
user avatar
1 vote
2 answers
114 views

create an alias on ZSH but need to type it twice

I'm trying to create an alias on ZSH. The aim of the alias is to activate a python virtualenv. I've put a line in my .zshrc alias SOU="source /home/andykw/.zshrc && source $(setopt ...
user avatar
  • 169
0 votes
0 answers
78 views

how to fix tmux color error over powerlevel10k shell

I have just finished to install oh-my-zsh and powerlevel10k and all is ok, the problem is whe I start a tmux session. The colors of my custom shell with powerlevel10k doesn't work. The colors change ...
user avatar
0 votes
0 answers
78 views

Issue using Git Bash on Windows Terminal

Few months ago I installed zsh on git bash (Git for Windows), then I installed oh-my-zsh and Windows Terminal and everything was working fine. Recently, when I open windows terminal, I get an error ...
user avatar
  • 101
0 votes
1 answer
173 views

How to I properly set the advanced FZF_DEFAULT_COMMAND environment variable to get it working properly with ohmyz.sh with fzf plugin installed?

I'm new to z shell and ohmyz.sh. I have the following in my zshrc to integrate fzf with rg. This is exactly how it appears in the fzf readme: FZF_BASE=/usr/local/bin DISABLE_FZF_AUTO_COMPLETION="...
user avatar
  • 445
2 votes
1 answer
147 views

How to make `zsh` immediately show all completions, without first inserting the common prefix?

I have zsh set up with Oh-My-Zsh. The z plugin allows me to jump to recently used directories. When I type z name<TAB>, it autocompletes name from the list of recently visited dirs by matching ...
user avatar
  • 143
0 votes
1 answer
3k views

Changing PATH Variable in zsh

I want to change my PATH variable in zsh. Problem: I don't understand where in the .zshrc file I have to make modifications. Normally, I would look for the assignment to the PATH variable and set the ...
user avatar
0 votes
0 answers
45 views

How to execute bindkey shortcut in same TTY?

My goal is to create a notifier function in zsh that tells me when a current command has finished running. The function is basically running and implemented but there is still one bug that I want to ...
user avatar
  • 163
2 votes
1 answer
314 views

Opening py files in vim by default without having to type "vim filename.py"

I was wondering whether it is possible to open python files in vim, without typing "vim" in front of it. For example: Instead of: vim filename.py simply $ filename.py Would open the file ...
user avatar
2 votes
1 answer
5k views

What ZSH theme does Kali use?

Could someone please give me the name of the default ZSH theme that Kali uses? Also, if you could please provide a link to it.
user avatar
  • 23
0 votes
0 answers
646 views

What is the meaning of these symbols about git to the right of the prompt?

I recently took over maintenance of a server from a now departed colleague and while I'm getting a handle on most of the stuff, one thing that's still a bit confusing is how he's set up the GIT ...
user avatar
0 votes
1 answer
351 views

why is shell (new terminal, new tmux panes/windows) slow to load?

When I open a new terminal it takes a couple seconds for the shell to load, when I open a new pane or window in tmux it might even take a second longer. The delay is about 3 seconds. I'm using zsh ...
user avatar
  • 1,004
2 votes
1 answer
95 views

Load specific ZSH_THEME base on specific directory contain specific string

I'm using ohmyzsh. I'm trying to load a diff themes base on the current directory path (pwd) Logics If pwd in or contain sustring /Sites/work/ load af-magic, else load robbyrussell. .zshrc I've tried ...
user avatar
  • 372
1 vote
2 answers
89 views

/root/.bashrc:157: = not found

#Get client IP base on current logged in user if [ $USER == 'root' ] then ip="$(last | awk 'NR==1 {print $3}')" else ip="$(echo $SSH_CONNECTION | cut -d " " -f 1)"...
user avatar
  • 372
2 votes
2 answers
57 views

Create new set of aliases based on current set of aliases (eg. gst -> dst)?

I'm using git aliases from zsh plugins: https://github.com/ohmyzsh/ohmyzsh/tree/master/plugins/git So it has git aliases like: gst # git status ga # git add gc "commit" # git commit -v "...
user avatar
0 votes
1 answer
39 views

How do i get this fancy "path bar with git icons" as shown in this picture of zsh

How do i get this fancy "path bar with git icons" as shown in this picture of zsh? What is it called?
user avatar
1 vote
1 answer
171 views

How can I disable kitty's paste from escaping?

If I have the string and copy that with CTRL+SHIFT+C https://test.invalid/?foo=bar()&baz=$quz{} And I paste that into the terminal I see the following, https://test.invalid/\?foo\=bar\(\)\&...
user avatar
  • 22.4k
0 votes
1 answer
219 views

How to keep hostname on title when I run commands

I'm trying zsh on Ubuntu 20.04 from Putty. One good feature I like is that zsh automatically show the running command on window title, which is good for forgetful me who forget what is running. ...
user avatar
  • 119
0 votes
1 answer
969 views

How to fix powerline fonts and symbols error in shell?

I've installed Arch about a week ago, and since then I been struggling with the powerline fonts. But after installing the pkg powerline-fonts, I configured the .zshrc file by adding these lines: ...
user avatar
  • 289
1 vote
1 answer
125 views

zsh-cursor displacement over ssh

I am running Arch Linux locally. When I connect to my remote Debian 10 server via ssh, the cursor behaves in an awkward way: As long as every command returns statuscode 0, everything is fine. When ...
user avatar
  • 454
0 votes
2 answers
4k views

zsh: When running source I get zshrc:116: unmatched

So today I wanted to add some extra alias to zsh. I did the usual nano ~/.zshrc and added my alias ex: alias desktop="cd desktop" (I've doubled checked that all variables for typos) Ctrl+...
user avatar
1 vote
1 answer
538 views

How to disable all menu tab completions in ZSH. I have the zsh-autosuggestions plugin installed, and i want that to be the only form of completions

So I installed zsh a few days ago, and I'm loving it. But when I type something in, it shows me the possible completion using the autosuggestions plugin, but I cannot fill it using tab, i have to use ...
user avatar
0 votes
1 answer
471 views

How do I get oh-my-zsh to automatically download and install plugins at first run?

I really like my .vimrc config file with automatically downloads and installs all dependencies including the plugin manager and all the new while removing plugins which were removed from my .vimrc ...
user avatar
0 votes
0 answers
35 views

Switched from bash to zsh and now I can't login as root [duplicate]

I have changed my shell from bash to zsh and set it as default in Ubuntu 20.10 and now every time I run the command su i get this: su Password: (entered correct password) su: Authentication failure ...
user avatar
1 vote
1 answer
53 views

Run the same command

I constantly need to close and re-open programs. To do this I press Control+C > Up Arrow > Enter. However, I have more than one program and need to run different commands for these programs. If ...
user avatar
  • 121
2 votes
1 answer
1k views

What are "zsh" commands for cut/copy/paste?

I want to configure zsh and bind its cutting, copying and pasting commands (or maybe they're called widgets idk) to different escape sequences, the ones that my terminal program sends across. Problem ...
user avatar
0 votes
0 answers
95 views

fc -RI in precmd, now up-line-or-history doesn't work

I'm using the option INC_APPEND_HISTORY_TIME. That doesn't work together with SHARE_HISTORY. So I thought I call fc -RI before each command. But now I can't access my history via up-line-or-history (...
user avatar
  • 325
0 votes
0 answers
170 views

Multiple if condition in single brackets in zsh

The command bellow works well in bash: find . -depth -name Chart.yaml -exec sh -c 'f="{}"; if [[ ($f =~ ./api-*) && !($f =~ ./api-pnp-*) && !($f =~ ./api-edb-*) ]]; then ...
user avatar
0 votes
1 answer
2k views

Get back to default zsh theme in kali linux

I tried to change the default zsh theme with oh-my-zsh from their github repository and I just edited .zshrc switching from the default theme to another one and it just somehow went wrong cause now I ...
user avatar
  • 289
3 votes
2 answers
249 views

How can I style the zsh completion section headers?

In my screenshot, the section headers ("recent branches", "local head", etc.) are visually indistinguishable from the completion suggestions. compinstall doesn't seem to be able to ...
user avatar
7 votes
7 answers
3k views

How to run windows executables from terminal without the explicitly specifying the .exe extension?

As the title says most of the question, how can we run windows executables without specifying the explicit .exe suffix at the end. For example reducing the call like explorer.exe . to explorer ., or ...
user avatar
-1 votes
1 answer
33 views

oh-my-zsh throws rrror when trying to access zsh profile in Mac OS Catalina

Trying to access either .zshrc or .zprofile doesn't work (it creates a new file). Trying to access the it with ~/.zshrc throws the same error. From my understanding I must have messed up one of my ...
user avatar
2 votes
1 answer
286 views

ZSH extends bash autocompletion

It's possible to make ZSH extends bash autocompletion? Bash can autocomplete almost every command in the system, and in ZSH i always need to enable a plugin for it. Here is an example (ignore the ...
user avatar
0 votes
1 answer
974 views

Customizing hostname in zsh prompt

I am using zsh with oh my zsh and I wanted to get a thing like this: How can I do it? I want a setting to put somewhere, so that whenever I restart my terminal and my system, it always displays the ...
user avatar

1
2 3 4 5