Skip to content

Conversation

semanser
Copy link
Contributor

@semanser semanser commented Aug 9, 2021

What's the problem this PR addresses?
Allows to show a corresponding dependency workspace when using yarn upgrade-interactive --show-workspaces command.

Before

Screenshot 2021-08-10 at 01 12 52

After

Screenshot 2021-08-10 at 01 12 08

Closes: #2591 #3281

Checklist

  • I have set the packages that need to be released for my changes to be effective.
  • I will check that all automated PR checks pass before the PR gets reviewed.

@semanser semanser force-pushed the semanser/show-workspaces-in-upgrade-interactive branch 2 times, most recently from c10fc5d to 287b451 Compare August 10, 2021 12:48
@semanser semanser marked this pull request as ready for review August 11, 2021 10:02
@semanser semanser requested a review from arcanis as a code owner August 11, 2021 10:02
Copy link

@bryanph bryanph left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gave it a shot, it worked well when running with --show-workspaces but running it without gives me this:
image

Overall it might be easier to show the workspace in a separate column instead?

@beckerei
Copy link

Is there anything I can do to help with this PR?
What's needed to get this in a future version?

@semanser semanser force-pushed the semanser/show-workspaces-in-upgrade-interactive branch from 287b451 to d5b0bae Compare September 22, 2021 16:19
@semanser
Copy link
Contributor Author

Fixed all the issues!

Screenshot 2021-09-22 at 19 07 13

@davebarr
Copy link

davebarr commented Jan 6, 2022

bump, I would love to see this merged!

@bryanph
Copy link

bryanph commented Apr 30, 2022

Any blockers for this one? Would love to see this change, this would make upgrading a monorepo with many workspaces a lot easier 😄 .

@rightaway
Copy link

Anything blocking this?

@simkessy
Copy link

@bryanph / @arcanis can this get merged?

@WoodyWoodsta
Copy link

Desperately need this as well.

@RDIL
Copy link
Member

RDIL commented Sep 7, 2022

Need the author to fix conflicts before this can be further looked at.

@RDIL RDIL self-requested a review September 7, 2022 15:26
@valleywood
Copy link

valleywood commented Nov 23, 2022

Please, can someone have a look at the conflicts? I desperately need this 🙏
@semanser ?

@davebarr
Copy link

New Year, new bump. Here's to wishing this merges in 2023!

@patrickconroy
Copy link

Just pointing out the obvious and not trying to be mean but without this in a monorepo with many workspaces, upgrade-interactive is almost useless. Is there at least a timeline for getting this reviewed?

@RDIL RDIL requested a review from merceyz March 7, 2023 02:05
@DiFuks
Copy link

DiFuks commented Jul 4, 2023

Any news?

@TheAsda
Copy link

TheAsda commented Oct 4, 2024

A few years have passed, any news?

@lights-a5
Copy link

Ran into this today. Would like this to be merged please.

github-merge-queue bot pushed a commit that referenced this pull request May 16, 2025
## What's the problem this PR addresses?
👋 Hello! I was randomly looking at the `@yarnpkg/cli` bundle, and
esbuild reported a few warnings (when building locally in the repo, and
inspecting on https://esbuild.github.io/analyze/ ).

One of these warnings, was that there are some duplicated external
libraries - such as `chalk`.


![{1BA9255A-15DD-48DC-9A9E-D8183671F486}](https://github.com/user-attachments/assets/e1b8bf8a-db5e-4a92-b7f4-eb6b747b6c49)
<details><summary>Full bundle graph</summary>
<img
src="https://github.com/user-attachments/assets/99133d9b-5bbf-4390-84ab-b608ef301501"
/>
</details> 

The savings from this PR are tiny (a few kb), but worth doing :)

## What does this PR do

This PR bumps chalk to consistently be [v4.1.2
](https://github.com/chalk/chalk/releases/tag/v4.0.0) up from v `3.0.0`.
The diff for 3.0.0 to 4.0.0 is
[here](chalk/chalk@v3.0.0...v4.0.0). The only
relevant breaking change is dropping node 8 support, which should
suffice for yarn (current engines of yarn is set to 18).

> [!NOTE]
> I didn't opt for [v5
](https://github.com/chalk/chalk/releases/tag/v5.0.0)- as it's esm only,
and may require some config tweaking. V5 **is** a smaller bundle though,
~half the size!

/aside - It would be a larger bundle saving to remove the dependency
entirely to something like https://www.npmjs.com/package/picocolors -
but that's potentially a larger piece of work, as `@yarnpkg/shell` [uses
some bespoke colors
](https://github.com/yarnpkg/berry/blob/master/packages/yarnpkg-shell/sources/index.ts#L815-L815).

I tried to bump ink, as they've made some improvements too - but it
seems they expect tools to bundle with an `esm` format - wheras yarn is
currently bundling as `iife`, so would require decent patching or
upstream changes ( I couldn't get either to work just yet).

## How did you fix it?

`yarn upgrade-interactive` to specify v4 of chalk :)
Note that yarn upgrade-interactive is difficult to use when using
workspaces, until #3260 (or similar) are closed. Similarly reported in
#2591 #3281.

## Checklist
- [x] I have read the [Contributing
Guide](https://yarnpkg.com/advanced/contributing).
- [x] I have set the packages that need to be released for my changes to
be effective.
- [x] I will check that all automated PR checks pass before the PR gets
reviewed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature] upgrade-interactive feature to show workspaces