Questions tagged [iterm]

iTerm is a third party replacement for the built-in Terminal application.

Filter by
Sorted by
Tagged with
215
votes
7answers
59k views

Using Alt/Cmd + Right/Left Arrow in iTerm

Is it possible to move between words in iTerm using Alt + Right/Left Arrows ? Now if I press Alt+Left I will get '[D' and '[C' if I press Alt+Right.
157
votes
8answers
69k views

iTerm - going one word backwards and forwards

Would it be possible to configure iTerm 2 to go backwards and forwards one word through the curent text in the command line using a keyboard shortcut?
148
votes
10answers
133k views

What is the difference between iTerm2 and Terminal?

I keep hearing that iTerm2 is much better than Terminal. However, when I downloaded iTerm2, I didn't see what made it preferable over Terminal. What are the differences between these two apps?
147
votes
6answers
105k views

iTerm as a slide-out terminal from the top of the screen

I have installed iTerm2 and was hoping I'd have something like guake (Yes I just switched from Ubuntu). I mapped the hotkey to a button of my choice and it works fine, but I miss the slide-down-from-...
138
votes
12answers
78k views

How can I save tabs in iTerm 2 so they restore the next time the app is run?

Can I save tabs on exit in my iTerm 2, so I don't have to open same directories again after restart? Like Chrome does, for example. I couldn't find such option in settings. Maybe "Arrangements" is ...
48
votes
2answers
19k views

How to open a new tab in iTerm in the same folder as the one that is open?

