diff --git a/.github/workflows/semantic-release.yml b/.github/workflows/semantic-release.yml index e1a93b5..57ae068 100644 --- a/.github/workflows/semantic-release.yml +++ b/.github/workflows/semantic-release.yml @@ -1,7 +1,7 @@ name: Release on: push: - branches: [ main, beta, prerelease ] + branches: [ main, beta, prerelease, oclif4 ] pull_request: branches: [ main ] jobs: diff --git a/.github/workflows/vulnerability-updates.yml b/.github/workflows/vulnerability-updates.yml new file mode 100644 index 0000000..eb9d68f --- /dev/null +++ b/.github/workflows/vulnerability-updates.yml @@ -0,0 +1,28 @@ +name: Vulnerability update + +on: + issues: + types: [opened, labeled, reopened] + workflow_dispatch: + +concurrency: + group: vulnerability-update-${{ github.event_name }}-${{ github.event.issue.number || github.run_id }} + cancel-in-progress: true + +jobs: + run: + if: | + github.event_name == 'workflow_dispatch' || + ( + github.event_name == 'issues' && + contains(github.event.issue.labels.*.name, 'vulnerability') + ) + uses: commercelayer/.github/.github/workflows/dependencies-update-pnpm.yaml@main + with: + reviewers: "malessani,gciotola,pfferrari,pviti" + use_milestone: false + run_test: true + run_build: true + run_check: true + issue_number: ${{ github.event_name == 'issues' && github.event.issue.number || '' }} + secrets: inherit diff --git a/.gitignore b/.gitignore index ae295d3..5055903 100644 --- a/.gitignore +++ b/.gitignore @@ -10,6 +10,8 @@ node_modules .editorconfig .oclif.manifest.json /package-lock.json +/tsconfig.tsbuildinfo test_data* *.env +tsconfig.tsbuildinfo diff --git a/.mocharc.json b/.mocharc.json index c05ca9a..efdb8bb 100644 --- a/.mocharc.json +++ b/.mocharc.json @@ -1,3 +1,4 @@ { - "import": "tsx" + "import": "tsx", + "timeout": 10000 } diff --git a/.releaserc b/.releaserc index c63e445..fa1143b 100644 --- a/.releaserc +++ b/.releaserc @@ -5,7 +5,8 @@ { "name": "main", "channel": "latest" }, "+([0-9])?(.{+([0-9]),x}).x", { "name": "beta", "prerelease": true }, - { "name": "prerelease", "prerelease": "rc" } + { "name": "prerelease", "prerelease": "rc" }, + { "name": "oclif4", "prerelease": true } ], "plugins": [ "@semantic-release/commit-analyzer", diff --git a/CHANGELOG.md b/CHANGELOG.md index c61892a..69d23ab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,102 @@ +# [7.0.0-oclif4.7](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.6...v7.0.0-oclif4.7) (2026-04-20) + + +### Bug Fixes + +* fix alias check and dependencie ([5f5d6fb](https://github.com/commercelayer/commercelayer-cli/commit/5f5d6fbc74208857145fd4e0a66b4abcb35941ee)) +* fix config command tests to exercise their respective commands ([ef28a27](https://github.com/commercelayer/commercelayer-cli/commit/ef28a27fe299b69bdea0f89696216b59d01ef114)) +* fix login test ([6fb6680](https://github.com/commercelayer/commercelayer-cli/commit/6fb668078d5fef3fe9f3d26e1b670c6c4f917b88)) +* fix overrides ([f05baf9](https://github.com/commercelayer/commercelayer-cli/commit/f05baf9efef7b32e71c640c3c4db0c3b23dce19a)) +* fix overrides ([f05810a](https://github.com/commercelayer/commercelayer-cli/commit/f05810afc7f8fbf07aca105dff0067abe28f4c39)) +* fix plugins:available command and update dependencies ([83e9400](https://github.com/commercelayer/commercelayer-cli/commit/83e9400f148f52beaa7a436ff1b035775223f593)) +* fix test config ([7071af7](https://github.com/commercelayer/commercelayer-cli/commit/7071af72e387a2412e1bad7e069ceab1b6260563)) +* remove dependencies overrides ([59b8aa3](https://github.com/commercelayer/commercelayer-cli/commit/59b8aa3497c3ced5f264c8878edcc4326737dc67)) +* run tests in updates workflow ([e7d89c5](https://github.com/commercelayer/commercelayer-cli/commit/e7d89c5b3061ff7b054fa10e41b0d81fbb62f4ff)) +* update dependencies ([d10fab4](https://github.com/commercelayer/commercelayer-cli/commit/d10fab4e65cb77c6695600fd7b91ca0a1d18785a)) +* update dependencies and add updates workflow ([242e14a](https://github.com/commercelayer/commercelayer-cli/commit/242e14ab543a76d809b8283efdf16ad9412649e8)) + + +### Features + +* add biome ([488db2c](https://github.com/commercelayer/commercelayer-cli/commit/488db2cc02c492e2bc94ca5d42b1e6b7243f0a21)) +* require node to v22 ([560dd60](https://github.com/commercelayer/commercelayer-cli/commit/560dd607adb44c0dd87d35f2c08ddb8f0aa67af4)) +* upgrade oclif core and test to v4 ([e8dc2c2](https://github.com/commercelayer/commercelayer-cli/commit/e8dc2c27cffbbdc1a296a83db40abda232b40992)) + + +### BREAKING CHANGES + +* require node to v22 +* upgrade oclif core and test to v4 + +# [7.0.0-oclif4.6](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.5...v7.0.0-oclif4.6) (2026-03-31) + + +### Bug Fixes + +* fix config command tests to exercise their respective commands ([4b10056](https://github.com/commercelayer/commercelayer-cli/commit/4b10056d619095e0c80a3f1ec4e2448925bcfa27)) + +# [7.0.0-oclif4.5](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.4...v7.0.0-oclif4.5) (2026-03-26) + + +### Bug Fixes + +* update dependencies ([0633985](https://github.com/commercelayer/commercelayer-cli/commit/06339853a7fecc14d4316d2aaad93c529a94c8bb)) + + +### Features + +* require node to v22 ([3a38321](https://github.com/commercelayer/commercelayer-cli/commit/3a383219c6016e4ded73c1fa39e35cb15c3ac968)) + + +### BREAKING CHANGES + +* require node to v22 + +# [7.0.0-oclif4.4](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.3...v7.0.0-oclif4.4) (2026-03-26) + + +### Bug Fixes + +* fix test script ([af84073](https://github.com/commercelayer/commercelayer-cli/commit/af840734e7143d0033a8a5cb7e3a2bf2c70ab863)) +* fix typescript version ([ded2ce2](https://github.com/commercelayer/commercelayer-cli/commit/ded2ce202b94fccca51e5b7d8d92b0b409834279)) + + +### Features + +* add biome and update actions ([f774195](https://github.com/commercelayer/commercelayer-cli/commit/f774195958782e2ea9cff565f3cc415d41720aa8)) + +# [7.0.0-oclif4.3](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.2...v7.0.0-oclif4.3) (2026-03-24) + + +### Features + +* add biome ([e899e39](https://github.com/commercelayer/commercelayer-cli/commit/e899e3936fe7fb7b838c628891f50a37ef930778)) + +# [7.0.0-oclif4.2](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.1...v7.0.0-oclif4.2) (2026-03-24) + + +### Bug Fixes + +* fix alias check and dependencie ([77503cb](https://github.com/commercelayer/commercelayer-cli/commit/77503cba0c8c2aaa83cb0c6af57421b7de5dd929)) + +# [7.0.0-oclif4.1](https://github.com/commercelayer/commercelayer-cli/compare/v6.8.3...v7.0.0-oclif4.1) (2026-03-19) + + +### Bug Fixes + +* fix login test ([4e31a78](https://github.com/commercelayer/commercelayer-cli/commit/4e31a7852a9317bb7fc682a2e68089f63f87500f)) +* fix test config ([e5c0fa7](https://github.com/commercelayer/commercelayer-cli/commit/e5c0fa7b73ee0688053aa3636adb480ffe9ddaf3)) + + +### Features + +* upgrade oclif core and test to v4 ([f19f72c](https://github.com/commercelayer/commercelayer-cli/commit/f19f72c61009a721d044b515da0c39892beb9d90)) + + +### BREAKING CHANGES + +* upgrade oclif core and test to v4 + # [6.9.0](https://github.com/commercelayer/commercelayer-cli/compare/v6.8.3...v6.9.0) (2026-03-26) @@ -11,6 +110,75 @@ * add biome and update actions ([f774195](https://github.com/commercelayer/commercelayer-cli/commit/f774195958782e2ea9cff565f3cc415d41720aa8)) +# [7.0.0-oclif4.6](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.5...v7.0.0-oclif4.6) (2026-03-31) + + +### Bug Fixes + +* fix config command tests to exercise their respective commands ([4b10056](https://github.com/commercelayer/commercelayer-cli/commit/4b10056d619095e0c80a3f1ec4e2448925bcfa27)) + +# [7.0.0-oclif4.5](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.4...v7.0.0-oclif4.5) (2026-03-26) + + +### Bug Fixes + +* update dependencies ([0633985](https://github.com/commercelayer/commercelayer-cli/commit/06339853a7fecc14d4316d2aaad93c529a94c8bb)) + + +### Features + +* require node to v22 ([3a38321](https://github.com/commercelayer/commercelayer-cli/commit/3a383219c6016e4ded73c1fa39e35cb15c3ac968)) + + +### BREAKING CHANGES + +* require node to v22 + +# [7.0.0-oclif4.4](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.3...v7.0.0-oclif4.4) (2026-03-26) + + +### Bug Fixes + +* fix test script ([af84073](https://github.com/commercelayer/commercelayer-cli/commit/af840734e7143d0033a8a5cb7e3a2bf2c70ab863)) +* fix typescript version ([ded2ce2](https://github.com/commercelayer/commercelayer-cli/commit/ded2ce202b94fccca51e5b7d8d92b0b409834279)) + + +### Features + +* add biome and update actions ([f774195](https://github.com/commercelayer/commercelayer-cli/commit/f774195958782e2ea9cff565f3cc415d41720aa8)) + +# [7.0.0-oclif4.3](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.2...v7.0.0-oclif4.3) (2026-03-24) + + +### Features + +* add biome ([e899e39](https://github.com/commercelayer/commercelayer-cli/commit/e899e3936fe7fb7b838c628891f50a37ef930778)) + +# [7.0.0-oclif4.2](https://github.com/commercelayer/commercelayer-cli/compare/v7.0.0-oclif4.1...v7.0.0-oclif4.2) (2026-03-24) + + +### Bug Fixes + +* fix alias check and dependencie ([77503cb](https://github.com/commercelayer/commercelayer-cli/commit/77503cba0c8c2aaa83cb0c6af57421b7de5dd929)) + +# [7.0.0-oclif4.1](https://github.com/commercelayer/commercelayer-cli/compare/v6.8.3...v7.0.0-oclif4.1) (2026-03-19) + + +### Bug Fixes + +* fix login test ([4e31a78](https://github.com/commercelayer/commercelayer-cli/commit/4e31a7852a9317bb7fc682a2e68089f63f87500f)) +* fix test config ([e5c0fa7](https://github.com/commercelayer/commercelayer-cli/commit/e5c0fa7b73ee0688053aa3636adb480ffe9ddaf3)) + + +### Features + +* upgrade oclif core and test to v4 ([f19f72c](https://github.com/commercelayer/commercelayer-cli/commit/f19f72c61009a721d044b515da0c39892beb9d90)) + + +### BREAKING CHANGES + +* upgrade oclif core and test to v4 + ## [6.8.3](https://github.com/commercelayer/commercelayer-cli/compare/v6.8.2...v6.8.3) (2026-03-16) diff --git a/README.md b/README.md index 28c0909..4445f8f 100644 --- a/README.md +++ b/README.md @@ -65,12 +65,680 @@ The Commerce Layer CLI supports the following commands: -* [`commercelayer applications`](docs/applications.md) - Manage login to CLI applications. -* [`commercelayer autocomplete`](docs/autocomplete.md) - Display autocomplete installation instructions. -* [`commercelayer cli`](docs/cli.md) - Core CLI commands. -* [`commercelayer help`](docs/help.md) - Display help for commercelayer. -* [`commercelayer plugins`](docs/plugins.md) - Manage CLI plugins. +* [`commercelayer applications`](#commercelayer-applications) +* [`commercelayer applications:add`](#commercelayer-applicationsadd) +* [`commercelayer applications:current`](#commercelayer-applicationscurrent) +* [`commercelayer applications:info`](#commercelayer-applicationsinfo) +* [`commercelayer applications:login`](#commercelayer-applicationslogin) +* [`commercelayer applications:logout`](#commercelayer-applicationslogout) +* [`commercelayer applications:provisioning`](#commercelayer-applicationsprovisioning) +* [`commercelayer applications:scope SCOPE`](#commercelayer-applicationsscope-scope) +* [`commercelayer applications:switch`](#commercelayer-applicationsswitch) +* [`commercelayer autocomplete [SHELL]`](#commercelayer-autocomplete-shell) +* [`commercelayer cli:dir`](#commercelayer-clidir) +* [`commercelayer cli:update`](#commercelayer-cliupdate) +* [`commercelayer cli:version`](#commercelayer-cliversion) +* [`commercelayer help [COMMAND]`](#commercelayer-help-command) +* [`commercelayer plugins`](#commercelayer-plugins) +* [`commercelayer plugins:available`](#commercelayer-pluginsavailable) +* [`commercelayer plugins:inspect PLUGIN...`](#commercelayer-pluginsinspect-plugin) +* [`commercelayer plugins:install PLUGIN`](#commercelayer-pluginsinstall-plugin) +* [`commercelayer plugins:latest [PLUGIN]`](#commercelayer-pluginslatest-plugin) +* [`commercelayer plugins:link PATH`](#commercelayer-pluginslink-path) +* [`commercelayer plugins:reset`](#commercelayer-pluginsreset) +* [`commercelayer plugins:uninstall [PLUGIN]`](#commercelayer-pluginsuninstall-plugin) +* [`commercelayer plugins:update`](#commercelayer-pluginsupdate) + +### `commercelayer applications` + +Show a list of all (logged in) available CLI applications. +```sh-session +USAGE + $ commercelayer applications [-k integration|sales_channel|user] [--live | -m test|live] [-a | --id + ] [-A core|provisioning | -o ] [-S] + +FLAGS + -A, --api=