On Mon, 23 Sep 2002 [EMAIL PROTECTED] wrote: > > In a message dated: Mon, 23 Sep 2002 11:37:40 EDT > "Thomas M. Albright" said: > > >If the due date is greater than today, it outputs the message "Due in x > >days." If the due date is less than today I get a message saying "You > >are -x days past due." How can I convert the negative number into a > >positive one in bash? > > Well, assuming that 'x' is a variable which contains some whole > number representing the number of days in which 'it' is due, a > negative number representing an over-due 'it', then: > > abs_x=`echo '$x' | sed s/-//` > > ought to do it. > Yay! Thanks!
-- TARogue (Linux user number 234357) You can always tell a Texan, but you can't tell him much. - Chris Wall _______________________________________________ gnhlug-discuss mailing list [EMAIL PROTECTED] http://mail.gnhlug.org/mailman/listinfo/gnhlug-discuss