Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • tools/list_profiles.sh

    r91ece11b rc21d4d6  
    22
    33#
    4 # Copyright (c) 2021 Jiri Svoboda
    54# Copyright (c) 2019 Jiří Zárevúcky
    65# All rights reserved.
     
    4039CONFIG_DEFAULTS="${SOURCE_DIR}/defaults"
    4140
    42 # Find the leaf subdirectories in the defaults directory.
    43 level1dirs=`ls "$CONFIG_DEFAULTS"`
    44 for dname in $level1dirs; do
    45         l2dirs=`ls "$CONFIG_DEFAULTS"/"$dname"`
    46         havel2=
    47         for dn in $l2dirs; do
    48                 if [ -d "$CONFIG_DEFAULTS/$dname/$dn" ]; then
    49                         echo "$dname/$dn"
    50                         havel2=true
    51                 fi
    52         done
    53         if [ -z "$havel2" ]; then
    54                 echo "$dname"
    55         fi
    56 done
     41# Find all the leaf subdirectories in the defaults directory.
     42find ${CONFIG_DEFAULTS} -type d -links 2 -printf "%P\n" | sort
Note: See TracChangeset for help on using the changeset viewer.