mirror of
https://github.com/kevinveenbirkenbach/linux-image-manager.git
synced 2024-11-21 22:51:05 +01:00
Added default value for boot size partition: https://chatgpt.com/share/a27feda0-8f84-4315-95b7-686a35986a49
This commit is contained in:
parent
c5b091e3b3
commit
93beadb519
@ -261,14 +261,27 @@ if [ "$transfer_image" = "y" ]
|
|||||||
info "Starting image transfer..."
|
info "Starting image transfer..."
|
||||||
if [ "$distribution" = "arch" ]
|
if [ "$distribution" = "arch" ]
|
||||||
then
|
then
|
||||||
|
|
||||||
|
# Default size of the boot partition
|
||||||
|
default_boot_size="+300M"
|
||||||
|
|
||||||
|
# Prompt to adjust the boot partition size
|
||||||
|
question "What size should the boot partition be? (Default: $default_boot_size):" && read -r boot_size
|
||||||
|
boot_size=${boot_size:-$default_boot_size}
|
||||||
|
|
||||||
|
# Use the provided size or the default size
|
||||||
|
info "The boot partition will be set to $boot_size."
|
||||||
|
|
||||||
|
# Partitioning with the specified size
|
||||||
info "Creating partitions..." &&
|
info "Creating partitions..." &&
|
||||||
( echo "o" #Type o. This will clear out any partitions on the drive.
|
(
|
||||||
|
echo "o" # Type o. This will clear out any partitions on the drive.
|
||||||
echo "p" # Type p to list partitions. There should be no partitions left
|
echo "p" # Type p to list partitions. There should be no partitions left
|
||||||
echo "n" # Type n,
|
echo "n" # Type n,
|
||||||
echo "p" # then p for primary,
|
echo "p" # then p for primary,
|
||||||
echo "1" # 1 for the first partition on the drive,
|
echo "1" # 1 for the first partition on the drive,
|
||||||
echo "" # Default start sector
|
echo "" # Default start sector
|
||||||
echo "+300M" #then type +300M for the last sector.
|
echo "$boot_size" # Size of the boot partition
|
||||||
echo "t" # Type t,
|
echo "t" # Type t,
|
||||||
echo "c" # then c to set the first partition to type W95 FAT32 (LBA).
|
echo "c" # then c to set the first partition to type W95 FAT32 (LBA).
|
||||||
echo "n" # Type n,
|
echo "n" # Type n,
|
||||||
|
Loading…
Reference in New Issue
Block a user