I have a variable like
date="January 01 2019"
I want to split it into different variables like
month=$(echo $date|awk '{print $1}')
only I want to simplify it by doing this operation just using bash functionality. Is there any way to do it? I can tell bash to only print, say, the first 3 characters of the variable
month=${date: 0: 7}
which would not work for other months.
Is there any way to do this?