Skip to content

Instantly share code, notes, and snippets.

View devedetti's full-sized avatar
🐍

Ignacio Benedetti devedetti

🐍
  • Argentina
  • 23:11 (UTC -03:00)
View GitHub Profile
@devedetti
devedetti / cartero_loco.py
Last active August 5, 2025 13:04
Consulta de seguimiento del Correo. Ejemplo: https://gist.github.com/nachopro/8151015
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import argparse
from HTMLParser import HTMLParser
from datetime import datetime
from BeautifulSoup import BeautifulSoup
from prettytable import PrettyTable
import requests
@devedetti
devedetti / gist:8151015
Last active January 1, 2016 13:28
Ejemplo de Cartero loco
Trackeo internacional
$ python correo.py RGxxx606xxxDE
Buscando información para: RGxxx606xxxDE ...
+-------------------+-----------+--------------------+------------------------------------------+--------+--------+
| Fecha | País | Oficina | Evento | Motivo | Acción |
+-------------------+-----------+--------------------+------------------------------------------+--------+--------+
| 13-Dec-2013 11:07 | GERMANY | | Receive item from customer (Otb) | | |
| 16-Dec-2013 12:08 | GERMANY | | Insert item into bag (Otb) | | |
| 17-Dec-2013 07:00 | GERMANY | | Send item abroad (EDI-received) | | |
@devedetti
devedetti / gist:9147465
Created February 22, 2014 01:54
Vim y gVim
.vimrc
------
syntax on
set tabstop=4
set softtabstop=4
set shiftwidth=4
set expandtab
set autoindent
set ruler
set hlsearch
@devedetti
devedetti / lineal.py
Last active August 29, 2015 14:01
Resolución de ecuaciones lineales
# -*- coding: utf-8 -*-
from decimal import Decimal
from fractions import Fraction
try:
entrada = raw_input
except:
entrada = input
# -*- coding: utf-8 -*-
from decimal import Decimal
from fractions import Fraction
from lineal import numero
try:
entrada = raw_input
except:
entrada = input
@devedetti
devedetti / FireQOS @ OpenWRT
Last active October 14, 2015 20:28
FireQOS: 10mpbs/1mps fiber at home
DEVICE=eth0.2
INPUT_SPEED=9600kbit
OUTPUT_SPEED=960kbit
interface $DEVICE world-in input rate $INPUT_SPEED #balanced
class interactive commit 20%
match udp sport 53
match tcp port 22
match icmp
match tcp sports 5222,5228
Traemos los heads y creamos un branch develop desde origin/develop (lo ejecutamos la primera vez).
$ git fetch origin
$ git checkout -b develop origin/develop
** Las proximas veces, como ya tenemos el branch develop localmente, siempre antes de crear un branch para un ticket nuevo corremos (parados en el branch develop):
$ git fetch origin
$ git pull
Creamos el branch del ticket, con su número y título.
$ git branch feature/Tnumber_ticket_title
var Route = function(data) {
this.id = data.id;
this.waypoints = data.waypoints;
this._L_LatLng_list;
this._L_Polyline_obj;
};
Route.prototype._fill_L_LatLng = function() {
@devedetti
devedetti / load.py
Created November 18, 2015 21:53
pa los pibes
from random import randint
import time
from django.db import transaction
from mobile.models import Mobile, Phone, Handy, Tablet, MobileNetwork
from asset.models import Asset
ROWS = 1000
@transaction.atomic
@devedetti
devedetti / test_obd.py
Last active July 23, 2016 04:02
An OBD 16x2 Display
import curses
from time import sleep
from random import randint
myscreen = curses.initscr()
MAX_RPM = 6500
EMPTY = chr(9617)
FULL = chr(9619)
SPEED = ((0, 0), (1,20), (21,40), (35, 60), (50, 90), (60, 145))