Swiftpack.co - x13a/libproc-swift as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by x13a.
x13a/libproc-swift 0.1.6
Swift wrapper for libproc library.
⭐️ 3
🕓 2 years ago
.package(url: "https://github.com/x13a/libproc-swift.git", from: "0.1.6")

libproc-swift

Swift wrapper for libproc library.

Example

import Darwin
import Proc

func main() throws {

    // To get pid path:
    let path = try Proc.pidPath(getpid()).get()
    print(path)
    
    // To list all pids:
    let pids = try Proc.listAllPids().get()
    print(pids)
    
    // To get `proc_bsdinfo`:
    let info = try Proc.pidInfo(proc_bsdinfo.self, getpid(), 0).get()
    print(info)
}

main()

GitHub

link
Stars: 3
Last commit: 1 year ago
Advertisement: IndiePitcher.com - Cold Email Software for Startups

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics