Socket
Book a DemoInstallSign in
Socket

pgschematojson

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pgschematojson

take postgres schema dump (--schema-only) and read it into a js object with keys and field types

latest
Source
npmnpm
Version
0.0.1
Version published
Maintainers
1
Created
Source

pgschematojson

take postgres schema dump (--schema-only) and read it into a js object with keys and field types

can be used cli or a module.

pg_dump --schema-only databasename | pgschematojson

install

sudo npm install -g pgschematojson

api

module.exports([schema],cb)

  • schema, takes an optional schema string to parse
  • cb, the callback with the resultant data object.
  • return value, if schema is not provided this returns a writeable stream which expects a piped stream of schema data

module.exports.dump(config)

runs pg_dump with provided config

  • config, {password:,user:,host:,database:}
  • returns a stream of schema data

Keywords

postgres

FAQs

Package last updated on 24 May 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts