commit ab73c10844eca0c3add1c1760e5092691dd2da89 parent 281ae8ad06237a39bdcc4d6f9b9afaf41a596cad Author: Jan Pobrislo <ccx@webprojekty.cz> Date: Tue, 21 Apr 2015 01:11:02 +0200 embed code in MBR Diffstat:
| M | zsh-functions/confz_fs_init | | | 11 | +++++++++++ |
1 file changed, 11 insertions(+), 0 deletions(-)
diff --git a/zsh-functions/confz_fs_init b/zsh-functions/confz_fs_init @@ -67,6 +67,17 @@ confz_disklabel_dos_check() { } +# embed file in MBR +confz_mbr_code_check() { + checkvars device from + if cmp -n 440 $vars[device] $vars[from]; then + return 0 + else + do_command=( dd bs=440B count=1 if=$vars[file] of=$vars[from] ) + fi +} + + # check for primary partition confz_primary_partition_check() { local prev option