Skip to content

godalming123/bento

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bento

A package manager with a focus on:

  • Having lots of packages (although currently there are less than a thousand)
  • Just working on every linux distro
  • Not necesitating root permissions to be installed, and to install packages
  • Being fast at installing and running packages
  • Being small (installed packages do not take too much space)
  • Being minimal (bento itself is a single, statically-linked binary)
  • Not polluting the host system (all packages install to the same cache directory)
  • (TODO) Being able to have multiple versions of the same package installed at the same time

Todo

  • Support installing different versions of the same package at the same time
  • Support using different versions of a package by setting environment variables like BENTO_helix_VERSION
  • Support fetching a list of versions of a package from github
  • Improve the list of sources that is displayed to get user confirmation to download sources:
    • Show extra information about the sources:
      • The description of the source
      • Possibly which programming language the source is written in
      • Possibly the homepage of the source
    • Properly wrap text that overflows
  • Add automated testing for binary-repository
    • Maybe one of the tests could use ldd or readelf to check the directlyDependentSharedLibraries field is set correctly
  • Possibly add support for other unix based operating systems, including freeBSD and macOS

Current limitations

If any of these limitations mean that I cannot package something, then I will remove the limitation:

  • Binary names must be unique
  • Library names must be exclusive
  • There are no post install scripts (I don't like post install scripts because they can sometimes be the longest part of a software installation, and there is no way to tell how long they will take)

Installation

1. Install bento

sudo curl --location https://github.com/godalming123/bento/releases/latest/download/linux-amd64 -o /usr/bin/bento
sudo chmod +x /usr/bin/bento
Building from source
git clone --depth 1 https://github.com/godalming123/bento.git
cd bento
go install
# `go install` puts the binary in `~/go/bin`, so make sure that directory is in your $PATH

2. Download the package repository

bento update

3. Add directories to your PATH

  • $HOME/.cache/bento/bin is the directory where all of the binaries in the package repository are stored
  • $HOME/.local/bin is a directory that some of the packages in the package repository install binaries to

~/.bashrc

+export PATH="$HOME/.cache/bento/bin:$HOME/.local/bin:$PATH"

Running bento packages as root

TODO: Add documentation for how to use privilege managers other than sudo.

sudo sh -c "PATH=$PATH COMMAND_NAME COMMAND_ARGS"

For example:

sudo sh -c "PATH=$PATH hx FILE_OWNED_BY_ROOT"

If bento is installed to /usr/bin, then you can also use the slightly shorter:

sudo $(which COMMAND_NAME) COMMAND_ARGS

Stargazers over time

Stargazers over time

About

Minimal cross-distro package manager

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages