Skip to content

Instantly share code, notes, and snippets.

@apaatsio
Last active February 23, 2019 09:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save apaatsio/63ca87cd20f805114dafac3b68c04d11 to your computer and use it in GitHub Desktop.
Save apaatsio/63ca87cd20f805114dafac3b68c04d11 to your computer and use it in GitHub Desktop.
Project size evaluator for Flutter Create contest 2019. More info: https://flutter.io/create
#!/bin/sh
# Project size evaluator for Flutter Create contest 2019.
# More info: https://flutter.io/create
MAX_SIZE=5120
SIZE=`find . -name "*.dart" | xargs cat | wc -c`
if [ $SIZE -gt $MAX_SIZE ];
then
echo "\e[31mThe project is TOO BIG! $SIZE / $MAX_SIZE";
exit 1
else
echo "\e[32mThe project is small enough. $SIZE / $MAX_SIZE";
fi;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment