Category: Uncategorized
-
Transferring from MongoDB to CouchDB
So I wanted to move a larger number of records from MongoDB to CouchDB. Here are the basic steps I took: I just wanted a selected number of fields (name, address, longitude, latitude) so I used mongoexport to put it into a JSON Array: ./mongoexport -d cookography -c places -f name,address,longitude,latitude -o test.json –jsonArray Both…
-
a DIV inside a LI
Suppose you want to have a bunches of DIVs contained inside of a List Item… AND you want them to not mess with the height of the List Item and appear as a line of text? Well then, take this sample HTML: [html] <li> <div class="inspection"> <div class="date"><a href="/report/1430/9115/">9-16-2010</a></div> <div class="inspection-type">License Renewal </div> <div class="violations">0…
-
PostGres – PostGIS on OSX Lion
I recently just wasted a lot of time trying to get PostGIS up and running on OSX Lion. I wanted to do this so I could pull in Open Street Map data for the DC region and then play with it in QGIS and import it into Tilemill. I will be the first to admit…
-
JSDOM Memory leaks
JSDOM is a great little module for NodeJS which lets you parse a DOM on the server. The only problem is that it has a memory leak. Not a big deal if you are only going to instantiate a couple times. A little trickier if you are screen scraping and need to call it 1000s…
-
For Looping jQuery Elements
When you get a jQuery object back from a selector, you general loop through all of the elements it contains using .each(). However I wanted to use a For Loop because I wanted to access a bunch of elements at once. I am scrapping a table and I might want to access multiple elements to…
-
Completely removing XCode
XCode 4.1 is now free in the App Store. I wanted to completely remove 3.0 version I had. Luckily there is a simple command line option for doing an uninstall: sudo /Developer/Library/uninstall-devtools –mode=all
-
Dynamic DIV IDs in Jade
Jade is an HTML templating language that works with Node.js and a bunch of other languages. It takes structured templates and converts them into HTML. Jade uses indentation to show what code should be within an HTML tag. It is also possible to use variables to generate text, they call it Interpolation and it is…
-
Plugin Hybrids
It is always fun to head out to lunch and find the latest in Hybrid technology.
-
Cuckoo’s Egg – Some Books Age Well
I am re-reading The Cuckoo’s Egg. It is a great book by Cliff Stoll, an astronomer turned sys admin who tracks a hacker through his system. There is a ton of insight in this book on the challenges of securing a system and various techniques. The crazy thing is that this took place in 1984.…
-
Self Check Out Ninja
You know you are a shelf check out ninja when you memorize produce calls. Bananas for example are #4011. It also shows that we eat a lot of bananas.