Welcome to the Disruptive Library Technology Jester. From here you can browse the musings and visions of a library technologist as he walks the fine line between the best of the library profession on one side and the best of technology on the other.

Modify Islandora objects on-the-fly using Devel “Execute PHP Code”

Alan Stanley taught me this trick at an Islandora Camp a few years ago, and when trying to remember it this morning I messed up one critical piece. So I’ll post it here so I have something to refer back to when I need to do this again.

The Drupal Devel module includes a menu item for executing arbitrary PHP code on the server. (This is, of course, something you want to set permissions on very tightly because it can seriously wreck havoc on your day if someone uses it to do bad things.) Navigate to /devel/php on your Islandora website (with the Devel module enabled), and you’ll get a nice, big ≶textarea> and an “Execute” button:

How to fix a directory that Git thinks is a submodule

Nuts. I added and committed a directory to my Git repository when the directory itself was another separate Git repository. Now Git thinks it’s some sort of submodule, but it doesn’t know how to deal with it:

$ git submodule update
No submodule mapping found in .gitmodules for path 'blah'

And worse, Git won’t let me remove it:

$ git rm blah
error: the following submodule (or one of its nested submodules)
uses a .git directory:
(use 'rm -rf' if you really want to remove it including all of its history)

So what to do? This:

$ git rm --cached blah
$ git add blah

In my case I had a situation where there were several Git repositories-inside-a-repository, so I wanted a way to deal with them all:

$ for i in `find . -type d -name .git -print | sed 's#/.git##'`; do 
> echo $i
> rm -rf $i/.git
> git rm --cached $i
> git add $i
> done

(Be careful not to run this find command at the root of your Git repository, of course, or else you will effectively destroy its usefulness as a git repo. )

Idea for an NPR Twitter bot — Tweet me about that story I just heard

So I had an idea for a Twitter bot I would like to see. Occasionally I’ll be listening to a story on NPR and I’ll want to know more about it. Sometimes the host will say something like: “come to npr.org for more information and click on…” Other times it will be because I missed a crucial bit of the story and I’ll want to know more about it. So why not have a Twitter bot that I can call upon to say “Tell me more about that story”:

Emerging Tech: Bluetooth Beacons and the DPLA

This is the text of a talk that I gave at the NN/LM Greater Midwest Region tech talk on January 29, 2016. It has been lightly edited and annotated with links to articles and other information. The topic was “Emerging Technology” and Trisha Adamus, Research Data Librarian at UW-Madison and Jenny Taylor, Assistant Health Sciences Librarian at UIC LHS in Urbana presented topics as well.

Bluetooth Beacons