Skip to content

Instantly share code, notes, and snippets.

View eluttner's full-sized avatar
🏠
Working from home

eduardo luttner eluttner

🏠
Working from home
View GitHub Profile
@eluttner
eluttner / Makefile
Created August 9, 2019 10:57 — forked from miguelmota/Makefile
Makefile docker push to AWS Elastic Container Registry (ECR)
# Login to AWS registry (must have docker running)
docker/registry/login:
$$(aws ecr get-login --no-include-email --region us-east-1 --profile=mycompany)
# Build docker target
docker/build:
docker build -f Dockerfile --no-cache -t mycompany/myapp .
# Tag docker image
docker/image/tag:
@eluttner
eluttner / docker-cheat-sheat.md
Created November 7, 2017 23:22 — forked from dwilkie/docker-cheat-sheat.md
Docker Cheat Sheet

Build docker image

$ cd /path/to/Dockerfile
$ sudo docker build .

View running processes

@eluttner
eluttner / formatters.py
Created October 5, 2015 21:53 — forked from igorsobreira/formatters.py
Django form field for Brazilian Real (R$)
from django.template.defaultfilters import floatformat
from django.contrib.humanize.templatetags.humanize import intcomma
from django.utils.encoding import force_unicode
def decimal_to_real(value, precision=2):
'''
Receives a Decimal instance and returns a string formatted as brazilian Real currency:
12,234.00. Without the "R$".
'''
value = floatformat(value, precision)
export PATH=/Library/PostgreSQL/9.3/bin/:"$PATH"
pip install psycopg2
@eluttner
eluttner / hack.sh
Created May 29, 2014 19:33 — forked from erikh/hack.sh
#!/usr/bin/env sh
##
# This is script with usefull tips taken from:
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
#
# install it:
# curl -sL https://raw.github.com/gist/2108403/hack.sh | sh
#