add pid file
Merge pull request #12 from X-Plat/add_pid_file

add pid file