Skip to content

Instantly share code, notes, and snippets.

@raganmd
Last active March 30, 2018 06:10
Show Gist options
  • Save raganmd/2938472ab3878db220ace4e09d4c0a93 to your computer and use it in GitHub Desktop.
Save raganmd/2938472ab3878db220ace4e09d4c0a93 to your computer and use it in GitHub Desktop.
# matthew ragan | matthewragan.com
import os
import signal
# first we need to find our process ID
# which we can grab from the dictionary
# we put into storage
pid = parent().fetch('other_app')['app_id']
# next we can kill this process based
# only on its process id
os.kill(pid, signal.SIGTERM)
parent().unstore("*")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment