mirror of
https://github.com/gohugoio/hugo.git
synced 2024-11-14 20:37:55 -05:00
b9bd35d72e
git-subtree-dir: docs git-subtree-split: fdea5430f89dfd849d39212abdf5ace0a4763e5a
747 B
747 B
title | description | godocref | date | publishdate | lastmod | categories | menu | keywords | signature | workson | hugoversion | relatedfuncs | deprecated | aliases | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
os.Stat | Gets a file information of a given path. | 2018-08-07 | 2018-08-07 | 2018-08-07 |
|
|
|
|
|
false |
If your current project working directory has a single file named README.txt
(30 bytes):
{{ $stat := os.Stat "README.txt" }}
{{ $stat.Name }} → "README.txt"
{{ $stat.Size }} → 30
Function os.Stat
returns os.FileInfo
.
For further information of os.FileInfo
, see golang page.