af001 / nim-daemons

Testing

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

nim-daemons

Two merged nim libraries to daemonize a nim application on Windows and Posix systems.

Install

nimble install https://github.com/af001/nim-daemons

Usage

when defined linux:
    let pidfile = getTempDir() / ".daemonized.pid"
    daemonize(pidfile):
        main()
elif defined windows:
    let pidfile = getTempDir() / "daemonized.pid"
    daemonize(pidfile):
        main()

References

This repo contains a combination of code from two projects. The windows daemon portion was obtained from nim-daemon, and the posix portion from nim-daemonize.

nim-daemon
nim-daemonize

About

Testing

License:MIT License


Languages

Language:Nim 100.0%