Add a "defaults" template function that returns "manifest.DefaultManifestEntry" (especially for doing "ClearDefaults" to be able to fully replicate the default output of "bashbrew cat", but in a different order)

This commit is contained in:
Tianon Gravi 2020-05-07 21:13:45 -07:00
parent 374f44bea9
commit 0fc0b0968a
1 changed files with 3 additions and 0 deletions

View File

@ -88,6 +88,9 @@ func cmdCat(c *cli.Context) error {
}
return filtered
},
"defaults": func() manifest.Manifest2822Entry {
return manifest.DefaultManifestEntry
},
}).Parse(format)
if err != nil {
return cli.NewMultiError(tmplMultiErr, err)