Skip to content

Commit

Permalink
schema/gen: Include .json instead of excluding .go
Browse files Browse the repository at this point in the history
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]: opencontainers/image-spec#533 (comment)

Signed-off-by: W. Trevor King <[email protected]>
  • Loading branch information
dattgoswami9lk5g committed May 30, 2025
1 parent cca5e91 commit 97ac83d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion schema/gen.go
Original file line number Diff line number Diff line change
Expand Up @@ -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$ .

0 comments on commit 97ac83d

Please sign in to comment.