Changeset - bf5396f22815
[Not reviewed]
0 1 0
Branko Majic (branko) - 4 years ago 2020-07-06 16:06:56
branko@majic.rs
Noticket: [factorio_manager.sh] Properly quote variables when performing file globbing with arrays.
1 file changed with 4 insertions and 4 deletions:
0 comments (0 inline, 0 general) First comment
games/factorio_manager.sh
Show inline comments
 
@@ -1587,7 +1587,7 @@ elif [[ $command == restore ]]; then
 

	
 
        # Set-up a list of files and directories that will get removed.
 
        shopt -s nullglob
 
        entries_to_remove=($instance_directory/*)
 
        entries_to_remove=("$instance_directory"/*)
 
        shopt -u nullglob
 

	
 
        # Present user with extensive warning on consequences.
 
@@ -1810,7 +1810,7 @@ elif [[ $command == info ]]; then
 

	
 
    # Mod information.
 
    shopt -s nullglob
 
    mod_files=($instance_directory/mods/*.zip)
 
    mod_files=("$instance_directory/mods"/*.zip)
 
    mod_list="$instance_directory/mods/mod-list.json"
 
    shopt -u nullglob
 

	
 
@@ -1939,7 +1939,7 @@ elif [[ $command == remove ]]; then
 

	
 
        # Set-up a list of files and directories that will get removed.
 
        shopt -s nullglob dotglob
 
        entries_to_remove=($instance_directory/*)
 
        entries_to_remove=("$instance_directory"/*)
 
        shopt -u nullglob dotglob
 

	
 
        # Present user with extensive warning on consequences.
 
@@ -2068,7 +2068,7 @@ elif [[ $command == copy ]]; then
 
        done
 

	
 
        # Set-up a list of files and directories to copy.
 
        entries_to_copy=($source_instance_directory/*)
 
        entries_to_copy=("$source_instance_directory"/*)
 

	
 
        if [[ $copy_backups == "y" && -e "$source_instance_directory/.bak" ]]; then
 
             entries_to_copy+=("$source_instance_directory/.bak")
0 comments (0 inline, 0 general) First comment
You need to be logged in to comment. Login now