diff --git a/initrd/etc/functions b/initrd/etc/functions index 553f4b27..1f7896ac 100755 --- a/initrd/etc/functions +++ b/initrd/etc/functions @@ -229,8 +229,8 @@ replace_config() { # then copy any remaining settings from the existing config file, minus the option you changed grep -v "^export ${CONFIG_OPTION}=" ${CONFIG_FILE} | grep -v "^${CONFIG_OPTION}=" >> ${CONFIG_FILE}.tmp || true - - mv ${CONFIG_FILE}.tmp ${CONFIG_FILE} + sort ${CONFIG_FILE}.tmp | uniq > ${CONFIG_FILE} + rm -f ${CONFIG_FILE}.tmp } combine_configs() { cat /etc/config* > /tmp/config