Thank you, that combination is doing what I need it to do.
I’m marking this as solved, but I’d love to see a breakdown of what
ps aux | grep node | grep -v "color" | awk '{print $2}' | xargs sudo kill -9
is doing exactly?
Thank you, that combination is doing what I need it to do.
I’m marking this as solved, but I’d love to see a breakdown of what
ps aux | grep node | grep -v "color" | awk '{print $2}' | xargs sudo kill -9
is doing exactly?
@sdetweil said in Command line to stop MM:
ps aux | grep node | grep -v “color” | awk ‘{print $2}’ | xargs sudo kill -9
Thank you for that. It worked, but gives me this: is it safe to ignore these warnings?
./run-start.sh: line 67: 3306 Killed electron js/electron.js $1
npm ERR! code ELIFECYCLE
npm ERR! errno 137
npm ERR! magicmirror@2.10.1 start: `./run-start.sh`
npm ERR! Exit status 137
npm ERR!
npm ERR! Failed at the magicmirror@2.10.1 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2020-02-03T20_03_35_641Z-debug.log
I ran it from ~/MagicMirror so I was in the directory. and all I typed was npm start.
My problem is that I want to be able to fire a script after a set time to stop the Magic Mirror. My goal is to attach a PIR motion sensor, and when someone comes close start the magic mirror, and after a few minutes with no motion, stop Magic Mirror and run another script. Maybe that helps understand my intent.
I have successfully created my config.js file and MM works from the terminal when I type
npm start
Is there a command to stop MM from the command line?