check variable content size in sh script

Tim Daneliuk tundra at tundraware.com
Sat May 18 16:03:33 UTC 2013


#foo works with sh



On May 18, 2013 10:58:30 AM Quartz <quartz at sneakertech.com> wrote:
>
> >> newfoo=${foo:0:51}
> >>
> >
> > That works for bash, not sh.
>
> Ok granted, but I don't think that ${#foo} is straight sh either, so I 
> assumed "things bash/tcsh/ksh/whatever accept when running in sh emulation" 
> were ok.
>
> ______________________________________
> it has a certain smooth-brained appeal
> _______________________________________________
> freebsd-questions at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to "freebsd-questions-unsubscribe at freebsd.org"




More information about the freebsd-questions mailing list