I try to open an app in OSX — let's say Notes for instance, I use two commands in terminal to switch to other user:
sudo -u user /Applications/Notes.app/Contents/MacOS/Notes
user, I can type, click and use normally as
If I use
su - user
then launch the app
It does launch the app, but the keyboard does not work; why is this? Can you pour some insight into this?