#!/usr/bin/php 1, '..' => 2, '.' => 3); $locales = array(); $index = 0; while ($arch = $directory->read()) { if (!isset($invalid_dir[$arch]) && is_dir($path.$arch)){ $locales[$index] = $arch; $index ++; } } $directory->close(); asort($locales); foreach ($locales as $locale){ echo $locale; $cmd = "./mergelocale.sh $locale"; exec($cmd); } exec( "php ./calc_l10n_stats.php" ); ?>