Skip to content

Instantly share code, notes, and snippets.

@mayuki
Created July 15, 2009 05:02
Show Gist options
  • Select an option

  • Save mayuki/147460 to your computer and use it in GitHub Desktop.

Select an option

Save mayuki/147460 to your computer and use it in GitHub Desktop.
import clr
from System.Diagnostics import *
pid_path = '/tmp/tig.pid'
f = open(pid_path, 'w')
f.write(Process.GetCurrentProcess().Id.ToString())
f.close()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment