mirror of
https://github.com/dw-0/kiauh.git
synced 2025-12-14 19:14:27 +05:00
Merge pull request #28 from th33xitus/work-ini
fix: #24 - .gitignore for kiauh.ini
This commit is contained in:
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
kiauh.ini
|
||||
@@ -1,6 +0,0 @@
|
||||
#don't edit this file if you don't know what you are doing...
|
||||
backup_before_update=false
|
||||
previous_origin_state=0
|
||||
previous_smoothing_state=0
|
||||
previous_shaping_state=0
|
||||
logupload_accepted=false
|
||||
@@ -257,3 +257,24 @@ create_shell_command_example(){
|
||||
done
|
||||
fi
|
||||
}
|
||||
|
||||
init_ini(){
|
||||
if [ ! -f $INI_FILE ]; then
|
||||
echo -e "#don't edit this file if you don't know what you are doing...\c" > $INI_FILE
|
||||
fi
|
||||
if [ ! $(grep -E "^backup_before_update=." $INI_FILE) ]; then
|
||||
echo -e "\nbackup_before_update=false\c" >> $INI_FILE
|
||||
fi
|
||||
if [ ! $(grep -E "^previous_origin_state=[[:alnum:]]" $INI_FILE) ]; then
|
||||
echo -e "\nprevious_origin_state=0\c" >> $INI_FILE
|
||||
fi
|
||||
if [ ! $(grep -E "^previous_smoothing_state=[[:alnum:]]" $INI_FILE) ]; then
|
||||
echo -e "\nprevious_smoothing_state=0\c" >> $INI_FILE
|
||||
fi
|
||||
if [ ! $(grep -E "^previous_shaping_state=[[:alnum:]]" $INI_FILE) ]; then
|
||||
echo -e "\nprevious_shaping_state=0\c" >> $INI_FILE
|
||||
fi
|
||||
if [ ! $(grep -E "^logupload_accepted=." $INI_FILE) ]; then
|
||||
echo -e "\nlogupload_accepted=false\c" >> $INI_FILE
|
||||
fi
|
||||
}
|
||||
Reference in New Issue
Block a user