Skip to content

Conversation

cedricbuild
Copy link

fixes #1577

.map(|p| {
let path = Path::new(p);
let relative_path = if path.is_absolute() {
let cwd = env::current_dir().unwrap_or("".into());
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This won't work if one or more search paths is given to fd, since it needs to be relative to the search path, which may not be the current directory.

.exclude
.iter()
.map(|p| {
let path = Path::new(p);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It isn't a path, it's a pattern.

What if there is a glob that occurs between the root and the search path?

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.

exclude and absolute path as argument

2 participants