mimeapps 0.2.0
MIME Applications Associations specification implementation
To use this package, run the following command in your project's root directory:
Manual usage
Put the following dependency into your project's dependences section:
This package provides sub packages which can be used individually:
mimeapps:list - A minimal D application.
mimeapps:test - A minimal D application.
mimeapps:open - A minimal D application.
Mimeapps
D library for finding associations between MIME types and applications, e.g. for deciding which application should be used to open a file.
Specification: MIME Applications Associations
Note: detection of file MIME type is out of the scope of mimeapps. You may consider using this library for this purpose.
Features
Implemented
- Reading mimeapps.list and mimeinfo.cache files.
- Detecting default application for MIME type.
- Getting all associated applications for MIME type.
Missing
- Adding, removing association or setting default application for MIME type.
- Support for desktop-specific mimeapps.list files.
Missing
Generating documentation
Ddoc:
dub build --build=docs
Ddox:
dub build --build=ddox
Running tests
dub test
Examples
Mimeapps list
List default application and other associated applications for MIME type(s):
dub run :list -- text/plain image/png text/html
Also can be used for uri schemes:
dub run :list -- x-scheme-handler/http
Mimeapps test
Parse all mimeapps.list and mimeinfo.cache found on the system. Reports errors to stderr. Use this example to check if the mimeapps library can parse all related files on your system.
dub run :test
Mimeapps open
Detect MIME type of file and open it with default application for found type.
dub run :open -- LICENSE_1_0.txt
Add option --ask to list all associated applications before opening the file.
dub run :open -- --ask LICENSE_1_0.txt
Pass http url to open in web browser:
dub run :open -- --ask https://github.com/MyLittleRobo/mimeapps
- Registered by Roman Chistokhodov
- 0.2.0 released 8 years ago
- FreeSlave/mimeapps
- BSL-1.0
- Copyright © 2016, Roman Chistokhodov
- Authors:
- Sub packages:
- mimeapps:list, mimeapps:test, mimeapps:open
- Dependencies:
- desktopfile
- Versions:
-
0.4.0 2021-Mar-27 0.3.8 2020-Oct-02 0.3.7 2020-Jul-25 0.3.6 2018-May-04 0.3.5 2017-Oct-23 - Download Stats:
-
-
0 downloads today
-
0 downloads this week
-
0 downloads this month
-
142 downloads total
-
- Score:
- 0.6
- Short URL:
- mimeapps.dub.pm