Install the osss command-line tools on macOS with MacPorts.
This is a signed ports tree served as a snapshot tarball; the ports fetch prebuilt
universal2 (Apple Silicon + Intel) binaries, so there is nothing to compile and no Rust
toolchain required.
sudo curl -fsSL https://macports.osss.net/osss-ports.pub \ -o /opt/local/share/macports/keys/ports/osss-ports.pub
MacPorts auto-loads every *.pub in that directory — no
pubkeys.conf edit needed. The snapshot tarball is signed with this
signify key and MacPorts verifies it on every sync.
Add this line to /opt/local/etc/macports/sources.conf, above the
default rsync://rsync.macports.org/… line:
https://macports.osss.net/ports.tar.gz
sudo port sync sudo port install postgres_sql_formatter
Install only what you want — each port stands alone. On the first sync MacPorts builds a local index for the tree; that is normal and happens on your machine.
pgsfpgsmpgstdpgtwtLeft is the port you install (the full project name, matching the Homebrew, FreeBSD, and Debian packaging); right is the command it provides.
sudo port sync && sudo port upgrade outdated picks up new releases as they ship — a new
version lands in the tree within moments of its release. The tree is rebuilt from each tool's latest
GitLab release automatically.
The snapshot tarball ports.tar.gz is signed with a dedicated signify key; its detached signature is at ports.tar.gz.sig and the public key at macports.osss.net/osss-ports.pub. MacPorts fetches the signature alongside the tree on every sync and refuses a tarball it cannot verify.