From mboxrd@z Thu Jan 1 00:00:00 1970 MIME-Version: 1.0 Date: Fri, 5 Mar 2010 22:52:10 -0600 Message-ID: From: Jason Catena To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> Content-Type: text/plain; charset=ISO-8859-1 Subject: [9fans] =?windows-1252?q?nb=97search_and_index_notes_in_files_by_?= =?windows-1252?q?keyword?= Topicbox-Message-UUID: e153920a-ead5-11e9-9d60-3106f5b1d025 http://swtools.wordpress.com/2010/03/05/nb%E2%80%94search-and-index-notes-in-files-by-keyword/ This isn't complicated, but it hit a sweet spot with me, since I like to break up information into smallish chunks and index it by keyword. It collects the keywords into one file per directory, and keeps a list of all the indexes in a file in $HOME. It searches all the existing indexes for the given keyword, then reconstructs the index for the current directory, so it presents slightly older results fast. Its relationship with plan9 is that it's written in rc, and outputs lines in a /path/file:line format for right-clicking with acme. I'm posting it here because I find it really useful, and I wish I'd come up with it years ago. The more you put into it the more useful it becomes, since it's got a fine degree of granularity (the particular keywords attached to a bit of information) and composability of keywords (just string a few grep and grep -v after the nb command). Jason Catena