Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@discordier
Created October 24, 2016 19:24
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 discordier/c1c2740337b072afe04e404f00741994 to your computer and use it in GitHub Desktop.
Save discordier/c1c2740337b072afe04e404f00741994 to your computer and use it in GitHub Desktop.
cmd sf: Search for symfony console app in the current dir (2.X or 3.X) and run whichever has been found
sf() {
if [ -f ./app/console ]; then
./app/console $@
return $?
fi;
if [ -f ./bin/console ]; then
./bin/console $@
return $?
fi;
echo "found neither ./app/console nor ./bin/console";
return 1;
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment