Am 31.12.2011 20:05, schrieb Ivan Vučica: > Hi all, > > I find it rather annoying to have to type "openapp ./AppName.app". I > propose the following patch for openapp, in interest of easier use of > bash autocomplete. > > Index: openapp.in <http://openapp.in> > =================================================================== > --- openapp.in <http://openapp.in> (revision 34347) > +++ openapp.in <http://openapp.in> (working copy) > @@ -246,7 +246,8 @@ > if [ -z "$openapp_full_appname" ]; then > echo "Can't find the required application: $openapp_app!" > if [ -d "./$openapp_app" ]; then > - echo "There is a $openapp_app in this directory; please use > 'openapp ./$openapp_app' if you want to open it!" > + echo "Using $0 \"./$openapp_app\"" > + exec "$0" "./$openapp_app" > fi > exit 1 > fi > > It's most definitely far from perfect, considering it does not pass any > arguments appearing after app name. However, it's good enough for most > of the cases, especially since it throws a warning which should help the > developer that needs that feature understand why the arguments are not > passed on. > > It is definitely more helpful than previous behavior, and I can't think > of any downsides.
You mean apart from the apparent downside of opening a security hole that allows somebody to plant a malicious app bundle in the cwd? By the same rationale, you shouldn't have "." in your PATH, despite of the minor inconvenience. Cheers, Niels _______________________________________________ Discuss-gnustep mailing list [email protected] https://lists.gnu.org/mailman/listinfo/discuss-gnustep
