zsh is a shell designed for interactive use, although it is also a powerful scripting language. Many of the useful features of bash, ksh, and tcsh were incorporated into zsh; many original features were added.

learn more… | top users | synonyms

1
vote
2answers
21 views

Is it possible to specify a different zshrc file on login over ssh?

I spend all day ssh'ing into servers for work and the remote user is one that is shared by myself and several colleagues so I can't just blindly customise the shell as not everyone will want my tweaks ...
1
vote
2answers
49 views

In Bash or ZSH, is there an opposite to the `clear` command?

Typing clear into a shell creates a bunch of new lines until the output history above is all but hidden. Is there a command or method that does the opposite of clear? That essentially moves your ...
3
votes
1answer
25 views

Need help with variables like $current_dir, $user_host etc

I am pretty new to Linux so please bear with me here :) I want to customize my shell prompt (in zsh). Right now it looks like this (not written by me): PROMPT="${user_host} ${current_dir} ...
0
votes
1answer
37 views

Problem with adding path using zsh

I added a directory modifying ~/.profile and adding export PATH=$PATH:/home/...etc etc. But I realized that using zsh terminal I couldn't use the recently installed binary until I logged out from zsh. ...
1
vote
1answer
67 views

How to change the default shell used in Byobu without changing user shell?

I've been using set -g default-shell /usr/bin/zsh set -g default-command /usr/bin/zsh in my ~/.byobu/.tmux.config for several years to set the shell that Byobu uses without changing (chsh) my login ...
3
votes
4answers
9k views

When I use ZSH, how do I set PATH in /etc/profile.d?

I'm using zsh as my shell, and I'm trying to configure my environment. I usually define my $JAVA_HOME variable by creating a file: /etc/profile.d/java.sh with the following content export ...
26
votes
5answers
1k views

Why bash is the default shell in most OS?

Why is bash the default shell in most os ubuntu, fedora, mac ...etc and why is it that a lot of advanced users mostly use zsh and if it is that good why is it not the default? ps I use both I don't ...
2
votes
1answer
36 views

oh my zsh binaries

I am trying to set a few permanent aliases in my terminal export PATH=$PATH:/Applications/orca alias subl='/Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin/subl' alias chem='wine ...
0
votes
3answers
3k views

changing shell from zsh to bash

My web server was tampered by someone who was using zsh shell. I feel more comfortable using bash shell, as that's the defaults that come with Ubuntu and OS X (the two main operating systems I use). ...
1
vote
0answers
40 views

How do I get terminator to use syntax highlighting?

When sifting through large amounts of input and output in my terminal emulator (terminator in this case) it would come in handy if I had some syntax highlighting available to make things more ...
0
votes
1answer
25 views

Creating alias in zshrc from json file

Does anyone know how to create alias in zshrc by reading reading JSON file from local machine E.g.: my JSON file names is ip.json is as {"local":"127.0.0.1"} and want to create alias in zshrc as ...
1
vote
1answer
93 views

“chsh: invalid option — 'l'”

I have installed Zsh via running: sudo apt-get install zsh Using the following guide for installing Zsh provided by oh-my-zsh I attempted to set it as my default shell, namely I ran: chsh -s ...
0
votes
1answer
30 views

Not able to run commands over SSH

I recently changed my .zshrc to remap interrupt from ctrl-C to ctrl-J, and suddenly I'm not able to run any commands on machines that I SSH into. No matter what command I type, it simply ignores it ...
3
votes
1answer
3k views

Change the background color of command line in zsh when I change the prompt theme

I installed the zsh package. Also, I downloaded the oh-my-zsh framework to customize zsh. When I change theme name in .zshrc file to one of the themes given here, it changes the color/type of prompt ...
5
votes
2answers
3k views

How to run zsh and tmux with xterm-256color by default

I am using ubuntu gnome 14.04 and I want to have tmux and zsh opened when I start a new terminal. For now, in my preference of the terminal, I run tmux by default. In the ~/.tmux.conf file I have ...
2
votes
1answer
63 views

Getting gnome-terminal to run tmux on start

I am trying to figure out how to get my gnome-terminal to launch run "tmux -2" on starting. I have tried modifying the Exec lines in the gnome-terminal.desktop file to Exec=gnome-terminal -e -tmux -2 ...
4
votes
1answer
231 views

