mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-04-21 21:18:42 +00:00
Rename get_targets_from_rustc
to get_target_from_rustc
Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
parent
1d71f92ee6
commit
95b7c4f771
1 changed files with 2 additions and 2 deletions
|
@ -68,7 +68,7 @@ impl<'a> IntoIterator for &'a Targets {
|
|||
/// Check [this issue](https://github.com/ryankurte/cargo-binstall/issues/155)
|
||||
/// for more information.
|
||||
pub async fn detect_targets() -> Targets {
|
||||
if let Some(target) = get_targets_from_rustc().await {
|
||||
if let Some(target) = get_target_from_rustc().await {
|
||||
let mut v = Targets::from_array([target]);
|
||||
|
||||
#[cfg(target_os = "linux")]
|
||||
|
@ -99,7 +99,7 @@ pub async fn detect_targets() -> Targets {
|
|||
}
|
||||
|
||||
// Figure out what the host target is, from rustc or from this program's own build target
|
||||
async fn get_targets_from_rustc() -> Option<Box<str>> {
|
||||
async fn get_target_from_rustc() -> Option<Box<str>> {
|
||||
match Command::new("rustc").arg("-vV").output().await {
|
||||
Ok(Output { status, stdout, .. }) if status.success() => Cursor::new(stdout)
|
||||
.lines()
|
||||
|
|
Loading…
Add table
Reference in a new issue