Sha256: e3863e4bfd65027bf4feb78cb7e2fb74f37f54ddb9757b3a4389a06e7fc3d255
Contents?: true
Size: 1.15 KB
Versions: 2
Compression:
Stored size: 1.15 KB
Contents
#!/usr/bin/env ruby require 'commander' require 'rubygems' require "parse/db/import" require "parse/db/import/version" Commander.configure do program :version, Parse::Db::Import::VERSION program :description, 'Simple app to import parse db' default_command :import command :import do |c| c.syntax = 'parse-db-import import [options]' c.summary = '' c.description = '' c.example 'parse-db-import --path [path] --dbname [database] --adapter [postgresql] --dbuser [user] --dbpassword [password] --host [host]', 'command example' c.option '--path String', String, 'The location of where the json files exist' c.option '--entity String', String, 'The entity to load, all if missing' c.option '--dbname String', String, 'db name' c.option '--adapter String', String, 'mysql, mysql2, postgresql or sqlite3 defaults to postgresql' c.option '--dbuser String', String, 'db user name' c.option '--dbpassword String', String, 'db password' c.option '--host String', String, 'db password' c.action do |args, options| options.path = ask("Path? ") unless options.path Parse::Db::Import.new.run(options) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
parse-db-import-0.0.2 | bin/parse-db-import |
parse-db-import-0.0.1 | bin/parse-db-import |