greedist Posted February 8 Share Posted February 8 (edited) If you run the command shown in the picture as Alfred, the osascript -e 'tell app "System Events" to restart' command won't work. Is there any way to solve this problem? Thank you in advance 🙏 Edited February 8 by greedist Link to comment
vitor Posted February 8 Share Posted February 8 It isn’t working because you’re entering an interactive SSH session and presumably not exiting, so the other commands never have a chance to run. What exactly are you trying to do? Link to comment
greedist Posted February 8 Author Share Posted February 8 7 minutes ago, vitor said: It isn’t working because you’re entering an interactive SSH session and presumably not exiting, so the other commands never have a chance to run. What exactly are you trying to do? I'm going to connect to iMac through the shh and boot through the window. Is this impossible? 🤔 Link to comment
vitor Posted February 8 Share Posted February 8 If what you want is to send the commands for them to be executed on the target machine, you give them as another argument to the SSH command. As in: ssh 'xxx@yyy' 'osascript -e "tell app \"System Events\" to restart"' Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now