Skip to content

Commit

Permalink
fiddle with gulpfile.js so that 'gulp install', our usual install com…
Browse files Browse the repository at this point in the history
…mand, does the right order full deployment and JS creation; work on #317
  • Loading branch information
kltm committed Mar 19, 2016
1 parent 96c1dba commit a809a94
Showing 1 changed file with 17 additions and 12 deletions.
29 changes: 17 additions & 12 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -250,10 +250,11 @@ gulp.task('docs', shell.task(_run_cmd_list(
/// AmiGO install.
///

gulp.task('install', ['build', 'compile']);
gulp.task('install', ['compile', 'build']);

// TODO/BUG: This should eventually be replaced by a read of
// javascript/web.
// javascript/web. For now, we'll just have this so we can work our
// way through the garage fixing things at our leisure.
var web_compilables = [
'AmiGOBioView.js',
'AmiGOCytoView.js',
Expand Down Expand Up @@ -291,23 +292,27 @@ function _client_compile_task(file) {

// Compile all JS used in AmiGO and move it to the staging/deployment
// directory.
gulp.task('compile', function(cb){
gulp.task('compile', ['build'], function(cb){
console.log('Start compile');
us.each(web_compilables, function(file){
console.log('Compiling: ' + file);
_client_compile_task(file);
});
console.log('End compile');
cb(null);
});

//
// Correctly build/deploy/roll out files into working AmiGO
// configuration.
gulp.task('build', shell.task(_run_cmd_list(
// First, make sure our subservient amigo2 package has what it
// needs to run at all.
['cd ./javascript/npm/amigo2-instance-data && npm install',
// './node_modules/.bin/browserify javascript/web/AmiGOCytoViewSource.js -o javascript/web/AmiGOCytoView.js --exclude "ringo/httpclient"',
// './node_modules/.bin/browserify javascript/web/AmiGOBioViewSource.js -o javascript/web/AmiGOBioView.js --exclude "ringo/httpclient"',
'./install -v'
]
)));
// First, make sure our subservient amigo2 package has what it
// needs to run at all.
[
'cd ./javascript/npm/amigo2-instance-data && npm install',
'./install -v'
]
))
);

///
/// GOlr operations and handling.
Expand Down

0 comments on commit a809a94

Please sign in to comment.