Get Date

Return a date in the requested format.

Source code

Usage

Input

Parameter Description Type Required Default Value
after Return a date number of days in the future int No None
before Return a date number of days in the past int No None
format Specify the format of the returned date.
string, iso, datetime
string No datetime
debug Increase log verbosity bool No False
silent Decrease log verbosity bool No False
output Output format
table
string No None

Output

Returns the generated date in the requested format:

'2021/01/01' | '2021-01-01T00:00:00Z' | '2021-01-01 00:00:00'

Examples

Get the date 10 days in the future in iso format:

aaws general get_date --after 10 --format iso

Get the date 15 days in the past in string format:

aaws general get_date --before 15 --format string