[user@mymachine folder]$ echo `date --date=tomorrow +%Y%m%d`
20160802
[user@mymachine folder]$ echo `date -d=tomorrow +%Y%m%d`
date: invalid date `=tomorrow'
I'm using Centos 5 if that makes any difference.
[user@mymachine folder]$ echo `date --date=tomorrow +%Y%m%d`
20160802
[user@mymachine folder]$ echo `date -d=tomorrow +%Y%m%d`
date: invalid date `=tomorrow'
I'm using Centos 5 if that makes any difference.
The short options or unix style options are usually separated from its argument using a space, but space is not strictly required in some cases
For instance
echo `date -dtomorrow +%Y%m%d`
and
echo `date -d tomorrow +%Y%m%d`
would work just fine
However in case of,
echo date -d=tomorrow +%Y%m%d
=tomorrow is considered the argument to d but it doesn't make a valid date string