I'm using iTerm for my command line needs, and when I open a tab using ⌘T I want it to open the tab cd'ed to the same location as the tab that was open when I hit ⌘T (instead of opening in my /Users/...
44
votes
2answers
19k views

Set iTerm2 as the ssh:// URL handler

Currently, Terminal is set to handle SSH urls. For example, if I do: $ open ssh://machine.example.com Then it will spawn a new SSH session in terminal. I'd like these to be opened in iTerm2 instead. ...
42
votes
5answers
22k views

How to jump to a location using mouse on iTerm/terminal?

I work on a terminal most of the time. Is there an application / plugin over iTerm or any other terminal like application using which I can control the cursor location of my terminal using a mouse ?
41
votes
2answers
23k views

Changing the default size of iTerm2 when it opens

I feel like this is a pretty stupid question but I Googled it and played around with it and still didn't figure it out so here we go: When I open iTerm2, it opens in a default size. How can I set it ...
29
votes
2answers
15k views

unknown option: mode-mouse with iterm, tmux

I've reset my computer and now tmux is complaining about my .tmux.conf having these directives: setw -g mode-mouse on set -g mouse-select-pane on set -g mouse-resize-pane on set -g mouse-select-...
28
votes
1answer
10k views

The history is shared between my iTerm2 terminal tabs: how can I switch that off?

I am using iTerm2 (with zsh), and for some reason the history is shared between the different tabs and windows that are open. In most of the cases for me, this is annoying, since I have tabs per ...
25
votes
1answer
5k views

Using tmux and pbpaste, pbcopy, and launchctl

I have discovered that tmux breaks pbpaste, pbcopy and launchctl. Is there a good way to make it play nice with these tools?
23
votes
3answers
32k views

How do I get different colors for directories, etc. in iTerm2?

I have a new MacBookPro, and I installed the latest release of iTerm2. Even after I imported various color schemes, I notice that they just change the color of the text and background only. What I ...
21
votes
2answers
21k views

For iTerm2, how do I make the working directory appear in the window title?

I recently switched to iTerm2 from the default Terminal app and have a usability issue. On Terminal, the working directory you are in shows up on the title bar along with the process and pixel size....
21
votes
3answers
11k views

Is it possible to have bash escape spaces in pwd?

I'd like to copy the current directory to the clipboard, something like: pwd | pbcopy. However, pwd does not escape the space, so something in "Application Support", for example, doesn't copy ...
20
votes
2answers
22k views

iTerm2 doesn't read com.googlecode.iterm2.plist

I am iTerm2 (1.0.0) user. I know how to create profiles, by using iTerm settings or modifying com.googlecode.iterm2.plist file. For convenience, I will use .plist to indicate com.googlecode.iterm2....
20
votes
4answers
40k views

iTerm colors for Prompt, Command, and Output

Right now my iTerm2 looks like this... Everything is the same color and is hard to read. Can I make any of the Prompt, Command, and Output different colors like this?
20
votes
1answer
3k views

Selecting text while jumping with cursor in iTerm2

I would like to know if it is possible to get text-editor-like functionality for selecting text in iTerm2. For example, in Sublime Text 3, I can do the following: ⇧ ⌥ → = Select ...
17
votes
6answers
2k views

How to find all the available tools in mac terminal?

I am trying to setup a bunch of development projects in my Mac. I have to run various tools like python, ruby, scala, groovy etc. To see if a tool is available I use options like ruby --version. ...
17
votes
4answers
20k views

open new tab in iTerm and execute command there

I have found way to open new tab in iTerm: newtabi() { osascript -e 'tell application "iTerm" to activate' -e 'tell application "System Events" to tell process "iTerm" to keystroke "t" using ...
17
votes
1answer
21k views

iterm - what's the key-combo to switch panes?

I've learned how to split my terminal windows with apple-d and apple-shift-d. Its very useful. How do I then switch between the two panes (see below) using the keyboard? I know I can use the mouse ...
17
votes
3answers
10k views

In iTerm2 Command Click on URLS does not work when inside a tmux session

When not inside a tmux session, Command-Click on URLs works flawlessly. How can I make links clickable in iTerm2 when inside a tmux session? When hitting Command the mouse pointer changes to the ...
16
votes
6answers
16k views

Completion for git commands

I recently switched from using an Ubuntu box for the last 7 years to a Mac. I have read other posts like Switching from Ubuntu to OS X and I'm lost and What is the difference between iTerm2 and ...
16
votes
6answers
11k views

iTerm2/Terminal full screen

Why is it not possible to have iTerm2 or Terminal app take up the full available space on the screen. Let me show an example: It's hard to see but if you look on the right and bottom edge, there is ...
16
votes
1answer
13k views

Where does iTerm store user preferences?

Where exactly is iTerm's user preferences file located? What I want is to sync this file over Github between several machines.
16
votes
6answers
6k views

Option + click in iTerm

In Terminal, Option + click allows me to place my cursor at any point on the current line-- great for editing really long commands. How can I do this in iTerm2? Update: According to this page, the ...
15
votes
3answers
7k views

Iterm2 disable Command shortcuts

I use Iterm2 on the Mac. Many times, I accidentally press Command+some key, so I'm wondering, is it possible to disable the Command shortcuts? Like Command+D for example, as I use tmux for split panes....
14
votes
3answers
23k views

Why does iterm2 close new sessions immediately?

I've made some changes to my .bashrc file in my new MacBook, mainly aliases for common commands. Shortly after, iterm2 immediately closes every new session or tab with the following cryptic message: ...
14
votes
2answers
2k views

Is anyone else having problems with using htop on High Sierra?

Since the upgrade to High Sierra my MacBook is crashing regularly in a catastrophic way that forces me to trigger a hard reset every time. I suspect htop being the culprit, but I can't tell for sure. ...
13
votes
1answer
12k views

How to highlight errors and warnings on iTerm terminal output?

I am looking for a solution that would allow me to use color highlighting to a set of important output messages inside iTerm terminal application. Things to highlight: application logs file warnings,...
13
votes
1answer
42k views

How do I configure my Terminal app with bash and iTerm2 with zshell and oh my zsh?

The Terminal app uses bash by default. And I don't want to change it. However I want to configure iTerm2 with zshell and oh my zsh. and I don't want bash on it. The instructions I checked online, make ...
13
votes
4answers
15k views

Remapping keys in iterm2

I'm trying to remap some of the default key combinations in iTerm2, and would like to understand what is going on when I bind keys to "Send Hex Codes". A previous post helped me get started with ...
13
votes
6answers
5k views

Are there any global key combinations suitable or specifically reserved on OS X for user assignment?

I'm trying to identify an appropriate global hotkey to set in iTerm2's preferences for showing/hiding it: I'd like to avoid any conflicts with other applications' hotkeys or other future use. Are ...
13
votes
3answers
27k views

How to set an iTerm2 startup command

How do I set a command on a profile so that when I start a new terminal window, it fires off that command. Specifically, I'd like to be able to set my virtualenv with: workon ENV So that it starts ...
12
votes
2answers
5k views

Delete key doesn't work in vim on iTerm2

Firstly, I typed some thing on insert mode, like Hello At this stage, if I didn't exit from insert mode, delete works and can delete the whole word if I want. If I quit insert mode, and open insert ...
12
votes
1answer
2k views

Mailto links on websites open iTerm instead of Mail

In both Chrome and Safari mailto: links open up iTerm instead of Mail. This seemed to have started happening right around the same time I added a shortcut through Settings > Keyboard > Shortcuts > ...
12
votes
1answer
3k views

How do I view inline images in w3m?

I am using a Mac (El Capitan), and trying to use w3m. But I don't see images when browsing pages. My question is: I want to view inline images in w3m, but don't find a way to do so. I have been ...
11
votes
1answer
3k views

How to find out which terminal app (iTerm or Terminal) is running from within bash

I need to have different color schemes for each of the two terminal types I use. I can set it in the .bash_profile as mentioned here. But how can I tell it to differ depending whether its a iTerm2 or ...
11
votes
2answers
7k views

iTerm2: How to change the color used to highlight search results?

It seems that iTerm2 is hardcoded to highlight search results using a yellow background color. I tried both the latest release and the nightlies but could not find a way to change that color. Did I ...
11
votes
2answers
12k views

Can I copy the entire scrollback buffer from iTerm2 to the clipboard?

I've just run some commands and have several pages of output in iTerm2. Now I'd like to save it somewhere. (I could have piped it to a file, but I didn't think of that.) Is there an easier way to ...
10
votes
1answer
17k views

Restoring iTerm2 to default values

I installed iTerm2, played a bit with the preferences. Now I would go back to the initial configuration, but removing the app and finding and removing any file on the disk apparently related to the ...
10
votes
1answer
2k views

How to find out why iTerm2 suddenly wants to access my Calendar?

Out of the blue I am prompted for this permission grant: How can I find out what is triggering this request and why? The last command I ran was du -h -d 1 in /
10
votes
1answer
4k views

How to drag window from anywhere on the window without using the title bar?

I have made iTerm borderless, like this: So, how can I move the window from anywhere inside the window and not just the title bar?
10
votes
4answers
10k views

Why don't my arrow keys work in vim under iTerm?

They work just fine if I use Terminal and start a vim session, but under iTerm I have to resort to using H-J-K-L to do left-up-down-right movement. In both Terminal and iTerm TERM=xterm-color. My ....
10
votes
3answers
4k views

When Terminal forks process, current app loses focus

While I'm running some program in Terminal (or iTerm2), when the program forks the process, the OS X desktop switches focus from the current application to the forked process. When this happens, the ...
10
votes
2answers
5k views

How to prevent iTerm2 from creating overlaps and broken lines after pasting multiline chunks of text?

If I paste multiline chunks of text into iTerm2, I always a get mess of output. It seems limited to only some programs running interactively (such as Bash, IRB - Python / VIM work flawlessly). Using ...
9
votes
4answers
5k views

How can I move through words when typing a command in iTerm2?

I'm in Lion with iTerm2, Zsh and Oh-My-Zsh but I cannot move through words when pressing: ALT+left arrow or CMD+left arrow or something instead, when I press "ALT+right arrow" it prints [C and when ...
9
votes
5answers
3k views

Remove iterm from cmd+tab apps

I was using TotalTerminal to get visor like terminal on a shortcut. But TotalTerminal is abandoned so I have switched to the iTerm2. My problem is that when I use a shortcut to trigger iTerms visor ...
9
votes
1answer
5k views

Changing the default keyboard shortcuts in iTerm2

In iTerm2, ⌘W will close the current shell. In Vim, Ctrl W, by default, sets you up for a window command (e.g., Ctrl Wh moves to the window on the left, etc.) I am new to using a Mac and haven't got ...
9
votes
2answers
8k views

Terminal not displaying colors for directory listings

I don't know why my bash session doesn't show colors. I have tried Terminal as well as iTerm. I have tried: ls -G Setting export CLICOLOR=1 and export LSCOLORS=GxFxCxDxBxegedabagaced Using different ...