Skip to content

Instantly share code, notes, and snippets.

@sergiolucero
Last active September 11, 2018 01:47
Show Gist options
  • Save sergiolucero/4f2963ce4f2225930dbbfbc131e9121f to your computer and use it in GitHub Desktop.
Save sergiolucero/4f2963ce4f2225930dbbfbc131e9121f to your computer and use it in GitHub Desktop.
localtime
from pytz import timezone
from datetime import datetime
def localtime():
santiago = timezone('America/Santiago')
scl_time = datetime.now(santiago)
return scl_time.strftime('%Y-%m-%d_%H-%M-%S')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment