Avoid copying the wrong files from WinPE
* if w_en_us was empty it would copy the contents from $(pwd)
This commit is contained in:
parent
0b31fa271d
commit
c5364a65a2
1 changed files with 30 additions and 12 deletions
|
|
@ -577,18 +577,36 @@ sed -i "s/${ISO_LABEL}/${UFD_LABEL}/" /mnt/Dest/arch/boot/syslinux/*cfg
|
||||||
|
|
||||||
echo "Copying WinPE files..." | tee -a "${LOG_FILE}"
|
echo "Copying WinPE files..." | tee -a "${LOG_FILE}"
|
||||||
if [[ ! -z "${arg_w:-}" ]]; then
|
if [[ ! -z "${arg_w:-}" ]]; then
|
||||||
rsync ${RSYNC_ARGS} \
|
if [[ ! -z "${w_bootmgr:-}" ]]; then
|
||||||
"${w_bootmgr}" "${w_bootmgr_efi}" "${w_en_us}" \
|
rsync ${RSYNC_ARGS} "${w_bootmgr}" /mnt/Dest/ >> "${LOG_FILE}" 2>&1
|
||||||
/mnt/Dest/ >> "${LOG_FILE}" 2>&1
|
fi
|
||||||
rsync ${RSYNC_ARGS} \
|
if [[ ! -z "${w_bootmgr_efi:-}" ]]; then
|
||||||
"${w_boot}"/* \
|
rsync ${RSYNC_ARGS} "${w_bootmgr_efi}" /mnt/Dest/ >> "${LOG_FILE}" 2>&1
|
||||||
/mnt/Dest/Boot/ >> "${LOG_FILE}" 2>&1
|
fi
|
||||||
rsync ${RSYNC_ARGS} \
|
if [[ ! -z "${w_en_us:-}" ]]; then
|
||||||
"${w_efi_boot}"/* "${w_efi_microsoft}"/* \
|
rsync ${RSYNC_ARGS} "${w_en_us}" /mnt/Dest/ >> "${LOG_FILE}" 2>&1
|
||||||
/mnt/Dest/EFI/Microsoft/ >> "${LOG_FILE}" 2>&1
|
fi
|
||||||
rsync ${RSYNC_ARGS} \
|
if [[ ! -z "${w_boot:-}" ]]; then
|
||||||
"${w_boot_bcd}" "${w_boot_sdi}" "${w_bootmgr}" "${w_sources}"/* \
|
rsync ${RSYNC_ARGS} "${w_boot}"/* /mnt/Dest/Boot/ >> "${LOG_FILE}" 2>&1
|
||||||
/mnt/Dest/sources/ >> "${LOG_FILE}" 2>&1
|
fi
|
||||||
|
if [[ ! -z "${w_efi_boot:-}" ]]; then
|
||||||
|
rsync ${RSYNC_ARGS} "${w_efi_boot}"/* /mnt/Dest/EFI/Microsoft/ >> "${LOG_FILE}" 2>&1
|
||||||
|
fi
|
||||||
|
if [[ ! -z "${w_efi_microsoft:-}" ]]; then
|
||||||
|
rsync ${RSYNC_ARGS} "${w_efi_microsoft}"/* /mnt/Dest/EFI/Microsoft/ >> "${LOG_FILE}" 2>&1
|
||||||
|
fi
|
||||||
|
if [[ ! -z "${w_boot_bcd:-}" ]]; then
|
||||||
|
rsync ${RSYNC_ARGS} "${w_boot_bcd}" /mnt/Dest/sources/ >> "${LOG_FILE}" 2>&1
|
||||||
|
fi
|
||||||
|
if [[ ! -z "${w_boot_sdi:-}" ]]; then
|
||||||
|
rsync ${RSYNC_ARGS} "${w_boot_sdi}" /mnt/Dest/sources/ >> "${LOG_FILE}" 2>&1
|
||||||
|
fi
|
||||||
|
if [[ ! -z "${w_bootmgr:-}" ]]; then
|
||||||
|
rsync ${RSYNC_ARGS} "${w_bootmgr}" /mnt/Dest/sources/ >> "${LOG_FILE}" 2>&1
|
||||||
|
fi
|
||||||
|
if [[ ! -z "${w_sources:-}" ]]; then
|
||||||
|
rsync ${RSYNC_ARGS} "${w_sources}"/* /mnt/Dest/sources/ >> "${LOG_FILE}" 2>&1
|
||||||
|
fi
|
||||||
|
|
||||||
# Uncomment boot entries
|
# Uncomment boot entries
|
||||||
sed -i "s/#UFD-WINPE#//" /mnt/Dest/EFI/boot/refind.conf
|
sed -i "s/#UFD-WINPE#//" /mnt/Dest/EFI/boot/refind.conf
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue