Skip to content

Instantly share code, notes, and snippets.

@tjlytle
Created November 14, 2016 15:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tjlytle/7cc33b2277e59e55a3ad18cf1ab9ac61 to your computer and use it in GitHub Desktop.
Save tjlytle/7cc33b2277e59e55a3ad18cf1ab9ac61 to your computer and use it in GitHub Desktop.
if(!process.argv[2]){
console.log('must pass a spec to edit');
process.exit();
}
require("swagger-editor/package.json"); // swagger-editor is a peer dependency.
var editor = require("swagger-editor-server");
editor.edit(process.argv[2], process.argv[3]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment