Skip to content

Instantly share code, notes, and snippets.

View hcosta's full-sized avatar

Hektor hcosta

View GitHub Profile
pip freeze > requirements.txt
$ virtualenv <env_name>
$ source <env_name>/bin/activate
(<env_name>)$ pip install -r path/to/requirements.txt
Variable: ANDROID_HOME Value: C:\Development\adt-bundle\sdk
Variable: ANT_HOME Value: C:\Development\apache-ant
Variable: JAVA_HOME Value: C:\Program Files\Java\jdk1.6.0_45
Next I added the following values to the """""Path system variable""""" NO USER in Environment Variables:
%JAVA_HOME%\bin;%ANT_HOME%\bin;%ANDROID_HOME%\platform-tools;%ANDROID_HOME%\tools;
@hcosta
hcosta / php.ini
Created July 1, 2014 11:33
more file size in phpmyadmin
post_max_size = 800M
upload_max_filesize = 800M
max_execution_time = 5000
max_input_time = 5000
memory_limit = 1000M
@hcosta
hcosta / import_export_mysql
Last active July 31, 2016 15:04
import/export mysql db
mysqldump -h localhost -u user_name -p your_database_name (your_table_name_optative) > dump_file.sql
mysql -u your_user -p your_database < dump_file.sql
@hcosta
hcosta / herokuconfig
Created August 4, 2014 14:33
Heroku Config
->heroku login
[email protected] & password
->cd C:\Users\yourusername\.ssh (OR for cygwin shell ->cd ~/.ssh)
->ssh-keygen -t rsa -f id_rsa
if asks any passphrase don't use blank, fill with a passphrase,but not forget it.
After generating the key you need to add it, like so
@hcosta
hcosta / gist:dd8188b1a4540e991ffa
Created November 13, 2014 15:38
install apk using adb
adb devices
# get device id
adb -s <id> install file.apk
git branch <new_branch>
git checkout <new_branch>
git checkout master
git merch <new_branch>
@hcosta
hcosta / Herencia.py
Created November 15, 2014 15:34
Clase de herencia para youtube
# coding=utf-8
# Superclase o clase padre/madre
class Libro:
# Inicializador
def __init__(self, isbn, titulo, autor, precio):
# Asignacion de variables
@hcosta
hcosta / hola.py
Last active August 29, 2015 14:09
class A:
def hola(self):
print "Hola clase A"
def a(self):
print "Soy de A"
class B:
def hola(self):
class A:
def saludo(self):
print "Hola, soy A."
class B(A):
def saludo(self):
print "Hola, soy B."
# En otro lenguaje se especificaría que el objeto sea
# una instancia explícita de una clase común, mientras