Changes to build.func

This commit is contained in:
Michel Roegl-Brunner 2025-05-16 08:55:05 +02:00
parent d3d9a7594c
commit f3dfd62c16

View File

@ -495,7 +495,7 @@ advanced_settings() {
echo -e "${INFO}${BOLD}${GN}Searching for bridges in ${iface_filepath}${CL}"
iface_indexes_tmpfile=$(mktemp -q -u '.iface-XXXX')
( grep -Pn '^\s*iface' "${iface_filepath}" | cut -d':' -f1 && wc -l "${iface_filepath}" | cut -d' ' -f1 ) | awk 'FNR==1 {line=$0; next} {print line":"$0-1; line=$0}' > "${iface_indexes_tmpfile}"
( grep -Pn '^\s*iface' "${iface_filepath}" | cut -d':' -f1 && wc -l "${iface_filepath}" | cut -d' ' -f1 ) | awk 'FNR==1 {line=$0; next} {print line":"$0-1; line=$0}' > "${iface_indexes_tmpfile}" || true
if [ -f "${iface_indexes_tmpfile}" ]; then