From 6f633c264cc143e88878d2b8d0393e563aad6cb6 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Fri, 27 Jan 2017 20:47:03 -0800 Subject: [PATCH] schema/gen: Include .json instead of excluding .go To avoid accidentally including .swp, .un~, etc. [1]. Test with: $ touch schema/.defs-image.json.swp $ touch schema/.content-descriptor.json.un~ $ touch schema/foojson $ make schema-fs $ grep '"/' schema/fs.go "/config-schema.json": { "/content-descriptor.json": { "/defs-config.json": { "/defs-image.json": { "/defs.json": { "/image-layout-schema.json": { "/image-manifest-schema.json": { "/manifest-list-schema.json": { "/": { local: "/", [1]: https://github.com/opencontainers/image-spec/pull/533#discussion_r98296739 Signed-off-by: W. Trevor King --- schema/gen.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/schema/gen.go b/schema/gen.go index cdc319405..ae78604fd 100644 --- a/schema/gen.go +++ b/schema/gen.go @@ -18,4 +18,4 @@ package schema // using esc (https://github.com/mjibson/esc). // This should generally be invoked with `make schema-fs` -//go:generate esc -private -pkg=schema -ignore=.*go -ignore=.*swp . +//go:generate esc -private -pkg=schema -include=.*\.json$ .