Skip to content

juliojimenez/hash

Tests Sanitizers & Fuzzing POSIX Compliance Quality Gate Status Debian Package Homebrew Formula GitHub Release

hash

A modern command line interpreter for Linux, macOS, and BSD.

Install

From Release

Linux x86_64

curl -LO https://github.com/juliojimenez/hash/releases/download/v27/hash-shell-v27-linux-x86_64
chmod +x hash-shell-v27-linux-x86_64
sudo mv hash-shell-v27-linux-x86_64 /usr/local/bin/hash-shell
hash-shell

Linux ARM64

curl -LO https://github.com/juliojimenez/hash/releases/download/v27/hash-shell-v27-linux-aarch64
chmod +x hash-shell-v27-linux-aarch64
sudo mv hash-shell-v27-linux-aarch64 /usr/local/bin/hash-shell
hash-shell

FreeBSD x86_64

fetch https://github.com/juliojimenez/hash/releases/download/v27/hash-shell-v27-freebsd-x86_64
chmod +x hash-shell-v27-freebsd-x86_64
sudo mv hash-shell-v27-freebsd-x86_64 /usr/local/bin/hash-shell
hash-shell

FreeBSD ARM64

fetch https://github.com/juliojimenez/hash/releases/download/v27/hash-shell-v27-freebsd-aarch64
chmod +x hash-shell-v27-freebsd-aarch64
sudo mv hash-shell-v27-freebsd-aarch64 /usr/local/bin/hash-shell
hash-shell

macOS (Apple Silicon)

curl -LO https://github.com/juliojimenez/hash/releases/download/v27/hash-shell-v27-darwin-arm64
chmod +x hash-shell-v27-darwin-arm64
sudo mv hash-shell-v27-darwin-arm64 /usr/local/bin/hash-shell

Ubuntu 24.04 (Noble)

curl -LO https://github.com/juliojimenez/hash/releases/download/v27/hash-shell_27-1~noble_amd64.deb
sudo dpkg -i hash-shell_27-1~noble_amd64.deb

Ubuntu 22.04 (Jammy)

curl -LO https://github.com/juliojimenez/hash/releases/download/v27/hash-shell_27-1~jammy_amd64.deb
sudo dpkg -i hash-shell_27-1~jammy_amd64.deb

Debian Bookworm

curl -LO https://github.com/juliojimenez/hash/releases/download/v27/hash-shell_27-1~bookworm_amd64.deb
sudo dpkg -i hash-shell_27-1~bookworm_amd64.deb

From Source

git clone https://github.com/juliojimenez/hash
cd hash
make
sudo make install
hash-shell

Homebrew (macOS)

brew install juliojimenez/hash/hash-shell
hash-shell

APT (Debian/Ubuntu)

# Add repository
echo "deb [trusted=yes] https://juliojimenez.github.io/hash/ stable main" | sudo tee /etc/apt/sources.list.d/hash-shell.list

# Install
sudo apt update
sudo apt install hash-shell

Upgrade with sudo apt upgrade hash-shell. See APT Installation Guide for more options.

Usage

Start hash

hash-shell

Execute a Script

hash-shell script.sh arg1 arg2

Execute Command String

hash-shell -c 'echo "Hello, World!"'

Change Default Shell To hash

Log off and log on to your session for changes to take effect.

chsh (Linux)

sudo bash -c 'echo "/usr/local/bin/hash-shell" >> /etc/shells'
chsh -s /usr/local/bin/hash-shell

usermod (Linux)

sudo usermod -s /usr/local/bin/hash-shell your_username

chsh (macOS)

sudo bash -c 'echo "/usr/local/bin/hash-shell" >> /etc/shells'
chsh -s /usr/local/bin/hash-shell

If hash was installed with brew:

sudo bash -c 'echo "$(brew --prefix)/bin/hash-shell" >> /etc/shells'
chsh -s "$(brew --prefix)/bin/hash-shell"

chsh (FreeBSD)

sudo sh -c 'echo "/usr/local/bin/hash-shell" >> /etc/shells'
chsh -s /usr/local/bin/hash-shell

Command Line Options

Option Description
-c string Execute commands from string
-i Force interactive mode
-l, --login Run as a login shell
-s Read commands from standard input
-v, --version Print version information
-h, --help Show help message

See Also

Newsletter

Keep up with development updates on Rede Livre

hash - A modern command line interpreter for Linux, macOS, and BSD. | Product Hunt

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages