Matlab *.m MIME type not working on linux POP OS

11 Views Asked by At

I installed MATLAB on linux POP OS. I have managed to get most of the matlab icons working on nautilus except for the *.m file extensions. (.fig and .mat files now work). I cannot figure out why it seems to ignore my .m MIME type. Here is my code:

I have in the following directory:

:/usr/share/mime/packages$ ls
apt.xml  bcompare.xml  freedesktop.org.xml  gcr-crypto-types.xml  libreoffice.xml  matlab-typemimes.xml  org.gnome.meld.xml

and inside my matlab-typemimes.xml file:

<mime-info xmlns='http://www.freedesktop.org/standards/shared-mime-info'>
    <mime-type type="application/x-matlab-m">
       <comment>Matlab source code</comment>
       <magic priority="50">
       <match value="MATLAB" type="string" offset="0"/>
       </magic>
       <glob pattern="*.m" weight="60"/>
       <generic-icon name="matlab-m"/>
    </mime-type>
    <mime-type type="image/x-matlab-fig">
        <comment>MATLAB figure</comment>
        <magic priority="50">
             <match value="MATLAB" type="string" offset="0"/>
        </magic>
        <glob pattern="*.fig" weight="60"/>
        <generic-icon name="matlab-fig"/>
    </mime-type>
    <mime-type type="application/x-matlab-data">
        <comment>MATLAB data file</comment>
        <magic priority="50">
             <match value="MATLAB" type="string" offset="0"/>
        </magic>
        <glob pattern="*.mat" weight="60"/>
        <generic-icon name="matlab-mat"/>
    </mime-type>
</mime-info>

Inside my folder for images I placed an svg file that has the icon i want:

/usr/share/icons$ ls
Adwaita                        gnome                     HighContrast            locolor          pop-os-branding
application-x-matlab-data.svg  gnome-logo-text-dark.svg  Humanity                LoginIcons       ubuntu-mono-dark
application-x-matlab-m.svg     gnome-logo-text.svg       Humanity-Dark           matlab_icon.png  ubuntu-mono-light
default                        hicolor                   image-x-matlab-fig.svg  Pop

I would appreciate any help please!

Tried updating the xml and image files, have had no luck with either. Cant explain why the .m file wont work but the other files will.your text

0

There are 0 best solutions below