fast, quiet, beautiful package management for BlahArch. (and yes, it is named after the ikea shark. all hail blahaj. 🦈)
haj is a modern, memory-safe wrapper for pacman written in rust. It replaces arch's notoriously loud and verbose terminal output with the clean, minimalistic aesthetic of modern package managers like cargo and bun, without compromising on speed or safety. also comes with love from the supreme plushie shark.
haj now features a blazing-fast, interactive tui powered by ratatui. run haj tui to access:
- real-time search: press / or f to instantly filter all sync repository packages natively via libalpm.
- live commands popups: haj streams native pacman execution logs directly into floating, minimalist UI panels with razor-thin progress bars.
- the orphan sweeper: press c on the dashboard to instantly detect and vaporize unneeded dependencies (pacman -Rns) and reclaim disk space.
- 3d rotating blahaj (best): a fully 3D, spinning ascii art shark rendered natively via display3d.
- the cargo/bun aesthetic: no more jagged progress bars or walls of text.
hajparsespacmanoutput streams in real-time, displaying a single, elegant progress spinner and clean transaction summaries. - native alpm engine:
hajusesalpm.rs(c bindings forlibalpm) to query your local and sync databases directly in memory. - blazing fast orphan detection: instead of parsing text scripts,
haj orphantraverses the true alpm directed acyclic graph (dag) to find unused dependencies in microseconds. - deadlock-free concurrency: built on
tokio,hajsafely drops database locks before handing state-mutation over topacman, guaranteeing zero lockfile collisions. - safe dry run: Includes a built-in
--dry-runflag to preview commands without touching your system.
haj is completely transparent and relies entirely on standard arch linux infrastructure:
- reads (
search,show,orphan) are done natively vialibalpmbindings for maximum performance. - writes (
install,remove,update,clean) are handed off securely to standardpacmansubprocesses (pacman -S,pacman -Rs, etc.).hajintercepts thestdout/stderrstreams via pseudo-terminals (pty), filters out the verbose noise, applies color formatting, and pipes the cleaned data to your screen in real-time.
you can install haj using your favorite aur helper:
yay -S haj
# or
paru -S hajinstall haj from the official blahArch repo for self-updating release via pacman,
add this to the bottom of your /etc/pacman.conf:
[blaharch]
SigLevel = Optional TrustAll
Server = https://asitos.github.io/blaharch-repo/$archthen just sync and install normally (or update haj if it is already installed):
sudo pacman -Sy hajrequires rust + cargo to be installed:
cargo install hajrequires the rust toolchain (cargo).
git clone https://github.com/asitos/haj.git
cd haj
cargo build --release
# install the binary to your system path
sudo install -Dm755 target/release/haj /usr/bin/hajhaj provides highly aliased commands for a faster typing experience.
| command | aliases | action |
|---|---|---|
tui |
t |
launch the interactive tui dashboard |
install <pkg> |
i |
install one or more packages |
remove <pkg> |
rm, toss |
remove packages & unneeded dependencies |
update |
up, sync |
sync mirror databases |
search <query> |
s |
search all remote sync databases (and aur) |
show <pkg> |
info |
show local package details |
list |
ls |
list explicitly installed packages |
clean |
c |
scrub the package cache |
orphan |
o |
detect orphaned dependencies |
owns <file> |
ow |
find which local package owns a file |
locate <file> |
loc |
search remote repos for a file name (pacman -F) |
files <pkg> |
lf |
list all files installed by a package |
load <file> |
l |
install a local package archive (.pkg.tar.zst) |
fetch <pkg> |
f |
download a package to cache without installing |
mark <pkg> |
m |
change the install reason of a package |
diff |
pn |
interactively manage and merge .pacnew config files |
-a,--aur: restrict operations to the aur.-r,--repo: restrict operations to arch repositories.-y,--noconfirm: bypass all confirmation prompts.-n,--needed: do not reinstall up-to-date packages.-i,--ignore <pkg>: ignore a package upgrade (comma-separated: pkg1,pkg2).-c,--config <path>: specify an alternate pacman config file.--root <path>: specify an alternate installation root.-v,--verbose: enable verbose debug logging.-d,--dry-run: preview a command without modifying the system.-h,--help: display help information.-V,--version: show version info.
launch the interactive dashboard:
haj tui
# or
haj tsearch for a package:
haj search neofetch
# or
haj s neofetchsync repositories and install a package:
sudo haj sync
# or
sudo haj up
sudo haj install htop cmatrix
or
sudo haj i htop cmatrixsafely preview removing a package without actually removing it:
haj -d toss firefoxhaj works perfectly out of the box, but can be customized globally by creating a config file at ~/.config/haj/config.toml. It uses the TOML format.
# ~/.config/haj/config.toml
[general]
animations = true
color = "auto"
verbose = falsemore config options are currently under work
haj is built with a focus on memory safety, zero-cost abstractions, and concurrent execution.
- asynchronous pty parsing: uses
tokioto spawn non-blocking pseudo-terminals, capturing and formattingpacman's c-level standard streams in real-time without deadlocking background workers. - ffi & memory safety: utilizes
alpm.rsto interface with arch linux'slibalpm. database locks are explicitly managed and safely dropped from memory before handing state mutation over to external processes. - dag traversal: the
orphandetection engine completely avoids bash scripting, instead traversing the system's directed acyclic graph (dag) directly in memory via c-bindings to calculate unneeded dependencies in microseconds.
MIT license. see LICENSE for more information.

