diff options
author | satotake <doublequotation@gmail.com> | 2018-08-05 12:37:20 +0900 |
---|---|---|
committer | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2018-08-06 09:54:26 +0200 |
commit | d71120852a8e14d0ea4d24de269fce041ef7b666 (patch) | |
tree | 9df7354faf35580fffb9f55357019b7e4388a2a2 /tpl/os/init.go | |
parent | a6b1eb1e9150aa5c1c86fe7424cc4167d6f59a5a (diff) |
Add fileStat to tpl/os/os
Diffstat (limited to 'tpl/os/init.go')
-rw-r--r-- | tpl/os/init.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tpl/os/init.go b/tpl/os/init.go index 3ef8702d6..08a36fe7b 100644 --- a/tpl/os/init.go +++ b/tpl/os/init.go @@ -55,6 +55,13 @@ func init() { }, ) + ns.AddMethodMapping(ctx.FileStat, + []string{"fileStat"}, + [][2]string{ + {`{{ (fileExists "files/README.txt").Size }}`, `11`}, + }, + ) + return ns } |