-
Notifications
You must be signed in to change notification settings - Fork 143
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Extend triple target to everything distributed by forc #667
Conversation
2ba1c68
to
24064ac
Compare
62341f0
to
feb64b0
Compare
src/target_triple.rs
Outdated
@@ -53,40 +53,37 @@ impl TargetTriple { | |||
} | |||
|
|||
pub fn from_component(component: &str) -> Result<Self> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we add a doc comment. feel free to tweak the below
/// Creates a target triple for the given component.
///
/// For components distributed by forc, uses the format "{os}_{architecture}".
/// For other components, uses the format "{architecture}-{vendor}-{os}".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool, done.
feb64b0
to
5bda149
Compare
1. forc-binaries, which is of the format "{os}_{arch}" 2. Everything else, which is the standard "{arch}-{vendor}-{os}" Currently, we only use the "{os}_{arch}" URL if the component is forc, however the forc-binaries tarball contains plugins and executables not defined in the forc component. This PR extends the "{os}_{arch}" result to everything distributed from forc.
5bda149
to
274463d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work!
Note: this is rebased on top of #666 👹
There are 2 types of downloads:
Currently, we only use the "{os}_{arch}" URL if the component is
forc
, however theforc-binaries
tarball contains plugins and executables not defined in theforc
component.This PR extends the "{os}_{arch}" result to everything distributed from
forc
.This fixes an issue found while investigating #654.