newren/git-filter-repo

Correct docs to suggest always using trailing slashes for directories with `--path-rename`

Open

#358 opened on Apr 11, 2022

View on GitHub
 (2 comments) (1 reaction) (0 assignees)Python (674 forks)batch import
docsgood first issue

Repository metrics

Stars
 (6,745 stars)
PR merge metrics
 (Avg merge 44d 2h) (1 merged PR in 30d)

Description

stitny~/r/nntplib (main)$ git --version
git version 2.35.1
stitny~/r/nntplib (main)$ git filter-repo --version
22826b5a68b6
stitny~/r/nntplib (main)$ git filter-repo --debug --path Doc/library/nntplib.rst --path Lib/nntplib.py --path Lib/test/test_nntplib.py --path-rename Doc/library: --path-rename Lib/test: --path-rename Lib:
[DEBUG] Passed arguments:
Namespace(analyze=False, blob_callback=None, commit_callback=None, debug=True, dry_run=False, email_callback=None, filename_callback=None, force=False, help=False, inclusive=True, mailmap=None, max_blob_size=0, message_callback=None, name_callback=None, no_ff=False, partial=False, path_changes=[('filter', 'match', b'Doc/library/nntplib.rst'), ('filter', 'match', b'Lib/nntplib.py'), ('filter', 'match', b'Lib/test/test_nntplib.py'), ('rename', 'match', [b'Doc/library', b'']), ('rename', 'match', [b'Lib/test', b'']), ('rename', 'match', [b'Lib', b''])], preserve_commit_encoding=False, preserve_commit_hashes=False, prune_degenerate='auto', prune_empty='auto', quiet=False, refname_callback=None, refs=['--all'], repack=True, replace_message=None, replace_refs=None, replace_text=None, report_dir=None, reset_callback=None, source=None, state_branch=None, stdin=False, strip_blobs_with_ids=set(), subdirectory_filter=None, tag_callback=None, tag_rename=None, target=None, to_subdirectory_filter=None, use_base_name=False, version=False)
[DEBUG] Migrating refs/remotes/origin/* -> refs/heads/*
[DEBUG] Removing 'origin' remote (rewritten history will no
        longer be related; consider re-pushing it elsewhere.
[DEBUG] Running: git fast-export --show-original-ids --signed-tags=strip --tag-of-filtered-object=rewrite --fake-missing-tagger --reference-excluded-parents --no-data --use-done-feature --mark-tags --reencode=yes --all
  (saving a copy of the output at .git/filter-repo/fast-export.original)
[DEBUG] Running: git -c core.ignorecase=false fast-import --force --quiet --date-format=raw-permissive
  (using the following file as input: .git/filter-repo/fast-export.filtered)
Parsed 1 commitsfatal: Empty path component found in input
fast-import: dumping crash report to .git/fast_import_crash_31798
Traceback (most recent call last):
  File "/usr/libexec/git/git-filter-repo", line 4004, in <module>
    main()
  File "/usr/libexec/git/git-filter-repo", line 4001, in main
    filter.run()
  File "/usr/libexec/git/git-filter-repo", line 3936, in run
    self._parser.run(self._input, self._output)
  File "/usr/libexec/git/git-filter-repo", line 1409, in run
    self._parse_commit()
  File "/usr/libexec/git/git-filter-repo", line 1260, in _parse_commit
    self._commit_callback(commit, aux_info)
  File "/usr/libexec/git/git-filter-repo", line 3483, in _tweak_commit
    if not self._prunable(commit, new_1st_parent,
  File "/usr/libexec/git/git-filter-repo", line 3239, in _prunable
    self._output.flush()
  File "/usr/libexec/git/git-filter-repo", line 2721, in flush
    self.file1.flush()
BrokenPipeError: [Errno 32] Broken pipe
stitny~/r/nntplib (main)$

Using openSUSE/Tumbleweed packages.

fast_import_crash_32751

Contributor guide