to keep your mac awake:
caffeinate -di
Thank you! Did not know about this command before - good to know