[Unison-hackers] Ignore files above a certain size

Benjamin C. Pierce bcpierce at cis.upenn.edu
Thu Mar 7 09:05:57 EST 2013


An even easier way is to deal with such files at reconciliation time.  We've already got mechanisms and preferences for overriding Unison's default reconciliation decisions based on many sorts of conditions (which file is newer, etc.).  The downside is that large files will not, then, be completely ignored -- they will show up in the user interface as conflicts.

Arguably, the right thing to do is to truly ignore such files.  This will be a bit harder to implement, since it will have to start with generalizing the current ignore mechanism to take into account current information from the filesystem beyond just path names.  And it will require a bit of care in reconciliation (because a file may then be ignored on one side and not the other and we'll want to make sure we correctly detect this situation and don't do something silly like delete one of the copies) and in the UI (because we'll have to report such situations to the user in some sensible way), as well as some thinking at the level of the formal spec to make sure that we can make sense out of such possibilities.  But if we can figure out how to do it nicely, it would open the door to all sorts of further extensions that people have been asking for for years, like per-directory .unisonignore files.

    - B

On Mar 7, 2013, at 6:21 AM, Alan Schmitt <alan.schmitt at polytechnique.org> wrote:

> Hello,
> 
> I've been asked to add a feature to Unison: ignore the files that are
> greater than a certain size. I've looked at the code and it seems the
> least invasive way to do it is to have such file create an Error during
> update detection. What do you think of this approach?
> 
> Best,
> 
> Alan
> _______________________________________________
> Unison-hackers mailing list
> Unison-hackers at lists.seas.upenn.edu
> http://lists.seas.upenn.edu/mailman/listinfo/unison-hackers



More information about the Unison-hackers mailing list