Skip to content

Instantly share code, notes, and snippets.


Richard Cotrina rcotrina94

View GitHub Profile
rcotrina94 /
Last active Aug 20, 2019
Realtek Semiconductor RTL8723DE Device d723 Linux Ubuntu
rcotrina94 /
Last active Jul 8, 2018
Instalando PyFBA en Ubuntu 18.04


sudo apt-get install libglpk-dev glpk-utils glpk-doc libglpk40 libgmp10 libgmpxx4ldbl


mkdir ~/pyfba
rcotrina94 / .hgignore
Created Jun 2, 2017
Mercurial Ignore File for Django (Python) Projects
View .hgignore
# glob syntax
syntax: glob
# Temp files
# Nodejs
rcotrina94 / server.js
Created Mar 6, 2017
NodeJS server with CORS headers.
View server.js
var socket = require(''),
http = require('http'),
server = http.createServer(function(req, res){
res.setHeader('Access-Control-Allow-Origin', '*');
// res.setHeader('Access-Control-Request-Method', '*');
// res.setHeader('Access-Control-Allow-Methods', 'OPTIONS, GET');
// res.setHeader('Access-Control-Allow-Headers', '*');
if ( req.method === 'OPTIONS' ) {
# -*- coding: utf-8 -*-
import telebot
from telebot import types
USER_WELCOME = "Bienvenido al servicio de HomeHub."
USER_REGISTERED = "{}, te hemos registrado en nuestro sistema."
TOKEN = "123456789:TOKEN4529424024-ConfiguraTuTokenXDXDXDXD"
bot = telebot.TeleBot(TOKEN)
View Peru.txt
||||||||||||||||| ||||||||||||||||||||||
|||||||||||||||| ||||||||||||||||||||
|||||||| ||||| . ||||||||||||||
|||||| |||| |||||||||||||||
|||||| |||||||||||||||||
rcotrina94 /
Last active Mar 24, 2016
Exportar en Django con "django-export-import"

Exportar en Django con "django-export-import"

django-export-import es un paquete de django que nos facilita la tarea de exportar e importar desde y hacia diferentes formatos de datos (CSV, XLS, JSON, HTML).

Éste paquete tiene 4 clases que serán las que más se utilizarían para exportar (y quizás también importar) fácilmente desde nuestra aplicación de Django.

class import_export.resource.ModelResource

Ésta clase nos sirve para poder utilizar los modelos de Django como recursos (Resources)

class import_export.resource.ResourceOptions (Meta)

rcotrina94 /
Last active Jun 8, 2022
What do professional developers think of online programming courses such as Codecademy or Code School?

What do professional developers think of online programming courses such as Codecademy or Code School?

by Song Zheng,Developer

90% of the people who use Codecademy and Codeschool to try to learn coding fail. This is because 90% of people who turn to Codecademy and Codeschool are learning programming for the sake of learning how to code. This is why you will not be hired if you list Codecademy and/or CodeSchool badges on your resume.

The other 10% of people who use Codecademy or Codeschool become successful developers because they are learning programming to build a tictactoe game to play with their friends; a ecommerce site so they can sell things; a video chat app to connect with relatives; etc.

There is a very different mentality between the 90% and the 10% who are learning programming, and the successful ones are those who sees learning platforms as means to an end, not the end itself. For example, if you have no programming experience and want to learn how to code, your goal should not be claimi

rcotrina94 /
Last active May 6, 2021
Install Moodle on NGINX
View login.html
{% extends "base/main.html" %}{% load staticfiles bootstrap %}
{% block header %}
{% endblock %}
{% block content %}
<div id="login-form" class="vcenter">
<div class="container-fluid">
<form method="POST" enctype="multipart/form-data" autocomplete="off">
{% csrf_token %}
<div class="col-xs-10 col-xs-offset-1 col-sm-6 col-sm-offset-3 col-lg-4 col-lg-offset-4">
<div class="panel panel-default">