This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// from local.ini | |
[couch_httpd_auth] | |
authentication_db = users | |
require_valid_user = true | |
// http://localhost:5984/users/_design/_auth/_view/users | |
{"total_rows":1,"offset":0,"rows":[ | |
{"id":"users","key":"stefano","value":{"password_sha":"EwPfA3e1xccq6zn5M0qUp6141hU=","roles":["_reader","_writer","_admin"],"seed":"1234"}} | |
]} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Barista.Template.teamMember = function(el, data) { | |
$.each(data.rows, function(i, member) { | |
el.clone().insertBefore(el).removeClass('t').removeClass('t-teamMember').text(member.name); | |
}); | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/__init__.py b/__init__.pyindex 66f0f05..57574d6 100644 | |
--- a/__init__.py | |
+++ b/__init__.py | |
@@ -5,7 +5,7 @@ import re | |
import sys | |
from exceptions import * | |
from utils import * | |
-from lxml import etree | |
+from xml.etree import ElementTree | |
from urllib import urlencode |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env coffee | |
# The URL of the web site to make crawlable | |
URL: 'http://localhost' | |
# Time to wait for all the scripts to run, in ms | |
DELAY: 3000 | |
# Script to run to clean up the markup before serializing | |
CLEANUP: (window) -> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;;; haml-mode.el --- Major mode for editing Haml files | |
;; Copyright (c) 2007, 2008 Nathan Weizenbaum | |
;; Author: Nathan Weizenbaum | |
;; URL: http://github.com/nex3/haml/tree/master | |
;; Version: 1.0 | |
;; Keywords: markup, language | |
;;; Commentary: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery.ajax({ | |
type: "PUT", | |
url: "http://key:[email protected]:5984/staging/doc1", | |
data: '{}', | |
contentType: "application/json", | |
success: function (data, textStatus, XMLHttpRequest) { | |
alert("ok " + data); | |
}, | |
error: function (XMLHttpRequest, textStatus, errorThrown) { | |
alert("ko"); // {}, "error", undefined |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git clone git://github.com/cloudant/opencore.git |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
conn = S3Connection(amazon_ID, amazon_KEY) | |
bucket = conn.get_bucket(bucketname) | |
k = Key(Bucket) | |
k.set_contents_from_filename(filename) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server = Server('http://user:[email protected]) | |
db = server.get_or_create(dbname) | |
doc = db[docid] | |
db.put_attachment(doc, file(filename)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import couchdbkit, boto |
OlderNewer