git @ Cat's Eye Technologies shelf / master
master

Tree @master (Download .tar.gz)

shelf

Version 0.5 | Entry @ catseye.tc | See also: ellsynctagfarmyastasoti


Cat's Eye Technologies' shelf is "a package installer which neither packages nor installs". It aims to be a replacement for toolshelf, implemented as a set of Bourne shell functions.

Quick Start

Download the file shelf.sh and put it somewhere, say $HOME/shelf.sh.

Or better, clone this repo as $HOME/.shelf; then the file shelf.sh will be at $HOME/.shelf/shelf.sh, and you can pull the latest changes with cd $HOME/.shelf && git pull origin master.

Then add these four lines to the end of your shell startup script (.bashrc, .bash_profile, or whatever):

. $HOME/.shelf/shelf.sh
export SHELF_FARMBASE=$HOME/.local                   # see below
export SHELF_PATH=$HOME/checkout1:$HOME/checkout2    # see below
shelf_init

Then start a new shell for it to take effect.

SHELF_FARMBASE is the directory where the link farms will be created. On some OSes $HOME/.local has a similar purpose, so it can be used here too. (Although note, the wisdom of doing that has not been fully vetted.)

SHELF_PATH should be a colon-separated list of directories where you will be keeping the source directories you wish to manage using shelf.

If you are using bash, you can also configure some nicer tab-completion by sourcing shelf_tabcomplete.sh, i.e. you can also add

. $HOME/.shelf/shelf_tabcomplete.sh

to your startup script.

Usage

The following shell functions are defined by shelf.sh and available for use:

Catalog files

In the context of shelf, a catalog file is a text file with one entry per line. Each entry consists of a directory name, optionally followed by an @ symbol followed by a tag name.

Several commands operate on catalog files, which are usually supplied via standard input. Some of these commands ignore the tag names.

Environment variables

TODO

History

0.5

0.4

0.3

0.2

0.1