Skip to content

Instantly share code, notes, and snippets.

Leonardo Antunes antunesleo

Block or report user

Report or block antunesleo

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
branflake2267 / main.dart
Created Mar 3, 2018
Flutter - Using the future builder with infinite list view.
View main.dart
import 'dart:async';
import 'package:flutter/material.dart';
void main() => runApp(new MyApp());
class MyApp extends StatelessWidget {
Widget build(BuildContext context) {
return new MaterialApp(
mayukh18 /
Created Sep 28, 2017
How to setup flask app with database on heroku

Setting up flask app in heroku with a database

The below article will cover the intricacies of setting up databases and heroku in respect to a flask app. This is more like a memo and will have out of sequence instructions or solutions to errors so read thoroughly.

Setting up a database

You'll need the packages

IamAdiSri / Python3, Pip3, Virtualenv and Virtualenvwrapper Setup
Last active Aug 14, 2019 — forked from evansneath/Python3 Virtualenv Setup
Setting up and using Python3, Pip3, Virtualenv (for Python3) and Virtualenvwrapper (for Python3)
View Python3, Pip3, Virtualenv and Virtualenvwrapper Setup
First install pip for Python2. Download the file from
$ cd <download location>
$ sudo -H python ./
Installing pip also installs Python3
To run Python3
$ python3
Install pip3 by just executing the same file as in the step above, but this time using Python3
$ sudo -H python3 ./
simongfxu / webpack.nginx.conf
Last active Aug 6, 2019
webpack-dev-server configuration in nginx on development server
View webpack.nginx.conf
upstream ws_server {
server {
listen 80;
location / {
proxy_pass http://ws_server/;
drmalex07 /
Created May 12, 2014
Convert GeoJSON to/from WKT in Python. #python #geojson #geometry
import json
import geojson
from shapely.geometry import shape
o = {
"coordinates": [[[23.314208, 37.768469], [24.039306, 37.768469], [24.039306, 38.214372], [23.314208, 38.214372], [23.314208, 37.768469]]],
"type": "Polygon"
s = json.dumps(o)
# extracted from http//
# under public domain terms
country_bounding_boxes = {
'AF': ('Afghanistan', (60.5284298033, 29.318572496, 75.1580277851, 38.4862816432)),
'AO': ('Angola', (11.6400960629, -17.9306364885, 24.0799052263, -4.43802336998)),
'AL': ('Albania', (19.3044861183, 39.624997667, 21.0200403175, 42.6882473822)),
'AE': ('United Arab Emirates', (51.5795186705, 22.4969475367, 56.3968473651, 26.055464179)),
'AR': ('Argentina', (-73.4154357571, -55.25, -53.628348965, -21.8323104794)),
'AM': ('Armenia', (43.5827458026, 38.7412014837, 46.5057198423, 41.2481285671)),
mobilemind /
Last active Aug 18, 2019
how to delete a git tag locally and remote
# delete local tag '12345'
git tag -d 12345
# delete remote tag '12345' (eg, GitHub version too)
git push origin :refs/tags/12345
# alternative approach
git push --delete origin tagName
git tag -d tagName
jgoodall /
Last active Jul 31, 2019
This is a sample of how to send some information to logstash via the TCP input from node.js or python.

This is a sample of how to send some information to logstash via the TCP input in nodejs or python. It assumes the logstash host is on and the TCP listening input is 9563.

The logstash.conf should look something like the sample file.

The log message should be a stringified JSON object with the log message in the @message field.

To use, run the node script node sendMessageToLogstash.js, or the python script python sendMessageToLogstash.js

alopes / stopwords.txt
Created Apr 10, 2013
Portuguese stop words
View stopwords.txt
banaslee / XGH - en.txt
Last active Aug 15, 2019
eXtreme Go-Horse Process
View XGH - en.txt
eXtreme Go Horse (XGH) Process
1. I think therefore it's not XGH.
In XGH you don't think, you do the first thing that comes to your mind. There's not a second option as the first one is faster.
2. There are 3 ways of solving a problem: the right way, the wrong way and the XGH way which is exactly like the wrong one but faster.
XGH is faster than any development process you know (see Axiom 14).
You can’t perform that action at this time.