Skip to content

chore: add workspace flag to package script #1344

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Feb 28, 2023

Conversation

Muthuveerappanv
Copy link
Contributor

@Muthuveerappanv Muthuveerappanv commented Feb 28, 2023

Description of your changes

As detailed in the linked issue, the package script present in the main package.json currently causes a recursion. This PR modifies the command to include the -ws flag so that the command is run in each one of the workspace packages.

Fixes #1343.

How to verify this change

Run the command after checking out the branch locally & confirm that the package command is called in each package of the workspace.

Screen Shot 2023-02-28 at 9 16 04 AM

Related issues, RFCs

Issue number: #1343

Checklist

  • My changes meet the tenets criteria
  • I have performed a self-review of my own code
  • I have commented my code where necessary, particularly in areas that should be flagged with a TODO, or hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have made corresponding changes to the examples
  • My changes generate no new warnings
  • The code coverage hasn't decreased
  • I have added tests that prove my change is effective and works
  • New and existing unit tests pass locally and in Github Actions
  • Any dependent changes have been merged and published
  • The PR title follows the conventional commit semantics

Breaking change checklist

Is it a breaking change?: NO

  • I have documented the migration process
  • I have added, implemented necessary warnings (if it can live side by side)

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@pull-request-size pull-request-size bot added the size/XS PR between 0-9 LOC label Feb 28, 2023
@Muthuveerappanv Muthuveerappanv changed the title fix worspace package script fix: package script include worspace Feb 28, 2023
@dreamorosi dreamorosi changed the title fix: package script include worspace chore: add workspace flag to package script Feb 28, 2023
@github-actions github-actions bot added the internal PRs that introduce changes in governance, tech debt and chores (linting setup, baseline, etc.) label Feb 28, 2023
@github-actions github-actions bot added the bug Something isn't working label Feb 28, 2023
@dreamorosi dreamorosi removed the bug Something isn't working label Feb 28, 2023
@dreamorosi dreamorosi self-requested a review February 28, 2023 10:28
Copy link
Contributor

@dreamorosi dreamorosi left a comment

Choose a reason for hiding this comment

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

Running the command with the proposed change causes the command to fail:
image

This is due to one of the workspace packages not having the package command. The command wasn't there because of what mentioned in the second paragraph of this comment (TL;DR; this package command at there root level is not really used).

Please add a line like this to the docs/snippets/package.json file and try running the command again locally, then please attach a screenshot to PR body under the "How to verify this change" section.

@dreamorosi
Copy link
Contributor

Hi @Muthuveerappanv thank you for opening this PR.

I have left a couple of comments that need to be addressed before we can merge it.

Also, please review the comments I have left in the linked issue around contributing and note that I took the liberty to edit the PR description so that it aligns with the requirements/instructions that are written in the PR comments.

Copy link
Contributor

@dreamorosi dreamorosi left a comment

Choose a reason for hiding this comment

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

Thank you for the changes and for addressing my comments.

I'll merge this later today.

@dreamorosi dreamorosi merged commit 87b94e5 into aws-powertools:main Feb 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal PRs that introduce changes in governance, tech debt and chores (linting setup, baseline, etc.) size/XS PR between 0-9 LOC
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Maintenance: npm script package is incorrect
2 participants