LOGGER: fixed blank newlines

This commit is contained in:
XargonWan 2024-11-28 15:01:21 +09:00
parent 1c94be1c33
commit 74fec2e9fa
2 changed files with 6 additions and 5 deletions

View file

@ -55,6 +55,7 @@ main_repository_name="RetroDECK"
features="$config/retrodeck/reference_lists/features.json" # A file where all the RetroDECK and component capabilities are kept for querying
es_systems="/app/share/es-de/resources/systems/linux/es_systems.xml" # ES-DE supported system list
es_find_rules="/app/share/es-de/resources/systems/linux/es_find_rules.xml" # ES-DE emulator find rules
logging_level="info" # Initializing this to avoid printing blank newlines, this will be actually red later from the config file
# Godot data transfer temp files

View file

@ -205,16 +205,16 @@ conf_read() {
do
if [[ (! -z "$current_setting_line") && (! "$current_setting_line" == "#"*) && (! "$current_setting_line" == "[]") ]]; then # If the line has a valid entry in it
if [[ ! -z $(grep -o -P "^\[.+?\]$" <<< "$current_setting_line") ]]; then # If the line is a section header
local current_section=$(sed 's^[][]^^g' <<< $current_setting_line) # Remove brackets from section name
local current_section=$(sed 's^[][]^^g' <<< "$current_setting_line") # Remove brackets from section name
else
if [[ "$current_section" == "" || "$current_section" == "paths" || "$current_section" == "options" ]]; then
local current_setting_name=$(get_setting_name "$current_setting_line" "retrodeck") # Read the variable name from the current line
local current_setting_value=$(get_setting_value "$rd_conf" "$current_setting_name" "retrodeck" "$current_section") # Read the variables value from retrodeck.cfg
local current_setting_name=$(cut -d'=' -f1 <<< "$current_setting_line" | xargs) # Extract name
local current_setting_value=$(cut -d'=' -f2 <<< "$current_setting_line" | xargs) # Extract value
declare -g "$current_setting_name=$current_setting_value" # Write the current setting name and value to memory
fi
fi
fi
done < $rd_conf
done < "$rd_conf"
}
conf_write() {