Find difference between two dates in bash

Viewed 19542

I attempted to get the difference between two dates with:

date -d $(echo $(date -d "Sun Dec 29 02:22:19 2013" +%s) - $(date -d "Sun Dec 28 03:22:19 2013" +%s) | bc)

However, this returns

date: invalid date ‘82800’

Why is this, and how can I get the desired result?

1 Answers
Related