Skip to content
Permalink
Browse files

changes assistantjs binary and cli to adapt initialization changes

  • Loading branch information...
antoniusostermann committed Oct 31, 2018
1 parent e67cb97 commit 4eea5a895fc804008970ff027a4bc7c9f8d723f2
Showing with 1,605 additions and 1,592 deletions.
  1. +10 −10 bin/assistant
  2. +1,569 −1,555 package-lock.json
  3. +26 −27 src/cli.ts
@@ -1,24 +1,24 @@
#!/usr/bin/env node
'use strict';
"use strict";

require('reflect-metadata');
require("reflect-metadata");

process.title = 'assistant';
process.title = "assistant";

var resolve = require('resolve');
var resolve = require("resolve");

resolve('assistant-source', { basedir: process.cwd() }, function(error, projectLocalSource) {
resolve("assistant-source", { basedir: process.cwd() }, function(error, projectLocalSource) {
var cli;
if (error) {
// Use it as global module
cli = require('../lib/cli').cli;
cli = require("../lib/cli").cli;
} else {
// Use it as local module
cli = require(projectLocalSource).cli;
}

// resolve local index.js configuration
resolve("./js/index.js", { basedir: process.cwd() }, function(error, projectIndex) {
// resolve local application initializer
resolve("./js/application-initializer.js", { basedir: process.cwd() }, function(error, projectIndex) {
cli(process.argv, error ? false : require(projectIndex));
});
});
});
});
Oops, something went wrong.

0 comments on commit 4eea5a8

Please sign in to comment.
You can’t perform that action at this time.