Created
April 15, 2019 19:33
-
-
Save stefpe/195ce32e5fe761e2b664d7e5c6b92790 to your computer and use it in GitHub Desktop.
find .h and .c files in a directory
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$files = glob('*.{h,c}', GLOB_BRACE); | |
if (!$files) { | |
die('error'); | |
} | |
foreach ($files as $file) { | |
printf("%s -> %d bytes\n", $file, filesize($file)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment