Understanding executable file setting

if you are interested in one more test, can you run
file -k East_to_West.txt
? the -k option checks to see if the file has any classification other than ascii. executable is one of those classifications.

1 Like

Thanks to @01101111, @Akito, @abhishek for your help. Not really a big problem, but yet it got explained. :grinning:

1 Like

If ls -l shows -rw-r–r-, and the dialog pops up, you should look for the cause by using fsck to verify the partition and contents integrity.

There are too many unknowns to give you a solution or at least tell you why this happens. Are you accessing this file through a dual boot Windows/Linux system, or is the file resides on a local ext drive?

Welcome to “It’s Foss Community” @ineuw. Thanks for your input. This was just a trivial problem and I was thinking it would be something quite simple to solve. I still consider I’m a new Linux user since I still have a lot to learn.
The file indeed had -rw-r–r-- as shown in the first post. The funny thing was, if I copied the file to /Home, I did not get the pop up screen. The file was created under windows, but now is on a cloud location. I am using a laptop that boots directly to Linux Mint Cinnamon 20.


After lots of testing here is what I know.
1- It does not matter whether the file was created under windows or Linux.
2- It does not matter where the file is located with one exception.
3- I do not get the pop up when the is located at /Home.


/home – no pop up
easyt50@X220:~$ ls -l Test
-rw-r–r-- 1 easyt50 easyt50 33 Aug 18 11:05 Test
Cloud location. – pop up
easyt50@X220:~/pCloudDrive$ ls -l Test
-rw-r–r-- 1 easyt50 easyt50 33 Aug 18 11:05 Test


So I ended up going with the solution @abhishek gave which is a great work around.

1 Like

@abishek’s is the valid solution if the majority of the work is with text files. Like everything else, any of three behavior options have advantages and disadvantages, But, if the message appears when the exec bit is removed, it is not normal behavior for the popup. and here I would like to have @abishek’s input.

1 Like

I agree. If the executable bit is not set, the pop-up should not appear. This is indeed a strange case where the file manager automatically assumes that a file is executable.
The Windows specific characters could be the issue but there is no clear explanation of how it could play the culprit here.

I believe I Found the explanation! Windows does not seems to be the problem per say.
I found out that it was how the partition is formatted that causes the pop up screen to come up or not.
*
FAT32 & EXT4 format = no pop up screen
*
exFAT & NTFS format = pop up screen
*
This test was run on an USB flash drive formatted each time to one of the 4 options. The same file was copied from /home to the flash drive. Then I edited the file. The test file on /home;
easyt50@X220:~$ ls -l Test
-rw-r–r-- 1 easyt50 easyt50 33 Aug 18 11:05 Test

2 Likes

That makes sense, since Linux type permissions are not supported on those file systems.