Skip to content

Version height computed to be 0 when project is built with path with non-canonical casing #618

@AArnott

Description

@AArnott

When a project's repo-relative path is reported as a/b but git records it as A/b, we fail to walk the tree in searching for version.json files. If the version.json file appears under that path, we can end up with a version height of 0:

The failing line is:

tree = this.Context.Repository.GetTreeEntry(tree, GitRepository.Encoding.GetBytes(directoryName));

We should probably have a fallback path here where we allow for case-insensitive matches when the git settings for the repo indicate case insensitivity is preferred.

We should add an automated test that runs against both managed and libgit2 implementations.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions