$ whois bash
Bash
first released in 1989 · by Brian Fox
$ guessprog --inspect bash
- year
- 1989
- paradigm
- procedural
- family
- shell scripting
- memory
- automatic gc
- binding
- dynamic
- safety
- weak
BASH(7)
- AUTHORS
- Brian Fox
- HISTORY
- Brian Fox wrote Bash for the GNU Project, releasing it in 1989 as a free replacement for the Bourne shell, the standard Unix shell written by Stephen Bourne. The name is a pun: "Bourne-Again SHell". Chet Ramey took over maintenance in the early 1990s and has looked after it ever since. Bash became the default shell of most Linux distributions and of macOS until 2019, when Apple switched to zsh.
- USAGE
- One of the most used languages in the world without most people thinking of it as one: it glues together build systems, CI pipelines, containers, installers and system administration on Linux and other Unix-like systems.
- SEE ALSO
- Bash on Wikipedia ↗
#!/usr/bin/env bash
set -euo pipefail
# Count lines of text per file extension
declare -A lines=()
while IFS= read -r -d '' f; do
ext="${f##*.}"
lines[$ext]=$(( ${lines[$ext]:-0} + $(wc -l < "$f") ))
done < <(find "${1:-.}" -type f -name '*.*' -print0)
for ext in "${!lines[@]}"; do
printf '%-8s %d\n' "$ext" "${lines[$ext]}"
done | sort -k2 -nr