创建pycharm.desktop
cd /usr/share/applications/
vi pycharm.desktop
内容如下:
#!/usr/bin/env xdg-open
[Desktop Entry]
Encoding=UTF-8
Name=Pycharm
Comment=pycharm-community-2019.2.3
Exec=sudo /usr/local/pycharm-community-2019.2.3/bin/pycharm.sh
Icon=/usr/local/pycharm-community-2019.2.3/bin/pycharm.png
Terminal=false
StartupNotify=true
Type=Application
Categories=Application;
复制到用户目录下
chmod 777 pycharm.desktop
cp pycharm.desktop /home/marvin/Desktop/
cd /home/marvin/Desktop
chmod 777 pycharm.desktop
chown marvin:marvin pycharm.desktop
运行
右键点击图标,然后open,再点击信任和运行。