Skip to content
alastairs edited this page Sep 14, 2010 · 3 revisions

PoSh-Couch Futures

Some ideas of things to introduce to PoSh-Couch.

  1. Remove-CouchDbDocument should be pipeline-aware (see the pipelining branch). See http://huddledmasses.org/writing-better-script-functions-for-the-powershell-pipeline/ for a good template for a function accepting pipeline input, and http://huddledmasses.org/using-script-functions-in-the-powershell-pipeline/ for some general information on writing PowerShell script functions handling pipeline input and output.
    1. As a result of this, an object encapsulating a document and revision number needs to be defined. This is because most operations in CouchDB operate on a specific revision of a document.
  2. Remove-CouchDbDocument should be able to accept an array of document IDs as well as just a single one. This can be handled more easily via idea 1 above: just pipe an array of documents into Remove-CouchDbDocument.
  3. Get-CouchDbDocument should be pipeline-aware so that it can emit objects onto the pipeline for use in Remove-CouchDbDocument, etc. This might be more easily achieved via emitting an array?
Clone this wiki locally