Add mapmerge 2 (#4645)

Adds TG's mapmerge2, a new TGM-compatible merger that handles things like dictionary expansion much better than the old tool, as well as supporting a git merge hook for map files.

This PR does not remove the old merger as this one is more annoying to setup.
This commit is contained in:
Lohikar
2018-06-01 15:54:51 -05:00
committed by Erki
parent 5397e798c6
commit 1d335dd9e9
19 changed files with 956 additions and 0 deletions

17
tools/hooks/python.sh Normal file
View File

@@ -0,0 +1,17 @@
#!/bin/bash
set -e
if command -v python3 >/dev/null 2>&1; then
PY=python3
else
PY=python
fi
PATHSEP=$($PY - <<'EOF'
import sys, os
if sys.version_info.major != 3 or sys.version_info.minor < 6:
sys.stderr.write("Python 3.6+ is required: " + sys.version + "\n")
exit(1)
print(os.pathsep)
EOF
)
export PYTHONPATH=tools/mapmerge2/${PATHSEP}${PYTHONPATH}
$PY "$@"