Skip to content
This repository was archived by the owner on Sep 11, 2020. It is now read-only.

Normalize filenames before comparing. #526

Merged
merged 2 commits into from
Aug 2, 2017
Merged

Normalize filenames before comparing. #526

merged 2 commits into from
Aug 2, 2017

Conversation

joshbetz
Copy link
Contributor

Some multibyte characters can have multiple representations. Before
comparing strings, we need to normalize them. In this case we're
normalizing to normalized form C, but it shouldn't matter as long as
both strings are normalized to the same form.

Fixes #495

Some multibyte characters can have multiple representations. Before
comparing strings, we need to normalize them. In this case we're
normalizing to normalized form C, but it shouldn't matter as long as
both strings are normalized to the same form.

Fixes #495
@mcuadros
Copy link
Contributor

mcuadros commented Aug 1, 2017

Can you add some tests? Also maybe can we use norm only for Darwin?

@codecov
Copy link

codecov bot commented Aug 1, 2017

Codecov Report

Merging #526 into master will decrease coverage by 0.5%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #526      +/-   ##
==========================================
- Coverage   78.12%   77.62%   -0.51%     
==========================================
  Files         129      130       +1     
  Lines        9746     9710      -36     
==========================================
- Hits         7614     7537      -77     
- Misses       1304     1360      +56     
+ Partials      828      813      -15
Impacted Files Coverage Δ
utils/merkletrie/noder/path.go 100% <100%> (ø) ⬆️
plumbing/transport/ssh/common.go 20.54% <0%> (-45.21%) ⬇️
plumbing/transport/ssh/auth_method.go 33.33% <0%> (-24.77%) ⬇️
remote.go 73.5% <0%> (-0.14%) ⬇️
repository.go 74.62% <0%> (-0.11%) ⬇️
plumbing/reference.go 69.84% <0%> (ø) ⬆️
worktree_darwin.go 100% <0%> (ø)
config/config.go 88% <0%> (+0.93%) ⬆️
plumbing/format/config/option.go 100% <0%> (+10.41%) ⬆️
plumbing/format/config/section.go 87.17% <0%> (+17.79%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a0885c5...5c1a2ec. Read the comment docs.

@mcuadros
Copy link
Contributor

mcuadros commented Aug 2, 2017

@joshbetz I just updated your PR with a proper tests, I understand that is hard to do testing, since is a complex project. Thanks a lot for your PR, as soon as the CI, this PR will be merged.

@mcuadros mcuadros merged commit 3713791 into src-d:master Aug 2, 2017
@joshbetz joshbetz deleted the fix/filename-form branch August 2, 2017 15:50
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants