1.1.3 • Published 3 years ago

openapi-yaml v1.1.3

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

openapi-yaml

This library manages a split openapi yaml file.

Extended syntax

This library uses $dir to manage split yaml files.

$dir is a property that converts yml under the target directory to object according to the directory structure.

file structure

  • A
    • B
      • C.yml

C.yml

example: Example

output $dir

{
  A: {
    B: {
      C: {
        example: 'Example'  
      }  
    }  
  }
}

Special notation

@ Is used as a special character in this library.

file structure

  • A
    • @B
      • C.yml

C.yml

example: Example

output $dir

{
  A: {
    '/B': {
      C: {
        example: 'Example'
      }  
    }  
  }
}

Cli options

openapi-yaml <yaml> [options]

command

namerequiredtypedescription
yamltrueStringPath of root yaml file

options

namealiasrequiredtypedescription
outputotrueStringOutput Path of combined yaml file

Get started

node

install

yarn

yarn add -D openapi-yaml

npm

npm install -D openapi-yaml

usage

cli

openapi-yaml ./main.yml -o ./merged.yml  

docker

docker run --rm -v $(pwd):/home tanmen/openapi-yaml ./main.yml -o ./merged.yml  

Issue

If you find a problem, please report it on Issue, and we will fix it.

Contributes

If you would like to cooperate with the development, please create a PR and participate.

License

MIT License

1.1.3

3 years ago

1.1.2

3 years ago

1.1.1

4 years ago

1.1.0

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago