@@ -541,6 +541,7 @@ function Framework() {
541541 'directory-definitions' : '/definitions/' ,
542542 'directory-temp' : '/tmp/' ,
543543 'directory-models' : '/models/' ,
544+ 'directory-schemas' : '/schemas/' ,
544545 'directory-resources' : '/resources/' ,
545546 'directory-public' : '/public/' ,
546547 'directory-public-virtual' : '/app/' ,
@@ -3307,6 +3308,16 @@ F.$load = function(types, targetdirectory, callback, packageName) {
33073308 } ) ;
33083309 }
33093310
3311+ if ( ! types || types . indexOf ( 'schemas' ) !== - 1 ) {
3312+ operations . push ( function ( resume ) {
3313+ dir = U . combine ( targetdirectory , isPackage ? '/schemas/' : F . config [ 'directory-schemas' ] ) ;
3314+ arr = [ ] ;
3315+ listing ( dir , 0 , arr ) ;
3316+ arr . forEach ( ( item ) => dependencies . push ( next => F . install ( 'schema' , item . name , item . filename , undefined , undefined , undefined , true , undefined , undefined , next , packageName ) ) ) ;
3317+ resume ( ) ;
3318+ } ) ;
3319+ }
3320+
33103321 if ( ! types || types . indexOf ( 'themes' ) !== - 1 ) {
33113322 operations . push ( function ( resume ) {
33123323 arr = [ ] ;
@@ -3864,7 +3875,7 @@ F.install = function(type, name, declaration, options, callback, internal, useRe
38643875 return F ;
38653876 }
38663877
3867- if ( type === 'definition' || type === 'eval' ) {
3878+ if ( type === 'definition' || type === 'eval' || type === 'schema' ) {
38683879
38693880 _controller = '' ;
38703881 _owner = ( packageName ? packageName + '@' : '' ) + type + '#' + name ;
0 commit comments