mirror of
				https://github.com/community-scripts/ProxmoxVE.git
				synced 2025-11-04 02:12:49 +00:00 
			
		
		
		
	Add TAB3 formatting var to core (#4496)
This commit is contained in:
		@@ -17,6 +17,7 @@ color() {
 | 
			
		||||
  BFR="\\r\\033[K"
 | 
			
		||||
  BOLD=$(echo "\033[1m")
 | 
			
		||||
  TAB="  "
 | 
			
		||||
  TAB3="      "
 | 
			
		||||
 | 
			
		||||
  # System
 | 
			
		||||
  RETRY_NUM=10
 | 
			
		||||
 
 | 
			
		||||
@@ -32,6 +32,7 @@ color() {
 | 
			
		||||
  BOLD=$(echo "\033[1m")
 | 
			
		||||
  HOLD=" "
 | 
			
		||||
  TAB="  "
 | 
			
		||||
  TAB3="      "
 | 
			
		||||
 | 
			
		||||
  # Icons
 | 
			
		||||
  CM="${TAB}✔️${TAB}"
 | 
			
		||||
@@ -528,16 +529,16 @@ advanced_settings() {
 | 
			
		||||
    exit_script
 | 
			
		||||
  fi
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
  BRIDGES=""
 | 
			
		||||
  IFACE_FILEPATH_LIST="/etc/network/interfaces"$'\n'$(find "/etc/network/interfaces.d/" -type f)
 | 
			
		||||
  OLD_IFS=$IFS; IFS=$'\n'
 | 
			
		||||
  OLD_IFS=$IFS
 | 
			
		||||
  IFS=$'\n'
 | 
			
		||||
 | 
			
		||||
  for iface_filepath in ${IFACE_FILEPATH_LIST}; do
 | 
			
		||||
    iface_indexes_tmpfile=$(mktemp -q -u '.iface-XXXX')
 | 
			
		||||
 | 
			
		||||
    ( grep -Pn '^\s*iface' "${iface_filepath}" | cut -d':' -f1 && wc -l "${iface_filepath}" | cut -d' ' -f1 ) | \
 | 
			
		||||
    awk 'FNR==1 {line=$0; next} {print line":"$0-1; line=$0}' > "${iface_indexes_tmpfile}"
 | 
			
		||||
    (grep -Pn '^\s*iface' "${iface_filepath}" | cut -d':' -f1 && wc -l "${iface_filepath}" | cut -d' ' -f1) |
 | 
			
		||||
      awk 'FNR==1 {line=$0; next} {print line":"$0-1; line=$0}' >"${iface_indexes_tmpfile}"
 | 
			
		||||
 | 
			
		||||
    if [ -f "${iface_indexes_tmpfile}" ]; then
 | 
			
		||||
      while read -r pair; do
 | 
			
		||||
@@ -549,7 +550,7 @@ advanced_settings() {
 | 
			
		||||
          BRIDGES="${iface_name}"$'\n'"${BRIDGES}"
 | 
			
		||||
        fi
 | 
			
		||||
 | 
			
		||||
        done < "${iface_indexes_tmpfile}"
 | 
			
		||||
      done <"${iface_indexes_tmpfile}"
 | 
			
		||||
      rm -f "${iface_indexes_tmpfile}"
 | 
			
		||||
    fi
 | 
			
		||||
 | 
			
		||||
@@ -974,7 +975,6 @@ config_file() {
 | 
			
		||||
    fi
 | 
			
		||||
  fi
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
  if [[ ! -z "$APT_CACHER_IP" ]]; then
 | 
			
		||||
    if [[ "$APT_CACHER_IP" =~ $ip_regex ]]; then
 | 
			
		||||
      APT_CACHER="yes"
 | 
			
		||||
 
 | 
			
		||||
@@ -19,6 +19,7 @@ color() {
 | 
			
		||||
  BOLD=$(echo "\033[1m")
 | 
			
		||||
  HOLD=" "
 | 
			
		||||
  TAB="  "
 | 
			
		||||
  TAB3="      "
 | 
			
		||||
 | 
			
		||||
  # System
 | 
			
		||||
  RETRY_NUM=10
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user