Name: Kippt
URL: http://kippt.com/save/?url=${url}&title=${title}&source=greader
Icon URL: http://kippt.com/static/img/favicon.png
class ListResource(ModelResource): | |
''' | |
API resource for lists | |
Logged in user is mapped to the model using this: | |
http://django-tastypie.readthedocs.org/en/latest/cookbook.html#creating-per-user-resources | |
''' | |
class Meta: | |
queryset = List.objects.all() |
# Put this in your urls.py file after the admin.autodiscover() line. | |
# --------------------------------------------------------------------------------- | |
# Monkeypatch the Celery admin to show a column for task run time in the list view. | |
from djcelery.admin import TaskMonitor | |
from djcelery.models import TaskState | |
admin.site.unregister([TaskState]) | |
TaskMonitor.list_display += ('runtime',) | |
admin.site.register(TaskState, TaskMonitor) |
_.extend Backbone.Router.prototype, { | |
# load a new fragment, replacing the current history entry with the new fragment | |
# this is used to prevent a back-button-redirect loop | |
redirect:(fragment) -> | |
Backbone.history.redirect(fragment) | |
} | |
_.extend Backbone.History.prototype, { | |
redirect:(fragment) -> | |
frag = (fragment || '').replace(/^#*/, '') |
$(function() { | |
var converter = new Showdown.converter(); | |
$("#user_input").keyup(function(){ | |
var txt = $("#user_input").val(); | |
var html = converter.makeHtml(txt); | |
$("#result").html(html) | |
$("#html_result").val(html.replace(/>/g, ">\n").replace(/</g, "\n<").replace(/\n{2,}/g, "\n\n")); | |
}); | |
var sample = "#### Underscores\nthis should have _emphasis_\nthis_should_not\n_nor_should_this\n\n\ |
import re | |
import simplejson | |
from django.http import HttpResponse | |
from django.conf import settings | |
class JSONResponse(HttpResponse): | |
def __init__(self, request, data): | |
indent = 2 if settings.DEBUG else None |
https://www.facebook.com/dialog/oauth?scope=email%2Cpublish_stream%2Coffline_access&state=&redirect_uri=http%3A%2F%2Flocalhost%3A8080%2Fsocial%2Ffacebook%2Fcallback%2F&response_type=code&client_id=2645809696793984 |
Name: Kippt
URL: http://kippt.com/save/?url=${url}&title=${title}&source=greader
Icon URL: http://kippt.com/static/img/favicon.png
# Add new server for organization YYYYYY | |
/server add grove YYYYYY.irc.grove.io/6667 | |
/set irc.server.YYYYYY.password "YYYYYY" | |
# Set your username to BBBB | |
/set irc.server.YYYYYY.username "BBBB" | |
/set irc.server.YYYYYY.nicks "BBBB" | |
# Set your password | |
/set irc.server.YYYYYY.command "/msg NickServ identify xxxxxx" |
/* | |
** GitHub'fy Grove.io with dot.js | |
** | |
** source: http://github.github.com/github-flavored-markdown/scripts/showdown.js | |
** dotjs: http://defunkt.io/dotjs/ | |
*/ | |
var repo = 'Organization/repo'; | |
setInterval(function(){ |
document.getElementById('groveNotificationEventDiv').addEventListener('groveNotificationEvent', function() { | |
var eventData = document.getElementById('groveNotificationEventDiv').innerText; | |
console.log(JSON.parse(eventData)); // Show data for notifications | |
// Do notification here | |
}); |