Implementation for copay distribution sass.
This commit is contained in:
parent
52a690e31e
commit
73a06b595f
105 changed files with 1150 additions and 480 deletions
|
|
@ -105,7 +105,9 @@ try {
|
|||
fs.writeFileSync('../externalServices.json', externalServices, 'utf8');
|
||||
|
||||
function copyDir(from, to, cb) {
|
||||
console.log('Copying dir ' + from + ' to');
|
||||
console.log('Copying dir ' + from + ' to ' + to);
|
||||
if (fs.existsSync(to)) fs.removeSync(to); // remove previous app directory
|
||||
if (!fs.existsSync(from)) return; // nothing to do
|
||||
var files = [];
|
||||
fs.walk(from)
|
||||
.on('data', function(item) {
|
||||
|
|
@ -115,16 +117,12 @@ function copyDir(from, to, cb) {
|
|||
var l = tmp.length - from.length;
|
||||
if (tmp.indexOf(from) == l) return; // #same dir
|
||||
|
||||
console.log('[apply.js.81]', l); //TODO
|
||||
|
||||
console.log('[apply.js.78]', from); //TODO
|
||||
// console.log('[apply.js.78]', to); //TODO
|
||||
console.log('[apply.js.78]', item.path); //TODO
|
||||
console.log('[apply.js.78]', tmp.indexOf(from)); //TODO
|
||||
}
|
||||
if (item.path.indexOf('DS_Store') >= 0) return;
|
||||
|
||||
files.push(item.path)
|
||||
if (!files.includes(path.dirname(item.path))) {
|
||||
files.push(item.path);
|
||||
}
|
||||
})
|
||||
.on('end', function() {
|
||||
files.forEach(function(i) {
|
||||
|
|
@ -139,5 +137,7 @@ function copyDir(from, to, cb) {
|
|||
|
||||
|
||||
copyDir(configDir + '/img/', '../www/img/app/', function() {
|
||||
console.log("apply.js finished. \n\n");
|
||||
copyDir(configDir + '/sass/', '../src/sass/app/', function() {
|
||||
console.log("apply.js finished. \n\n");
|
||||
});
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue