Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

<up> key for terminal history #5

Open
linqiaozhi opened this issue Jul 17, 2018 · 7 comments
Open

<up> key for terminal history #5

linqiaozhi opened this issue Jul 17, 2018 · 7 comments

Comments

@linqiaozhi
Copy link

Thank you for the excellent plugin.

However, when typing in the terminal, pressing the <up> arrow key does not let me see my last command. Instead, it says:

E21: Cannot make changes, 'modifiable' is off

When I disable this plugin, the <up> and <down> keys for scrolling through the history work as normal. Is there a workaround? Notably, the history command still works--so history is being collected, it seems the keymapping is just messed up somehow.

@gu-fan
Copy link
Owner

gu-fan commented Jul 18, 2018

my here works fine. (I'm using hkbb's <Fn>+hjkl + zsh

I haven't map any other keys with plugin (it's really simple you can check the plugin through

check your up mapping with :nmap <up> or terminal settings

@linqiaozhi
Copy link
Author

:nmap <up> gives 'No mapping found.'

I have the same issue on multiple terminals across OS X and Linux, all of which are using default settings. And it only happens when the plugin is enabled.

It's not only <up> but any of the arrow keys causes it to exist "insert mode" of the terminal, i.e. as if I hit <esc> or <ctrl>+W+N.

@gu-fan
Copy link
Owner

gu-fan commented Jul 21, 2018

so you met problems on OS X and Linux?
I'm using it in OS X.

You can try uncomment all the mapping / commands in the plugin and see if things are different.

https://github.com/gu-fan/simpleterm.vim/blob/master/plugin/simpleterm.vim#L367

@linqiaozhi
Copy link
Author

linqiaozhi commented Jul 23, 2018

I commented out the following line, and that fixed it.

" In terminal, use <ESC> to toggle terminal-mode
" then, use a or i to back to terminal-mode, like insert-mode
tnor <ESC> <C-\><C-n>

Not sure why--but that is definitely the problem.

Feel free to close, since you can't replicate it. I have a Macbook Pro running High Sierra.

@gu-fan
Copy link
Owner

gu-fan commented Jul 23, 2018

fine
leave it here if someone find it useful
I will remove that line later

@eugeneware
Copy link

Thanks. I had to disable this plugin too because arrow navigation was broken. I'm using OS X 10.14.3 with iTerm 3.2.7 and I'm having the issue as well.

Arrow keys get messed up. Pushing down arrow pulls me out of terminal insert mode into terminal normal mode.

linqiaozhi added a commit to linqiaozhi/simpleterm.vim that referenced this issue May 12, 2019
linqiaozhi added a commit to linqiaozhi/simpleterm.vim that referenced this issue May 12, 2019
@kennylouie
Copy link

^ Noticed same issue on OS X 10.14.4 using iTerm 3.2.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants