LinuxCommandLibrary

ash

Lightweight POSIX-compliant shell

TLDR

Start ash shell
$ ash
copy
Execute a command
$ ash -c "[command]"
copy
Run script
$ ash [script.sh]
copy

SYNOPSIS

ash [-c command] [script] [arguments]

DESCRIPTION

ash (Almquist Shell) is a lightweight POSIX-compliant shell. It's smaller and faster than bash, making it suitable for embedded systems and as /bin/sh on minimal systems.
Many systems use dash (Debian Almquist Shell) as their ash implementation. BusyBox also includes an ash implementation.

PARAMETERS

-c command

Execute command string
-i
Interactive mode
-l
Login shell
-s
Read commands from stdin

CONFIGURATION

/etc/profile

System-wide login shell initialization.
~/.profile
Per-user login shell initialization.
$ENV
If set, sourced for interactive shells (often points to ~/.ashrc).

CAVEATS

Less feature-rich than bash; no arrays, extended globbing, or many bashisms. Scripts should use POSIX syntax only. Good for speed, not convenience.

HISTORY

ash was written by Kenneth Almquist for BSD Unix in 1989 as a POSIX-compliant replacement for the Bourne shell. It has been forked into dash and is used in BusyBox.

SEE ALSO

dash(1), bash(1), sh(1), busybox(1)

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard