debian Create Shortcut

Some software start-up mode for the .sh file each time it starts to run commands in the terminal. Not very convenient, you can create a launcher learned to solve the problem by looking up data.
In linux, everything is a file. Starter is a suffix .desktop file.
I created intelliJ idea of starters, document reads as follows

[Desktop Entry]
Encoding=UTF-8
Name=IntelliJ IDEA
GenericName=IntelliJ IDEA
Comment=The Java IDE for Professional Developers by JetBrains
Exec=/opt/SoftWare/idea-IU-172.4343.14/bin/idea.sh %f
Icon=/opt/SoftWare/idea-IU-172.4343.14/bin/idea.png
Terminal=false
Type=Application
Categories=Application;Programme;


Grammar explanations:

Key words meaning

[Desktop Entry] Header
Encoding coding
Name Application Name
Application Name Name [xx] in different languages
GenericName 描述
Comment Comment
Exec command execution
Icon Icon Path
Terminal whether to use terminal
Type Starter type
Categories types of applications (content-related)

 


manual:

Create a file to .desktop suffix.
Writing content, modify permissions
double-click to start the program, adding confidence
to move to the / usr / share / applications / directory, so you can display in the upper left corner of the application

Description:
where the Exec commonly used parameters are:% f% F% u% U
% f: a single file name, even if you select multiple files. If the selected file is not in the local file system (for example in HTTP or FTP), this file will be copied to a temporary file as local,% f to point to the local temporary files;
% F.: List file. A program can open several local files at the same time. Each file in a divided manner is transmitted to the execution of the program segment.
% u: single URL. Local file passed as a URL or file path of the file.
% U: URL list. Each URL in the manner of segments to be passed to the program. Local file passed as a URL or file path of the file.

Guess you like

Origin www.cnblogs.com/Ai-Hen-Jiao-zhi/p/12121861.html