sistema_progs

Programas para customizar o meu entorno de traballo nos meus equipos persoais
Log | Files | Refs

inte_without_codepoint.sh (495B)


      1 #!/usr/bin/env bash
      2 
      3 YELLOW='\033[1;33m'
      4 GREEN='\033[0;32m'
      5 NC='\033[0m'
      6 filename="./build/mapping.txt"
      7 count=0
      8 
      9 name=""
     10 
     11 while read -r line
     12 do
     13     if [ "${line:0:1}" = "#" ]
     14     then
     15 	name_num=(${line//:/ })
     16 	name=${name_num[0]:1}
     17     else
     18 	str=""
     19 	IFS=';' read -ra array_glyph <<< "$line"
     20 	for glyph in "${array_glyph[@]}"; do
     21 	    info=(${glyph//:/ })
     22 	    echo -e "export ${info[0]}=\u${info[1]}"
     23 	    # echo "export ${info[0]}=\$(echo -e \"\u${info[1]}\")"
     24 	done
     25     fi
     26 
     27 done < "$filename"