/Gulp

Guess I'm too `new` skool!  ;-P

Cheers!

On Tue, Jan 08, 2008 at 12:47:53AM -0500, John Levine wrote:
> >---------------------
> >#!/bin/sh
> >
> >if [ ".gz" = "`echo \"$STRING\" | sed -n 's/.*\(\.gz\)$/\1/p'`" ]; then
> > echo test;
> >fi
> 
> Ewwww.  I think that we can now safely take advantage of
> features added to the shell in the late 1970s.
> 
> -----------------------
> #!/bin/sh
> 
> case "$1" in
>  *.gz) echo that is a gzipped file ;;
>  *) echo that is not a gzipped file ;;
> esac
> 
> -----------------------
_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to