Skip to content

Commit

Permalink
🔥 😎 remove old migrations (#7887)
Browse files Browse the repository at this point in the history
refs #7489

- remove old migration code
- this logic was sourced out to knex-migrator
  • Loading branch information
kirrg001 authored and kevinansfield committed Jan 25, 2017
1 parent 042750f commit 2d19ae2
Show file tree
Hide file tree
Showing 23 changed files with 312 additions and 1,680 deletions.
18 changes: 0 additions & 18 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -405,24 +405,6 @@ var overrides = require('./core/server/overrides'),
cfg.express.test.options.node_env = process.env.NODE_ENV;
});

// #### Reset Database to "New" state *(Utility Task)*
// Drops all database tables and then runs the migration process to put the database
// in a "new" state.
grunt.registerTask('cleanDatabase', function () {
var done = this.async(),
models = require('./core/server/models'),
migration = require('./core/server/data/migration');

migration.reset().then(function () {
models.init();
return migration.init();
}).then(function () {
done();
}).catch(function (err) {
grunt.fail.fatal(err.stack);
});
});

// ### Test
// **Testing utility**
//
Expand Down
2 changes: 1 addition & 1 deletion core/server/api/db.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
var Promise = require('bluebird'),
exporter = require('../data/export'),
importer = require('../data/importer'),
backupDatabase = require('../data/migration').backupDatabase,
backupDatabase = require('../data/db/backup'),
models = require('../models'),
errors = require('../errors'),
utils = require('./utils'),
Expand Down
File renamed without changes.
Loading

0 comments on commit 2d19ae2

Please sign in to comment.