cortesi / modd

A flexible developer tool that runs processes and responds to filesystem changes
MIT License
2.79k stars 130 forks source link

does not follow changes on files under symlinked folder #53

Open eminden opened 6 years ago

eminden commented 6 years ago

modd successfully catches changes with the following config as stated on the readme,

mydir/symlinkdir/** {
    prep: echo changed
}

but this is not working,

mydir/symlinkdir/some/another/folder/binaryfile {
    prep: echo changed
}

any suggestion?

cortesi commented 6 years ago

Hi there. Yes, this is a limitation that would be complicated to work around. We'd have to parse the matching pattern to detect whether it might be rooted over a symlink directory, and then rewrite the pattern on the fly to compensate.

For now, I suggest doing something like this:

mydir/symlinkdir **/some/another/folder/binaryfile {
    prep: echo changed
}

This adds the symlink directory to the match path, and then uses a broad match pattern to catch modifications within it.