Skip to content

schema/gen: Include .json instead of excluding .go#538

Merged
jonboulle merged 1 commit into
opencontainers:masterfrom
wking:schema-fs-include
Mar 9, 2017
Merged

schema/gen: Include .json instead of excluding .go#538
jonboulle merged 1 commit into
opencontainers:masterfrom
wking:schema-fs-include

Conversation

@wking

@wking wking commented Jan 28, 2017

Copy link
Copy Markdown
Contributor

To avoid accidentally including .swp, .un~, etc. 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: "/",

CC @vbatts.

@vbatts

vbatts commented Jan 30, 2017

Copy link
Copy Markdown
Member

this didn't work for me ☹️
I had to just add to the ignores.

@wking

wking commented Jan 30, 2017 via email

Copy link
Copy Markdown
Contributor Author

@vbatts

vbatts commented Jan 31, 2017

Copy link
Copy Markdown
Member

sorry, it works, but when i had tmp files (vim .*.swp files) the pattern still built them into the schema-fs.

@wking

wking commented Jan 31, 2017 via email

Copy link
Copy Markdown
Contributor Author

@vbatts

vbatts commented Feb 14, 2017

Copy link
Copy Markdown
Member

rebase pls

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#533 (comment)

Signed-off-by: W. Trevor King <wking@tremily.us>
@wking wking force-pushed the schema-fs-include branch from eab6872 to 6f633c2 Compare February 14, 2017 21:46
@wking

wking commented Feb 14, 2017 via email

Copy link
Copy Markdown
Contributor Author

@vbatts

vbatts commented Feb 14, 2017

Copy link
Copy Markdown
Member

LGTM

Approved with PullApprove

@jonboulle

jonboulle commented Mar 9, 2017

Copy link
Copy Markdown
Contributor

lgtm

Approved with PullApprove

@jonboulle jonboulle merged commit a896cfc into opencontainers:master Mar 9, 2017
wking added a commit to wking/image-spec that referenced this pull request Mar 9, 2017
With:

  $ go get -u github.com/mjibson/esc
  $ make schema/fs.go

now that 6f633c2 (schema/gen: Include .json instead of excluding .go,
2017-01-27, opencontainers#538) has landed.

Signed-off-by: W. Trevor King <wking@tremily.us>
@wking wking mentioned this pull request Mar 9, 2017
@wking wking deleted the schema-fs-include branch March 17, 2017 22:13
@vbatts vbatts mentioned this pull request May 19, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants