diff --git a/buildsuite b/buildsuite index 7039ca8..9510b58 100755 --- a/buildsuite +++ b/buildsuite @@ -17,6 +17,10 @@ # # Functions {{{1 +lscolors_buildsuite_print_extensions() { + sed -r -e '/^[ ]+#/d; /^[^\.\*]/d; /^$/d; s/^([\.\*][^ ]+).*/\1/' ../LS_COLORS +} + verbose() { if [[ "$verbose" = "1" ]]; then echo "$1" >&2 @@ -114,13 +118,14 @@ chmod 0777 WORLDWRITEABLE # Supported extensions while read line; do if [[ ! -f test"$line" ]]; then - line="${line//\*/}" + line="${line//\*/.}" if [[ "${line:0:1}" == "." ]]; then touch ./DIRECTORY/test"$line" else touch ./DIRECTORY/"$line" fi fi -done < <(sed -r -e '/^[ ]+#/d; /^[^\.\*]/d; /^$/d' ../LS_COLORS | grep -Po '^[\.\*]([A-z0-9]+)' ) +done < <( lscolors_buildsuite_print_extensions ) + # vim: ft=sh foldmethod=marker: