Linux - recommended apps to open a file -


In Ubuntu Linux, assume I'll create a simple text file. When I right click on that file, there is an option to open with other apps it will show a list of recycled applications which can open a text file.

My question is how does the OS know which app can open that file?

Edit : What do app developers need to do to make this candidate? I also have to say that OS verifies it in any way (the developer has specified the app to open a specific file format); For example, a video gaming application might refer to opening a text file itself, but when the user tries to use it, there will be a problem.

Your app's .desktop file with your code in the other code Try to create in the dialog to open it. .desktop should look something like this

  [desktop entry] encoding = UTF-8 name = & lt; AppName & gt; Comment = Some details about the application Exec = & lt; AppName & gt; % U Terminal = true type = application icon = / usr / share / pixmaps / & lt; AppName & gt; .svg Categories = Applications; Utility; Reader editor; StartupNotify = True MimeType = Text / plain; NoDisplay = true  

to do this ~ / .local / share / applications / & lt; AppName & gt; Save as .desktop and open the application to be automatically selected as other application as the default application. There are many options for

.desktop files but it is important to know what they meant.

provides a very good guide and explanation for creating your .esctop files and all possible parameters that you can use on them so that you can enter special There is a doubt about creating .desktop file You can go to the site and see examples of there.

Note: - Not sure if OS is playing a video or not, if it does, then it will verify with MimeType and if The app has txt / plain and this one video player will fail, but then I'm not sure on this. / P>


Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -