Have you checked out the latest commit (952832147)?

These are apparently the "old" 2021 edition rules which are being
applied here - latest master is on the 2024 edition for some time now
[0]. The changes here are the exact reverse of some of the changes done
in the follow-up tree-wide formatting commit [1].

(Also, running `cargo fmt` on latest master does not produce any
changes, FWIW. So this should not be necessary - that's what caught me.)

[0] https://git.proxmox.com/?p=pve-installer.git;a=commitdiff;h=c305be5e
[1] https://git.proxmox.com/?p=pve-installer.git;a=commitdiff;h=a1575df4

On Tue Apr 22, 2025 at 6:27 PM CEST, Michael Köppl wrote:
> Signed-off-by: Michael Köppl <m.koe...@proxmox.com>
> ---
>  proxmox-auto-installer/src/utils.rs         |  6 +++---
>  proxmox-installer-common/src/options.rs     |  4 ++--
>  proxmox-tui-installer/src/views/bootdisk.rs | 10 +++++-----
>  3 files changed, 10 insertions(+), 10 deletions(-)
>
> diff --git a/proxmox-auto-installer/src/utils.rs 
> b/proxmox-auto-installer/src/utils.rs
> index 85a1f52..b1d8787 100644
> --- a/proxmox-auto-installer/src/utils.rs
> +++ b/proxmox-auto-installer/src/utils.rs
> @@ -1,4 +1,4 @@
> -use anyhow::{Context, Result, bail};
> +use anyhow::{bail, Context, Result};
>  use clap::ValueEnum;
>  use glob::Pattern;
>  use log::info;
> @@ -12,12 +12,12 @@ use crate::{
>      udevinfo::UdevInfo,
>  };
>  use proxmox_installer_common::{
> -    ROOT_PASSWORD_MIN_LENGTH,
> -    options::{FsType, NetworkOptions, ZfsChecksumOption, ZfsCompressOption, 
> email_validate},
> +    options::{email_validate, FsType, NetworkOptions, ZfsChecksumOption, 
> ZfsCompressOption},
>      setup::{
>          InstallBtrfsOption, InstallConfig, InstallFirstBootSetup, 
> InstallRootPassword,
>          InstallZfsOption, LocaleInfo, RuntimeInfo, SetupInfo,
>      },
> +    ROOT_PASSWORD_MIN_LENGTH,
>  };
>  use serde::{Deserialize, Serialize};
>
> diff --git a/proxmox-installer-common/src/options.rs 
> b/proxmox-installer-common/src/options.rs
> index 9271b8b..4b48130 100644
> --- a/proxmox-installer-common/src/options.rs
> +++ b/proxmox-installer-common/src/options.rs
> @@ -1,4 +1,4 @@
> -use anyhow::{Result, bail};
> +use anyhow::{bail, Result};
>  use regex::Regex;
>  use serde::{Deserialize, Serialize};
>  use std::net::{IpAddr, Ipv4Addr};
> @@ -552,7 +552,7 @@ mod tests {
>                  state: InterfaceState::Up,
>                  mac: "01:23:45:67:89:ab".to_owned(),
>                  addresses: Some(vec![
> -                    CidrAddress::new(Ipv4Addr::new(192, 168, 0, 2), 
> 24).unwrap(),
> +                    CidrAddress::new(Ipv4Addr::new(192, 168, 0, 2), 
> 24).unwrap()
>                  ]),
>              },
>          );
> diff --git a/proxmox-tui-installer/src/views/bootdisk.rs 
> b/proxmox-tui-installer/src/views/bootdisk.rs
> index 60d5316..9d228cc 100644
> --- a/proxmox-tui-installer/src/views/bootdisk.rs
> +++ b/proxmox-tui-installer/src/views/bootdisk.rs
> @@ -4,17 +4,17 @@ use std::{
>  };
>
>  use cursive::{
> -    Cursive, Vec2, View,
>      view::{Nameable, Resizable, ViewWrapper},
>      views::{
>          Button, Dialog, DummyView, LinearLayout, NamedView, PaddedView, 
> Panel, ScrollView,
>          SelectView, TextView, ViewRef,
>      },
> +    Cursive, Vec2, View,
>  };
>
>  use super::{DiskSizeEditView, FormView, IntegerEditView, TabbedView};
> -use crate::InstallerState;
>  use crate::options::FS_TYPES;
> +use crate::InstallerState;
>
>  use proxmox_installer_common::{
>      disk_checks::{
> @@ -22,9 +22,9 @@ use proxmox_installer_common::{
>          check_lvm_bootdisk_opts, check_zfs_raid_config,
>      },
>      options::{
> -        AdvancedBootdiskOptions, BTRFS_COMPRESS_OPTIONS, BootdiskOptions, 
> BtrfsBootdiskOptions,
> -        Disk, FsType, LvmBootdiskOptions, ZFS_CHECKSUM_OPTIONS, 
> ZFS_COMPRESS_OPTIONS,
> -        ZfsBootdiskOptions,
> +        AdvancedBootdiskOptions, BootdiskOptions, BtrfsBootdiskOptions, 
> Disk, FsType,
> +        LvmBootdiskOptions, ZfsBootdiskOptions, BTRFS_COMPRESS_OPTIONS, 
> ZFS_CHECKSUM_OPTIONS,
> +        ZFS_COMPRESS_OPTIONS,
>      },
>      setup::{BootType, ProductConfig, ProxmoxProduct, RuntimeInfo},
>  };



_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to