Given a set of documents, each associated with multiple tags, how can I retrieve the documents tagged with an arbitrary set of tags?
My solution
Use http://github.com/dch/couchdb-docs as source including modified perl scripts
curl -kL http://install.perlbrew.pl | bash
perlbrew install perl-5.14.2
perlbrew switch perl-5.14.2
perlbrew install-cpanm
This is where I'm thinking of going, in no particular order:
| #!/usr/bin/env perl | |
| use Modern::Perl; | |
| use Mojo::UserAgent; | |
| my $api = "https://api.github.com"; | |
| my $repo = "$api/repos/apache/couchdb"; | |
| ################################################################################ | |
| # TODO | |
| # modify AUTHORS directly |
| cl.exe | |
| -LD -MD -Zi -Wall | |
| -Ic:/erlang/lib/erl_interface-3.7.7/include | |
| -Ic:/erlang/usr/include | |
| -Iz:/source/erlgeom/deps/geos/include | |
| ..\c_src\erlgeom.c | |
| -link | |
| -LIBPATH:c:/erlang/lib/erl_interface-3.7.7/lib | |
| -LIBPATH:c:/erlang/usr/lib | |
| -LIBPATH:z:/source/erlgeom/deps/geos/lib |
| def get_or_create_db(self, db_name, designs=ALL_DESIGNS): | |
| from couchapp import dispatch | |
| couchapp_dir = os.path.join( | |
| settings.PROJECT_DIR, '..', '..', 'couchdb', 'tweet_counts' | |
| ) | |
| server = couchdbkit.Server(uri=settings.COUCHDB_SERVER_URI, | |
| resource_class=couchdb.RequestsResource) | |
| db = server.get_db(db_name) | |
| try: | |
| db.info() |
| {port_env, [ | |
| %% add MS Visual C++ support to rebar on Windows | |
| {"win32", "CC", "cl.exe"}, | |
| {"win32", "CXX", "cl.exe"}, | |
| {"win32", "LINKER", "link.exe"}, | |
| {"win32", "DRV_CXX_TEMPLATE", | |
| "$CXX /c $CXXFLAGS $DRV_CFLAGS $PORT_IN_FILES /Fo$PORT_OUT_FILE"}, | |
| {"win32", "DRV_CC_TEMPLATE", | |
| "$CC /c $CFLAGS $DRV_CFLAGS $PORT_IN_FILES /Fo$PORT_OUT_FILE"}, |
| -module(t). | |
| -export([start/0, go/0, analyze/0, server/0]). | |
| start() -> | |
| percept:profile("test.dat", {t, go, []}, [procs]). | |
| go() -> | |
| Led = led:start(1), | |
| Led1 = led:start(1), |
| Another mustache.erl example, this time showing off lists and asking for context in one of the view functions. |
| { | |
| "all_or_nothing": true, | |
| "docs": [ | |
| { | |
| "_id": "doc1", | |
| "device_id": "wub" | |
| }, | |
| { | |
| "_id": "doc2", | |
| "device_id": "wub" |