Re: Funny action on opening a pdf document
I've just commited the ticket for this: http://www.midnight-commander.org/ticket/2965 you may find it interesting as it explains also how xdg-open is working and tries to explain this all is illogical. I also ended up digging into this as suddenly everything was opening in a web browser (fallback for xdg-open). Regards Adam Pribyl ___ mc mailing list https://mail.gnome.org/mailman/listinfo/mc
Re: Funny action on opening a pdf document
[Theodore Kilgore, 2013-01-19] OK. I can not do any more of this on the machine which is in the workplace right now, but I tried it at home on my Raspberry Pi which was having the same problem. It seems to fix the problem well enough. great Some observations, both for you who apparently are connected with xdg-open and for the MC people: I'm just a xdg-open user 1. The RPI is a little machine, with minimal resources. It is not expected to deal with mail, so there was no .mailcap file. No mail programs, not even client programs, and so nothing related was installed, either. Hence, the only way that was reasonable for creating a .mailcap file was to copy one over there. For similar reasons, there was no /etc/mime.types, either, and no .mime.types file in my user directory. On Debian, it is provided by mime-support package which is Priority: standard so you have to do some work to... not have this files installed by default. -- Piotr Ożarowski Debian GNU/Linux Developer www.ozarowski.pl www.griffith.cc www.debian.org GPG Fingerprint: 1D2F A898 58DA AF62 1786 2DF7 AEF6 F1A2 A745 7645 signature.asc Description: Digital signature ___ mc mailing list https://mail.gnome.org/mailman/listinfo/mc
Re: Funny action on opening a pdf document
On Sun, 20 Jan 2013, Piotr Ozarowski wrote: [Theodore Kilgore, 2013-01-19] OK. I can not do any more of this on the machine which is in the workplace right now, but I tried it at home on my Raspberry Pi which was having the same problem. It seems to fix the problem well enough. great Some observations, both for you who apparently are connected with xdg-open and for the MC people: I'm just a xdg-open user 1. The RPI is a little machine, with minimal resources. It is not expected to deal with mail, so there was no .mailcap file. No mail programs, not even client programs, and so nothing related was installed, either. Hence, the only way that was reasonable for creating a .mailcap file was to copy one over there. For similar reasons, there was no /etc/mime.types, either, and no .mime.types file in my user directory. On Debian, it is provided by mime-support package which is Priority: standard so you have to do some work to... not have this files installed by default. Not all distros are identical. What you have, of course, is an indirect proof that I am not running Debian on the Raspberry Pi. Thanks for the help. Theodore Kilgore ___ mc mailing list https://mail.gnome.org/mailman/listinfo/mc
Re: Funny action on opening a pdf document
[Theodore Kilgore, 2013-01-18] xdg-open opens a file or URL in the user's preferred application explicitly mentioning a file or a url and then it says If a file is provided the file will be opened in the preferred application for files of that type. These words would indicate that it is going to open a file by doing something to the file, not by doing the extraneous act of starting a web browser. do you have something like: application/pdf;xpdf '%s'; prioryty=1; test=test -n $DISPLAY in ~/.mailcap or /etc/mailcap? If not, can you add it to ~/.mailcap and check xdg-open again? You can also add to ~/.mime.types: application/pdf pdf if /etc/mime.types doesn't have it. -- Piotr Ożarowski Debian GNU/Linux Developer www.ozarowski.pl www.griffith.cc www.debian.org GPG Fingerprint: 1D2F A898 58DA AF62 1786 2DF7 AEF6 F1A2 A745 7645 ___ mc mailing list https://mail.gnome.org/mailman/listinfo/mc
Re: Funny action on opening a pdf document
[Theodore Kilgore, 2013-01-18] On Fri, 18 Jan 2013, Piotr Ozarowski wrote: [Theodore Kilgore, 2013-01-18] xdg-open opens a file or URL in the user's preferred application explicitly mentioning a file or a url and then it says If a file is provided the file will be opened in the preferred application for files of that type. These words would indicate that it is going to open a file by doing something to the file, not by doing the extraneous act of starting a web browser. do you have something like: application/pdf;xpdf '%s'; prioryty=1; test=test -n $DISPLAY in ~/.mailcap or /etc/mailcap? No I did not. If not, can you add it to ~/.mailcap and check xdg-open again? You can also add to ~/.mime.types: I have no such file create it then application/pdf pdf (didn't try adding any .mime.types file. Are you sure it isn't xpdf at the end?) yes, I'm sure (it will let xdg-open know that *.pdf files have application/pdf mime type and later it will choose the right app from ~/.mailcap) if /etc/mime.types doesn't have it. No such file in /etc, either. so that's why xdg-open tries to open this file in a browser The man page says it has something to do with cups. nothing to do with CUPS, see http://en.wikipedia.org/wiki/Mailcap No help from adding the line to .mailcap. echo 'application/pdf pdf' ~/.mime.types -- Piotr Ożarowski Debian GNU/Linux Developer www.ozarowski.pl www.griffith.cc www.debian.org GPG Fingerprint: 1D2F A898 58DA AF62 1786 2DF7 AEF6 F1A2 A745 7645 ___ mc mailing list https://mail.gnome.org/mailman/listinfo/mc
Re: Funny action on opening a pdf document
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 16.01.2013 17:55, Theodore Kilgore wrote: Please, update to latest version (4.8.7) and try to run: MC_XDG_OPEN=false mc It's will switch off the usage of xdg-open and will use an internal file associations. Is it what you expected? - -- WBR, Slavaz. -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.13 (GNU/Linux) iEYEARECAAYFAlD4c0EACgkQb3oGR6aVLppzPgCfSGSqdT3Vs1OMGg2F36/1roWj SOsAnRVv93j3dX/9kNOAN3aPtd9z09nm =MxFn -END PGP SIGNATURE- ___ mc mailing list https://mail.gnome.org/mailman/listinfo/mc