freebsd | ||
src | ||
submodules | ||
tests | ||
.gitignore | ||
.gitmodules | ||
CHANGELOG.md | ||
LICENSE | ||
Makefile | ||
nim.cfg | ||
nimble.lock | ||
NOTICE.txt | ||
pathsd.nimble | ||
README.md |
pathsd
pathsd is a small CLI utility to manage the PATH
enironment variable.
Building and installing
pathsd is written in Nim programming language. To build it, you need to install the compiler. Consult nim documentation for instructions on installing nim on your OS. The required version is 2.0.0 or newer.
To build pathsd, issue the following command:
$ make
The built binary will be placed in build/pathsd
. To install, copy it
somewhere.
Usage
pathsd requires at least one directory of parts to operate on, e.g.
paths.d/
├── 01-bilbo
└── 02-homebrew
Each of the files should have one or more lines, each line being a single
entry in the rendered PATH
variable.
Running the program with such a directory would yield the following result:
$ pathsd paths.d/
export PATH="/Users/bilbo/opt/bin:/opt/homebrew/bin:/opt/homebrew/sbin":<paths inherited from $PATH>
You can specify multiple directories. They'll be processed one by one in the order specified on the command line.
The program is best used in your shell's startup file, e.g.
eval $(pathsd paths.d/)
At the time of writing, only bash
is supported.
Author
pathsd is developed by Tomek Wójcik
License
pathsd is licensed under the MIT License.