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

<prefix> e (edit configuration) does not work #416

Closed
cheunjm opened this issue Oct 5, 2020 · 6 comments
Closed

<prefix> e (edit configuration) does not work #416

cheunjm opened this issue Oct 5, 2020 · 6 comments

Comments

@cheunjm
Copy link

cheunjm commented Oct 5, 2020

Cloned fresh repo, didn't change .tmux.conf nor .tmux.conf.local

Everything works fine, except when I try to edit .tmux.conf.local config by using e, the terminal blinks for a second with a new tab /Users/.../.tmux.conf.local and goes away.

This is what I have from .tmux.conf:

bind e new-window -n "~/.tmux.conf.local" "sh -c '\${EDITOR:-vim} ~/.tmux.conf.local && tmux source ~/.tmux.conf && tmux display \"~/.tmux.conf sourced\"'"

I have oh-my-zsh set up, and $EDITOR is set as mvim.

@gpakosz
Copy link
Owner

gpakosz commented Oct 6, 2020

Hello @cheunjm 👋

From your description, I understand that the ~/.tmux.conf.local file doesn't exist?

@cheunjm
Copy link
Author

cheunjm commented Oct 6, 2020

Hi @gpakosz , thanks for the amazing work!

Sorry if I wasn't clear, both ~/.tmux.conf and ~/.tmux.conf.local exists, but e is not working

@gpakosz
Copy link
Owner

gpakosz commented Oct 6, 2020

Ok I installed MacVim to reproduce your problem.

It's because mvim forks and opens the GUI

@cheunjm
Copy link
Author

cheunjm commented Oct 6, 2020

@gpakosz Thanks for testing it out for me. I'll try to swap mvim with vi and let you know if it helps

@gpakosz
Copy link
Owner

gpakosz commented Oct 6, 2020

Can you please try the gh-416 branch while keeping EDITOR set to mvim?

@cheunjm
Copy link
Author

cheunjm commented Oct 6, 2020

I can confirm that it now works on gh-416 while keeping the EDITOR set to mvim.

Thanks a lot!

@cheunjm cheunjm closed this as completed Oct 6, 2020
@gpakosz gpakosz reopened this Oct 6, 2020
@gpakosz gpakosz closed this as completed in 8ffeb1d Oct 6, 2020
tunght13488 added a commit to tunght13488/.tmux that referenced this issue Oct 27, 2020
* upstream/master: (60 commits)
  fixed status line that doesn't work with tmux 2.3, fixes gpakosz#418
  added 'tmux_conf_theme_colour_XX' variables to ease theming
  added support for custom variables defined in ~/.tmux.conf.local (2), fixes gpakosz#417
  fixed '<prefix> + e' binding when EDITOR is set to 'gvim' or 'mvim', fixes gpakosz#416
  updated _maximize_pane() that stopped working with tmux 3.2 (2), fixes gpakosz#415
  added support for custom variables defined in ~/.tmux.conf.local
  updated _maximize_pane() that stopped working with tmux 3.2, fixes gpakosz#381
  worked around tmux not killing jobs launched with run-shell -b, fixes gpakosz#407
  updated installation instructions, closes gpakosz#348 (2)
  fixed window-status-current-format, fixes gpakosz#390, closes gpakosz#333
  replaced awk by perl in _ssh_or_mosh_args() to benefit from word boundary anchors, closes gpakosz#363
  added support for explicit 'split-window' with ssh reconnect, closes gpakosz#164
  enabled GitHub sponsors, closes gpakosz#339
  made #{uptime_xxx} work under FreeBSD
  made #{loadavg} work under FreeBSD
  fixed status-left and status-right theming, fixes gpakosz#397
  updated README.md to mention strftime(3) peculiarities, closes gpakosz#309
  added a sleep call to the wttr.in example to throttle network requests, closes gpakosz#297
  updated installation instructions, closes gpakosz#348
  fixed _battery_info() not accommodating for empty lines, fixes gpakosz#377
  ...
gpakosz pushed a commit that referenced this issue Aug 20, 2022
…nd the default shell is zsh (2), #fixes 593

${EDITOR//gvim/vim} and ${EDITOR//mvim/vim} have been introduced to fix #416,
however the replace all substitution is not POSIX and is not supported by termux
or dash

the proper fix for #416 is to set EDITOR to 'gvim -f' or 'mvim -f'
gpakosz pushed a commit that referenced this issue Aug 20, 2022
…nd the default shell is zsh (2), fixes #593

${EDITOR//gvim/vim} and ${EDITOR//mvim/vim} have been introduced to fix #416,
however the replace all substitution is not POSIX and is not supported by termux
or dash

the proper fix for #416 is to set EDITOR to 'gvim -f' or 'mvim -f'
thisisrandy pushed a commit to thisisrandy/.tmux that referenced this issue Sep 8, 2022
…nd the default shell is zsh (2), fixes gpakosz#593

${EDITOR//gvim/vim} and ${EDITOR//mvim/vim} have been introduced to fix gpakosz#416,
however the replace all substitution is not POSIX and is not supported by termux
or dash

the proper fix for gpakosz#416 is to set EDITOR to 'gvim -f' or 'mvim -f'
ooosssososos pushed a commit to ooosssososos/.tmux that referenced this issue Mar 1, 2023
…nd the default shell is zsh (2), fixes gpakosz#593

${EDITOR//gvim/vim} and ${EDITOR//mvim/vim} have been introduced to fix gpakosz#416,
however the replace all substitution is not POSIX and is not supported by termux
or dash

the proper fix for gpakosz#416 is to set EDITOR to 'gvim -f' or 'mvim -f'
farhadkarimi pushed a commit to farhadkarimi/.tmux that referenced this issue Aug 18, 2023
farhadkarimi pushed a commit to farhadkarimi/.tmux that referenced this issue Aug 18, 2023
…nd the default shell is zsh (2), fixes gpakosz#593

${EDITOR//gvim/vim} and ${EDITOR//mvim/vim} have been introduced to fix gpakosz#416,
however the replace all substitution is not POSIX and is not supported by termux
or dash

the proper fix for gpakosz#416 is to set EDITOR to 'gvim -f' or 'mvim -f'
Rafiot pushed a commit to Rafiot/.tmux that referenced this issue Jan 24, 2024
…nd the default shell is zsh (2), fixes gpakosz#593

${EDITOR//gvim/vim} and ${EDITOR//mvim/vim} have been introduced to fix gpakosz#416,
however the replace all substitution is not POSIX and is not supported by termux
or dash

the proper fix for gpakosz#416 is to set EDITOR to 'gvim -f' or 'mvim -f'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants