Just thought I post a quick update point out the new Gist List in that left hand side-bar thingy! Just some documentation and Clojure solutions, but hopefully someone finds them useful/enjoyable.
What I’ve added is a couple of pieces of documentation for Drupal and Apache
Solr that are part of the outcome of a recent project. The Drupal docs
are related to creating and understanding some aspects of integrating
Views with your module(s). From the deceptively simple process of
explaining your data to Views via the
this gist. Or
creating and extending View handlers.
Also I wrote something around how to leverage the Solr and Drupal
This gist is pretty much
just a list of some useful functions, and where and how they should be
used. How to ask the
apachesolr module the right
questions and how to search Solr from code.
I wrote the other piece of documentation about the basics of constructing a Solr query. It’s here. I found the state of simple getting started type tutorials for Solr query syntax to be awful and the official documentation is terrible for new users. So I thought I’d condense what I learned into a easily digestible starter for any new users.
The first two little gists though are a couple of solutions to some Clojure koans. One is a string leetifier that will convert a given string to late 90s l33t sP3ak. It’s missing one of the rules surrounding the capitilisation of some letters if they appear after a number, but it’s still works and was a fun problem in Clojure.
The other is a scrabble word scorer, that will return the score for a given word based on some baked in letter values. It supports double and triple letter and word scores based that are added using an optional second parameter. I didn’t really add any constraints so it’ll probably try to score an entire sentence if you’re keen.
The gists are public of course, so please comment/fork/clone as ye sees fit! I should have some Haskell shenanigans to add soon too!