Skip to content

Conversation

@matklad
Copy link
Contributor

@matklad matklad commented Aug 5, 2020

current_dir and relative paths to executables works differently on
unix and windows (unix behavior does not make sense), see:

https://github.com/oconnor663/duct.rs/blob/17e30e83a16b202551df4d70d0b2cc174cb53e5d/src/lib.rs#L295-L324

The original motivation to set cwd was to make rustfmt read the
correct rustfmt.toml, but that was future proofing, rather than a bug
fix.

So, let's just remove this and see if breaks or fixes more use-cases.

If support for per-file config is needed, we could use --config-path
flag.

bors r+
🤖

`current_dir` and relative paths to executables works differently on
unix and windows (unix behavior does not make sense), see:

https://github.com/oconnor663/duct.rs/blob/17e30e83a16b202551df4d70d0b2cc174cb53e5d/src/lib.rs#L295-L324

The original motivation to set cwd was to make rustfmt read the
correct rustfmt.toml, but that was future proofing, rather than a bug
fix.

So, let's just remove this and see if breaks or fixes more use-cases.

If support for per-file config is needed, we could use `--config-path`
flag.
@bors
Copy link
Contributor

bors bot commented Aug 5, 2020

@bors bors bot merged commit 2ad29eb into rust-lang:master Aug 5, 2020
@matklad matklad deleted the relfmt branch August 5, 2020 13:49
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.

1 participant