WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: mimeapps.list  (Read 2355 times)

Offline emninger

  • Sr. Member
  • ****
  • Posts: 267
mimeapps.list
« on: November 23, 2015, 11:53:33 PM »
When i click on FF > Downloads > Open file in folder nothing happens. Now, i think this should be configured in FF > Options > Applications but there does not exist the option "folder".

Just guessing in the dark, to have this option there should be configured something in ~/mimeapps.list. But how?

Thanks a lot in advance.

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: mimeapps.list
« Reply #1 on: November 24, 2015, 04:37:10 AM »
I just recently got  xdg-open  (xdg-utils.tcz) to work. The xdg-mime script has  /usr/bin/file  hardcoded which I have changed to  /usr/local/bin/file  and added  file.tcz  to  xdg-utils.tcz.dep .

Also I've added a check for sysmlinks otherwise  file  can't find the MIME type.
Code: [Select]
    #/usr/local/bin/file -i "$1" 2> /dev/null | cut -d ":" -f 2 | sed s/"^ "//
    ### Fix for symlinks.
    if [ -L "$1" ]; then
        FILE="$(readlink "$1")"
    else
        FILE="$1"
    fi
    /usr/local/bin/file -i "$FILE" 2> /dev/null | cut -d ":" -f 2 | sed s/"^ "//

While this is now working  ~/.local/share/applications/defaults.list  is read for the application to use for each mime type.
Mine currently looks like this
Code: [Select]
[Default Applications]
text/plain=tinycore-editor.desktop
text/sh=tinycore-editor.desktop
text/x-sh=tinycore-editor.desktop
text/shellscript=tinycore-editor.desktop
text/x-shellscript=tinycore-editor.desktop
text/txt=tinycore-editor.desktop
text/x-txt=tinycore-editor.desktop
text/x-diff=tinycore-editor.desktop
text/cfg=tinycore-editor.desktop
text/log=tinycore-editor.desktop
inode/directory=xfe.desktop
application/x-directory=xfe.desktop
application/pdf=firefox.desktop
text/html=firefox.desktop
text/htm=firefox.desktop
x-scheme-handler/mailto=thunderbird.desktop
application/xhtml+xml=firefox.desktop
x-scheme-handler/http=firefox.desktop
x-scheme-handler/https=firefox.desktop
image/xcf=gimp2.desktop
image/ico=viewnior.desktop
image/svg=viewnior.desktop
image/bmp=viewnior.desktop
image/gif=viewnior.desktop
image/jpeg=viewnior.desktop
image/jpg=viewnior.desktop
image/pjpeg=viewnior.desktop
image/png=viewnior.desktop
image/tiff=viewnior.desktop
image/x-bmp=viewnior.desktop
image/x-gray=viewnior.desktop
image/x-icb=viewnior.desktop
image/x-ico=viewnior.desktop
image/x-png=viewnior.desktop
image/x-portable-anymap=viewnior.desktop
image/x-portable-bitmap=viewnior.desktop
image/x-portable-graymap=viewnior.desktop
image/x-portable-pixmap=viewnior.desktop
image/x-xbitmap=viewnior.desktop
image/x-xpixmap=viewnior.desktop
image/x-pcx=viewnior.desktop
image/svg+xml=viewnior.desktop
image/svg+xml-compressed=viewnior.desktop
image/vnd.wap.wbmp=viewnior.desktop
application/aup=autacity.desktop
application/x-audacity-project=autacity.desktop
audio/x-flac=autacity.desktop
audio/basic=autacity.desktop
audio/x-aiff=autacity.desktop
application/ogg=autacity.desktop
audio/x-vorbis+ogg=autacity.desktop
x-content/audio-player=smplayer.desktop
audio/m4a=smplayer.desktop
audio/mp3=smplayer.desktop
audio/wav=smplayer.desktop
audio/ac3=smplayer.desktop
audio/mp4=smplayer.desktop
audio/mpeg=smplayer.desktop
audio/vnd.rn-realaudio=smplayer.desktop
audio/vorbis=smplayer.desktop
audio/x-adpcm=smplayer.desktop
audio/x-matroska=smplayer.desktop
audio/x-mp2=smplayer.desktop
audio/x-mp3=smplayer.desktop
audio/x-ms-wma=smplayer.desktop
audio/x-vorbis=smplayer.desktop
audio/x-wav=smplayer.desktop
audio/mpegurl=smplayer.desktop
audio/x-mpegurl=smplayer.desktop
audio/x-pn-realaudio=smplayer.desktop
audio/x-scpls=smplayer.desktop
audio/aac=smplayer.desktop
audio/flac=smplayer.desktop
audio/ogg=smplayer.desktop
x-content/video-player=smplayer.desktop
video/xvid=smplayer.desktop
video/mpg=smplayer.desktop
video/flv=smplayer.desktop
video/3gp=smplayer.desktop
video/3gpp=smplayer.desktop
video/avi=smplayer.desktop
video/mp4=smplayer.desktop
video/flv=smplayer.desktop
video/mpeg=smplayer.desktop
video/quicktime=smplayer.desktop
video/vnd.rn-realvideo=smplayer.desktop
video/x-matroska=smplayer.desktop
video/x-ms-asf=smplayer.desktop
video/x-msvideo=smplayer.desktop
video/x-ms-wmv=smplayer.desktop
video/x-ogm=smplayer.desktop
video/x-theora=smplayer.desktop
video/webm=smplayer.desktop


If you any of those apps setup to load ondemand, you can, while they are loaded, copy their  *.desktop  file from
/usr/local/share/applications
to
~/.local/share/applications
Provided the main executable from the extension share the same name as the extension itself (or the ondemand script).
Download a copy and keep it handy: Core book ;)

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: mimeapps.list
« Reply #2 on: November 24, 2015, 04:41:45 AM »
Quote
Now, i think this should be configured in FF > Options > Applications but there does not exist the option "folder".
This actually works if changing "Content Type - file" to use your favorite file manager.
Download a copy and keep it handy: Core book ;)

Offline emninger

  • Sr. Member
  • ****
  • Posts: 267
Re: mimeapps.list
« Reply #3 on: November 24, 2015, 06:30:08 AM »
Thanks a lot! It does :D