From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from shymkent.ilbers.de ([unix socket]) by shymkent (Cyrus 2.5.10-Debian-2.5.10-3+deb9u2) with LMTPA; Thu, 27 Mar 2025 11:32:23 +0100 X-Sieve: CMU Sieve 2.4 Received: from mail-pl1-f183.google.com (mail-pl1-f183.google.com [209.85.214.183]) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPS id 52RAWLFP004526 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 27 Mar 2025 11:32:22 +0100 Received: by mail-pl1-f183.google.com with SMTP id d9443c01a7336-227a8cdd272sf15104175ad.2 for ; Thu, 27 Mar 2025 03:32:22 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1743071535; cv=pass; d=google.com; s=arc-20240605; b=Lg4x/EOqfrRZLFeoK3tdvzimMfT+hY6jfLV/22pvQ7JApsjA8xY+O7rQOGO1JjSI5+ JwRKU22mgBTxLcKgR7IB9etw5hchS+4UhV2aWbWwu1W+4YsHW8zXWrEQYU+HfruaeuCg abqHcrlJ0HShyAT4jCemUNaKxECDbVSrh8zbKFgiKlfzapbeEAnabYSd6RakjjVqyKKR NH0riQz652yjEXZHQEda1WnLQkCIejdfD5MHQX7OqbfCTnV408IRAq3hnmVYtqbaKh4k +kP1Ebz+ICoP6ScH6z1CGHUlof0+J5RcgKr6Cke79evTWd5TWs7W6SqOTblgk+ro0vHY 5dYA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:mime-version:user-agent :content-transfer-encoding:references:in-reply-to:date:to:from :subject:message-id:sender:dkim-signature; bh=1rWM547im0VZtH8xKLPEzTT/LcERKSZCJRAS7cp3BNI=; fh=Nv4yFWBDxEz4BPO6dVVLPvy+KKPuhzuxPrWNo6dyB1o=; b=l0Mx92kMFEZSEr3mxhYumWg66nMCdneVMk5xLSnE4mcBllGbjdEf36yk/elqVAT62O gc0PqzhxV/4KsTtLODd1kG9nC6KPC+N9vvg1yaQEaijuDe6NyFM3DdZz6JLanoHVNPWi 8yxf+ij7i39RffWZh5caq7p4qA0qlBmfZuSnBUyTK/V9j8XHNlJF5mA6dCXXWygWkomp rMAqrNII52ZzzNNAp1S2WPx+MJFQ6T6YaeoXSI7BXOqf5pRWbHrjglcS4v5E5cevlnFR kH9GbRxzTm719wxWm1g/bOJTbPuYv64bTnLF74vNyXgF6Gh2eifqqW+KL1fllwTgiNr2 d7MQ==; darn=ilbers.de ARC-Authentication-Results: i=2; gmr-mx.google.com; spf=pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=ubely@ilbers.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1743071535; x=1743676335; darn=ilbers.de; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:x-original-authentication-results :x-original-sender:mime-version:user-agent:content-transfer-encoding :references:in-reply-to:date:to:from:subject:message-id:sender:from :to:cc:subject:date:message-id:reply-to; bh=1rWM547im0VZtH8xKLPEzTT/LcERKSZCJRAS7cp3BNI=; b=r9Sc9Ei+1NOaNGNgO4nux8gEZ3jbeuIgZY32GnuByeMJBnFdWlHwISkMH+R4/d65NK IHREPdh4SDtHMF9LbpRf8oCsO/pr3938qKmLpVpyDQHCLp3ScI2eg0MmcsjJo3CeaaMw yQmyIjKPd0P4snVAYmi9VqIgGfkqZtaPrHCBFEpDho26cyujjzqJMr+pZjuc/rOvLRFw x6CIXcQMZdO9nIpeztEf/rEC6TFavJyWwHHASpzc8Xg1wg85yt0ykzU+mYo+sIOYoUSj atqDn8gJ0/o0cEUfLaKsA12EBKhTVgXUKBbUJ4gf4v9WpWsjjqf8V4x+lvdwUedl9zV4 Jzaw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743071535; x=1743676335; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender:mime-version :user-agent:content-transfer-encoding:references:in-reply-to:date:to :from:subject:message-id:x-beenthere:x-gm-message-state:sender:from :to:cc:subject:date:message-id:reply-to; bh=1rWM547im0VZtH8xKLPEzTT/LcERKSZCJRAS7cp3BNI=; b=XgWNX4VyGT6RxJm+fYbasg7jWjYRNzlcjMLRUT8CIi0Zb5AnIRjQqemyrvkdDlQ29n RZwoqNbAYM5Fe1o5J2QSms1Zajb+/uJKrkKkU85+dARobZ36tNtM8+KojzkBVsl8RI2x n7je16YW3LI+KrBnTPoSoTC12cgOkvNSerd7WDKT5+rnAe74vQ5MJ5PpowvxZCJKI8wk Rf/5SFgdOKrzbudJhqfy8iBWpxKVXlTWYTasF/OpA2u8u6eb4akciiKtAM9Kpm4QbG/d YCR1AZVc+OHl39af3jgNqequnZpWlCSYOxmaYmCLM+Y1kIIviHd3qzKNchBZTcgWc8O/ D98g== Sender: isar-users@googlegroups.com X-Forwarded-Encrypted: i=2; AJvYcCU1E53CNdLgrdgm8UdEyLwZkJoflLrBlpH/qu/xc0sSZ2TDFTJSj/0OIsqS3aLf6HahhsHh@ilbers.de X-Gm-Message-State: AOJu0YwYch3ognD+PPNB+B7xQOhlWSQaoiVBJGx8iIiPAGBRrw2cUGnf wo+DyraP9cq30UrW3H34I+5QLzzf+D/GcVvg7dWm47TcvS8ZduCi X-Google-Smtp-Source: AGHT+IFuyBvKK06Ji/cOqniPuPQHhGsrXGU6dM5zBxw8C29z9D6c0kIVqy96rpPzaI05mtJsCYimWg== X-Received: by 2002:a05:6a00:ac4:b0:736:2ff4:f255 with SMTP id d2e1a72fcca58-739610a5471mr3741858b3a.15.1743071535283; Thu, 27 Mar 2025 03:32:15 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com; h=ARLLPAJWKpEkYMwodqkgaqT/FgR37hBBLInnXpgcbA0XhPVIVQ== Received: by 2002:aa7:91d2:0:b0:732:d98:9b2e with SMTP id d2e1a72fcca58-73960de5775ls704461b3a.0.-pod-prod-04-us; Thu, 27 Mar 2025 03:32:13 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCVpTz02J8PaJ0hv6+rufwjXyFLZismyl4MaM/FxDyqrzhCsWM2ASp1y4EYpCYUJTZBf3bHNrf8zpGhN@googlegroups.com X-Received: by 2002:a05:6a00:4b10:b0:736:a4ca:62e1 with SMTP id d2e1a72fcca58-73960e30196mr3815947b3a.6.1743071533519; Thu, 27 Mar 2025 03:32:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1743071533; cv=none; d=google.com; s=arc-20240605; b=esisZRJHKxhhEZTRQ7Hey8VRxcRIaeypw3bcIbHlCa8PNUUBTA8aXRZUJJS387zmhC d1AvBxIRx0FWE3die7LiM94jegjYXQfFQvsnxOByYzEG1sAlRY5xJRTXdGq9EEI4MWbz 8olLqdoupvEvNALCqVnVb5iolFGmLUBjEYLkbcGVS0f/0IxYgAxIdW5dx/NjhqncEkyG 9JtgS/9tgMQcqdYNNGbyqnEWgyeTBz0AFYbFW+eIrBT8Tgcqg9ECvaKNgkqzrkIFA/ux cQo8BRidRADOcEeH/CwtlgZe5/1RXcBZPRCG3lKnoSg/M21eqaEbS7tsqaQYRuOXCmHe Tb0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id; bh=1n+33VbadqFITiqKxZtSW7NdKU5OCma42ZGe5JQ43vg=; fh=xEaguVBF0tSuSVpJYsv0jH295li1pT99R8G73C5QyKg=; b=fZhq9uVnSaqwIxm7MfC+48CpQtjCHVS2k5G5vIzPA0dtF2sKidxdaTsiGWBTGWGtBz KORQUM1o0H3yD9OmtgPv4rh3I3iQ76hAHLYxTV85F/DtzSefwLB8mWfmgYoZWTmHRmaP E/dUZ4jXANE3cjXlzPsvrOSKNgME/vdhIvv37dzz0rH5toYr9vyDTyL3KIBmiiJU1OaW pD+f9Q6FlaciEk1FMbIMX8SE4BI55oOG15nyKDD5mI+5zCIkjztCKDwCmvyDX1N3d8iV suZRb1J78tmP5XHYkHoWnTPVJhlB84t6zd4wJIVoW0wENsgQyptsVBAkYBAPJxSArwts /sEQ==; dara=google.com ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=ubely@ilbers.de Received: from shymkent.ilbers.de (shymkent.ilbers.de. [85.214.156.166]) by gmr-mx.google.com with ESMTPS id 41be03b00d2f7-af93315493asi24379a12.0.2025.03.27.03.32.12 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 27 Mar 2025 03:32:13 -0700 (PDT) Received-SPF: pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) client-ip=85.214.156.166; Received: from [127.0.0.1] (host-80-81-17-52.static.customer.m-online.net [80.81.17.52]) (authenticated bits=0) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPSA id 52RAW8i8004517 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 27 Mar 2025 11:32:10 +0100 Message-ID: <4627b14fa88b52d3723c7675b8d5fa4febb539c9.camel@ilbers.de> Subject: Re: [PATCH v5] isar-installer: show progress bar during bmaptool copy process From: Uladzimir Bely To: Kasturi Shekar , isar-users@googlegroups.com Date: Thu, 27 Mar 2025 13:32:08 +0300 In-Reply-To: <20250319094251.604338-1-kasturi.shekar@siemens.com> References: <20250319094251.604338-1-kasturi.shekar@siemens.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.56.0 (by Flathub.org) MIME-Version: 1.0 X-Spam-Status: No, score=-4.6 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,RCVD_IN_RP_CERTIFIED,RCVD_IN_RP_RNBL,RCVD_IN_RP_SAFE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shymkent.ilbers.de X-Original-Sender: ubely@ilbers.de X-Original-Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=ubely@ilbers.de Precedence: list Mailing-list: list isar-users@googlegroups.com; contact isar-users+owners@googlegroups.com List-ID: X-Spam-Checked-In-Group: isar-users@googlegroups.com X-Google-Group-Id: 914930254986 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , X-TUID: xrEJ8EbXV+Tm On Wed, 2025-03-19 at 15:12 +0530, 'Kasturi Shekar' via isar-users wrote: > - Added support for a progress gauge using a named pipe to capture > and display > =C2=A0percentage progress when using `bmaptool`. > - The progress bar is displayed only when the `bmaptool` version is > 3.8 or above, > =C2=A0as versions prior to 3.8 has some issues with `--psplash-pipe` flag= . > - For `bmaptool` versions below 3.8, the image copy process continues > without a > =C2=A0progress bar to maintain compatibility. > - The gauge uses `dialog --gauge` to dynamically update the progress > based on > =C2=A0output from the `bmaptool` process. >=20 > Signed-off-by: Kasturi Shekar > --- > =C2=A0.../files/usr/bin/deploy-image-wic.sh=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0 | 38 > ++++++++++++++++++- > =C2=A01 file changed, 37 insertions(+), 1 deletion(-) >=20 > diff --git a/meta-isar/recipes-installer/deploy- > image/files/usr/bin/deploy-image-wic.sh b/meta-isar/recipes- > installer/deploy-image/files/usr/bin/deploy-image-wic.sh > index 7f552eee..66c35506 100755 > --- a/meta-isar/recipes-installer/deploy-image/files/usr/bin/deploy- > image-wic.sh > +++ b/meta-isar/recipes-installer/deploy-image/files/usr/bin/deploy- > image-wic.sh > @@ -149,7 +149,43 @@ if ! $installer_unattended; then > =C2=A0=C2=A0=C2=A0=C2=A0 clear > =C2=A0fi > =C2=A0 > -if ! bmaptool copy ${bmap_options} "$installer_image_uri" > "${installer_target_dev}"; then > +# Function to compare version numbers > +version_ge() { > +=C2=A0=C2=A0=C2=A0 if [ "$(printf '%s\n' "$1"X "$2" | sort -V | head -n = 1)" !=3D > "$1"X ]; then > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 return 0 > +=C2=A0=C2=A0=C2=A0 else > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 return 1 > +=C2=A0=C2=A0=C2=A0 fi > +} > + > +# Get bmap-tools version > +bmap_version=3D$(bmaptool --version | awk '{ print $NF }') > + > +if version_ge "$bmap_version" "3.8"; then > +=C2=A0=C2=A0=C2=A0 # Create a named pipe for progress communication > +=C2=A0=C2=A0=C2=A0 progress_pipe=3D"/tmp/progress" > +=C2=A0=C2=A0=C2=A0 if ! mkfifo "$progress_pipe"; then > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 echo "Error: Failed to create= named pipe $progress_pipe" > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 exit 1 > +=C2=A0=C2=A0=C2=A0 fi > + > +=C2=A0=C2=A0=C2=A0 # Add psplash pipe to bmap_options > +=C2=A0=C2=A0=C2=A0 bmap_options=3D"$bmap_options --psplash-pipe=3D$progr= ess_pipe" > +=C2=A0=C2=A0=C2=A0 quiet_flag=3D"-q" > + > +=C2=A0=C2=A0=C2=A0 # Initialize the dialog gauge and update it dynamical= ly > +=C2=A0=C2=A0=C2=A0 ( > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 while true; do > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if re= ad -r line < "$progress_pipe"; then > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0 percentage=3D$(echo "$line" | awk '{ print $2 }') > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0 echo "$percentage" > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 fi > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 done > +=C2=A0=C2=A0=C2=A0 ) | dialog --gauge "Flashing image, please wait..." 1= 0 70 0 & > + > +fi > + > +if ! bmaptool ${quiet_flag} copy ${bmap_options} > "$installer_image_uri" "${installer_target_dev}"; then > =C2=A0=C2=A0=C2=A0=C2=A0 exit 1 > =C2=A0fi > =C2=A0 > --=20 > 2.39.5 Applied to next, thanks. --=20 Best regards, Uladzimir. --=20 You received this message because you are subscribed to the Google Groups "= isar-users" group. To unsubscribe from this group and stop receiving emails from it, send an e= mail to isar-users+unsubscribe@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/isar-users/= 4627b14fa88b52d3723c7675b8d5fa4febb539c9.camel%40ilbers.de.