LoginSignup
24
18

More than 5 years have passed since last update.

tmux下でElectronがうまく動作しない

Last updated at Posted at 2015-09-23

問題

tmux環境で起動したElectronアプリでフォーム入力ができませんでした。
atom shell時代から知られているtmuxの仕様ないしバグのようで、フォーム入力できないだけでなく色々問題があるようです。
atom shell doesn't work in tmux

解決法

reattach-to-user-namespaceを入れると治ります。

以下、インストール・設定方法

  1. homebrewでreattach-to-user-namespaceをインストールします

    console
    $ brew install reattach-to-user-namespace
    
  2. .tmux.confに以下の設定を追加します

    ~/.tmux.conf
    set-option -g default-command "reattach-to-user-namespace -l zsh"
    

あとはtmuxを再起動すれば治るはずですが、摩訶不思議な動作に悩まされる可能性を残したくない人は、Electronの起動はtmux環境とは別に行った方が賢明かもしれません。

24
18
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
24
18