SlackBuilds Repository

15.0 > Development > shfmt (3.14.1)

shfmt is a command-line formatter for shell programs. It supports
POSIX Shell, Bash, Zsh, and mksh syntax, and can check, format, or
rewrite shell scripts consistently.

Examples:

shfmt script.sh # write formatted output to stdout
shfmt -w script.sh # rewrite the file in place
shfmt -d script.sh # show formatting differences
shfmt -l . # list files that need formatting

Run "shfmt -h" for the complete list of options. The package installs
the executable as /usr/bin/shfmt. Upstream documentation and the source
form of the manual page are installed under /usr/doc/shfmt-3.14.1/.

The separate vendor archive supplies the Go modules, so the SlackBuild
does not download dependencies or a Go toolchain. Go and the modules
are needed only while building; shfmt has no runtime dependencies
outside the standard Go runtime embedded in the binary.

This package is built from the official mvdan/sh v3.14.1 release:
https://github.com/mvdan/sh

This requires: google-go-lang

Maintained by: r1w1s1
Keywords: zsh,bash,mksh,shell,posix,script,golang,formatter,formatting
ChangeLog: shfmt

Homepage:
https://github.com/mvdan/sh

Source Downloads:
sh-3.14.1.tar.gz (6414c4cca680e88786a9987b67edcf05)
shfmt-3.14.1-vendor.tar.gz (74c91190b6d12987ccc15644fd45c4dc)

Download SlackBuild:
shfmt.tar.gz
shfmt.tar.gz.asc (FAQ)

(the SlackBuild does not include the source)

Individual Files:
• README
• shfmt.SlackBuild
• shfmt.info
• slack-desc

Validated for Slackware 15.0

See our HOWTO for instructions on how to use the contents of this repository.

Access to the repository is available via:
ftp git cgit http rsync

© 2006-2026 SlackBuilds.org Project. All rights reserved.
Slackware® is a registered trademark of Patrick Volkerding
Linux® is a registered trademark of Linus Torvalds