Using Linux (Redhat)I need some help regarding the a/m requestWhen I use  dialog: --calendar to output the date.The format will be dd/mm/yyyy but I need the format to be d/m/yyyy for day and month numbers smaller than 10.ExampleOutput: 01/09/2012Result: 1/9/2012Any suggestions are appreciated.
how to remove 0 (zero) from the day and month but not from the year (01/09/2012) using in Linux (Redhat)
linux;shell script;date
You can use sed. Here it removes all leading 0's appearing at the beginning of every word: \<. $ echo 01/09/2012 | sed 's/\<0//g'1/9/2012You might also used \b which match any word boundary:$ echo 01/09/2012 | sed 's/\b0//g'1/9/2012