rustup icon indicating copy to clipboard operation
rustup copied to clipboard

Add safe-directories.

Open ehuss opened this issue 3 years ago • 6 comments
trafficstars

This is an implementation of RFC 3279.

ehuss avatar Jun 12 '22 01:06 ehuss

Questions/Notes:

  • I did not add any sort of "unstable" flag to enable this feature. Which approach do you think would be good?

    • Merge this on a separate branch, and create a testing release from that?
    • Merge on master, and revert it if a release needs to be made before we commit to this feature?
    • Add some unstable gate, such as a CLI flag or environment variable like RUSTUP_UNSTABLE_SAFE_DIRECTORIES=true to mirror the Cargo one. This might be the most desirable, but requires changing a bunch of things to support it.
  • Should I bump DEFAULT_METADATA_VERSION? I think the only consequence of not doing that is that an older version of rustup may delete the safe_directories settings. If it is bumped, then older rustups will just fail, which seems worse.

  • I can't tell why some code uses macros like info! and others use a Notification.

  • I can't tell why some code is in rustup_mode.rs and some is in common.rs.

  • The ownership checking code is copied from Cargo until a new cargo_util is published.

ehuss avatar Jun 12 '22 01:06 ehuss

How did the cargo part of this go Eric? I'm reluctant to start validating this until we know Cargo makes sense.

kinnison avatar Aug 27 '22 10:08 kinnison

I need to follow up on some things, and I have been procrastinating. 🐌

ehuss avatar Aug 30 '22 23:08 ehuss