Skip to content

Added OPEN and CLOSE events#202

Closed
betim wants to merge 1 commit intofsnotify:masterfrom
betim:master
Closed

Added OPEN and CLOSE events#202
betim wants to merge 1 commit intofsnotify:masterfrom
betim:master

Conversation

@betim
Copy link
Copy Markdown

@betim betim commented Mar 28, 2017

What does this pull request do?

Adds OPEN and CLOSE events from unix.*

Where should the reviewer start?

inotify.go and fsnotify.go

How should this be manually tested?

Add a folder with watcher.Add(...) then try to open/modify/write file.

@radu-munteanu
Copy link
Copy Markdown

You won't get that merge approved, as it only works with one OS. Check this thread: #191

@betim
Copy link
Copy Markdown
Author

betim commented Mar 28, 2017

@radu-munteanu, you mean it does not work in one OS?

I totally understand that fsnotify tends to be as cross-platform as possible. But not implementing something rather essential I cannot. Besides windows has file locking so combination of file locking and Op.Write event should give windows programmer freedom to implement the same functionality as getting Op.Close on linux.

@bevand10
Copy link
Copy Markdown

bevand10 commented Apr 29, 2017

@betim - I'd recommend switching to this fork as it'll better suit your needs by supporting IN_CLOSE_WRITE https://github.com/ericbrisrubio/fsnotify

@Dmitry-N-Medvedev
Copy link
Copy Markdown

@bevand10, Dave, if there is no IN_CLOSE_WRITE or similar operation how would one implement processing of newly created or changed files? I personally, being a nub tho, don't know how that could be implemented.

Without CLOSE operation the fsnotify seems to have next to now real-world application at all.

@betim
Copy link
Copy Markdown
Author

betim commented May 2, 2017

@bevand10 - I'm using my own fork for this, it works very well.

@nathany
Copy link
Copy Markdown
Contributor

nathany commented Aug 30, 2018

Thanks for the PR. We would like to spin out a inotify package with support for all OS features on Linux, but fsnotify itself needs a common API across every OS.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants