Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
|
04-15-2017, 05:05 PM
|
#1
|
LQ Newbie
Registered: May 2016
Posts: 23
Rep:
|
A message "This text file seems to be an executable script" when opening FB2 files
Hello!
When opening FB2 files, the message "This text file seems to be an executable script. What do you want to do with it?" appears instead of opening by FB2Reader. Screenshot is attached.
How to remove this message and make these files to be opened by FB2Reader at once?
Lubuntu 16.04 x64.
|
|
|
04-15-2017, 05:47 PM
|
#2
|
Senior Member
Registered: Dec 2003
Location: The Key Stone State
Distribution: CentOS Sabayon and now Gentoo
Posts: 1,249
Rep:
|
Check your file association and make sure the file extension is linked to your FB2Reader.
|
|
|
04-15-2017, 08:12 PM
|
#3
|
LQ Newbie
Registered: May 2016
Posts: 23
Original Poster
Rep:
|
And how to change it? I've added:
- "application/x-fictionbook+xml=FBReader.desktop" to /etc/gnome/defaults.list;
- "application/x-fictionbook+xml fb2 fb2.zip" to /etc/mime.types;
- "application/x-fictionbook+xml; /usr/bin/FBReader %s; test=test -n "$DISPLAY"" to /etc/mailcap;
and made reboot. There is no result.
|
|
|
04-15-2017, 08:15 PM
|
#4
|
Senior Member
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: Fedora
Posts: 4,228
|
Try turning off execute permission: chmod -x 1.fb2
|
|
|
04-15-2017, 08:29 PM
|
#5
|
LQ Newbie
Registered: May 2016
Posts: 23
Original Poster
Rep:
|
Yes, it worked, but is it possible to fix it fo all FB2 files? It's not good to do this for all of the books in library.
Text files in another formats are opened correctly.
|
|
|
04-16-2017, 05:16 AM
|
#6
|
LQ Addict
Registered: Dec 2013
Posts: 19,872
|
right-click the icon in your file manager, go properties => open with...
and set desired app as default.
works on pcmanfm.
|
|
|
04-16-2017, 07:58 AM
|
#7
|
Senior Member
Registered: Dec 2003
Location: The Key Stone State
Distribution: CentOS Sabayon and now Gentoo
Posts: 1,249
Rep:
|
As ondoho said should do the trick.
|
|
|
04-16-2017, 09:19 AM
|
#8
|
LQ Newbie
Registered: May 2016
Posts: 23
Original Poster
Rep:
|
Quote:
Originally Posted by ondoho
right-click the icon in your file manager, go properties => open with...
and set desired app as default.
works on pcmanfm.
|
It doesn't help, even after rebooting.
PCManFM option "Don't ask option to launch executable file" doesn't help too. Nothing happens because system tries to launch it as executable, not to open it with FBReader.
As smallpond said, block executing work, but it has to be made for all books, and it's not comfortable at all.
Are there any ways to fix it once and forever? As you can see, I tried to do everything.
|
|
|
04-16-2017, 01:18 PM
|
#9
|
LQ Veteran
Registered: Jul 2006
Location: London
Distribution: PCLinuxOS, Salix
Posts: 6,191
|
In your home directory there should be something like
.local/share/applications/mimeapps.list
or
.local/share/applications/defaults.list
which you can edit. Try adding something like
text/fb2=fbreader.desktop
|
|
|
04-16-2017, 04:00 PM
|
#10
|
LQ Addict
Registered: Dec 2013
Posts: 19,872
|
it is possible that you downloaded a bunch of documents that some 1D10T marked executable.
that is annoying, but the only option is to change them back to NOT executable.
however:
Quote:
Originally Posted by Sam_Rosewood
PCManFM option "Don't ask option to launch executable file" doesn't help too. Nothing happens because system tries to launch it as executable
|
that's strange, it surely works on my system.
you could show us where you got the files, or one of them, somebody could give it a try.
|
|
|
04-16-2017, 07:51 PM
|
#11
|
LQ Newbie
Registered: May 2016
Posts: 23
Original Poster
Rep:
|
DavidMcCann, it doesn't help. System already has the type application/x-fictionbook+xml.
ondoho, I can't put this file here or link because of LQ rules. But I have a library of FB2 books, and this behaviour is for all of them. So I have a doubt that's the problem in files.
I can't understand logic of this extension system: pictures are opening in viewer, music and video - in player, documents - in LibreOffice. And it's correct. But these simple FB2 books show this annoying message.
|
|
|
04-17-2017, 12:25 PM
|
#12
|
LQ Veteran
Registered: Jul 2006
Location: London
Distribution: PCLinuxOS, Salix
Posts: 6,191
|
I think the answer is going to be replacing PCManFM. On most file managers, you can set the default application for file types. Xfce is not that much bigger than LXDE, but Thunar has that facility.
|
|
|
04-17-2017, 01:09 PM
|
#13
|
LQ Addict
Registered: Dec 2013
Posts: 19,872
|
i'm using pcmanfm right now & have been for a long time and cannot, in a general way, reproduce the problem.
the preference dialog "Don't ask option to launch executable file" is effective.
now i think about it, pcmanfm runs as a daemon on Lubuntu, maybe it needs to be restarted for certain changes to take effect? Sam_Rosewood, have you tried to log out/in after changing the preferences?
|
|
|
04-17-2017, 09:06 PM
|
#14
|
LQ Newbie
Registered: May 2016
Posts: 23
Original Poster
Rep:
|
DavidMcCann, this is not the way. I want to solve this problem, but not to go away from it.
ondoho, reboot doesn't help. This option "Don't ask option to launch executable file" works only if I set chmod -x in terminal or manually (screenshot). Yeah, I can set it for all the files in my library, but this is temporary measure. And I'll have to to it with every new FB2 file that I get. This is not comfortable.
|
|
|
04-18-2017, 10:03 AM
|
#15
|
Senior Member
Registered: Dec 2003
Location: The Key Stone State
Distribution: CentOS Sabayon and now Gentoo
Posts: 1,249
Rep:
|
You need to change the way the files are being saved. Not sure why the executable flag is being set on your downloads but that seems to be the problem.
|
|
|
All times are GMT -5. The time now is 01:39 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|