zarro 1.159.0 → 1.161.0

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.
@@ -2,19 +2,20 @@
2
2
  (function () {
3
3
  const gulp = requireModule("gulp");
4
4
  gulp.task("generate-local-task", async () => {
5
- const path = require("path"), { ask } = requireModule("ask"), rawName = await ask("name of new task"), { writeTextFile, fileExists } = require("yafs"), taskName = rawName.trim().replace(/\s+/g, "-"), target = path.join("local-tasks", `${taskName}.ts`);
5
+ const log = requireModule("log"), path = require("path"), { ask } = requireModule("ask"), rawName = await ask("name of new task"), { writeTextFile, fileExists } = require("yafs"), taskName = rawName.trim().replace(/\s+/g, "-"), target = path.join("local-tasks", `${taskName}.ts`);
6
6
  if (await fileExists(target)) {
7
7
  throw new Error(`File already exists at '${target}' - remove it first or rename your task`);
8
8
  }
9
9
  await writeTextFile(target, template.replace("%TASK_NAME%", taskName));
10
+ log.info(`generated new task file at: ${target}`);
10
11
  });
11
- const template = `
12
- /// <reference path="../node_modules/zarro/types.d.ts" />
13
- const
14
- gulp = requireModule<Gulp>("gulp");
15
-
16
- gulp.task(\`%TASK_NAME%\`, async () => {
17
-
18
- });
12
+ const template = `
13
+ /// <reference path="../node_modules/zarro/types.d.ts" />
14
+ const
15
+ gulp = requireModule<Gulp>("gulp");
16
+
17
+ gulp.task(\`%TASK_NAME%\`, async () => {
18
+
19
+ });
19
20
  `.trim();
20
21
  })();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zarro",
3
- "version": "1.159.0",
3
+ "version": "1.161.0",
4
4
  "description": "Some glue to make gulp easier, perhaps even zero- or close-to-zero-conf",
5
5
  "bin": {
6
6
  "zarro": "./index.js"
package/types.d.ts CHANGED
@@ -705,7 +705,7 @@ declare global {
705
705
  type StatFunction = (path: string) => Promise<fs.Stats | null>
706
706
 
707
707
  interface GitSha {
708
- fetchGitSha(): Promise<string>;
708
+ fetchGitSha(forRepo?: string): Promise<string>;
709
709
 
710
710
  init(): Promise<void>;
711
711