How to configure gedit as git core.editor?

后端 未结 2 1515
無奈伤痛
無奈伤痛 2020-12-28 16:10

I have gedit configured as git core.editor.

git config --global core.editor \"gedit\"

This works fine unless there is already a gedit windo

2条回答
  •  执笔经年
    2020-12-28 16:39

    The simplest way to solve this would be to upgrade gedit (which is at 3.8.3 with an Ubuntu 13.10)

    In 3.x, -s (standalone) and -w (wait) are available.
    That allows for (as commented by Fortisimo):

    git config --global core.editor "gedit -w -s" 
    

    As Gábor Lipták comments below, this works with gedit3, which is installed with:

    sudo apt-get install gedit-common/trusty 
    sudo apt-get install gedit/trusty
    

    (on Linux Mint)

提交回复
热议问题