Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

clever-orm

Package Overview
Dependencies
Maintainers
3
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

clever-orm - npm Package Compare versions

Comparing version 0.0.13 to 0.0.14

14

bin/rebase.js
var fs = require( 'fs' )
, utils = require( 'utils' )
, env = utils.bootstrapEnv(); // Bootstrap the environment
, env = utils.bootstrapEnv() // Bootstrap the environment
, moduleName = process.argv && process.argv[ 2 ] != 'null'
? process.argv[ 2 ]
: false;

@@ -8,7 +11,12 @@ console.log('Forcing Database to be created! (Note: All your data will disapear!)');

// Load all the modules
env.moduleLoader.loadModules();
if ( moduleName ) {
env.moduleLoader.loadModule( 'clever-orm', env );
env.moduleLoader.loadModule( moduleName, env );
} else {
env.moduleLoader.loadModules( env );
}
// Force a sync
injector.getInstance( 'sequelize' )
.sync()
.sync( { force: true } )
.success(function () {

@@ -15,0 +23,0 @@ console.log( 'Database is rebased' );

@@ -6,3 +6,6 @@ var fs = require( 'fs' )

, async = require( 'async' )
, inflect = require( 'i' )();
, inflect = require( 'i' )()
, moduleName = process.argv && process.argv[ 2 ] != 'null'
? process.argv[ 2 ]
: false;

@@ -14,3 +17,8 @@ // Bootstrap the environment, but don't initializeModuleRoutes( injector )

// Load all the modules
env.moduleLoader.loadModules();
if ( moduleName ) {
env.moduleLoader.loadModule( 'clever-orm', env );
env.moduleLoader.loadModule( moduleName, env );
} else {
env.moduleLoader.loadModules( env );
}

@@ -17,0 +25,0 @@ // Load the seedData and get the models

@@ -0,0 +0,0 @@ {

@@ -7,2 +7,5 @@ 'use strict';

module.exports = function( grunt ) {
// Arguments for individual module rebase/seed
var dbTarget = grunt.option( 'module' ) || null;
return [{

@@ -60,6 +63,6 @@ prompt: {

rebase: {
cmd: "NODE_PATH=./lib/:./modules/; node modules/clever-orm/bin/rebase.js"
cmd: "NODE_PATH=./lib/:./modules/; node modules/clever-orm/bin/rebase.js " + dbTarget
},
seed: {
cmd: "NODE_PATH=./lib/:./modules/; node modules/clever-orm/bin/seedModels.js"
cmd: "NODE_PATH=./lib/:./modules/; node modules/clever-orm/bin/seedModels.js " + dbTarget
}

@@ -66,0 +69,0 @@ }

@@ -0,0 +0,0 @@ var Sequelize = require( 'sequelize' )

{
"name": "clever-orm",
"version": "0.0.13",
"version": "0.0.14",
"dependencies": {

@@ -5,0 +5,0 @@ "mysql": "2.0.0-rc2",

@@ -0,0 +0,0 @@ # Cleverstack ORM module

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc