@ -33,6 +33,7 @@ var ROOT_DIR = __dirname + '/', // absolute path to project's root
BUILD _TARGETS = [ BUILD _TARGET , BUILD _WORKER _TARGET ] ,
BUILD _TARGETS = [ BUILD _TARGET , BUILD _WORKER _TARGET ] ,
FIREFOX _BUILD _DIR = BUILD _DIR + '/firefox/' ,
FIREFOX _BUILD _DIR = BUILD _DIR + '/firefox/' ,
CHROME _BUILD _DIR = BUILD _DIR + '/chromium/' ,
CHROME _BUILD _DIR = BUILD _DIR + '/chromium/' ,
B2G _BUILD _DIR = BUILD _DIR + '/b2g/' ,
EXTENSION _SRC _DIR = 'extensions/' ,
EXTENSION _SRC _DIR = 'extensions/' ,
LOCALE _SRC _DIR = 'l10n/' ,
LOCALE _SRC _DIR = 'l10n/' ,
GH _PAGES _DIR = BUILD _DIR + 'gh-pages/' ,
GH _PAGES _DIR = BUILD _DIR + 'gh-pages/' ,
@ -127,6 +128,7 @@ target.generic = function() {
target . web = function ( ) {
target . web = function ( ) {
target . generic ( ) ;
target . generic ( ) ;
target . extension ( ) ;
target . extension ( ) ;
target . b2g ( ) ;
echo ( ) ;
echo ( ) ;
echo ( '### Creating web site' ) ;
echo ( '### Creating web site' ) ;
@ -139,6 +141,7 @@ target.web = function() {
mkdir ( '-p' , GH _PAGES _DIR + BUILD _DIR ) ;
mkdir ( '-p' , GH _PAGES _DIR + BUILD _DIR ) ;
mkdir ( '-p' , GH _PAGES _DIR + EXTENSION _SRC _DIR + '/firefox' ) ;
mkdir ( '-p' , GH _PAGES _DIR + EXTENSION _SRC _DIR + '/firefox' ) ;
mkdir ( '-p' , GH _PAGES _DIR + EXTENSION _SRC _DIR + '/chromium' ) ;
mkdir ( '-p' , GH _PAGES _DIR + EXTENSION _SRC _DIR + '/chromium' ) ;
mkdir ( '-p' , GH _PAGES _DIR + EXTENSION _SRC _DIR + '/b2g' ) ;
cp ( '-R' , GENERIC _DIR + '/*' , GH _PAGES _DIR ) ;
cp ( '-R' , GENERIC _DIR + '/*' , GH _PAGES _DIR ) ;
cp ( FIREFOX _BUILD _DIR + '/*.xpi' , FIREFOX _BUILD _DIR + '/*.rdf' ,
cp ( FIREFOX _BUILD _DIR + '/*.xpi' , FIREFOX _BUILD _DIR + '/*.rdf' ,
@ -147,6 +150,7 @@ target.web = function() {
GH _PAGES _DIR + EXTENSION _SRC _DIR + 'chromium/' ) ;
GH _PAGES _DIR + EXTENSION _SRC _DIR + 'chromium/' ) ;
cp ( 'web/index.html.template' , GH _PAGES _DIR + '/index.html' ) ;
cp ( 'web/index.html.template' , GH _PAGES _DIR + '/index.html' ) ;
cp ( '-R' , 'test/features' , GH _PAGES _DIR ) ;
cp ( '-R' , 'test/features' , GH _PAGES _DIR ) ;
cp ( '-R' , B2G _BUILD _DIR , GH _PAGES _DIR + EXTENSION _SRC _DIR + 'b2g/' ) ;
cd ( GH _PAGES _DIR ) ;
cd ( GH _PAGES _DIR ) ;
exec ( 'git init' ) ;
exec ( 'git init' ) ;
@ -602,8 +606,7 @@ target.b2g = function() {
echo ( ) ;
echo ( ) ;
echo ( '### Building B2G (Firefox OS App)' ) ;
echo ( '### Building B2G (Firefox OS App)' ) ;
var B2G _BUILD _DIR = BUILD _DIR + '/b2g/' ,
var B2G _BUILD _CONTENT _DIR = B2G _BUILD _DIR + '/content/' ;
B2G _BUILD _CONTENT _DIR = B2G _BUILD _DIR + '/content/' ;
var defines = builder . merge ( DEFINES , { B2G : true } ) ;
var defines = builder . merge ( DEFINES , { B2G : true } ) ;
target . bundle ( { defines : defines } ) ;
target . bundle ( { defines : defines } ) ;