antfu-collective / bumpp

Interactive CLI that bumps your version numbers and more
https://jstools.dev/version-bump-prompt/
MIT License
597 stars 43 forks source link

`--execute` argument not works with `%s` placeholder #10

Open azat-io opened 1 year ago

azat-io commented 1 year ago

Describe the bug

Hi!

Looks like --execute argument not works %s placeholder (like --commit or --tag argument). I want to use bumpp with changelogen.

Like this:

{
  "scripts": {
    "release":  "bumpp package.json --execute=\"pnpm exec changelogen --output changelog.md -r %s && git add changelog.md\" --commit \"build: publish v%s\" --tag --all"
  }
}

But I get the following error:

ERROR  ENOENT: no such file or directory, chdir '/Users/azat/Developer/eslint-plugin-perfectionist' -> '/Users/azat/Developer/eslint-plugin-perfectionist/&&'                                                                                     6:48:17 PM

  at wrappedChdir (node:internal/bootstrap/switches/does_own_process_state:112:14)
  at process.chdir (node:internal/worker:108:5)
  at Module.defaultMain (node_modules/.pnpm/changelogen@0.5.3/node_modules/changelogen/dist/chunks/default.mjs:21:11)
  at node_modules/.pnpm/changelogen@0.5.3/node_modules/changelogen/dist/cli.mjs:22:56
  at async main (node_modules/.pnpm/changelogen@0.5.3/node_modules/changelogen/dist/cli.mjs:22:3)

Reproduction

https://github.com/azat-io/eslint-plugin-perfectionist

System Info

System:
    OS: macOS 13.4
    CPU: (10) arm64 Apple M1 Pro
    Memory: 2.68 GB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.2.0 - ~/.asdf/installs/nodejs/20.2.0/bin/node
    Yarn: 1.22.19 - /opt/homebrew/bin/yarn
    npm: 9.6.6 - ~/.asdf/plugins/nodejs/shims/npm
  Browsers:
    Chrome: 114.0.5735.106
    Firefox: 111.0.1
    Safari: 16.5

Used Package Manager

pnpm

Validations