Under windows programming, there's win32 api that allow us to monitor the status of a file or a directory: when changed, there's event notification for a user callback function. E.g. when creating a directory in one explorer window, other explorer window related with this directory will also be refreshed.
My question: how to do this on linux? Does linux provide any sytem call or posix api or shell command to monitory a file/directory?
I know git can do it, but how does git made it?
Thanks!
The equivalent Linux API is inotify: