Skip to content

Commit

Permalink
Removing some bashisms.
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolasnoble committed Apr 15, 2015
1 parent c547dcb commit 970f5d9
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions tools/buildgen/generate_projects.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,21 +46,19 @@ end2end_test_build=`mktemp /tmp/genXXXXXX`
$gen_build_json > $end2end_test_build

global_plugins=`find ./tools/buildgen/plugins -name '*.py' |
sort | grep -v __init__ |
while read p ; do echo -n "-p $p " ; done`
sort | grep -v __init__ | awk ' { printf "-p %s ", $0 } '`

for dir in . ; do
local_plugins=`find $dir/templates -name '*.py' |
sort | grep -v __init__ |
while read p ; do echo -n "-p $p " ; done`
sort | grep -v __init__ | awk ' { printf "-p %s ", $0 } '`

plugins="$global_plugins $local_plugins"

find -L $dir/templates -type f -and -name *.template | while read file ; do
out=${dir}/${file#$dir/templates/} # strip templates dir prefix
out=${out%.*} # strip template extension
json_files="build.json $end2end_test_build"
data=`for i in $json_files; do echo -n "-d $i "; done`
data=`for i in $json_files ; do echo $i ; done | awk ' { printf "-d %s ", $0 } '`
if [ "x$TEST" = "xtrue" ] ; then
actual_out=$out
out=`mktemp /tmp/gentXXXXXX`
Expand Down

0 comments on commit 970f5d9

Please sign in to comment.