mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-30 19:00:09 +00:00
fixed cli problem (hackish) and found a bug in core.ImageGridFeatures.buildFeatureList() (w.o. args)...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
11b84d736e
commit
ae43366f9f
@ -30,7 +30,8 @@ require('features/meta')
|
|||||||
require('features/experimental')
|
require('features/experimental')
|
||||||
require('features/demo')
|
require('features/demo')
|
||||||
|
|
||||||
if(window.nodejs != null){
|
// node features...
|
||||||
|
if(typeof(window) == 'undefined' || window.nodejs != null){
|
||||||
require('features/filesystem')
|
require('features/filesystem')
|
||||||
require('features/cli')
|
require('features/cli')
|
||||||
}
|
}
|
||||||
|
|||||||
@ -98,7 +98,11 @@ module.CLI = core.ImageGridFeatures.Feature({
|
|||||||
that.features.features.length,
|
that.features.features.length,
|
||||||
that.features.features.join('\n '))
|
that.features.features.join('\n '))
|
||||||
})
|
})
|
||||||
|
// XXX make this applicable features...
|
||||||
.option('laf, --list-available-features', 'list available features', function(){
|
.option('laf, --list-available-features', 'list available features', function(){
|
||||||
|
// XXX bug, this hangs....
|
||||||
|
//console.log(core.ImageGridFeatures.buildFeatureList())
|
||||||
|
|
||||||
var f = core.ImageGridFeatures.features
|
var f = core.ImageGridFeatures.features
|
||||||
console.log('Features available (%d):\n ',
|
console.log('Features available (%d):\n ',
|
||||||
f.length,
|
f.length,
|
||||||
@ -121,14 +125,7 @@ module.CLI = core.ImageGridFeatures.Feature({
|
|||||||
// and after setup...
|
// and after setup...
|
||||||
.option('sm, --setup-minimal', 'setup minimal features', function(){
|
.option('sm, --setup-minimal', 'setup minimal features', function(){
|
||||||
// load features we might need...
|
// load features we might need...
|
||||||
// XXX require js loads these at the root...
|
var all = require('features/all')
|
||||||
var location = require('features/location')
|
|
||||||
var history = require('features/history')
|
|
||||||
var app = require('features/app')
|
|
||||||
var marks = require('features/ui-marks')
|
|
||||||
var filesystem = require('features/filesystem')
|
|
||||||
var metadata = require('features/metadata')
|
|
||||||
var experimental = require('features/experimental')
|
|
||||||
|
|
||||||
// extend the current instance to a minimal non-ui
|
// extend the current instance to a minimal non-ui
|
||||||
// state...
|
// state...
|
||||||
|
|||||||
@ -6,6 +6,10 @@
|
|||||||
|
|
||||||
define(function(require){ var module = {}
|
define(function(require){ var module = {}
|
||||||
|
|
||||||
|
if(typeof(window) == 'undefined'){
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
//var DEBUG = DEBUG != null ? DEBUG : true
|
//var DEBUG = DEBUG != null ? DEBUG : true
|
||||||
|
|
||||||
var object = require('lib/object')
|
var object = require('lib/object')
|
||||||
|
|||||||
@ -7,6 +7,10 @@
|
|||||||
|
|
||||||
define(function(require){ var module = {}
|
define(function(require){ var module = {}
|
||||||
|
|
||||||
|
if(typeof(window) == 'undefined'){
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
//var DEBUG = DEBUG != null ? DEBUG : true
|
//var DEBUG = DEBUG != null ? DEBUG : true
|
||||||
|
|
||||||
// XXX is this correct...
|
// XXX is this correct...
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user