diff --git a/git-filter-repo b/git-filter-repo index 9cce52ae..9cd79737 100755 --- a/git-filter-repo +++ b/git-filter-repo @@ -2987,11 +2987,14 @@ class RepoFilter(object): abort(_("GIT_DIR must be .git")) # Check for refname collisions + print("AQUI 1"); if config_settings.get(b'core.ignorecase', b'false') == b'true': + print("AQUI 2"); collisions = collections.defaultdict(list) for ref in refs: collisions[ref.lower()].append(ref) msg = "" + print(collisions) for ref in collisions: if len(collisions[ref]) >= 2: msg += " " + decode(b", ".join(collisions[ref])) + "\n" @@ -3001,8 +3004,10 @@ class RepoFilter(object): "filesystem since you have refs that differ in case only:\n" "%s") % msg) if config_settings.get(b'core.precomposeunicode', b'false') == b'true': + print("AQUI 3"); import unicodedata # Mac users need to have python-3.8 collisions = collections.defaultdict(list) + print(collisions) for ref in refs: strref = decode(ref) collisions[unicodedata.normalize('NFC', strref)].append(strref) diff --git a/t/t9390-filter-repo.sh b/t/t9390-filter-repo.sh index ce4ab0c0..4730f0c4 100755 --- a/t/t9390-filter-repo.sh +++ b/t/t9390-filter-repo.sh @@ -1361,7 +1361,7 @@ test_expect_success 'startup sanity checks' ' git config core.precomposeUnicode true && git update-ref refs/remotes/origin/lamé refs/heads/master && git update-ref refs/remotes/origin/lamé refs/heads/master && - git config core.ignoreCase true && + git show-ref && test_must_fail git filter-repo --path numbers 2>../err test_i18ngrep "Cannot rewrite history on a character normalizing" ../err && git update-ref -d refs/remotes/origin/lamé && @@ -1370,6 +1370,8 @@ test_expect_success 'startup sanity checks' ' ) ' +exit 2 + test_expect_success 'other startup error cases and requests for help' ' ( # prevent MSYS2 (Git for Windows) from converting the colon to