Questions tagged [mime-types]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2 votes
2 answers
52 views

How do I bulk edit the default application for many file types in XFCE?

Last year I test drove Lapce & somehow set it to be the default application for over 100 source file types. I don't remember how I did this, but the XFCE Default Applications program tells me so. ...
Garrigus Carraig's user avatar
0 votes
1 answer
60 views

Where does this feature request/fix of filtering when uploading files belong?

Using a R-shiny app in Ubuntu, with a field to upload an .Rmd file, that has a filter for file extension: # R-shiny code fileInput("id", "label", accept = c( ".Rmd&...
Ferroao's user avatar
  • 293
0 votes
0 answers
93 views

How can I assign a mimetype to a file extension?

Sometimes my .tsx files are assigned the mimetype application/javascript. But I'd like my .tsx files to always have the mimetype text/plain. How can I achieve this?
Adrian Lopez's user avatar
0 votes
1 answer
260 views

How do I associate an application with all mime types it supports?

Let's say I have xarchiver installed by default, and associated by default with most archive types. I've installed engrampa, and now want to assciate it with the various archive types instead. I don't ...
HolyBlackCat's user avatar
0 votes
0 answers
69 views

xdg-mime and file command identifying file type differently

If you look at the screenshot bellow you will find that gnome is telling a file which is ASCII text as audio/x-mod. For the time being I have set audio/x-mod=codium.desktop in mimeapps.list, but I do ...
Ahmad Ismail's user avatar
  • 2,648
0 votes
0 answers
58 views

How to delete a MIME type in Linux/Gnome?

Linux associates the *.key files to the application/x-iwork-keynote-sffkey mime type, which corresponds to an Apple MacOS application. I don't open Apple files in my Linux PC. I would like to delete/...
hpr's user avatar
  • 11
0 votes
1 answer
49 views

Is it bad that I changed the default application of application/x-trash files?

I was trying to use the mimeopen command to open an image file. I ended up being asked to pick the default application of application/x-trash. I was practicing python and thought I should press ...
kingjofr's user avatar
0 votes
1 answer
85 views

Listing mime-type for each input file

I want to pass a set of file names to a bash function, and list the mime-type as follows. video/mp4 file.mp4 video/mkv file.mkv Here is the loop iterating each file for fl in "$@"; do ...
Vera's user avatar
  • 1,223
0 votes
1 answer
178 views

File is not readable when script is called by cron

This really has me scratching my head. I have a PERL script on a RHEL 7 server that creates an xlsx file via MIME::Lite and emails it to several people. If I run the script from the command line it ...
Chanel's user avatar
  • 99
2 votes
1 answer
59 views

Most thorough way to determine the user-perspective "type" of a file in Linux?

I am looking (in a file-manager sort of application) to provide the most pertinent natural-language description of what kind of a file each file in a directory is. There seem to be several command-...
Glen Whitney's user avatar
0 votes
1 answer
335 views

Why I do get text/plain and text/x-java for two different js files?

I use /usr/bin/file -i file_path to get information about my files. I have a simple website project, in which I have a couple of js files. When I use /usr/bin/file -i file_name.js for some of them, I ...
Ali EXE's user avatar
  • 129
5 votes
0 answers
1k views

How to set the default application to open folders?

I'm really stuck; I want to add Open with vs code to the folders context menu following the same approach as for files by means of the so-called MIME; editing the file ~/.config/mimeapps.list allows ...
EnthusiastiC's user avatar
3 votes
1 answer
490 views

wrong filetype for extension

I have some octave files, ending with the default .m extension. In file, I am getting it as ASCII text: file euler.m euler.m: ASCII text and plain text icon in nautilus. How I can assign .m ...
BaRud's user avatar
  • 1,629
2 votes
0 answers
109 views

How to stop Zoom from stealing URI associations when installing with FlatPak?

Ever since installing Zoom Flatpak I've noticed that many web-links (like telephone numbers) that should not be associated to ZOOM are now being opened by ZOOM. I'd like to maintain Zoom assocition ...
Jonathan's user avatar
2 votes
0 answers
41 views

Are there different formats for Mathematica Notebooks and how are MIME types defined in them?

I use Mathematica 12.3 on Xubuntu 20.4. The computer runs with German localization. I wondered, why one of my notebooks is displayed with the icon usually used for LibreOfficeWriter documents. In the ...
Adalbert Hanßen's user avatar
2 votes
1 answer
658 views

Custom mime type for directories

Is it possible to make a custom mime type for directories (inode/directory)? Just like what MacOS does with *.app folders (app bundle) which make it possible to open them in another program.
Bytez's user avatar
  • 21
2 votes
1 answer
273 views

Linux setting of the program that opens a file clicked in Firefox downloads list?

Asking this question I thought I knew what this was about. That question was asking how to prevent Firefox from making files listed in its downloads list be opened with wrong programs. I still want to ...
cipricus's user avatar
  • 1,480
