/SwiftFolderMonitor

Monitor changes to a folder in your filesystem.

Primary LanguageSwift

Swift File Monitor

Monitor a directory in your filesystem for changes.

let url = NSURL(fileURLWithPath: "~/Desktop".stringByExpandingTildeInPath)!
let monitor = FolderMonitor(url: url, handler: {
    println("Found change")
})

You can also pause and resume getting callbacks. Don't worry about balancing calls to start and stop. I took care of that for you. ;)

monitor.start()
monitor.stop()

Inspiration