# zig fmt: support directories · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/1ca90b585692c9611c64412844d2f3a7b3e11340)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 1ca90b585692c9611c64412844d2f3a7b3e11340

Requested commit: 1ca90b585692c9611c64412844d2f3a7b3e11340

Commit: 1ca90b585692c9611c64412844d2f3a7b3e11340

Tree: 6cf95158bbd2a5f527ae315305f40941a6d56b6b

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

```
zig fmt: support directories

zig fmt accepts any number of file paths. For each one, if it
is a file, then it formats the file. If it is a directory, then
zig recursively scans the directory, formatting all files that
end in `.zig`.

it maintains a map of paths that have been seen already, to avoid
softlink loops.

closes #1068

```

## Parents

- [cd4676a2338430d9e424f297b8b576143c5be180](https://git.cafe/gitcafe/zig/commit/cd4676a2338430d9e424f297b8b576143c5be180?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/1ca90b585692c9611c64412844d2f3a7b3e11340?format=markdown)
