@open-pioneer/build-package-cli 0.2.0 → 0.2.1

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog @open-pioneer/build-package-cli
2
2
 
3
+ ## 0.2.1
4
+
5
+ ### Patch Changes
6
+
7
+ - f0cd283: Add package.json metadata
8
+ - Updated dependencies [f0cd283]
9
+ - @open-pioneer/build-package@0.7.1
10
+
3
11
  ## 0.2.0
4
12
 
5
13
  ### Minor Changes
package/README.md CHANGED
@@ -1,15 +1,44 @@
1
1
  # @open-pioneer/build-package-cli
2
2
 
3
- Provides the `build-package` command line tool.
3
+ Provides the `build-pioneer-package` command line tool.
4
4
 
5
- `build-package` should be invoked from the package's source directory.
6
- The package will then be built according to the instructions in the package's `build.config.mjs`:
5
+ Installation:
7
6
 
7
+ ```bash
8
+ $ pnpm add -D @open-pioneer/build-package-cli
8
9
  ```
9
- $ build-package
10
- # TODO output
10
+
11
+ ```text
12
+ $ pnpm build-pioneer-package --help
13
+ Usage: build-pioneer-package [options]
14
+
15
+ Builds an open pioneer package for publishing.
16
+
17
+ Options:
18
+ -p, --package <path> package directory (defaults to current directory)
19
+ -q, --silent disable logging
20
+ -d, --debug show exception stack traces
21
+ -V, --version output the version number
22
+ -h, --help display help for command
11
23
  ```
12
24
 
25
+ `build-pioneer-package` should be invoked from the package's source directory.
26
+ The package will then be built according to the instructions in the package's `build.config.mjs`.
27
+ The output will be written to the package's `dist` directory.
28
+
29
+ ```text
30
+ $ build-pioneer-package
31
+ Building package at <...>
32
+ Building JavaScript...
33
+ Generating TypeScript declaration files...
34
+ Copying assets...
35
+ Writing package metadata...
36
+ Copying auxiliary files...
37
+ Success
38
+ ```
39
+
40
+ To configure the build process, use the `publishConfig` section in your `build.config.mjs`.
41
+
13
42
  ## License
14
43
 
