PSV - The "Pipe Separated Values" Formatter

What Does psv Do?

psv is a unix command line utility, and golang module, for working with plaintext tables of Pipe-Separated-Values.

You may also know of them as markdown tables.

Let us start with a simple example: imagine you want to create a simple shopping list.

You open your favourite unix text editor and type in the following:

… and then you hear a voice from the shadows …

we've run out of corn flakes!

… so you add corn flakes to your list …

… and you start to feel sad because now your beautiful table looks terrible, and it will be a lot of effort to clean it up again.

psv, however, was invented for exactly this situation! (cleaning up plaintext tables, not creating shopping lists)

Let us now assume that vim is your editor of choice and that you have already installed psv.

You place your cursor anywhere within your shopping list and type the vim command:

!ip psv <Return>

… and all of a sudden your table is back in shape:

So that's basically it.

In a nutshell, psv

  • reads plaintext tables of pipe-separated-values (hence the name)
  • manipulates them (sorting, adding, removing or rearranging columns, …)
  • and generates new, nicely formatted versions of your tables

psv has plenty of subtle features to discover.

The following pages demonstrate and explain all of psv's capabilities, many of them with interactive examples.

If you want to find out more, click "next" to start your tour …

Previous Next