@multiplatform.one/cli 1.0.30 → 1.0.31

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.
@@ -1,15 +1,15 @@
1
1
  // src/bin/multiplatformOne.ts
2
2
  import fs from "fs/promises";
3
+ import fsSync from "fs";
3
4
  import inquirer from "inquirer";
4
5
  import os from "os";
5
6
  import path from "path";
6
- import pkg from "@multiplatform.one/cli/package.json";
7
7
  import { execa } from "execa";
8
8
  import { fileURLToPath } from "url";
9
9
  import { program } from "commander";
10
10
  process.env.COOKIECUTTER = path.resolve(path.dirname(fileURLToPath(import.meta.url)), "../../scripts/cookiecutter.sh");
11
11
  program.name("multiplatform.one");
12
- program.version(pkg.version);
12
+ program.version(JSON.parse(fsSync.readFileSync(path.resolve(path.dirname(fileURLToPath(import.meta.url)), "../../package.json"), "utf8"))?.version);
13
13
  program.command("init").argument("[remote]", "the remote to use", "https://gitlab.com/bitspur/multiplatform.one/cookiecutter").option("--name <name>", "the name of the project").description("init multiplatform.one").action(async (remote) => {
14
14
  if ((await execa("git", [
15
15
  "rev-parse",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@multiplatform.one/cli",
3
- "version": "1.0.30",
3
+ "version": "1.0.31",
4
4
  "author": "BitSpur <support@bitspur.com> (https://bitspur.com)",
5
5
  "contributors": [
6
6
  {
@@ -52,7 +52,7 @@
52
52
  "@types/node": "~20.12.13",
53
53
  "tsup": "^8.1.0",
54
54
  "typescript": "~5.3.3",
55
- "@multiplatform.one/utils": "^0.0.15"
55
+ "@multiplatform.one/utils": "^0.0.16"
56
56
  },
57
57
  "dependencies": {
58
58
  "commander": "^9.5.0",
@@ -20,10 +20,10 @@
20
20
  */
21
21
 
22
22
  import fs from 'fs/promises';
23
+ import fsSync from 'fs';
23
24
  import inquirer from 'inquirer';
24
25
  import os from 'os';
25
26
  import path from 'path';
26
- import pkg from '@multiplatform.one/cli/package.json';
27
27
  import type { CookieCutterConfig } from '../types';
28
28
  import { execa } from 'execa';
29
29
  import { fileURLToPath } from 'url';
@@ -31,7 +31,11 @@ import { program } from 'commander';
31
31
 
32
32
  process.env.COOKIECUTTER = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '../../scripts/cookiecutter.sh');
33
33
  program.name('multiplatform.one');
34
- program.version(pkg.version);
34
+ program.version(
35
+ JSON.parse(
36
+ fsSync.readFileSync(path.resolve(path.dirname(fileURLToPath(import.meta.url)), '../../package.json'), 'utf8'),
37
+ )?.version,
38
+ );
35
39
 
36
40
  program
37
41
  .command('init')