You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
lerna ls has never exited non-zero with no results. lerna changeddoes exit non-zero, as it was intended to be a filter for lerna publish in CI (for example). (lerna changed is equivalent to lerna ls --since)
ba54439 was a bit overzealously trying to avoid an empty console.log(). Perhaps testing result.text.length instead of result.count is more appropriate? It would still emit an empty array, in your case.
Expected Behavior
lerna ls --since REF --json
prints [] if there are no changed packagesCurrent Behavior
lerna ls --since REF --json
prints an empty string if there are no changed packagesPossible Solution
not sure off the top of my head but i'd be happy to do a pr to fix it
Steps to Reproduce (for bugs)
on master, run
lerna ls --since master --json
Context
i have a script that runs this to get changed packages. It needs a special case to handle no packages which is unnecessary
the behavior seems to have changed recently. it used to return a non-zero exit code if there were no unchanged packages, which also seemed wrong.
Your Environment
lerna --version
yarn --version
node --version
The text was updated successfully, but these errors were encountered: