git-parse icon indicating copy to clipboard operation
git-parse copied to clipboard

Rename paths with spaces not recognized correctly

Open flash1293 opened this issue 1 year ago • 2 comments

What happens?

In case of a PR renaming a file with spaces in the path, the old and new path of the change entry will be broken. Maybe similar to https://github.com/wayfair/git-parse/issues/63

What were you expecting to happen?

Should recognize them correctly

Reproducing the Bug

Check out https://github.com/vuejs/docs Try to parse commit bb9f97a9ca0acc7408e0c59750e712d94360f499

The diff via git show in the terminal:

diff --git a/src/.vuepress/public/images/sponsors/primevue copy.png b/src/public/images/sponsors/primevue copy.png
similarity index 100%
rename from src/.vuepress/public/images/sponsors/primevue copy.png
rename to src/public/images/sponsors/primevue copy.png

The diff entry via git-parse:

{
      "oldPath": "src/.vuepress/public/images/sponsors/primevue copy.png\tsrc/public/images/sponsors/primevue",
      "newPath": "copy.png"
    }

Environment

3.0.0 on MacOs

flash1293 avatar Sep 11 '22 16:09 flash1293

👋 Thanks for filing this issue!

So far I have been unable to reproduce the bug as described by cloning the vue docs and running:

gitToJs("../docs", {
	sinceCommit: "bb9f97a9ca0acc7408e0c59750e712d94360f499",
});

Can you please provide more specifics about how to recreate this issue? A minimal reproduction repo & script would be really helpful to track this down.

finn-orsini avatar Oct 06 '22 00:10 finn-orsini

Automatically marking issue as stale due to lack of activity

github-actions[bot] avatar Dec 11 '22 00:12 github-actions[bot]

Automatically closing this issue as stale

github-actions[bot] avatar Dec 25 '22 00:12 github-actions[bot]