Merge commit '7c62d6ef1654c0383eae474d3bd9ddf7754c1f30'

This commit is contained in:
Bjørn Erik Pedersen
2023-08-07 10:38:12 +02:00
43 changed files with 253 additions and 319 deletions

View File

@@ -13,13 +13,13 @@ The `os.Stat` function attempts to resolve the path relative to the root of your
```go-html-template
{{ $f := os.Stat "README.md" }}
{{ $f.IsDir }} --> false (bool)
{{ $f.ModTime }} --> 2021-11-25 10:06:49.315429236 -0800 PST (time.Time)
{{ $f.Name }} --> README.md (string)
{{ $f.Size }} --> 241 (int64)
{{ $f.IsDir }} false (bool)
{{ $f.ModTime }} 2021-11-25 10:06:49.315429236 -0800 PST (time.Time)
{{ $f.Name }} README.md (string)
{{ $f.Size }} 241 (int64)
{{ $d := os.Stat "content" }}
{{ $d.IsDir }} --> true (bool)
{{ $d.IsDir }} true (bool)
```
Details of the `FileInfo` structure are available in the [Go documentation](https://pkg.go.dev/io/fs#FileInfo).