Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯
Focusing

Joao Daher joaodaher

🎯
Focusing
View GitHub Profile
View Pycharm and Docker
Run Docker daemon
brew install socat
socat TCP-LISTEN:2375,reuseaddr,fork UNIX-CONNECT:/var/run/docker.sock
In PyCharm, go to Preferences>Build,Execution>Docker and add a new:
API URL: tcp://localhost:2375
Certficates Folder: <empty>
Docker Compose Executable: /Applications/Docker.app/Contents/Resources/bin/docker-compose
View Gitflow.md

Fluxo de desenvolvimento

Branches

Master

Cada commit nessa branch deve ser considerado pronto para deploy em produção (ContinuousIntegration-ready)

  • Branch off: -
  • Merge to: hotfix/
View Elastic Cloud on GCP.md
View humanizeEduk.py
from datetime import datetime
def _ordinal(day):
SUFFIX = {
1: 'st',
2: 'nd',
3: 'rd',
}
if day in [11, 12, 13]:
@joaodaher
joaodaher / content_api_checker.py
Last active Sep 25, 2018
Test all possible v1 endpoints from Content API, comparing staging and development environments
View content_api_checker.py
import requests
from dateutil.parser import parse
class DictDiffer(object):
"""
Calculate the difference between two dictionaries as:
(1) items added
(2) items removed
(3) keys same in both but changed values
@joaodaher
joaodaher / setup.py
Last active Mar 31, 2020
Pipfile to setup.py install_requires
View setup.py
import json
import os
from setuptools import find_packages, setup
def read(f):
return open(f, 'r', encoding='utf-8').read()
def parse_requirements():
You can’t perform that action at this time.