iterm

How to get Cmd-left/right working with iTerm2 and Vim (without requiring .vimrc changes)?

余生长醉 提交于 2019-11-28 18:53:26
I want to be able to use Option-left and Option-right to skip words (and Cmd-left/right to go to beginning and end of lines) within Vim as it does at my shell prompt. My Iterm2 preferences have mappings to do this (e.g. Option-left to Esc-H and a one for option-right to Esc-F to skip over words), and this works in the shell locally or when ssh'd to a remote server. When I use Vim locally or remotely, option-left works, but option-right does not. I suspect this is because Vim naturally listens for Esc-H , but not Esc-F . I am able to get around this by modifying .vimrc file to Esc-b to b and

iterm vim colorscheme not working

天大地大妈咪最大 提交于 2019-11-28 17:01:55
When I run vim from the command line in iTerm, syntax highlighting doesn't seem to work locally. In vim for example I have installed a nice colorscheme that works quite well in MacVim but it would be great if in iTerm it showed the same one. Any ideas how I can turn this on? This is the color scheme I'm trying to use http://www.vim.org/scripts/script.php?script_id=2340 That color scheme looks like it only supports 256-color terminals. If Vim thinks that your terminal only supports 8 colors, you won't see that specific color scheme. You can check this in Vim by: :echo &t_Co If that returns 8 ,

Incorrect colors with vim in iTerm2 using Solarized

只愿长相守 提交于 2019-11-28 15:03:40
I am having a strange issue with iTerm2, in terminal vim (non-gui) and the solarized color scheme. First, I have set iTerm2 to use the dark solarized colour scheme. I am also using solarized for vim. I have the following lines in my .vimrc set background=dark colorscheme solarized In the terminal the color scheme looks incorrect: For reference this is how it looks under MacVim (gui vim) What do I need to change in iTerm or my .vimrc to get the colors looking correctly in my console vim? Bill Turner A couple of things to check: In iTerm2, in Preferences -> Profiles -> Terminal, under "Terminal

How to export iTerm2 Profiles

断了今生、忘了曾经 提交于 2019-11-28 15:00:13
I needed to reformat my computer and now I'm having trouble copying the settings/profiles over. I copied the files in ~/Library/Application\ Support/iTerm/ I also copied ~/Library/Preferences/com.googlecode.iterm2.plist but it keeps giving me this error: Failed to load preferences from custom directory. Falling back to local copy. Missing or malformed file at "/ com.googlecode.iterm2.plist" I also tried saving the profile in a directory so I could send it but it doesn't work. Here's the location: iTerm ▶ General ▶ Preferences ▶ Save Settings To Folder and here's the output: Failed to copy

lose vim colorscheme in tmux mode

↘锁芯ラ 提交于 2019-11-28 14:55:55
I'm running iterm2 and when I'm in tmux mode the colorscheme I have set in vim does not show up. Only the color scheme I've set in iterm. If I run vim from shell the colorscheme appears correct - its only when I'm in tmux mode. I've tried setting :colorscheme molokai when in vim (see screenshot below) and it doesn't change - again, the default colorscheme for iterm2 remains. Am I missing some setting to iterm or tmux.conf? My dotfles are up on github here. I had the same problem. Only difference was I am using solarize rather then molokai . To fix the issue, I have set up an alias in ~/.bashrc

Homebrew fatal: needed a single revision (MacOs Sierra)

余生长醉 提交于 2019-11-27 20:52:56
问题 Not sure if this problem is related to upgrading to MacOs Sierra, but since that moment this error occurs when I run 'brew update' → brew update Checking out v1.0.0 in /usr/local/Homebrew/Library/Taps/caskroom/homebrew-cask... To checkout master in /usr/local/Homebrew/Library/Taps/caskroom/homebrew-cask run: 'cd /usr/local/Homebrew/Library/Taps/caskroom/homebrew-cask && git checkout master fatal: Cannot update paths and switch to branch 'v1.0.0' at the same time. Did you intend to checkout

How to export iTerm2 Profiles

生来就可爱ヽ(ⅴ<●) 提交于 2019-11-27 08:57:38
问题 I needed to reformat my computer and now I'm having trouble copying the settings/profiles over. I copied the files in ~/Library/Application\ Support/iTerm/ I also copied ~/Library/Preferences/com.googlecode.iterm2.plist but it keeps giving me this error: Failed to load preferences from custom directory. Falling back to local copy. Missing or malformed file at "/ com.googlecode.iterm2.plist" I also tried saving the profile in a directory so I could send it but it doesn't work. Here's the

iTerm 2: How to set keyboard shortcuts to jump to beginning/end of line?

空扰寡人 提交于 2019-11-27 05:43:05
I can see that Ctrl + left / right jumps to the beginning/end of line. How to change this to Cmd + left / right arrow ? In order to get Alt + left / right arrow working correctly for word jumping follow this article . Matthias Add in iTerm2 the following Profile Shortcut Keys FOR ACTION SEND ⌘← "SEND HEX CODE" 0x01 ⌘→ "SEND HEX CODE" 0x05 ⌥← "SEND ESC SEQ" b ⌥→ "SEND ESC SEQ" f Here is a visual for those who need it To jump between words and start/end of lines in iTerm2 follow these steps: iTerm2 -> Preferences ( ⌘ + , ) Open the “Keys” tab Add the following Global Shortcut Keys Move cursor

“M-” bindings in vim on iTerm2/Terminal don't work

你。 提交于 2019-11-27 02:38:56
问题 I noticed that iTerm2 offers the very convenient feature of using "Option key as +ESC" (or as meta, but apparently that's obsolete). I tried them both and the option key works as expected in Bash ( set -o emacs mode) and Emacs, but not in Vim. Thus, I can't make use of any "M-" bindings. What I've found is that: if I set option to "+ESC", vim just understands ESC+key, and has no idea I actually meant Meta-key. if I set option to "meta", keys modified with "option" behave just as without a

iTerm 2: How to set keyboard shortcuts to jump to beginning/end of line?

喜欢而已 提交于 2019-11-26 12:48:58
问题 I can see that Ctrl + left / right jumps to the beginning/end of line. How to change this to Cmd + left / right arrow ? In order to get Alt + left / right arrow working correctly for word jumping follow this article. 回答1: Add in iTerm2 the following Profile Shortcut Keys FOR ACTION SEND ⌘← "SEND HEX CODE" 0x01 ⌘→ "SEND HEX CODE" 0x05 ⌥← "SEND ESC SEQ" b ⌥→ "SEND ESC SEQ" f Here is a visual for those who need it 回答2: To jump between words and start/end of lines in iTerm2 follow these steps: