1. Open the terminal and enter the command sudo gedit ~/desktop/pycharm.desktop
2. Enter the following content in the blank file
[Desktop Entry]
Name = Pycharm
Type = Application
Exec = /home/lzm2306/下载/pycharm-community-2022.1.3/bin/pycharm.sh
Icon = /home/lzm2306/下载/pycharm-community-2022.1.3/bin/pycharm.png
Terminal = False
(lzm2306)是用户名
Press save to exit, then the desktop will appear pycharm.desktop file
3. Enter the root user and enter the command chmod -R 777 '/home/lzm2306/desktop/pycharm.desktop'
4. The pycharm.desktop file becomes the application shortcut of the pycharm icon, you can click the icon to open pycharm directly