pkgz v0.1.8
Pkgz is a fast, extensible CLI tool written in Crystal π for managing software packages across multiple Linux distributions.
β¨ Features
- β Install, remove, update and search apps
- π Interactive source selection if app is available in multiple sources
- π Automatically uses
doasorsudofor privilege elevation - π¦ Supports:
- Apt / Nala (Debian/Ubuntu)
- Flatpak
- Pacman (Arch)
- Paru (AUR helper)
- Yay (AUR helper)
- DNF (Fedora/RHEL)
- APK (Alpine)
- Pacstall
- Zypper (openSUSE)
- XBPS (Void) (
Untested) - FreeBSD & FreeBSD Ports (
Untested) - OpenBSD & OpenBSD Ports (
Untested)
- βοΈ Configurable via
~/.config/pkgz/config.toml - π± Extensible to support other package managers
π¦ Requirements
To use pkgz, youβll need the following:
-
Privilege elevation:
Eithersudoordoasmust be installed. -
At least one supported package manager:
Linux:apt,nala,flatpak,pacman,paru,yay,dnf,zypper,apk,xbps, orpacstall
BSD:FreeBSD pkg,FreeBSD Ports,OpenBSD pkg,OpenBSD Ports -
Crystal compiler:
Only needed if you're building from source.
(Prebuilt binaries donβt require Crystal.)
βοΈ Configuration
Create or edit ~/.config/pkgz/config.toml:
[sources]
apt = true
nala = false
flatpak = true
paru = false
yay = false
pacman = false
dnf = false
pacstall = true
zypper = false
xbps = false
freebsd = false
freebsd_ports = false
openbsd = false
openbsd_ports = false
[elevator]
command = "sudo" # or "doas"
You only need to add the sources you will use and set them to true
Also you Must have an elevator set, either sudo or doas
π Installation
π§ͺ Recommended: One-liner Install (Linux x86_64)
You can install the latest prebuilt binary directly with:
curl -sS https://raw.githubusercontent.com/roguehashrate/pkgz/main/install.sh | bash
This installs pkgz to ~/.local/bin.
Make sure ~/.local/bin is in your $PATH.
π Verify Download (Optional)
To verify the integrity of the binary:
curl -LO https://github.com/roguehashrate/pkgz/releases/download/v0.1.8/pkgz
curl -LO https://github.com/roguehashrate/pkgz/releases/download/v0.1.8/pkgz.sha256
sha256sum -c pkgz.sha256
Build from Source
git clone https://github.com/roguehashrate/pkgz
cd pkgz
crystal build src/pkgz.cr --release -o pkgz
mv pkgz ~/.local/bin/
Prebuilt Binary
Download from Releases:
mv pkgz ~/.local/bin
chmod +x ~/.local/bin/pkgz
Tarball (for Arch and others)
wget https://github.com/roguehashrate/pkgz/releases/download/v0.1.8/pkgz-0.1.8.tar.gz
wget https://github.com/roguehashrate/pkgz/releases/download/v0.1.8/pkgz-0.1.8.tar.gz.sha256
sha256sum -c pkgz-0.1.8.tar.gz.sha256
tar -xvf pkgz-0.1.8.tar.gz
cd pkgz
chmod +x install.sh
./install.sh
Make sure ~/.local/bin is in your PATH.
π Usage
pkgz <install|remove|update|search|clean|info|--version> [app-name]
Examples:
pkgz install gimp
pkgz remove gimp
pkgz clean
pkgz info gimp
pkgz update
pkgz --version
Sample output:
$ pkgz install gimp
π Searching for 'gimp' in sources...
π¦ Found 'gimp' in multiple sources:
1. APT
2. Flatpak
Which one would you like to use? [1-2]: 2
π Installing with Flatpak...
π Privilege Elevation
- Automatically detects and uses
doasorsudo. - Privileged commands are run with the configured elevator command.
π§© Extending Pkgz
To add support for a new package manager:
- Subclass
Pkgz::Source - Implement:
nameavailable?(app)install(app)remove(app)updatesearch(app)
- Add your source to the enabled sources list and config.
Created by roguehashrate
pkgz
- 2
- 0
- 1
- 0
- 1
- 26 minutes ago
- June 23, 2025
Other
Tue, 23 Dec 2025 19:31:09 GMT