Unison's "ignorenot" parameter does not work

724 Views Asked by At

I have the following instruction in my unison profile:

ignore = Path node_modules
ignorenot = Path node_modules/scaffold

Easy enough, right? Except that it doesn't work. It keeps on ignoring the node_modules/scaffold folder.

I even tried it with a regex:

ignorenot = Regex /node_modules/scaffold/.*

So what's going on here? I'm running unison 2.48.4

1

There are 1 best solutions below

0
On

Apparently, when you ignore a directory, there is no way to un-ignore a descendant.

What you should do instead is ignore the directory's contents, and then un-ignore a specific child. This will work for example:

ignore = Path node_modules/*
ignorenot = Path node_modules/scaffold