0 votes
1 answer
623 views

Failing to associate an icon to a custom MIME type

I'm failing to add a custom icon to a custom MIME type file. I don't know what I'm doing wrong, I've followed several tutorials in here and on other websites. First I created a xml file called org.xml ...
Nicryc's user avatar
  • 295
1 vote
1 answer
205 views

How can I use a prefix in the <glob> element of a mime info file?

I have a bunch of files in the form of xyz-timestamp.log, which I want to associate with a different application, than normal log files. I read up on mime types and found out, that I can add a mime-...
Minix's user avatar
  • 5,835
2 votes
2 answers
744 views

What is an effective way to automatically append file extensions to extensionless files?

I wrote a bash script today during my lunch break that finds extensionless files in a directory and appends a file extension to those files. The script is relatively long because I added a bunch of ...
David Moore's user avatar
1 vote
2 answers
120 views

Reason for text/plain pattern "*,v" in shared-mime-info?

The freedesktop.org media type database shared-mime-info has a filename pattern *,v associated with MIME type text/plain, and I can't figure out why - if only because ,v and *,v are basically useless ...
Tim Pederick's user avatar
1 vote
1 answer
669 views

How do I set priority of which application opens a url schema (rdp://) in kde?

I have several applications installed that handles url schema rdp:// (for example, rdp://[email protected]). These applications are Krdc and Remmina. I want such links to be opened in krdc, but they are ...
Ashark's user avatar
  • 889
4 votes
2 answers
317 views

File Provides Different Mime-types on Different Operating Systems

So I have a bash script that in part does the following: file -b --mime-type "$1" I then have logic to check if it is the expected type of file. if [[ $type == "application/gzip" ]]...
thePinochleKid's user avatar
1 vote
0 answers
193 views

Sending HTML with Mutt mangles the reply history badly; How can I make replies survive a call to Pandoc?

In mutt, I'm trying to write formatted emails, but the pre-processing step that converts markdown to HTML is mangling the previous messages. I'm using this answer to convert my messages to HTML. In ...
Josh Vander Hook's user avatar
0 votes
1 answer
149 views

show "detailed type" instead of "type" as default in nemo

I would like to differ between SVG, JPEG, PNG images in a folder. It is anoying to always change it, so I want to set "detailed type" instead of "type" as default.
JoKalliauer's user avatar
0 votes
2 answers
88 views

Sorry mime the second (mate-control-center vs. firefox)

My OS is Debian stretch (mate Desktop) Since about 2 years I have a problem with default setting for application browser(in mate-control-center) and firefox. whenever I let firefox set itselfs as ...
nobody's user avatar
  • 352
0 votes
1 answer
465 views

messed up systemwide mime data base

In debian stretch (mate desktop) i messed up systemwide my mime data base. How can I restore it. Note I renamed first my /usr/share/mime/mimeinfo.cache. but the Problem is, I think it is broken. ...
nobody's user avatar
  • 352
0 votes
1 answer
718 views

Make Firefox open app without first prompting to choose from window with one choice

No posted answer in StackExchange worked: they are years-old and pertain to very old versions of Firefox. EDIT: At first I posted about opening files from the downloads list. I later discovered I get ...
nmgeek's user avatar
  • 101
0 votes
0 answers
713 views

xdg-mime not doing anything

Created an empty file in ~ called test.desktop. Ran xdg-mime default test.desktop inode/directory, which returned success (returned 0). After this, xdg-mime query default inode/directory returned caja-...
Carla is my name's user avatar
0 votes
0 answers
302 views

How to properly use mailx to attach a file (not replace content)?

I am using $ mailx -V mailx (GNU Mailutils) 3.5 Copyright (C) 2007-2017 Free Software Foundation, inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free ...
divB's user avatar
  • 178
3 votes
1 answer
1k views

How to set all youtube links to open in mpv

I would like to set my system to open all links is mpv as default ie. I click link to youtube video in IRC, mumble, discord, signal etc. it opens in mpv. I have read through xdg-open and xdg-mime but ...
Vahvaloac's user avatar
0 votes
2 answers
4k views

Getting MP4 to play in Firefox in OpenSuse

I'm not sure since when, but MP4 videos are not playable anymore on Firefox. There's an error message in the Web-Console saying HTTP-Content-Type "video/mp4" is not supported. OS: OpenSuse ...
WallaceNC's user avatar
2 votes
0 answers
441 views

xdg-scheme-handler doesn't open script with same terminal that launching it from a desktop menu does

I'm trying to set a x-scheme-handler URI for my python application. This application is launched via a shell script in /usr/bin. I've had a desktop file for a while, and it's worked fine, opening the ...
Tabulate's user avatar
  • 121
3 votes
1 answer
842 views

How to register new mimetypes not available in xfce4-mime-settings so that they are recognized with xdg-open under XFCE4?

I am trying to register new mimetypes under XFCE4. In particular, I would like to register the protocol zoommtg so I can launch Zoom meetings from links in the webbrowser Chrome. Chrome will launch ...
Pete's user avatar
  • 133
1 vote
1 answer
33 views

The most common commenting marks and mimetypes

I'd like to write a shell script to optionally view files without comments (which sometimes take a lot of space so that it becomes difficult to see the lines active in a config file, etc.) and this ...
Sadi's user avatar
  • 495
0 votes
1 answer
1k views

Executable binaries labelled as shared library files

After compiling software from source code, I can usually launch the compiled binary by double-clicking on it. Recently however, most of my compiled binaries are not responding to double-click, even if ...
JS4137's user avatar
  • 175
10 votes
4 answers
2k views

Removing files based on MIME types in linux

I'm quite a beginner to Linux and I'm having trouble removing files based on the mime type. Currently, I have a set of files on my Linux machine, and below are the types for a small subset. 0FiTahKc: ...
alex's user avatar
  • 101
0 votes
1 answer
164 views

help debugging thumbnailer script in nemo

I recently installed 'stl-thumb' as a thumbnailer plugin to the file managers, but I notice that it isn't converting all files with the .stl extension. Upon closer inspection using the shell 'file --...
Scott's user avatar
  • 151
3 votes
0 answers
132 views

Is it possible to require both glob and magic specified in mimetype definition?

Given the following freedesktop shared-mime-info file: <?xml version="1.0" encoding="UTF-8"?> <mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info&...
user418703's user avatar
2 votes
0 answers
101 views

Is it possible to use unicode character within glob pattern in mime definition file?

I'm issuing the command xdg-mime install nv-custom.xml - using this file: <?xml version="1.0" encoding="UTF-8"?> <mime-info xmlns="http://www.freedesktop.org/...
user418703's user avatar
1 vote
1 answer
448 views

Where does xdg-mime save its per-user default app settings?

Where does xdg-mime save the settings I make with commands which set the default app to handle MIME types? i.e. commands such as: xdg-mime default evince.desktop application/pdf ? I'm using SLES (...
einpoklum's user avatar
  • 9,462
1 vote
1 answer
2k views

How to set MIME priority for applications?

Image types (e.g. image/jpeg, image/png etc.) are widely supported by ImageMagick and Eye of GNOME, so the only way I see to set priority for EOG is to check it's supported formats in .desktop and ...
user avatar
4 votes
1 answer
1k views

Debian Buster XFCE: make PCManFM default, including for Open a Directory, as in Chromium - downloads - show in folder

Using Debian Buster XFCE. XFCE is married to Thunar, so cannot remove thunar. I would prefer Chromium (or any other app that might choose to open a directory), as when viewing Downloads and clicking '...
Shawn Hughes's user avatar
3 votes
1 answer
2k views

Assign an icon to a custom mimetype

I tried to create a custom mimetype (text/graphml+xml) by creating the file ~/.local/share/mime/packages/graphml+xml-mime.xml with this content: <?xml version="1.0" encoding="UTF-8"?> <mime-...
Ninguém's user avatar
  • 151
0 votes
0 answers
376 views

Cannot make xdg-mime query return chosen browser

After maybe one year of using Chromium as the default browser, my Linux switched spontaneously to using Firefox (probably because of some updates). I want to switch back. Based on this answer, I ...
maaartinus's user avatar
  • 5,049
3 votes
1 answer
3k views

How to associate a new (custom) mime type with files (based on file extension)?

This is part 2 of How to install a new (custom) mime type on my Linux system using CLI tools? Using the steps in the accepted answer at the above question, I created the following mime-type mx-...
MountainX's user avatar
  • 17.9k
2 votes
1 answer
756 views

Click link to download a file, but KDE tries to open it with an application. How to download instead?

I'm running Riot.im (an Electron desktop app) in KDE (on Arch Linux). For many file types, when I click a link to download the file in Riot, the file is downloaded as expected. I am presented with KDE'...
MountainX's user avatar
  • 17.9k
8 votes
3 answers
3k views

KDE is not saving a mime-type file association

I'm running Arch Linux and KDE and I am exploring how mime-types are behaving (and misbehaving) on my system. Consider this mime-type file association. The following console output shows that I have ...
MountainX's user avatar
  • 17.9k
2 votes
1 answer
380 views

Digging deeper into differing mime-type associations

I would like to gain a deeper understanding of mime-types. So far I understand the following thanks to @munzir-taha It is normal to have different mime-type file associations on different systems, ...
MountainX's user avatar
  • 17.9k
14 votes
1 answer
7k views

How to install a new (custom) mime type on my Linux system using CLI tools?

I would like know the full steps to create and register a new custom mime type on my system. If it matters, I am running KDE on Arch Linux. The steps should include writing the XML file and ...
MountainX's user avatar
  • 17.9k