xdg: add mimetypes
Signed-off-by: Myned <dev@bjork.tech>
This commit is contained in:
parent
516191efba
commit
ed53cd1afa
1 changed files with 91 additions and 8 deletions
|
@ -4,12 +4,17 @@
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
with lib; let
|
with lib; let
|
||||||
evince = "org.gnome.Evince.desktop";
|
apostrophe = "org.gnome.gitlab.somas.Apostrophe.desktop";
|
||||||
firefox-esr =
|
clapper = "com.github.rafostar.Clapper.desktop";
|
||||||
config.home-manager.users.${config.custom.username}.programs.firefox.package.desktopItem.name;
|
decibels = "org.gnome.Decibels.desktop";
|
||||||
|
file-roller = "org.gnome.File Roller.desktop";
|
||||||
|
firefox-esr = "firefox-esr.desktop";
|
||||||
|
font-viewer = "org.gnome.font-viewer.desktop";
|
||||||
gnome-text-editor = "org.gnome.TextEditor.desktop";
|
gnome-text-editor = "org.gnome.TextEditor.desktop";
|
||||||
loupe = "org.gnome.Loupe.desktop";
|
loupe = "org.gnome.Loupe.desktop";
|
||||||
nautilus = "org.gnome.Nautilus.desktop";
|
nautilus = "org.gnome.Nautilus.desktop";
|
||||||
|
onlyoffice = "onlyoffice-desktopeditors.desktop";
|
||||||
|
papers = "org.gnome.Papers.desktop";
|
||||||
|
|
||||||
cfg = config.custom.settings.xdg;
|
cfg = config.custom.settings.xdg;
|
||||||
in {
|
in {
|
||||||
|
@ -34,16 +39,96 @@ in {
|
||||||
# https://www.iana.org/assignments/media-types/media-types.xhtml
|
# https://www.iana.org/assignments/media-types/media-types.xhtml
|
||||||
#?? xdg-mime query <default|filetype>
|
#?? xdg-mime query <default|filetype>
|
||||||
defaultApplications = {
|
defaultApplications = {
|
||||||
|
"application/epub+zip" = papers;
|
||||||
|
"application/gzip" = file-roller;
|
||||||
|
"application/java-archive" = gnome-text-editor;
|
||||||
"application/json" = gnome-text-editor;
|
"application/json" = gnome-text-editor;
|
||||||
"application/pdf" = evince;
|
"application/octet-stream" = "";
|
||||||
"application/xhtml+xml" = gnome-text-editor;
|
"application/pdf" = papers;
|
||||||
|
"application/rtf" = onlyoffice;
|
||||||
|
"application/schema+json" = gnome-text-editor;
|
||||||
|
"application/sql" = gnome-text-editor;
|
||||||
|
"application/toml" = gnome-text-editor;
|
||||||
|
"application/vnd.adobe.flash.movie" = clapper;
|
||||||
|
"application/vnd.ms-excel.sheet.macroEnabled.12" = onlyoffice;
|
||||||
|
"application/vnd.ms-excel" = onlyoffice;
|
||||||
|
"application/vnd.ms-powerpoint" = onlyoffice;
|
||||||
|
"application/vnd.ms-visio.drawing.main+xml" = gnome-text-editor;
|
||||||
|
"application/vnd.oasis.opendocument.formula-template" = onlyoffice;
|
||||||
|
"application/vnd.oasis.opendocument.graphics" = onlyoffice;
|
||||||
|
"application/vnd.oasis.opendocument.spreadsheet" = onlyoffice;
|
||||||
|
"application/vnd.oasis.opendocument.text" = onlyoffice;
|
||||||
|
"application/vnd.openxmlformats-officedocument.presentationml.presentation" = onlyoffice;
|
||||||
|
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" = onlyoffice;
|
||||||
|
"application/vnd.openxmlformats-officedocument.wordprocessingml.document" = onlyoffice;
|
||||||
|
"application/vnd.sqlite3" = gnome-text-editor;
|
||||||
|
"application/vnd.visio" = gnome-text-editor;
|
||||||
|
"application/x-asar" = gnome-text-editor;
|
||||||
|
"application/x-bat" = gnome-text-editor;
|
||||||
|
"application/x-compressed-tar" = file-roller;
|
||||||
|
"application/x-designer" = gnome-text-editor;
|
||||||
|
"application/x-desktop" = gnome-text-editor;
|
||||||
|
"application/x-etherpeek" = gnome-text-editor;
|
||||||
|
"application/x-font-bdf" = font-viewer;
|
||||||
|
"application/x-font-pcf" = font-viewer;
|
||||||
|
"application/x-gz-font-linux-psf" = font-viewer;
|
||||||
|
"application/x-mobipocket-ebook" = papers;
|
||||||
|
"application/x-mozilla-bookmarks" = gnome-text-editor;
|
||||||
|
"application/x-php" = gnome-text-editor;
|
||||||
|
"application/x-powershell" = gnome-text-editor;
|
||||||
|
"application/x-shellscript" = gnome-text-editor;
|
||||||
|
"application/x-trash" = gnome-text-editor;
|
||||||
|
"application/x-xpinstall" = gnome-text-editor;
|
||||||
"application/xhtml_xml" = gnome-text-editor;
|
"application/xhtml_xml" = gnome-text-editor;
|
||||||
|
"application/xhtml+xml" = gnome-text-editor;
|
||||||
"application/xml" = gnome-text-editor;
|
"application/xml" = gnome-text-editor;
|
||||||
|
"application/yaml" = gnome-text-editor;
|
||||||
|
"application/zip" = file-roller;
|
||||||
|
"audio/midi" = decibels;
|
||||||
|
"audio/mpeg" = decibels;
|
||||||
|
"audio/vnd.wave" = decibels;
|
||||||
|
"audio/x-mod" = gnome-text-editor;
|
||||||
|
"font/ttf" = font-viewer;
|
||||||
|
"font/woff2" = font-viewer;
|
||||||
|
"image/bmp" = loupe;
|
||||||
|
"image/gif" = loupe;
|
||||||
|
"image/heif" = loupe;
|
||||||
"image/jpeg" = loupe;
|
"image/jpeg" = loupe;
|
||||||
"image/png" = loupe;
|
"image/png" = loupe;
|
||||||
|
"image/svg+xml" = loupe;
|
||||||
|
"image/tiff" = loupe;
|
||||||
|
"image/vnd.microsoft.icon" = loupe;
|
||||||
|
"image/vnd.zbrush.pcx" = loupe;
|
||||||
|
"image/webp" = loupe;
|
||||||
|
"image/x-tga" = loupe;
|
||||||
|
"image/x-xcf" = loupe;
|
||||||
"inode/directory" = nautilus;
|
"inode/directory" = nautilus;
|
||||||
|
"text/css" = gnome-text-editor;
|
||||||
|
"text/csv" = gnome-text-editor;
|
||||||
"text/html" = gnome-text-editor;
|
"text/html" = gnome-text-editor;
|
||||||
|
"text/javascript" = gnome-text-editor;
|
||||||
|
"text/markdown" = apostrophe;
|
||||||
"text/plain" = gnome-text-editor;
|
"text/plain" = gnome-text-editor;
|
||||||
|
"text/tab-separated-values" = gnome-text-editor;
|
||||||
|
"text/vnd.trolltech.linguist" = gnome-text-editor;
|
||||||
|
"text/x-changelog" = gnome-text-editor;
|
||||||
|
"text/x-common-lisp" = gnome-text-editor;
|
||||||
|
"text/x-copying" = gnome-text-editor;
|
||||||
|
"text/x-csrc" = gnome-text-editor;
|
||||||
|
"text/x-dbus-service" = gnome-text-editor;
|
||||||
|
"text/x-gettext-translation" = gnome-text-editor;
|
||||||
|
"text/x-go" = gnome-text-editor;
|
||||||
|
"text/x-gradle" = gnome-text-editor;
|
||||||
|
"text/x-java" = gnome-text-editor;
|
||||||
|
"text/x-log" = gnome-text-editor;
|
||||||
|
"text/x-makefile" = gnome-text-editor;
|
||||||
|
"text/x-meson" = gnome-text-editor;
|
||||||
|
"text/x-python" = gnome-text-editor;
|
||||||
|
"text/x-readme" = gnome-text-editor;
|
||||||
|
"text/x-rst" = gnome-text-editor;
|
||||||
|
"text/x-scss" = gnome-text-editor;
|
||||||
|
"video/mp4" = clapper;
|
||||||
|
"video/x-matroska" = clapper;
|
||||||
"x-scheme-handler/http" = firefox-esr;
|
"x-scheme-handler/http" = firefox-esr;
|
||||||
"x-scheme-handler/https" = firefox-esr;
|
"x-scheme-handler/https" = firefox-esr;
|
||||||
};
|
};
|
||||||
|
@ -56,9 +141,7 @@ in {
|
||||||
templates = "/home/${config.custom.username}/SYNC/linux/config/templates";
|
templates = "/home/${config.custom.username}/SYNC/linux/config/templates";
|
||||||
|
|
||||||
extraConfig = {
|
extraConfig = {
|
||||||
XDG_SCREENSHOTS_DIR = "${
|
XDG_SCREENSHOTS_DIR = "${config.home-manager.users.${config.custom.username}.xdg.userDirs.pictures}/Screenshots";
|
||||||
config.home-manager.users.${config.custom.username}.xdg.userDirs.pictures
|
|
||||||
}/Screenshots";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue