milkee 2.1.2 → 2.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/main.js +8 -3
  2. package/package.json +1 -1
package/dist/main.js CHANGED
@@ -101,7 +101,9 @@
101
101
  }
102
102
  } else if (stat.isFile()) {
103
103
  if (targetPath.endsWith('.js' || targetPath.endsWith('.js.map'))) {
104
- consola.info(`Found file: ${targetPath}`);
104
+ if (fs.existsSync(targetPath)) {
105
+ consola.info(`Found file: \`${targetPath}\``);
106
+ }
105
107
  filesList.push(targetPath);
106
108
  }
107
109
  }
@@ -265,8 +267,8 @@
265
267
  backupFiles = [];
266
268
  restoreBackups = function() {
267
269
  var backup, e, i, len;
270
+ consola.info("Restoring previous files...");
268
271
  if (backupFiles.length > 0) {
269
- consola.info("Restoring previous files...");
270
272
  for (i = 0, len = backupFiles.length; i < len; i++) {
271
273
  backup = backupFiles[i];
272
274
  try {
@@ -284,6 +286,8 @@
284
286
  }
285
287
  }
286
288
  return consola.success("Restored!");
289
+ } else {
290
+ return consola.info("No files found to restore.");
287
291
  }
288
292
  };
289
293
  clearBackups = function() {
@@ -318,6 +322,7 @@
318
322
  if (stat.isDirectory()) {
319
323
  consola.info("Executing: Refresh");
320
324
  items = fs.readdirSync(targetDir);
325
+ consola.start("Bucking up files...");
321
326
  for (i = 0, len = items.length; i < len; i++) {
322
327
  item = items[i];
323
328
  originalPath = path.join(targetDir, item);
@@ -331,7 +336,7 @@
331
336
  }
332
337
  // itemPath = path.join targetDir, item
333
338
  // fs.rmSync itemPath, recursive: true, force: true
334
- consola.success(`Existing: files backed up with hash \`${hash}\``);
339
+ consola.success(`Files backed up with hash \`${hash}\``);
335
340
  } else {
336
341
  // consola.success "Refreshed!"
337
342
  consola.info("Executing: Refresh (Single File)");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "milkee",
3
- "version": "2.1.2",
3
+ "version": "2.1.3",
4
4
  "description": "A simple CoffeeScript build tool with coffee.config.cjs",
5
5
  "main": "dist/main.js",
6
6
  "bin": {