[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Unison not syncing files under ~/.kde

On Sun, Mar 08, 2009 at 09:53:35AM +0530, Girish Kulkarni wrote:
> On Sun, Mar 8, 2009 at 9:21 AM, A. F. Cano wrote:
> >  ignorenot = Path afc/.kde/share/apps/kpilot   #this is a directory
> >  ignorenot = Path afc/.kde/share/apps/karm/karm.ics #individual file
> >  ignorenot = Path afc/.wine/user_files
> >
> > But these do not propagate.
> >
> >  ignore = Path afc/Desktop
> >  ignore = Name .*
> >  ignore = Name *.o
> Which Unison version are you using?  The Unison manual has the
> following to say about ignorenot:

Ah yes, forgot to be complete: 
unison version 2.27.57

>     "Note that the semantics of ignore and ignorenot is a little
>     counter-intuitive. When detecting updates, Unison examines paths
>     in depth-first order, starting from the roots of the replicas and
>     working downwards. Before examining each path, it checks whether
>     it matches ignore and does not match ignorenot; in this case it
>     skips this path and all its descendants. This means that, if some
>     parent of a given path matches an ignore pattern, then it will be
>     skipped even if the path itself matches an ignorenot pattern. In
>     particular, putting ignore = Path * in your profile and then using
>     t ignorenot to select particular paths to be synchronized will not
>     work. Instead, you should use the path preference to choose
>     particular paths to synchronize."

Well, I understand what this says, but it's a problem.  Of course, I
want to synchronize my home directory, all the regular (not .files)
files and sub-directories.  This can be dynamic, so it's not reasonable
to have to add every new subdirectory to the unison file via a separate

On the other hand, with the few exceptions noted, I don't want .config
files to be propagated as they reflect settings that might be different
and change on different computers.

> See --
> http://www.cis.upenn.edu/~bcpierce/unison/download/releases/stable/unison-manual.html#prefs
> In your case apparently .kde is ignored because its path matches an
> ignore criterion.  Then it doesn't matter even if some descendent of
> .kde matches a ignorenot criterion.

Yes, I've tried to add:

ignorenot = Path afc/.kde

with the predictable result that now all the files and directories under
.kde are fair game.  As those include desktop settings that change or
are different on different computers, lots of conflicts.

> A solution is to edit your ignore patterns to keep .kde safe.  (Use
> regexp maybe?)

I don't see how I can still not sync all .files, regardless of where
they are and be able to explicitely tell unison about specific files
under a .directory.  Am I missing something? or is this a severe
limitation worthy of a bug report?

I have also tried to make symbolic links to bypass the ".kde" in the

ln -s /home/afc/.kde/share/apps/karm /home/afc/karm

After adding "follow afc/karm" the files are copied, but this feels like
a kludgy work-around.  Still, it's better than the original behavior.

> HTH,
> Girish.

Thanks for answering.


Reply to: