date +”%T”

How do I get the current server time in shell script on Linux or Unix-like operating systems? How do I store the current time in the shell variable and use in my scripts?

{ 5 comments }