Skip to content

Latest commit

 

History

History
22 lines (17 loc) · 297 Bytes

README.md

File metadata and controls

22 lines (17 loc) · 297 Bytes

Swift-Daemon

You can daemonize any swift process. Daemon can detach your swift script from shell.

import Foundation
import Daemon

DispatchQueue(label: "foo").async {
    while true {
        print(".")
        sleep(1)
    }
}

Daemon.daemonize()

while true {
    sleep(1)
}