+use std::io::IsTerminal;
use std::path::PathBuf;
use std::process::Command;
use std::{collections::HashMap, path::Path};
use proxmox_offline_mirror::types::Snapshot;
use proxmox_subscription::{ProductType, SubscriptionInfo};
use proxmox_sys::command::run_command;
+use proxmox_sys::fs::file_get_contents;
use proxmox_sys::fs::{replace_file, CreateOptions};
-use proxmox_sys::{fs::file_get_contents, linux::tty};
use proxmox_time::epoch_to_rfc3339_utc;
use serde_json::Value;
)]
/// Interactive setup wizard.
async fn setup(_param: Value) -> Result<(), Error> {
- if !tty::stdin_isatty() {
+ if !std::io::stdin().is_terminal() {
bail!("Setup wizard can only run interactively.");
}
use std::fmt::Display;
+use std::io::IsTerminal;
use std::matches;
use std::path::Path;
use proxmox_schema::api;
use proxmox_section_config::SectionConfigData;
use proxmox_subscription::ProductType;
-use proxmox_sys::linux::tty;
use proxmox_offline_mirror::helpers::tty::{
read_bool_from_tty, read_selection_from_tty, read_string_from_tty,
)]
/// Interactive setup wizard.
async fn setup(config: Option<String>, _param: Value) -> Result<(), Error> {
- if !tty::stdin_isatty() {
+ if !std::io::stdin().is_terminal() {
bail!("Setup wizard can only run interactively.");
}