On Friday 06 October 2006 04:16, Frans Pop wrote: > After reading the discussion again, I realized that I had accidentally > replaced "guided" by "automatic", so below a new proposed first p-a > screen. Attached a proposed patch that: - implements the dialog changes (with a few changes from the last proposal) - implements confirmation of changes before LVM volumes are created - adds some explicit warnings that data will be lost in other dialogs TODO: - show which disk is being used when selecting the recipe Please review. A review of the new wording of templates would be appreciated (before being committed for translation). /me was surprised how easy it was to implement these changes; compliments to David for his restructuring of the p-a-* scripts Cheers, FJP
Index: partman-auto/debian/changelog
===================================================================
--- partman-auto/debian/changelog (revision 41357)
+++ partman-auto/debian/changelog (working copy)
@@ -6,12 +6,13 @@
[ Frans Pop ]
* Activate LVM support in recipes for hppa.
+ * Implement selection of method before disk for regular guided partitioning.
[ Simon Huggins ]
* Add a raid method so we get multiple disk partitioning functionality back
again.
- -- Frans Pop <fjp@debian.org> Wed, 04 Oct 2006 14:03:43 +0100
+ -- Frans Pop <fjp@debian.org> Sat, 7 Oct 2006 03:33:30 +0200
partman-auto (57) unstable; urgency=low
Index: partman-auto/debian/partman-auto.templates
===================================================================
--- partman-auto/debian/partman-auto.templates (revision 41357)
+++ partman-auto/debian/partman-auto.templates (working copy)
@@ -22,18 +22,24 @@
Type: select
Choices: ${CHOICES}
_Description: Partitioning method:
- This installer can guide you through partitioning a disk for use by
- Debian, or if you prefer, you can do it manually. If you do choose to
- use the guided partitioning tool, you will still have a chance later to
- review and customise the results.
+ The installer can guide you through partitioning a disk (using different
+ standard recipes) or, if you prefer, you can do it manually. With guided
+ partitioning you will still have a chance later to review and customise
+ the results.
+ .
+ If you choose guided partitioning for an entire disk, you will next be
+ asked which disk should be used.
Template: partman-auto/purge_lvm_from_device
Type: boolean
Default: false
-_Description: Remove all logical volume data?
+_Description: Remove existing logical volume data?
The selected device already contains logical volumes and/or
volume groups from a previous LVM installation, which must be removed
from the disk before creating any partitions.
+ .
+ Note that this will also permanently erase any data currently on the
+ logical volumes.
Template: partman-auto/cannot_purge_lvm_from_device
Type: error
@@ -56,6 +62,8 @@
Type: select
Choices: ${CHOICES}
_Description: Partitioning method:
+ If you choose guided partitioning for an entire disk, you will next be
+ asked which disk should be used.
Template: partman-auto/choose_recipe
Type: select
@@ -89,30 +97,31 @@
Template: partman-auto/text/use_biggest_free
Type: text
# TRANSLATORS: This is a menu entry. Keep in under 55 columns/characters
-_Description: Use the largest continuous free space
+_Description: Guided - use the largest continuous free space
Template: partman-auto/text/use_device
Type: text
# TRANSLATORS: This is a menu entry. Keep in under 55 columns/characters
-# The string replacing ${DEVICE} may be very long, so make your translation
-# as short as possible and keep the variable AT THE END
-# for example "Erase entire disk: IDE0 master - Maxtor 46L489"
-_Description: Erase entire disk: ${DEVICE}
+_Description: Guided - erase entire disk
Template: partman-auto/select_disk
Type: select
Choices: ${CHOICES}
_Description: Select disk to partition:
+ Note that all data on the disk you select will be erased, but not before
+ you have confirmed that you really want to make the changes.
Template: partman-auto/select_disks
Type: multiselect
Choices: ${CHOICES}
_Description: Select disk(s) to partition:
+ Note that all data on the disk(s) you select will be erased, but not before
+ you have confirmed that you really want to make the changes.
Template: partman-auto/text/custom_partitioning
Type: text
# TRANSLATORS: This is a menu entry. Keep in under 55 columns/characters
-_Description: Manually edit partition table
+_Description: Manual
Template: partman-auto/text/auto_free_space
Type: text
Index: partman-auto/automatically_partition/some_device/choices
===================================================================
--- partman-auto/automatically_partition/some_device/choices (revision 41357)
+++ partman-auto/automatically_partition/some_device/choices (working copy)
@@ -1,21 +1,4 @@
#!/bin/sh
-. /lib/partman/definitions.sh
-
-mypart=''
-mysize=0
-
-for dev in $DEVICES/*; do
- [ -d "$dev" ] || continue
-
- # Skip /dev/mapper/X and /dev/mdX devices
- device=$(cat $dev/device)
- $(echo "$device" | grep -q "/dev/md[0-9]*$") && continue
- $(echo "$device" | grep -q "/dev/mapper/") && continue
-
- db_subst partman-auto/text/use_device DEVICE $(device_name $dev)
- db_metaget partman-auto/text/use_device description
- printf "$dev\t$RET\n"
-done
-
-
+db_metaget partman-auto/text/use_device description
+printf "regular\t$RET\n"
Index: partman-auto/automatically_partition/some_device/do_option
===================================================================
--- partman-auto/automatically_partition/some_device/do_option (revision 41357)
+++ partman-auto/automatically_partition/some_device/do_option (working copy)
@@ -1,5 +1,8 @@
#!/bin/sh
-dev=$1
+. /lib/partman/definitions.sh
+. /lib/partman/auto-shared.sh
-autopartition $dev
+disk=$(select_auto_disk) || exit 99
+
+autopartition $disk
Index: partman-auto-lvm/debian/changelog
===================================================================
--- partman-auto-lvm/debian/changelog (revision 41357)
+++ partman-auto-lvm/debian/changelog (working copy)
@@ -1,3 +1,12 @@
+partman-auto-lvm (16) UNRELEASED; urgency=low
+
+ * Show confirmation dialog before making changes to the partition table.
+ Closes: #368633.
+ * Change description for method.
+ * Avoid double sourcing of common functions.
+
+ -- Frans Pop <fjp@debian.org> Sat, 7 Oct 2006 04:44:32 +0200
+
partman-auto-lvm (15) unstable; urgency=low
[ David Härdeman ]
Index: partman-auto-lvm/debian/partman-auto-lvm.templates
===================================================================
--- partman-auto-lvm/debian/partman-auto-lvm.templates (revision 41357)
+++ partman-auto-lvm/debian/partman-auto-lvm.templates (working copy)
@@ -1,7 +1,7 @@
Template: partman-auto-lvm/text/choice
Type: text
# TRANSLATORS: This is a menu entry. Keep in under 55 columns/characters
-_Description: Automatically set up LVM
+_Description: Guided - erase entire disk and set up LVM
Template: partman-auto-lvm/new_vg_name
Type: string
Index: partman-auto-lvm/auto-lvm_tools.sh
===================================================================
--- partman-auto-lvm/auto-lvm_tools.sh (revision 41357)
+++ partman-auto-lvm/auto-lvm_tools.sh (working copy)
@@ -86,6 +86,10 @@
create_partitions
+ if ! confirm_changes "partman-lvm"; then
+ return 30
+ fi
+
# Write the partition tables
disable_swap
cd $dev
Index: partman-auto-lvm/autopartition-lvm
===================================================================
--- partman-auto-lvm/autopartition-lvm (revision 41357)
+++ partman-auto-lvm/autopartition-lvm (working copy)
@@ -1,9 +1,5 @@
#!/bin/sh
-. /lib/partman/definitions.sh
-. /lib/partman/recipes.sh
-. /lib/partman/lvm_tools.sh
-. /lib/partman/auto-shared.sh
. /lib/partman/auto-lvm_tools.sh
dev="$1"
Index: partman-auto-crypto/debian/changelog
===================================================================
--- partman-auto-crypto/debian/changelog (revision 41357)
+++ partman-auto-crypto/debian/changelog (working copy)
@@ -1,9 +1,14 @@
partman-auto-crypto (2) UNRELEASED; urgency=low
+ [ Max Vozeler ]
* Run debconf-updatepo to generate debian/po/templates.pot
- -- Max Vozeler <xam@debian.org> Sat, 23 Sep 2006 13:33:21 +0200
+ [ Frans Pop ]
+ * Change description for method
+ * Avoid double sourcing of common functions
+ -- Frans Pop <fjp@debian.org> Sat, 7 Oct 2006 04:46:32 +0200
+
partman-auto-crypto (1) unstable; urgency=low
[ David Härdeman ]
Index: partman-auto-crypto/debian/partman-auto-crypto.templates
===================================================================
--- partman-auto-crypto/debian/partman-auto-crypto.templates (revision 41357)
+++ partman-auto-crypto/debian/partman-auto-crypto.templates (working copy)
@@ -1,4 +1,4 @@
Template: partman-auto-crypto/text/choice
Type: text
# TRANSLATORS: This is a menu entry. Keep in under 55 columns/characters
-_Description: Automatically set up encrypted LVM
+_Description: Guided - erase entire disk and set up encrypted LVM
Index: partman-auto-crypto/autopartition-crypto
===================================================================
--- partman-auto-crypto/autopartition-crypto (revision 41357)
+++ partman-auto-crypto/autopartition-crypto (working copy)
@@ -1,9 +1,5 @@
#!/bin/sh
-. /lib/partman/definitions.sh
-. /lib/partman/recipes.sh
-. /lib/partman/lvm_tools.sh
-. /lib/partman/auto-shared.sh
. /lib/partman/auto-lvm_tools.sh
. /lib/partman/crypto_tools.sh
Attachment:
pgpmgTwJSLHRK.pgp
Description: PGP signature