Projet

Général

Profil

Révision 8550e097

Ajouté par Julien Enselme il y a plus de 9 ans

Command subsitution are not quoted. Quotes posed problems in loop.

Voir les différences:

bin/usage.sh
17 17

  
18 18
number_found=0
19 19

  
20
for dir in "$(find . -maxdepth 1 -mindepth 1 -type d ! -name all ! -name languages ! -name images | sort)" ; do
20
for dir in $(find . -maxdepth 1 -mindepth 1 -type d ! -name all ! -name languages ! -name images | sort) ; do
21 21
    # List projects that correspond to the status.
22 22
    # Keep project_name if listed.
23 23
    # Count line result. 0 if not listed or 1 if listed.
24 24
    # Print site_dir if listed.
25 25

  
26 26
    cd "${dir}";
27
	if [ 1 -le "$(drush pml --status="$2" | grep "$3" | wc -l)" ] ; then
27
	if [ 1 -le $(drush pml --status="$2" | grep "$3" | wc -l) ] ; then
28 28
        echo "${dir}";
29 29
        number_found=$(($number_found + 1))
30 30
    fi

Formats disponibles : Unified diff