This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo -e "o\ny\nn\n1\n\n\n8300\nw\ny\n" | sudo gdisk /dev/"$DEVICE_NAME" | |
# o create a new empty GUID partition table (GPT) [Delete All Partition] | |
# y yes, proceed | |
# n add a new partition | |
# 1 partition number 1 | |
# default, first sector | |
# default, last sector | |
# 8300 Hex code or GUID [8300 Linux filesystem] | |
# w write table to disk and exit | |
# y yes, proceed |
NewerOlder