gnome-terminal can't set 256 color support correctly with or without tmux

I've been trying to set up 256 color support correctly for quite some time but it seems to never work for me so I'm not even remotely sure what I'm doing wrong. How it looks in the terminal vs gVIM: ...
0
votes
2answers
2k views

oh my zsh for the root and for all user

I have installed zsh and I am using oh my zsh plugins for easily Everything works fine, but when I become a root user, it changes to the normal bash and sh what should I do to make the oh my zsh ...
19
votes
2answers
7k views

How do you share history between terminals in zsh?

How can it be achieved so that every command that is entered, is visible in every open terminal's history? When having multiple terminals open, the history isn't shared, i.e. what you entered in one ...
3
votes
1answer
120 views

Silence GUI Program's Terminal Output

I am running a zsh function to open a .tex file in vim, while opening its related .pdf file in evince. I am currently using xdotool to open a new tab in the current gnome-terminal window, and then ...
1
vote
0answers
27 views

How does one get tab-completion in gsettings from zsh?

I notice that when using the bash shell (for example) the gsettings command has tab-completion; but when I use the Z shell (zsh) gsettings has no tab-completion. How can I enable it?
1
vote
1answer
77 views

Where can I find zsh man pages?

I installed the packages zsh and zsh-doc, but when I type man zsh, I get no manual entry for zsh. Where can I find zsh docs?
0
votes
1answer
54 views

how duplicate a oh-my-zsh terminal and retaining the path from previous terminal

In shell zsh command line/terminal when i duplicate the terminal using Ctrl+ Shift + T , it doesn't retain the path i was on my previous terminal. Also Ctrl+Shift+N opens a fresh terminal. Though ...
5
votes
4answers
3k views

How to fix strange backspace behaviour with urxvt + zsh?

