Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Actually use relative paths when extracting #229

Merged
merged 1 commit into from
Dec 14, 2021
Merged

Conversation

sigmaSd
Copy link
Contributor

@sigmaSd sigmaSd commented Dec 9, 2021

In my testing this source_path.strip_prefix(Component::CurDir).unwrap_or(source_path) seems to only removes ./ but if a path is already canonicalized it will fail to remove it example: /home/user/.. -> fails to removes /home/user

By using the current_dir instead, it fixes the second case, but doesn't remove ./ which is maybe a good thing.

@marcospb19 marcospb19 merged commit 35a158e into ouch-org:master Dec 14, 2021
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