We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 5291ec0 + 3878b5b commit 26ccc46Copy full SHA for 26ccc46
build.js
@@ -18,12 +18,10 @@ const OUT_DIR_ESM5 = `${NPM_DIR}/package/esm5`;
18
/* Package version */
19
shell.echo(`Setup package version`);
20
let version = config.version;
21
-const versionContent = `export default '${version}';\\n`;
22
-let result = shell.exec(`printf "${versionContent}" >./src/ui-scroll.version.ts`);
23
-if (result.code !== 0) {
24
- shell.echo(chalk.red(`Error: Can't define package version`));
25
- shell.exit(1);
26
-}
+const versionContent = `export default '${version}';`;
+const versionFilePath = './src/ui-scroll.version.ts'
+shell.touch(versionFilePath)
+shell.echo(versionContent).to(versionFilePath)
27
shell.echo(chalk.green(`${PACKAGE} v${version}`));
28
29
shell.echo(`Start building...`);
0 commit comments