Skip to content

Instantly share code, notes, and snippets.

@hschmitt
hschmitt / email-reminder.php
Created September 28, 2011 03:11 — forked from chrisguitarguy/email-reminder.php
Sends an email reminder if you haven't posted on your WordPress blog in a week
<?php
/*
Plugin Name: Reminder Emails
Plugin URI: http://www.christopherguitar.net/
Description: Sends a reminder email if you haven't posted in seven days.
Version: n/a
Author: Christopher Davis
Author URI: http://www.christopherguitar.net
License: GPL2, Creative Commons
*/
9 from django.conf import settings
86 def recipes(request, wine_id):
87 """
88 Returns a list of recipes recommended for a wine.
89 """
90 # Grab the wine from the database
91 wine = get_object_or_404(Wine.objects.current(), id=wine_id).
92 # Start building the document
93 document = OrderedDict()
<html>
<head>
<title></title>
</head>
<body>
<p>
&nbsp;</p>
<p>
<strong>Descripci&oacute;n Detallada:</strong></p>
<p>
{ "name": "circuito1",
"category": { "href": "http://localhost:8080/api/v1/circuits/categories/architecture", "rel": "alternate", "title": "Arquitectura", "type": "application/json" },
"description":"This is a placeholder\n Description",
"author": {"name" : "Hansy Schmitt"},
"rating": 0.0,
"topics": [],
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAAgQDZbfgEyFa8W+C1KPjrS1U80G3XJr8wysow6RRSgSaiS+zfR4H4z/RzI55gqTPG1QR9xH8iMKw9VRvNvhe2wVa3K5y8XPHvVRBWavW6mkueiOUZa5mDURvaHDQdQvSdjVr8g5fb4osmcqNH3KCScu4IjPmqdS3VGnQxWpS+TLKhlQ== schmitt.hansy@gmail.com
@hschmitt
hschmitt / gist:3530953
Created August 30, 2012 15:30
DragonBot Js
if ("undefined" == typeof ZotataPlayUserID) var ZotataPlayUserID = "";
if ("undefined" == typeof ZotataPlayAuthKey) var ZotataPlayAuthKey = "";
if ("undefined" == typeof debug) var debug = -1 != location.hostname.indexOf("t.dragonbound.net");
var VERSION = 101,
SERVER_ADDRESS = -1 != location.hostname.indexOf("t.dragonbound.net") ? "http://t.dragonbound.net:9000" : "http://game.dragonbound.net:80",
LOCATION_TYPE_UNKNOWN = "unknown",
LOCATION_TYPE_CHANNEL = "channel",
LOCATION_TYPE_ROOM = "room",
ROOM_STATUS_WAITING = "W",
ROOM_STATUS_FULL = "F",
# -*- coding: utf-8 -*-
from django.contrib import admin
from circuits.models import Circuit, CircuitStop, Topic
from circuits import constants
class CircuitAdmin(admin.ModelAdmin):
list_display = ('name','description','category','category_dropdown')
class Media:
js = ('/static/js/inline_admin.js','')
Guía para contribuir con los repositorios de github de GDGLima
1.- Animarse con las ganas para contribuir... y terminar de leer esta guía.
2.- Tener una cuenta en github.
3.- Instalar algun cliente git (TortoiseGit en windows, git cli en MAC y linux distros)
4.- Configurar nuestra cuenta en github (Estos pasos los podemos completar siguiendo esta otra guía https://help.github.com/articles/set-up-git en ingles)
import random
import sys
def product_key():
all_keys = []
#Check Arguments
if len(sys.argv) == 2:
total_keys = int(sys.argv[1])
else:
print "Esta funcion requiere como 1 argumento"
import random
import sys
def ascii_acumulator():
#Check Arguments
acumulador = 0
if len(sys.argv) == 2:
filename = sys.argv[1]
try:
handler = open(filename, "r")