| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
|
|
|
|
| |
that doesn't exist, or cannot be read
The problem is its use of unsafeInterleaveIO, which causes its IO code
to run when the thunk is forced, outside any exception trapping the caller
may do.
|
|
|
|
|
|
|
|
|
| |
Not yet tested and places git-annex-shell is run need to be modified to
pass the new field settings.
Note that rsyncServerSend was changed to fork, rather than directly exec
rsync, because it needs to keep the transfer lock held, and clean up the
transfer log when done.
|
| |
|
| |
|
| |
|
|\ |
|
| |
| |
| |
| |
| | |
Its truncation behavior is a red flag, so avoid using it in these places
where only raw ByteStrings are used, without looking at the data inside.
|
| |
| |
| |
| | |
My, GHC makes this hard.
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| | |
Handle kevent interruptions in the haskell code, so it can yield to other threads
|
| |
| |
| |
| | |
new event dispatch seems a bit broken though
|
| |
| |
| |
| |
| | |
Kqueue code for dispatching events is not tested and probably doesn't
build.
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This *may* now return Add or Delete Changes as appropriate. All I know
for sure is that it compiles.
I had hoped to avoid maintaining my own state about the content of the
directory tree, and rely on git to check what was changed. But I can't;
I need to know about new and deleted subdirectories to add them to the
watch list, and git doesn't deal with (empty) directories.
So, wrote all the code to scan directories, remember their past contents,
compare with current contents, generate appropriate Change events, and
update bookkeeping info appropriately.
|
| | |
|
| |
| |
| |
| | |
Many thanks to geekosaur in #haskell for help with this.
|
| | |
|
| | |
|
| |
| |
| |
| |
| | |
Have not tried to build this yet. But barring minor mistakes, I think it's
good.
|
| |
| |
| |
| | |
Will need to update the DirMap to add or remove subdirs.
|
| | |
|
| | |
|
|/ |
|
|
|
|
|
|
| |
Could not reproduce the build failure I had seen related to this,
but the numbers were wrong with statfs64. Probably pulling from the wrong
place in the structure. statvfs seems to work..
|
| |
|
|
|
|
|
| |
Check for it in configure; and add a --force option for people without it
who want to live dangerously.
|
|
|
|
|
|
| |
elsewhere
+d is probably more expensive, but I need it
|
| |
|
|
|
|
| |
need to truncate, or part of previous longer pid may be left after writing
|
|
|
|
| |
Uses lsof -F0 to get machine-readable output
|
| |
|
|
|
|
|
| |
Including support for unbound thread sleeping. Haskell's max thread sleep
is 37 minutes, due to maxBound Int!
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The idea, not yet done, is to use this to detect when a file
has an old change time, and avoid expensive restaging of the file.
If git-annex watch keeps track of the last time it finished a full scan,
then any symlink that is older than that time must have been scanned
before, so need not be added. (Relying on moving, copying, etc of a file
all updating its change time.)
Anyway, this info is available for free since inotify already checks it,
so it might as well make it available.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now really only done in the startup scan.
It turns out to be quite hard for event handlers to know when the startup
scan is complete. I tried to make addWatch pass that info, but found
threading the state very difficult. For now, a quick hack, using the fast
flag.
Note that it's actually possible for inotify events to come in while the
startup scan is still ongoing. Due to my hack, the expensive check will
be done for files added in such inotify events.
|
|
|
|
|
|
| |
This requires a relatively expensive test at file add time to see if it's
in git already. But it can be optimised to only happen during the startup
scan.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Ok, that's odd.. opening it before fork breaks the locking.
I don't understand why.
|
|
|
|
|
| |
Writes pid to a file. Is supposed to take an exclusive lock, but that's not
working, and it's too late for me to understand why.
|
| |
|
| |
|
| |
|