]> git.giacomolli.uk - onechat/blob - bin/format
Revert compaction view block messages
[onechat] / bin / format
1 #!/usr/bin/env bash
2 set -euo pipefail
3 cd "$(dirname "$0")/.."
4
5 # Lists the tracked and the new, not ignored files that match a pattern.
6 files() {
7   git ls-files --cached --others --exclude-standard -- "$@"
8 }
9
10 gofumpt -w .
11 files '*.nix' | xargs nixfmt
12 files '*.rst' | xargs rstfmt
13 files '*.md' | xargs mdformat