Poor Man's Tagging
an adventure in triple nested hashes.
PMT is a ruby script which can help you sort your data in a manner which has been heretofore unavailable in Windows NT/2k/XP. Lets say you have a lot of files of a limited set of types (source code, docs, TRM's, manuals, etc...) which are used in a limited set of projects that you work on, all which can be grouped together under some sort of name. Lets say for exmaple we have a few sets of these.
- Your custom Rails App in source code for some project
- This ruby script and it's docs
- Your library of PDF's about programming
- A few year's tax returns
PMT allows you to "tag" your data, in a exceptionally crude and gross scale, and then sorts it into a tagging heirarchy in your file system using "junctions" in Windows (or softlinks in other OS's) to point back to the original data.
First, arrange your data in the "raw" folder with the following naming template: name_type_project
raw/
MyCustomApp_src_Programming/
pmt_src_Programming/
pmt_doc_Programming/
Books_pdf_Programming/
taxes2006_doc_Finances/
taxes2005_doc_Finances/
And then run the script to auto-generate this tree (all peers to "raw"):
by project/
Finances/
doc/
taxes2006/
taxes2005/
Programming/
doc/
pmt/
src/
MyCustomApp/
pmt/
pdf/
Books/
by type/
doc/
Programming/
pmt/
Finances/
taxes2006/
taxes2005/
src/
Programming/
MyCustomApp/
pmt/
pdf/
Programming/
Books/
by name/
taxes2005/
doc/
Finances/
taxes2006/
doc/
Finances/
pmt/
doc/
Programming/
src/
Programming/
MyCustomApp/
src/
Programming/
Books/
pdf/
Programming/
These are just examples. You can develop your own Project names, types, group names. You might find that only one type of organization appeals to you. I found that I tend to use multiple approaches to find information. Using this system, you can find it anyway you need to.
Dependencies
This project is dependent on the "junction.exe" program provided by http://www.sysinternals.com. It's a really neat little utility that takes all the headache out of making junctions in Windows (the ruby implementation would be quite nasty).
Usage
Simply call the scripts with -c for create, -d for delete, or -r to delete, then create the structure. It will assume that you'll want to have the folder structure defined from where you call it.
by name by type by project raw [emrainey@macbookpro ~/Data]$ pmt.rb -c
Incidently this should also work in *nixes too like Mac OSX, but it uses "ln -s" instead of junctions.
