Score:1

The system does not differentiate between text and Arduino files

er flag

I use ubuntu 22.04 LTS with Gnome 42.5 on wayland. I have installed the latest version of the Arduino IDE (an .AppImage file). My problem is that when I have to open the sketches from the file manager (I use Gnome Files) it either recognizes the .ino files as plain text files or as C source files. If I set the Arduino IDE as default to open the file .ino, then I always open all text files with Arduino. How can I "separate" plain text files from Arduino ones (.ino extension)?

Thanks in advance for the help

Update 29/04/2023:

What I don't understand is why some sketches are recognized as plain text files (image 1) and others as C sources (image 2), even though they both have the .ino extension. Isn't there a way to create a new mime-type category for .ino files? I hope I explained myself better.

Image 1: .ino file recognized as plain text file

Image 2: .ino file recognized as C sources file

Update 30/08/2023:

I know that .ino files are actually plain text files, but I'd like to be able to create a new mime type category (I understand that on Linix files are "identified" like this)for .ino files. I found some guides on the internet, but it never worked. Actually I would need this for other programs as well. What I'm trying to do is a Windows-like solution where files are "identified" by extension.

Thank you

sim.dll

waltinator avatar
it flag
The system does not differentiate Arduino files from text files because Arduino files ARE text files. Read `man file`.
cn flag
check the 1st line of the file.
sim.dll avatar
er flag
Thanks for the pointers, but can I create a new mime-type category for .ino files? Thank you
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.