Not sure exactly where the bug lies, but I just triggered a bug trying to use UpdateFromUpstream.sh.
Essentially, it seems to be triggered if your CWD when you execute the script has a symlink as part of the path, in my case:
~/projects/src/ITK/Modules/ThirdParty/MINC #projects is a symlink
This broke UpdateFromUpstream.sh in such a way that it couldn’t merge properly and ended up modifying the top-level CMakeLists.txt.
If instead I de-referenced the symlink so my CWD was real:
> cd $(realpath .) #now in /data/chamal/projects/gabriel/src/ITK/Modules/ThirdParty/MINC
All is well.