Skip to content

Instantly share code, notes, and snippets.

View rcotrina94's full-sized avatar

Richard Cotrina rcotrina94

View GitHub Profile
@rcotrina94
rcotrina94 / Color.sh
Last active August 29, 2015 14:24
Color palettes
#!/bin/bash
#
# This file echoes a bunch of color codes to the
# terminal to demonstrate what's available. Each
# line is the color code of one foreground color,
# out of 17 (default + 16 escapes), followed by a
# test use of that color on all nine background
# colors (default + 8 escapes).
#

#Linux FAQs

@rcotrina94
rcotrina94 / run.py
Created September 22, 2015 14:13
Run ALU raspberry pi server
# -*- coding: utf-8 -*-
import numdisplay
from datetime import datetime
from flask import Flask
app = Flask(__name__)
@app.route("/num/<int:number>")
def num(number=None):
if number == None:
@rcotrina94
rcotrina94 / alu.ino
Last active September 30, 2015 01:23
Alu Arduino
//Entradas para A
int iA0 = 13;
int iA1 = 12;
int iA2 = 11;
int iA3 = 10;
//Entradas para B
int iB0 = 9;
int iB1 = 8;
int iB2 = 7;
@rcotrina94
rcotrina94 / InsertarFinalVProlog.md
Created October 2, 2015 03:03
Visual Prolog: Insertar un elemento al final de una lista

#Visual Prolog

Insertar un elemento al final de una lista

@rcotrina94
rcotrina94 / InsertarInicioVProlog.md
Created October 2, 2015 03:08
Visual Prolog: Insertar un elemento al inicio de una lista

Visual Prolog

Insertar un elemento al inicio de una lista

@rcotrina94
rcotrina94 / esPrimoVProlog.md
Last active October 7, 2015 00:09
Visual Prolog: Verificar si un número es primo o no.

Visual Prolog

Identificar si el número es primo o no.

@rcotrina94
rcotrina94 / nginx_trim_www.conf
Last active November 11, 2015 19:05
[Nginx] Redirect www to no-www for multiple server names.
server {
listen 80;
server_name ~^(?!www\.)(?<domain>.+)$;
return 301 $scheme://$domain$request_uri;
}
@rcotrina94
rcotrina94 / Installing GNU Health.md
Last active May 16, 2020 04:43
Installing GNU Health

Instalando GNU Health

Antes de instalar GNU Health y sus dependencias se debe tener en cuenta los requisitos de software para el sistema, que son los siguientes:

  • Sistema Operativo: GNU Health es independiente del S.O., sin embargo es muy recomendado el uso de un S.O. Libre (como GNU/Linux or FreeBSD)
  • Motor de Base de datos: PostgreSQL
  • Python: >= 2.7 < 3.0
  • Tryton: = 3.4
  • BASH Shell
@rcotrina94
rcotrina94 / RPI2_django_server.md
Last active February 13, 2017 03:09
Turning a Raspberry Pi 2 ready into a portable Django development server.

Actualizar índices de repositorios

sudo apt-get update

Instalar git

sudo apt-get install git

Instalar mercurial

sudo apt-get install mercurial

Instalar instalador de módulos de Python - Instalar pip