# Watching for file changes on macOS

DevFeed: [Watching for file changes on macOS](<https://devfeed.tech/articles/watching-for-file-changes-on-macos-51126.md>)

Original publisher: [Read original article](<https://alexwlchan.net/2026/watch-files-on-macos/>)

Published: 2026-05-11T06:41:24Z

Content type: tutorial

Language: en

Sources: [alexwlchan](<https://devfeed.tech/sources/alexwlchan.md>)

Topics: [macOS](<https://devfeed.tech/topics/macos.md>), [Filesystems](<https://devfeed.tech/topics/filesystems.md>), [Swift](<https://devfeed.tech/topics/swift.md>), [notifications](<https://devfeed.tech/topics/notifications.md>), [API](<https://devfeed.tech/topics/api.md>), [Python](<https://devfeed.tech/topics/python.md>), [Streams](<https://devfeed.tech/topics/streams.md>)

Tags: [api](<https://devfeed.tech/tags/api.md>), [blogging-about-blogging](<https://devfeed.tech/tags/blogging-about-blogging.md>), [file](<https://devfeed.tech/tags/file.md>), [macos](<https://devfeed.tech/tags/macos.md>), [notifications](<https://devfeed.tech/tags/notifications.md>), [python](<https://devfeed.tech/tags/python.md>), [script](<https://devfeed.tech/tags/script.md>), [swift](<https://devfeed.tech/tags/swift.md>)

## AI overview

A tutorial on using macOS FSEvents with a Swift script to detect file changes and pass notifications to Python, supporting live reload for a locally generated website.

## Source excerpt

I've written a Swift script that uses the FSEvents API to get notified of file changes, then I'm using stdout as a bridge to forward those notifications to Python.