> -----Original Message----- > From: Jihuang Zhou > Sent: Thursday, March 13, 2003 4:42 PM > Subject: a question about shell script > > > Hi list, > Anybody knows how to get an input parameter list from the second > parameter to the second last? > For example, if $*="aa bb cc ....mm nn", I need the "bb ... mm". > Here, the number n may change. Any commad like substr in Shell?
Yes! Type: man bash Then at the colon prompt, type: /substring\ expansion The leading slash puts man into search mode for the string that follows. All the cases listed this section of the man page will probably be of use to you. Especially the ${parameter:offset:length} case. Steve Cowles -- redhat-list mailing list unsubscribe mailto:[EMAIL PROTECTED] https://listman.redhat.com/mailman/listinfo/redhat-list