mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-05-07 12:40:04 +00:00
Refactor & Optimize: Launch target detection as soon as possible
Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
parent
4dae214af3
commit
b4c6db7cda
1 changed files with 3 additions and 3 deletions
|
@ -291,6 +291,9 @@ async fn entry(jobserver_client: LazyJobserverClient) -> Result<()> {
|
|||
bin_dir: opts.bin_dir.take(),
|
||||
};
|
||||
|
||||
// Launch target detection
|
||||
let desired_targets = get_desired_targets(&opts.targets);
|
||||
|
||||
// Initialize reqwest client
|
||||
let client = create_reqwest_client(opts.secure, opts.min_tls_version.map(|v| v.into()))?;
|
||||
|
||||
|
@ -318,9 +321,6 @@ async fn entry(jobserver_client: LazyJobserverClient) -> Result<()> {
|
|||
// Initialize UI thread
|
||||
let mut uithread = UIThread::new(!opts.no_confirm);
|
||||
|
||||
// Launch target detection
|
||||
let desired_targets = get_desired_targets(&opts.targets);
|
||||
|
||||
// Compute install directory
|
||||
let (install_path, custom_install_path) = get_install_path(opts.install_path.as_deref());
|
||||
let install_path = install_path.ok_or_else(|| {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue