[gnome-hwtest] gnome-hwtest-install: Bug fixes
- From: Owen Taylor <otaylor src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-hwtest] gnome-hwtest-install: Bug fixes
- Date: Tue, 22 Jul 2014 20:10:11 +0000 (UTC)
commit c0eeb58340adaeefd474e0416ec4ee9fd7ea3919
Author: Owen W. Taylor <otaylor fishsoup net>
Date: Tue Jul 22 14:55:39 2014 -0400
gnome-hwtest-install: Bug fixes
Fix computation of free space in GB
Fix bug that prevented installing a target machine preserving the existing partitions
src/gnome-hwtest-install | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/src/gnome-hwtest-install b/src/gnome-hwtest-install
index 3686b94..f9b17ee 100755
--- a/src/gnome-hwtest-install
+++ b/src/gnome-hwtest-install
@@ -80,8 +80,9 @@ convert_size() {
*MB)
echo $((${1%MB} * 1000))
;;
- *gB)
- echo $((${1%GB} * 1000000))
+ *GB)
+ # GB output can be non-integral
+ python -c "print int(${1%GB} * 1000000)"
;;
esac
}
@@ -246,7 +247,7 @@ delete_existing=no
install_bootloader=no
confirm "Delete existing partitions on $device?" && delete_existing=yes
-[ $controller -a "$delete_existing" != yes ] && exit
+$controller && [ "$delete_existing" != yes ] && exit
if [ $delete_existing = yes ] ; then
free_start=1024
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]