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

learn more… | top users | synonyms

2
votes
1answer
96 views

Using homebrew's OpenSSH on OS X with ZSH

I've installed the latest version of OpenSSH on OS X using homebrew. As per the instructions in the formula, I have edited the org.openbsd.ssh-agent.plist file to point to /usr/local/bin/ssh-agent, ...
1
vote
1answer
34 views

Hide all output from a background process

I have a bunch of commands in my zshrc which invoke another command in the background. The background command is an alias to a text-to-speech program (I use it to give me audio cues when processes ...
1
vote
1answer
40 views

ZSH Cull Old Aliases

When I call alias in a zsh shell, I get a list of aliases. Some of them are desired, some are not. I originally created a .alias file in my home directory, and added source $HOME/.alias to my .zshrc. ...
1
vote
1answer
39 views

Alternative to “fc -s” in zsh?

In bash, I had a handy alias: alias r="fc -s" Which just repeated last command. Same as !!. I am now used to it (muscle memory), but I can't seem to figure out how to recreate the alias. fc doesn't ...
2
votes
1answer
451 views

What is the difference between .zshrc and .zshrc-e

I've recently switched to using zsh instead of bash and I installed both zsh and oh-my-zsh. while messing with my configuration I noticed that there is a file named ".zshrc-e" in addition to the ...
1
vote
1answer
60 views

Adding file autocompletion in rake with zsh

I have oh-my-zsh installed with the rails plugin, when I use zsh completion with rake, it completes with the tasks list from rake -T. When I run a specific test, one of the parameters is the path to ...
0
votes
1answer
37 views

How to limit the number of lines for zsh 'cd -' completion?

Zsh's directory history is very useful. However, after wandering among many directories, it's annoying because too many lines are printed. How to limit the number of the lines to 10 or so, and print ...
1
vote
2answers
142 views

Terminal Command Colors [closed]

I like to have a really beatiful console style. I use zsh and I have changed my theme to "agnoster" See it under: oh-my-zsh My problem is that I do not have OS X and iTerm2 but I want to have these ...
0
votes
0answers
23 views

zsh hebrew alignment right to left

There is a way to configure zsh, to align right to left Hebrew file names? for example, if I use the command "ls" and there is Hebrew and English file names, the Hebrew file names will be displayed ...
0
votes
1answer
282 views

How to remove zsh alias?

I have an alias which is predefined by an oh-my-zsh plugin. -> % alias gcm gcm='git checkout master' I'd like to remove it, i.e. I'd like alias | pcregrep "\bgcm\b" return 1. I've tried with ...
0
votes
1answer
123 views

Tried Installing ZSH through cygwin and then trying to use zsh through Cmder

I tried to install Cygwin (64 bit version) on my computer, and it went through hunky-dory until at the very end, autorebase.bat failed with exit code 1. I read through the logs and they weren't too ...
1
vote
1answer
18 views

Where should I place environment-dependent configurations for zsh?

I have a repository on github that consists of most of my dot files, including files like .zshrc. When I need to move to a new development environment, I just need to pull my dot files from github ...
0
votes
0answers
78 views

Git add file path completion not working with zsh on OS X

When trying to tab complete files with git add <partial-path><tab> the completion hangs. I have to quit it with ctrl-c. This is also the case for git rm. All other zsh tab completion seems ...
0
votes
1answer
76 views

Input accents in iTerm with international keyboard

I have an international keyboard where accents are inserted doing ALT+` e ==> è ALT+e e ==> é In Terminal.app this works correctly, in iTerm2 it doesn't. I get a bell sound when I ...
0
votes
1answer
165 views

Do I have to manually update my PATH in Cygwin shells?

I use Cygwin on Windows 7. I'm not really a Windows user, so it's already a little inconvenient for me to have to have this extra layer in between my OS and Zsh, my shell of choice. Now, I frequently ...
0
votes
1answer
49 views

Switch from ZSH to default OS X

http://stackoverflow.com/questions/13476232/make-iterm2-launch-with-zsh I used chsh -s /bin/zsh as described above to set zsh as default. I'd like to switch back to default standard terminal that ...
2
votes
2answers
220 views

sed error when launching terminal on OS X

I get these error messages when launching bash or zsh in standard Terminal.app or iTerm2 sed: 1: "\#^system_type=# { s#^s ...": extra characters at the end of p command sed: 1: "\#^system_type=# { ...
1
vote
2answers
45 views

How to exclude a file from a command with ZSH?

Given this directory content : one.file two.file three.file in bash, when I enter rm *.file !(two) only one.file and three.file are deleted. How can I do this in ZSH?
2
votes
2answers
130 views

PATH set before /etc/zshenv

I am trying to find which file adds /opt/texbin folder to my PATH variable on Ubuntu. It is not present in my /etc/environment file. sudo grep -lr texbin . 2>/dev/null outputs nothing in the /etc ...
3
votes
2answers
93 views

How do I handle multiple quotes in an alias (for bash or zsh)

I am using zsh, and I am trying to use python as a simple calculator. I'm very familiar with python, but can't seem to get the alias (or function) to work properly. So far I've got: pycalc() { ...
1
vote
0answers
209 views

How do I get the aws cli completion to work with zsh on ubuntu?

I installed aws console cli following the instructions here: http://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-set-up.html#install-bundle-other-os I want to get completion working ...
0
votes
0answers
57 views

Redirect colored output to file

I want to store a colored terminal output to a file (maybe a .rtf or whatever). In OSX I am able to manually copy it and paste it in a .rft file using Textedit, however I wanted to store it ...
1
vote
0answers
74 views

Strange Unicode behavior in xterm

I recently switched my system from ISO-8859-15 to UTF-8 (I know I am a little late), works fine so far, I am just having a little issue with xterm and zsh. When entering German - Umlaute (ä,ö,ü) and ...
1
vote
1answer
44 views

Speeding up explorer.exe global shortcuts [duplicate]

I'm running Cygwin on windows with cmder as a terminal for zsh. The way I got it to be a bit similar to what my linux setup has is I placed a shotcut (.lnk) on my desktop with a keyboard shortcut ...
3
votes
1answer
229 views

Using sed with parallel gives empty output when redirecting to file

I'm using the zsh shell. I am trying to use sed to substitute some text in many files, using parallel to speed up the process. When I tested this on one file and let the command output go to stdout I ...
2
votes
1answer
43 views

How to bind Control+apostrophe via bindkey in zsh

There is way to bind Control+apostophe via bindkey? I have tried: bindkey "\C-'" bindkey "^'" bindkey "\C-\x27" and all of this is not working
1
vote
1answer
17 views

Odd issue with OR operator in zsh

I'm seeing an odd issue with CentOS 6.4, zsh 4.3.10 (x86_64-redhat-linux-gnu). This is running two regular expressions on the same string. Neither expression passes the if conditional, but when I OR ...
0
votes
0answers
57 views

Why is there a bash process running in my Terminal if I use Zsh?

When I run the "top" command on OSX Mavericks, a bash process appears even though I am using Zsh, why?
0
votes
1answer
559 views

Adding a jar file to CLASSPATH is still not executable

Perhaps I just don't understand how the whole CLASSPATH environment variable works when trying to find .jar files on your system. I thought if you specified it, you could launch .jar files with java ...
1
vote
1answer
33 views

How do I replace a specific argument of a previous command in zsh?

Let's say I have the following command: /long/path/to/bin -a foo -b 2 -c 3 -d 4 foo | gunzip -c | less And now I want to replace foo behind 4 with bar, so it becomes: /long/path/to/bin -a foo -b 2 ...
1
vote
3answers
63 views

How do I properly install and organize terminal software on OS X?

I've been learning vim and messing around with installing certain terminal extensions like zsh and tmux. So far I've been installing everything according to their online instructions, and this has ...
0
votes
0answers
190 views

When opening Terminal: “NO LOGINS: System going down at 01:10”

I'm trying to get a terminal open, and I get this message: NO LOGINS: System going down at 01:10 Login incorrect login: *myname* Login incorrect login: It doesn't prompt for my password. This ...
0
votes
0answers
19 views

zsh not finding new applications in PATH [duplicate]

In my path, I have rbenv shims followed by /usr/local/bin, then /usr/bin. Whenever I install a new version of ruby using rbenv, applications such as gem and bundle should automatically be find first ...
0
votes
1answer
158 views

bypass 'noglob' for 'which' in zsh?

I want to use the 'which' command to see which executable is actually being invoked, but the defensive 'noglob' aliases keep getting in the way. Is there a shortcut that I can use to find which ...
0
votes
1answer
454 views

OSX: Operation not permitted

on my mac os system (v. 10.9.3) I wanted to uninstall my zsh so first of all I executed the uninstall script in zsh. This failed so I wanted to delete the affected files by my own and am stuck here. ...
1
vote
0answers
103 views

Need to reset OS X terminal AFTER logging out of Ubuntu (ssh + zsh)

I have a problem I cannot understand, and cannot debug for the life of me. I run Mac OS X 10.9.2 (latest) and use Terminal.app and zsh as my shell. A server I work remotely on runs Ubuntu 13.04 and ...
1
vote
2answers
112 views

How do I unset (undo) unix set -C in zsh?

This works as expected $ echo "foo" > foo $ cat foo # foo $ echo "updated" > foo $ cat foo # updated From man set -C If set, bash does not overwrite an ...
2
votes
1answer
54 views

Dynamic directory hash

There's a nice method in zsh called hash -d with example usage: hash -d magic=/very/long/name/$USER/even/more Then I can cd ~magic/deeper. Is it possible to achieve the same result but so that ...
0
votes
1answer
42 views

Tmux printing ^P

My terminal has recently started printing control characters (e.g. ^P or ^N) when I press Ctrl+P (or other combinations). I'm not sure what caused the change. Here is my .tmux.conf file. Any ideas? ...
3
votes
3answers
532 views

How do you set alias sudo='nocorrect sudo ' correctly?

Until Recently I had alias sudo='sudo ' in my .zshrc file. Today I ran into this error on trying to do sudo mv: ➜ ~ sudo mv nginx.conf.orig nginx.conf.orig2 sudo: nocorrect: command not found Now ...
0
votes
1answer
47 views

zsh and Ruby print issue

Has anyone come across an issue where Ruby's print method leaves behind a % at the end of the line using zsh? I'm using oh-my-zsh (https://github.com/robbyrussell/oh-my-zsh) with iTerm2. Here is an ...
1
vote
2answers
688 views

mac os x byobu vertical split using iTerm, tmux, zsh

How to get vertical split on Mac OS X in byobu? Ctrl + F2 is not working. It open new window instead of spliting the current. In oposite spliting horizontaly with shift + F2 works ok.
1
vote
1answer
124 views

Zsh autocomplete function with sed

I'm struggling to write an ZSH autocomplete function. My goal is to autocomplete ta's and tk's first argument with the projects listed in tmux list-sessions and tmuxinator list. Here's what I have so ...
6
votes
2answers
1k views

zsh (z shell) numpad/numlock doesn't work

I just upgraded to zsh/oh-my-zsh. Almost immediately I notice on my machine that the 10-digit numpad is not working. It was working in bash and fish shell. Oddly, if I hold down the fn/function key ...
1
vote
1answer
65 views

What is the ZSH equivalent of 'expr'?

The expr utility evaluates an expression and writes the result on standard output. What is the canonical ZSH way to evaluate an expression, and print the result? Solution: I believe the answer is ...
0
votes
0answers
104 views

Using <ctrl+arrow> with zsh within (byobu-)tmux within gnome-terminal

I already added the following lines in my profile.tmux configuration file: TERM=xterm-256color set -g terminal-overrides "xterm*:kLFT5=\eOD:kRIT5=\eOC:kUP5=\eOA:kDN5=\eOB:smkx@:rmkx@" unbind C-Left ...
0
votes
2answers
211 views

Disallowing windows to rename themselves in tmux

I've installed tmux on an OS X system with zsh provided by oh-my-zsh. I usually use quite a number of tmux windows for a whole bunch of ssh sessions, and I like to keep these windows named after the ...
1
vote
0answers
332 views

How to restore my iterm2/zsh session after restart?

I use oh-my-zsh with iTerm2 on osx and I'd like them to retain the same tabs with the same directories and hopefully the same textual history after a restart. Currently after a restart iTerm reopens ...
3
votes
1answer
607 views

Iterating over keys (or k/v pairs) in zsh associative array?

In zsh, I want to iterate over an associative array. I need both keys and values. But when I iterate over the associative array normally (for x in $assoc_array), I get only values. All examples ...
2
votes
1answer
89 views

zsh tab completion to run scripts in current folder (.<TAB>scr<TAB>)->./script.sh

I have an issue with zsh (or oh-my-zsh): When I want to run a script in current directory, I do ./script.sh. In bash I could do .<TAB> and it would give me ./ where I could continue typing the ...