fedora将pycharm图标添加到桌面

首先看一下官方给出的安装指南:

1. Unpack the PyCharm distribution archive that you downloaded to
     where you wish to install the program. We will refer to this destination
     location as your {installation home} below.

  2. Open a console and cd into "{installation home}/bin" and type:

       ./pycharm.sh

     to start the application. As a side effect, this will initialize various
     configuration files in the ~/.PyCharmCE2018.1 directory.

大概意思就是解压后直接运行.sh文件即可。桌面没有图标,每次打开都需要进入到安装包文件里,用终端输入命令打开,非常麻烦。

解决方法:

新建一个文件/usr/share/applications/Pycharm.desktop,文件内容为

[Desktop Entry]
Type=Application
Name=Pycharm
GenericName=Pycharm3
Comment=Pycharm3:The Python IDE
Exec=sh /usr/local/pycharm-community-2018.1.1/bin/pycharm.sh
Icon=/usr/local/pycharm-community-2018.1.1/bin/pycharm.png
Terminal=pycharm
Categories=Pycharm;

最后,在搜索中输入pycharm即可看到图标,双击打开即可。

到这里还没有结束,我们的目的是将图标放在桌面上,接下来的一步非常简单,到/usr/share/application/下右击对应的.desktop文件选择“copy to”--"desktop"。

你可能感兴趣的:(Linux)