nix/os/devices: add relabel command

After bytewise-copying from a prevoius disk, the partition labels and
logical volume groupnames need to be renamed according to the new disk
id.
This commit is contained in:
steveej 2019-01-12 22:24:30 +01:00
parent e9464dfbe7
commit 4f26e935ee
3 changed files with 52 additions and 1 deletions

View file

@ -94,6 +94,9 @@ hm-iterate-qtile:
disk-prepare dir:
just -v _device diskPrepare {{dir}} --argstr rebuildarg "dummy"
disk-relabel dir previous:
just -v _device diskRelabel {{dir}} --argstr rebuildarg "dummy" --argstr previousDiskId {{previous}}
# Mount the target disk specified by device configuration directory. The 'dir' argument points to a device configuration, e.g. 'nix/os/devices/steveej-live-mmc-SL32G_0x259093f6'
disk-mount dir:
just -v _device diskMount {{dir}} --argstr rebuildarg "dummy"