On 2022-08-03 11:47, gumb wrote:
On 02/08/2022 14:13, Bengt Gördén wrote:
$ strace -o firefox.log firefox && egrep mime.types firefox.log openat(AT_FDCWD, "/home/bengan/.mime.types", O_RDONLY) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/etc/mime.types", O_RDONLY) = 133 openat(AT_FDCWD, "/home/bengan/.mime.types", O_RDONLY) = -1 ENOENT (No such file or directory)
I don't understand what this last paragraph is or does.
It runs strace (trace system calls and signals) and saves log to firefox.log. When you quit firefox the next command (after &&) is run and greps for "mime.types" in the file firefox.log It was just to show you that firefox opens $HOME/.mime.types and /etc/mime.types. strace is a nice thing to trace system calls of a program. I use it if something has gone wrong or if I just want to see what the heck a program is doing, syscall-wise that is.
Do I create a copy of /etc/mime.types to put at $HOME/.mime.types, or just a new blank text file with the one relevant modified line text/html html htm shtml ? And does anything need restarting or rebooting afterwards for it to take effect?
A blank file with the modified line is enough. this creates or adds that to your file. echo "text/html html htm shtml" >> $HOME/.mime.types -- /bengan