[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Tiny Clojure library to get current process ID and save/read PID files.

Notifications You must be signed in to change notification settings

dsabanin/clj-pid

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

clj-pid

Tiny Clojure library to get current process ID and save/read PID files.

Install

Available from Clojars.

Usage

(use ['clj-pid.core :as 'pid])

(def pid-file "/var/run/my-daemon.pid")

;; Get current process PID
(pid/current) ; => "39350"

;; Save pid file
(pid/save pid-file)

;; Delete pid file
(pid/delete pid-file) ; => true / false

;; Delete pid file on JVM shutdown
(pid/delete-on-shutdown! pid-file)

License

Copyright (C) 2013 Dima Sabanin

Distributed under the Eclipse Public License, the same as Clojure.

About

Tiny Clojure library to get current process ID and save/read PID files.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published