Skip to content

Instantly share code, notes, and snippets.

View mtalimanchuk's full-sized avatar

Maxim Talimanchuk mtalimanchuk

View GitHub Profile
@brock
brock / psql-with-gzip-cheatsheet.sh
Last active June 27, 2024 10:09
Exporting and Importing Postgres Databases using gzip
# This is just a cheat sheet:
# On production
sudo -u postgres pg_dump database | gzip -9 > database.sql.gz
# On local
scp -C production:~/database.sql.gz
dropdb database && createdb database
gunzip < database.sql.gz | psql database
@jesseyv
jesseyv / gist:1175064
Created August 27, 2011 06:24
Tornado Template Syntax
Basic Output
Hello, {{ current_user.name }}
Basic Logic
{% if not current_user %}
You're not logged in!
{% elif current_user and curent_user.is_admin %}
Good day, sir!
{% else %}