Skip to main content

Questions tagged [zsh]

Zsh is a shell designed for interactive use, although it is also a powerful scripting language.

0 votes
1 answer
73 views

zsh on MacOS catalina 10.15.17

I'm having a little trouble putting this all together... I want to make a simple shell script to organize and sort around 60 GB worth of music and movie files that are spread out over 3 or for 4 ...
ZJS_Spctr555's user avatar
0 votes
0 answers
150 views

Configure zsh syntax highlighting for bash-my-aws

I have been using zsh syntax highlighter from this repo and it has been very great so far. Now, I discovered a repo called bash-my-aws which aliases my awscli commands to a more usable and compact ...
Rynn_'s user avatar
  • 1
1 vote
2 answers
632 views

How to change folder separator and ~ character in p10k command line

In powerlevel10k (zsh) the path to branch separator can be a triangle or semicircle (bottom in image); in powerline (top of image), the "triangles" can separate also folder/subfolder instead ...
Ferroao's user avatar
  • 190
1 vote
0 answers
281 views

Source multiple files in background/parallel (ZSH)

For various reasons I would like to be able to source a series of files in background and wait for them all to finish: source ./my_file_1.sh & source ./my_file_2.sh & ... # etc wait But, ...
Jack's user avatar
  • 111
0 votes
1 answer
362 views

gnome-terminal does not display UTF-8 characters correctly (zsh)

I installed zsh v5.8.1 on Ubuntu 22.04.3. And my gnome-terminal looks like so: the symboles do not seem to be right. Whats wrong?
milkpirate's user avatar
1 vote
1 answer
161 views

Correct way to end ssh tunnel

I frequently need to connect to a database instance on AWS, so I use an SSH tunnel. I can create one with the following command: ssh -N -L 12345:some-database.rds.amazonaws.com:5432 admin@bastion....
Mike Christensen's user avatar
1 vote
0 answers
208 views

How to `zcompile` global (system-wide) zsh scripts?

For my local dotfiles I have this snippet at the end of my .zshrc: for f in ~/.zshrc ~/.zshenv ; do [ "${f}"(:A) -ot "$f".zwc ] || zcompile "$f" done This ensures ...
Petr's user avatar
  • 3,173
1 vote
0 answers
96 views

Zsh zle function segfaults on `trap 'zle reset-prompt' EXIT`

I have the following function to select a tmux session with fzf: function tmx { [ -n "$ZLE_STATE" ] && trap 'zle reset-prompt' EXIT local tmux item tmux="$(which ...
Petr's user avatar
  • 3,173
1 vote
1 answer
211 views

iTerm 2 ZSH font all one color

Related to iTerm 2 ZSH colors/themes not showed correctly Machine: macOS Ventura 13.3 My iTerm2 wont use any other colors than all white (and all black in vim) for my fonts. Can anyone see what I'm ...
Jessica Sanford's user avatar
3 votes
1 answer
153 views

Bash read -e -i "Test" needs to be in Zsh

What is zsh equivalent for : read -e -i "This is pre written text " t get user into readline with a pre written text ready to edit an save to a variable ?
cantik memekmu's user avatar
0 votes
1 answer
1k views

How to get kube-ps1 working in the Warp terminal on MacOSX?

I'm trying to move from iterm2 to warp, but one thing that I can't get working, which is quite crucial for me, is the kube-ps1 project. What it does is to make the current Kubernetes context visible ...
Johan's user avatar
  • 103
2 votes
1 answer
2k views

zsh: stdout and stderr both to console AND log

I'm converting a script from bash to zsh and have been floundering for days with the output. I want the stdout and stderr to both go to both the console and a log file. I've tried everything I can ...
Jim Worrall's user avatar
0 votes
1 answer
161 views

How to properly set sudo crontab to backup files with superuser rights nightly?

I'm writing a script to backup some dirs such as /etc in a nightly backup. The script works if I run it manually and input a password, but fails to launch in crontab For testing purpose I've made a ...
hyperswiss's user avatar
0 votes
1 answer
165 views

Trigger a ZSH function when a command calls for sudo password

I quite often run into a situation where a long running system upgrade gets stuck on getting a sudo password, most often because the time for the last input has expired and I simply forgot about the ...
radrow's user avatar
  • 143
1 vote
1 answer
950 views

XDG Base Directory environment variables not respected by notionally compliant software

The goal I'm running Arch Linux. I want to store all config/data/cache/state files in subdirectories of ~/local, like so: ~ ├── downloads ├── documents └── local ├── data ├── state ├── ...
theo's user avatar
  • 336

15 30 50 per page