15
44
  [Apache-2.0](https://www.apache.org/licenses/LICENSE-2.0)
package/dist/index.js CHANGED
@@ -27,7 +27,7 @@ var import_commander = require("commander");
27
27
  var import_node_process = require("node:process");
28
28
 
29
29
  // package.json
30
- var version = "0.2.0";
30
+ var version = "0.2.1";
31
31
 
32
32
  // src/index.ts
33
33
  var import_build_package = require("@open-pioneer/build-package");
package/dist/index.js.map CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../src/index.ts", "../package.json"],
4
- "sourcesContent": ["// SPDX-FileCopyrightText: con terra GmbH and contributors\n// SPDX-License-Identifier: Apache-2.0\nimport { Command } from \"commander\";\nimport { cwd, exit } from \"node:process\";\nimport { version } from \"../package.json\";\nimport { build } from \"@open-pioneer/build-package\";\n\nconst program = new Command();\nprogram\n .name(\"build-pioneer-package\")\n .description(\"Builds an open pioneer package for publishing.\")\n .option(\"-p, --package <path>\", \"package directory (defaults to current directory)\")\n .option(\"-q, --silent\", \"disable logging\")\n .option(\"-d, --debug\", \"show exception stack traces\")\n .version(version);\nprogram.parse();\n\nasync function main() {\n const chalk = (await import(\"chalk\")).default;\n const opts = program.opts();\n const debug = opts.debug ?? false;\n const silent = opts.silent ?? false;\n const packagePath = opts.package ?? cwd();\n try {\n await build({\n packageDirectory: packagePath,\n logger: silent ? null : console\n });\n exit(0);\n } catch (e) {\n if (debug) {\n console.error(e);\n } else {\n console.error(chalk.red((e as Error).message ?? String(e)));\n }\n exit(1);\n }\n}\n\nmain().catch((e) => {\n console.error(\"Fatal error\", e);\n exit(1);\n});\n", "{\n \"name\": \"@open-pioneer/build-package-cli\",\n \"version\": \"0.2.0\",\n \"type\": \"commonjs\",\n \"license\": \"Apache-2.0\",\n \"bin\": {\n \"build-pioneer-package\": \"./dist/index.js\"\n },\n \"scripts\": {\n \"clean\": \"rimraf dist\",\n \"build\": \"node build.mjs build\",\n \"build-dev\": \"node build.mjs buildDev\",\n \"dev\": \"node build.mjs watch\"\n },\n \"files\": [\n \"dist/**/*.js\",\n \"dist/**/*.js.map\",\n \"CHANGELOG.md\",\n \"README.md\",\n \"LICENSE\"\n ],\n \"dependencies\": {\n \"@open-pioneer/build-package\": \"workspace:^\",\n \"chalk\": \"^5.2.0\",\n \"commander\": \"^10.0.1\"\n },\n \"devDependencies\": {\n \"build-tools\": \"workspace:*\"\n },\n \"engines\": {\n \"node\": \">= 16\"\n }\n}\n"],
4
+ "sourcesContent": ["// SPDX-FileCopyrightText: con terra GmbH and contributors\n// SPDX-License-Identifier: Apache-2.0\nimport { Command } from \"commander\";\nimport { cwd, exit } from \"node:process\";\nimport { version } from \"../package.json\";\nimport { build } from \"@open-pioneer/build-package\";\n\nconst program = new Command();\nprogram\n .name(\"build-pioneer-package\")\n .description(\"Builds an open pioneer package for publishing.\")\n .option(\"-p, --package <path>\", \"package directory (defaults to current directory)\")\n .option(\"-q, --silent\", \"disable logging\")\n .option(\"-d, --debug\", \"show exception stack traces\")\n .version(version);\nprogram.parse();\n\nasync function main() {\n const chalk = (await import(\"chalk\")).default;\n const opts = program.opts();\n const debug = opts.debug ?? false;\n const silent = opts.silent ?? false;\n const packagePath = opts.package ?? cwd();\n try {\n await build({\n packageDirectory: packagePath,\n logger: silent ? null : console\n });\n exit(0);\n } catch (e) {\n if (debug) {\n console.error(e);\n } else {\n console.error(chalk.red((e as Error).message ?? String(e)));\n }\n exit(1);\n }\n}\n\nmain().catch((e) => {\n console.error(\"Fatal error\", e);\n exit(1);\n});\n", "{\n \"name\": \"@open-pioneer/build-package-cli\",\n \"version\": \"0.2.1\",\n \"type\": \"commonjs\",\n \"license\": \"Apache-2.0\",\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"https://github.com/open-pioneer/build-tools.git\",\n \"directory\": \"packages/build-package-cli\"\n },\n \"keywords\": [\n \"open-pioneer-framework\"\n ],\n \"bugs\": {\n \"url\": \"https://github.com/open-pioneer/build-tools/issues\"\n },\n \"bin\": {\n \"build-pioneer-package\": \"./dist/index.js\"\n },\n \"scripts\": {\n \"clean\": \"rimraf dist\",\n \"build\": \"node build.mjs build\",\n \"build-dev\": \"node build.mjs buildDev\",\n \"dev\": \"node build.mjs watch\"\n },\n \"files\": [\n \"dist/**/*.js\",\n \"dist/**/*.js.map\",\n \"CHANGELOG.md\",\n \"README.md\",\n \"LICENSE\"\n ],\n \"dependencies\": {\n \"@open-pioneer/build-package\": \"workspace:^\",\n \"chalk\": \"^5.2.0\",\n \"commander\": \"^10.0.1\"\n },\n \"devDependencies\": {\n \"build-tools\": \"workspace:*\"\n },\n \"engines\": {\n \"node\": \">= 16\"\n }\n}\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;AAEA,uBAAwB;AACxB,0BAA0B;;;ACDtB,cAAW;;;ADGf,2BAAsB;AAEtB,IAAM,UAAU,IAAI,yBAAQ;AAC5B,QACK,KAAK,uBAAuB,EAC5B,YAAY,gDAAgD,EAC5D,OAAO,wBAAwB,mDAAmD,EAClF,OAAO,gBAAgB,iBAAiB,EACxC,OAAO,eAAe,6BAA6B,EACnD,QAAQ,OAAO;AACpB,QAAQ,MAAM;AAEd,eAAe,OAAO;AAClB,QAAM,SAAS,MAAM,OAAO,OAAO,GAAG;AACtC,QAAM,OAAO,QAAQ,KAAK;AAC1B,QAAM,QAAQ,KAAK,SAAS;AAC5B,QAAM,SAAS,KAAK,UAAU;AAC9B,QAAM,cAAc,KAAK,eAAW,yBAAI;AACxC,MAAI;AACA,cAAM,4BAAM;AAAA,MACR,kBAAkB;AAAA,MAClB,QAAQ,SAAS,OAAO;AAAA,IAC5B,CAAC;AACD,kCAAK,CAAC;AAAA,EACV,SAAS,GAAP;AACE,QAAI,OAAO;AACP,cAAQ,MAAM,CAAC;AAAA,IACnB,OAAO;AACH,cAAQ,MAAM,MAAM,IAAK,EAAY,WAAW,OAAO,CAAC,CAAC,CAAC;AAAA,IAC9D;AACA,kCAAK,CAAC;AAAA,EACV;AACJ;AAEA,KAAK,EAAE,MAAM,CAAC,MAAM;AAChB,UAAQ,MAAM,eAAe,CAAC;AAC9B,gCAAK,CAAC;AACV,CAAC;",
6
6
  "names": []
7
7
  }
package/package.json CHANGED
@@ -1,8 +1,19 @@
1
1
  {
2
2
  "name": "@open-pioneer/build-package-cli",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "type": "commonjs",
5
5
  "license": "Apache-2.0",
6
+ "repository": {
7
+ "type": "git",
8
+ "url": "https://github.com/open-pioneer/build-tools.git",
9
+ "directory": "packages/build-package-cli"
10
+ },
11
+ "keywords": [
12
+ "open-pioneer-framework"
13
+ ],
14
+ "bugs": {
15
+ "url": "https://github.com/open-pioneer/build-tools/issues"
16
+ },
6
17
  "bin": {
7
18
  "build-pioneer-package": "./dist/index.js"
8
19
  },
@@ -16,7 +27,7 @@
16
27
  "dependencies": {
17
28
  "chalk": "^5.2.0",
18
29
  "commander": "^10.0.1",
19
- "@open-pioneer/build-package": "^0.7.0"
30
+ "@open-pioneer/build-package": "^0.7.1"
20
31
  },
21
32
  "devDependencies": {
22
33
  "build-tools": "0.0.0"