For this I highly recommend https://zolk3ri.name/cgit/zpkg/ which I have been using for years now. It works wonderfully for my use case, and might work for yours, too. It is very simple.
It means that if you install anything from scratch, you have to `make install` (or the like, depending on the build system) it to, say, `~/.local/pkg/foo-1.0` and then run `zpkg link foo:1.0` to install (i.e. link) the "package".
After that you just have to make sure you have (typically in your `~/.bash_profile` file):
- added `~/.local/bin` to your `PATH` environment variable, and
- added `~/.local/man` to your `MANPATH` environment variable
Seems to do the job. For help, read the source code or type `zpkg --help` which should be of tremendous help.
By the way, I have noticed that someone created a package manager with the same name, but its initial commit was in 2019, while this one's was in 2017.
It is written in OCaml, so you do need to have the OCaml compiler installed. I recommend doing it via `opam`, but your Linux distribution's package manager will suffice (simply `ocaml` on Arch Linux, for example). Run `make` to compile it, it will produce a working executable file.
If you find any bugs, report it via e-mail which can be found in the `LICENSE` file. I reported a bug before and it was fixed almost immediately. I suppose you can send pull requests or mention missing features, the creator seemed friendly to me.
To be frank, I forgot how it compares to GNU Stow because it was many years ago, but I did use GNU Stow prior to finding this program. All I remember is that it is way simpler, and it seemed to be perfect for my use case, no more and no less than what I needed. Maybe it works for you, too.
Environment variables and their defaults:
It means that if you install anything from scratch, you have to `make install` (or the like, depending on the build system) it to, say, `~/.local/pkg/foo-1.0` and then run `zpkg link foo:1.0` to install (i.e. link) the "package".After that you just have to make sure you have (typically in your `~/.bash_profile` file):
- added `~/.local/bin` to your `PATH` environment variable, and
- added `~/.local/man` to your `MANPATH` environment variable
Seems to do the job. For help, read the source code or type `zpkg --help` which should be of tremendous help.
By the way, I have noticed that someone created a package manager with the same name, but its initial commit was in 2019, while this one's was in 2017.
It is written in OCaml, so you do need to have the OCaml compiler installed. I recommend doing it via `opam`, but your Linux distribution's package manager will suffice (simply `ocaml` on Arch Linux, for example). Run `make` to compile it, it will produce a working executable file.
Direct link to the source code: https://zolk3ri.name/cgit/zpkg/tree/src/zpkg.ml
If you find any bugs, report it via e-mail which can be found in the `LICENSE` file. I reported a bug before and it was fixed almost immediately. I suppose you can send pull requests or mention missing features, the creator seemed friendly to me.
---
The above is a modified version of an old comment of mine: https://news.ycombinator.com/item?id=24238587
---
To be frank, I forgot how it compares to GNU Stow because it was many years ago, but I did use GNU Stow prior to finding this program. All I remember is that it is way simpler, and it seemed to be perfect for my use case, no more and no less than what I needed. Maybe it works for you, too.