Recreating PyCharm launcher in Ubuntu

后端 未结 17 1050
一向
一向 2021-01-30 06:16

I installed pycharm normally via bin/pycharm.sh, but the mistake I made was doing bash pycharm.sh while the pycharm directory has inside the D

17条回答
  •  鱼传尺愫
    2021-01-30 06:54

    I managed to solve it. The thing is, Pycharm already installs a launcher inside .local/share/applications. Thus, you need to get rid of it before proceeding to create your own. After that, all you have to do is add your own *.desktop file to the applications directory inside usr/share/applications/.

    You need to create your .desktop file using sudo and inside the desktop file:

    [Desktop Entry]
    Encoding=UTF-8
    Name=PyCharm
    Exec=/opt/pycharm-3.0.1/bin/pycharm.sh
    Icon=/opt/pycharm-3.0.1/bin/pyCharm.png  # Changed from pycharm_32.png
    Type=Application
    Categories=Development;
    StartupWMClass=PyCharm
    

    After that is done, you can launch your app properly. Please note that pycharm.sh must also have execution rights.

提交回复
热议问题