Rename functions for consistency

This commit is contained in:
the-sane 2020-09-07 21:59:34 -04:00 committed by GitHub
parent 24b81ffa26
commit 14f8a8a822
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -513,14 +513,14 @@ mapcount_set() {
} }
# Check if setting the open file descriptors limit was successful # Check if setting the open file descriptors limit was successful
check_filelimit() { filelimit_check() {
if [ "$(ulimit -Hn)" -lt 524288 ]; then if [ "$(ulimit -Hn)" -lt 524288 ]; then
message warning "As far as this helper can detect, the open files limit\nwas not successfully configured on your system.\nYou may experience crashes.\n\nWe recommend manually configuring this limit to at least 524288." message warning "As far as this helper can detect, the open files limit\nwas not successfully configured on your system.\nYou may experience crashes.\n\nWe recommend manually configuring this limit to at least 524288."
fi fi
} }
# Check the open file descriptors limit and let the user fix it if needed # Check the open file descriptors limit and let the user fix it if needed
set_filelimit() { filelimit_set() {
filelimit="$(ulimit -Hn)" filelimit="$(ulimit -Hn)"
# If the file limit is already set, no need to do anything # If the file limit is already set, no need to do anything
@ -551,7 +551,7 @@ set_filelimit() {
fi fi
# Verify that setting the limit was successful # Verify that setting the limit was successful
check_filelimit filelimit_check
} }
# Delete the shaders directory # Delete the shaders directory
@ -656,7 +656,7 @@ while true; do
# Set the menu options # Set the menu options
menu_options=("$mapcount_msg" "$filelimit_msg" "$sanitize_msg" "$shaders_msg" "$vidcache_msg" "$version_msg" "$quit_msg") menu_options=("$mapcount_msg" "$filelimit_msg" "$sanitize_msg" "$shaders_msg" "$vidcache_msg" "$version_msg" "$quit_msg")
# Set the corresponding functions to be called for each of the options # Set the corresponding functions to be called for each of the options
menu_actions=("mapcount_set" "set_filelimit" "sanitize" "rm_shaders" "rm_vidcache" "set_version" "quit") menu_actions=("mapcount_set" "filelimit_set" "sanitize" "rm_shaders" "rm_vidcache" "set_version" "quit")
# Call the menu function # Call the menu function
menu menu