Install sqx

sqx is a single self-contained executable. There is no runtime, no database server and no shared library to install. Download one file, make it executable and you are done.

1. Download the binary

Open the latest GitHub release and download the file for your system.

SystemFile
macOS, Apple Silicon (M1, M2, M3, M4)sqx-darwin-arm64
macOS, Intelsqx-darwin-amd64
Linux, x86-64sqx-linux-amd64
Linux, ARM64 (AWS Graviton, Raspberry Pi 4/5 64-bit)sqx-linux-arm64
Linux, ARMv7 (Raspberry Pi 32-bit)sqx-linux-arm
Linux, x86 32-bitsqx-linux-386
Windows, x86-64sqx-windows-amd64.exe
Windows, ARM64sqx-windows-arm64.exe
FreeBSD, x86-64sqx-freebsd-amd64
FreeBSD, ARM64sqx-freebsd-arm64

Not sure which one? Run uname -sm on macOS or Linux. arm64 or aarch64 means ARM64; x86_64 means amd64. On Windows, most PCs need amd64.

You can also download from the terminal. Replace the file name with the one for your system:

curl -L -o sqx https://github.com/sqx-go/sqx-go.github.io/releases/latest/download/sqx-linux-amd64

2. Verify the download (optional)

Each release includes a SHA256SUMS file. Download it into the same folder as the binary, then run:

shasum -a 256 -c SHA256SUMS --ignore-missing

You should see OK next to the file you downloaded.

3. Put it on your PATH

macOS, Linux and FreeBSD

chmod +x sqx
sudo mv sqx /usr/local/bin/sqx
sqx version

On macOS, if you see "cannot be opened because the developer cannot be verified", remove the download quarantine flag:

xattr -d com.apple.quarantine /usr/local/bin/sqx

Windows (PowerShell)

mkdir $HOME\bin -Force
Move-Item .\sqx-windows-amd64.exe $HOME\bin\sqx.exe
[Environment]::SetEnvironmentVariable("Path", [Environment]::GetEnvironmentVariable("Path", "User") + ";$HOME\bin", "User")
sqx version

Open a new terminal after changing Path.

4. Check that it works

echo '[{"hello":"world"}]' | sqx "SELECT * FROM stdin"
+-------+
| hello |
+-------+
| world |
+-------+

Install with Go

If you have Go installed, you can skip the download and run:

go install github.com/sqx-go/sqx-go.github.io/sqx@latest
sqx version

This puts sqx in $(go env GOPATH)/bin, which needs to be on your PATH. To update, run the same command again.

Update and uninstall

  • Update: download the new release and replace the file.
  • Uninstall: delete the binary. You can also delete the web cache in ~/.cache/sqx (Linux), ~/Library/Caches/sqx (macOS) or %LocalAppData%\sqx (Windows).

Prefer to compile it yourself? See Build from source.