#!/bin/bash

resetToMenu()
{
    # Find all directories in the containers folder and create variables for them
    if [ -d "$containers_dir" ]; then
        for dir in "$containers_dir"/*/; do
            if [ -d "$dir" ]; then
                # Get the directory name and remove any trailing slashes
                local app_name=$(basename "$dir")
                # Convert app name to lowercase and replace any non-alphanumeric characters with underscore
                app_name=$(echo "$app_name" | tr '[:upper:]' '[:lower:]' | tr -cd '[:alnum:]_')
                # Set the variable
                eval "${app_name}=n"
            fi
        done
    fi
    
    # Set any additional non-container variables here
    # Restore
    restoresingle=n
    
    # Migrate
    migratecheckforfiles=n
    migratemovefrommigrate=n
    migrategeneratetxt=n
    migratescanforupdates=n
    migratescanforconfigstomigrate=n
    migratescanformigratetoconfigs=n
    
    # Database
    toollistalltables=n
    toollistallapps=n
    toollistinstalledapps=n
    toolupdatedb=n
    toolemptytable=n
    tooldeletedb=n
    
    # Tools
    toolsresetgit=n
    toolstartpreinstallation=n
    toolsstartcrontabsetup=n
    toolrestartcontainers=n
    toolstopcontainers=n
    toolsremovedockermanageruser=n
    toolsinstalldockermanageruser=n
    toolinstallremotesshlist=n
    toolinstallcrontab=n
    toolinstallcrontabssh=n

    mainMenu
}