On Thu, Mar 31, 2011 at 01:28:44PM +0100, Richard Parsons wrote:
If anyone can suggest a better way of working out 'yesterday' than that horrible case sequence I'd love to see it. While the case works it grates rather when I look at it! (It has to be in ash or sh, the NAS doesn't have bash or similar)
date -d yesterday +%a works for me.
Sadly my WD NAS doesn't know about 'yesterday' :-
root@backup# date -d yesterday +%a date: invalid date `yesterday' root@backup#
The NAS uses busybox for the bulk of its commands and 'date' is among those so I guess it's a fairly limited implementation.