diff options
author | Karel Zak | 2016-02-01 14:08:04 +0100 |
---|---|---|
committer | Karel Zak | 2016-02-01 14:08:04 +0100 |
commit | d09c06baf4eccfb81cb9a5d0285ba6337aec2919 (patch) | |
tree | 97437221d25f5f8e7f7c51a15247d4babbd61081 | |
parent | hwclock: remove extra space from --show output (diff) | |
download | kernel-qcow2-util-linux-d09c06baf4eccfb81cb9a5d0285ba6337aec2919.tar.gz kernel-qcow2-util-linux-d09c06baf4eccfb81cb9a5d0285ba6337aec2919.tar.xz kernel-qcow2-util-linux-d09c06baf4eccfb81cb9a5d0285ba6337aec2919.zip |
sfdisk: add 'U' shortcut for ESP
echo -e ',512M,U\n,,L' | sfdisk --label gpt /dev/foo
to make ESP system partition.
References: https://github.com/karelzak/util-linux/issues/267
Signed-off-by: Karel Zak <kzak@redhat.com>
-rw-r--r-- | disk-utils/sfdisk.8 | 3 | ||||
-rw-r--r-- | libfdisk/src/script.c | 3 |
2 files changed, 6 insertions, 0 deletions
diff --git a/disk-utils/sfdisk.8 b/disk-utils/sfdisk.8 index 77fb3f752..4aa0b6208 100644 --- a/disk-utils/sfdisk.8 +++ b/disk-utils/sfdisk.8 @@ -301,6 +301,9 @@ home partition; means 933AC7E1-2EB4-4F13-B844-0E14E2AEF915 for GPT .TP .B X linux extended partition; means 85 for MBR. +.TP +.B U +EFI System partition, means C12A7328-F81F-11D2-BA4B-00A0C93EC93B for GPT .RE .PP The default diff --git a/libfdisk/src/script.c b/libfdisk/src/script.c index 1191da474..79e2add04 100644 --- a/libfdisk/src/script.c +++ b/libfdisk/src/script.c @@ -972,6 +972,9 @@ static struct fdisk_parttype *translate_type_shortcuts(struct fdisk_script *dp, case 'H': /* Home */ type = "933AC7E1-2EB4-4F13-B844-0E14E2AEF915"; break; + case 'U': /* UEFI system */ + type = "C12A7328-F81F-11D2-BA4B-00A0C93EC93B"; + break; } } |