I toggle the "Use all F1, F2 as standard keys" setting very often and would like to automate it via a script (or a keyboard shortcut). Is it possible? I've tried to Google the right arguments for
defaults write ... but unsuccessfully.
Update: I ended up creating https://github.com/jkbrzt/macos-fn-toggle based of the answers here.
Update II: There's now also — https://github.com/Pyroh/Fluor — a really nice menubar app that allows you to automatically change the behaviour of the keyboard's fn keys depending on the active application.