I use urxvt in combination with zsh. However since my fresh install of ubuntu 10.04 I have the following problem. If I type backspace the cursor moves to the right (instead of deleting the characters ...
4
votes
3answers
1k views

Apt-get * wildcard with ZSH

ZSH: sudo apt-get remove --purge ubuntuone-* ERROR: zsh: no matches found: ubuntuone-* Works on Bash. What's the problem ? :-D
0
votes
0answers
17 views

How to make Tilda works with zsh? [duplicate]

I followed the steps listed here: http://whaaat.com/content/update-shell-zsh-osx-unix And if I hit ctrl + shift + T, zsh opens up, but if I start Tilda, it still uses bash. BUT, the tricky part: if ...
2
votes
3answers
1k views

Edit ZSH theme for virtualenv name

I use zsh theme intheloops. The theme looks like this when no virtual env. is active -- an empty line -- [sourabh@skynet] ~/Code/django_apps/cope (master) ⚡ ❯ and when an env. is active, (env ...
0
votes
1answer
54 views

Reset terminal after each command in ZSH

I am using Konsole + ZSH in KDE with several tabs open. In some tabs I run different programs -- Python scripts with ipdb and other. At some point I cannot enter new line anymore -- pressing Enter ...
0
votes
0answers
72 views

zsh suddenly lost the ability to search history with up/down arrow keys

I am using Trusty with zsh from official repos. The resource file is very simple with a loading of oh-my-zsh. Everything was smooth until a few days ago, using up or down arrow keys suddenly failed ...
15
votes
3answers
12k views

Can't make ZSH the default shell

I am trying to set ZSH as my default shell, however it keeps reverting back to bash. I have tried this code: sudo chsh -s $(which zsh) I've also tried: sudo chsh -s /bin/zsh Also tried these ...
1
vote
3answers
76 views

List hidden files but exclude directories.

Is there a way to list files, but not directories, prefixed with a . (hidden files)?
1
vote
1answer
35 views

The display previous/next command shortcuts doesn't work

I read in some article that Ctrl+P - to display previous command Ctrl+N - to display next command But in my terminal it doesn't work. What might be a problem here? I really would like to display ...
1
vote
1answer
83 views

Kubuntu 14.10, .zshenv is sourced twice

I have added some directories into $PATH variable in my ~/.zshenv conf file. After reboot I noticed that these paths are appeared twice. I tried to print call stacks and got the following: .zshenv ...
7
votes
1answer
5k views

Error Password: chsh: PAM: Authentication failure when try to install Oh my zsh

I try to install Oh my zsh. After install zsh (sudo apt-get update && sudo apt-get install -y zsh) Then I install sudo apt-get install -y curl then install git. the problems occurs ...
2
votes
2answers
2k views

Git Branch in ZSH Prompt?

When working on a git repository with multiple branches, how do I modify my zsh prompt to include my current active branch?
1
vote
0answers
103 views

Where do I find the zsh manual in Ubuntu versions later than 12.04?

At the moment I am learning zsh based on recommendations from friends and colleagues. To my surprise I was unable to find the man page for zsh and a man page named zshmisc which apparently was ...
1
vote
2answers
3k views

Rerun previous command under sudo

I want to be able to run a command, it fails cause it doesn't have proper permissions. Then I can write "please" to sudo the command I just ran. Here's what I want to do in the terminal: $ run ...
1
vote
1answer
1k views

Reset Zsh config?

Yesterday I installed Zsh, and tried to configure some things, but somehow everything is messed up. A lot of commands do not work, I've done PROMPT in ~/.zshrc but it does not work correctly either. ...
16
votes
5answers
1k views

zsh man page documentation missing in packages?

I have a newly installed xubuntu 13.10 x64. I decided to install zsh via synaptic and make it my default shell. The installed zsh's version is: zsh 5.0.2 (x86_64-pc-linux-gnu). The installed zsh ...
0
votes
0answers
45 views

Problems installing Betty in zsh

I tried to install Betty in zsh like that: cd ~ && git clone https://github.com/pickhardt/betty echo "alias betty=\"~/betty/main.rb\"" >> ~/.zshrc source ~/.zshrc I installed her in ...
1
vote
1answer
607 views

Changing the background of terminal in ZSH when connected to server

I use terminator as a terminal, zsh shell and oh my zsh, on both my laptop and my server, for what it's worth, I created an alias named vps to connect to my vps using ssh. Currently terminator ...
0
votes
1answer
36 views

Zsh typing problem

I just installed Zsh and wrote my own PROMPT thing so I have custom prompt. I also use emacs formatting in ~/.zshrc which says bindkey -e. Now when I open the shell, for some reason, it acts very ...
2
votes
1answer
99 views

Enable Zsh prompt username

So I just installed Zsh, and it shows for each command arrow and then ~. How do I enable my username@computername or something similar? I am reading https://wiki.archlinux.org/index.php/zsh but cannot ...
12
votes
2answers
3k views

Pressing enter produces ^M instead of a newline

For example, if I am tail -fing a file or reading user input, <Enter> will produce ^M in the terminal instead of ending the read or adding a newline to stdout. ^J works fine. I'm sshing into ...
0
votes
2answers
521 views

How to fix symbolic links after switching from Bash to ZSH

I had bash as my default shell even though I was only using zsh. I always started it myself by opening the terminal and typing zsh. Today I decided to use it as my default shell. So I found this ...
1
vote
1answer
119 views

Upstart sub-command tab completion with zsh

I've just recently switched to ZShell, and am loving it so far. One issue I'm having however is that my init.d or upstart scripts used to have tab completion for their subcommands, but now it doesn't. ...
12
votes
4answers
1k views

Configuring to detect if a command does not exist, suggest installation

Can the zsh shell be configured to show what bash shows when a command does not exist, similarly to this: kahless:~$ sysv-rc-conf The program 'sysv-rc-conf' is currently not installed. You can ...
0
votes
2answers
59 views

argument-aware alias command?

I want to create an alias for curl which automatically writes the file it curls into a file with the same name in the current directory. For example: % curl https://bootstrap.pypa.io/get-pip.py ...
2
votes
1answer
818 views

Can't set alias in zsh — command not found?

I'm trying to set alias conky-lua ="conky -c ./.conky/conkyrc &" so to start conky-lua. but when I source .zshrc it says command not found. A possible solution that I found on Stackoverflow is to ...
20
votes
3answers
29k views

Setting up aliases in zsh

I know that in bash you can set up aliases in a .bash_aliases file so that the command you type doesnt need to be a command stored in the binaries in the system. Is there any way I can get aliases ...