Skip to content

added support for windows file paths#60

Open
ribsey wants to merge 2 commits intoHBehrens:masterfrom
ribsey:master
Open

added support for windows file paths#60
ribsey wants to merge 2 commits intoHBehrens:masterfrom
ribsey:master

Conversation

@ribsey
Copy link

@ribsey ribsey commented Nov 29, 2022

I encountered a library with windows file paths and some of them had even the current working directory during the build added in front of the file path, like this:
D:\\stack\\targets\\ST\\STM32F0/HW-Abstraction.c:122
or this:
D:\\some\\other\\path\\D:\\stack\\targets\\ST\\STM32F0/HW-Abstraction.c:122

So with the new regex and the backslash to slash replacement, these paths get parsed as well.

and some paths, where the current directory was added befor the file path (only seen with windows paths)
@HBehrens
Copy link
Owner

Thank you for providing some more real-world data into the mix and providing a matching implementation, @ribsey 💪

@noahp I haven't look at the code in a while, do you know if this part does have tests already? With all of this regex shenanigans, I am worried we will (one day) introduce a regression during the attempt to add more features. If yes, adding the examples provided would be awesome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants