Skip to content

chore: rewrite readmes correctly in aws-cdk-lib and monocdk (backport #17573)#17635

Merged
mergify[bot] merged 2 commits intomasterfrom
mergify/bp/master/pr-17573
Nov 22, 2021
Merged

chore: rewrite readmes correctly in aws-cdk-lib and monocdk (backport #17573)#17635
mergify[bot] merged 2 commits intomasterfrom
mergify/bp/master/pr-17573

Conversation

@mergify
Copy link
Copy Markdown
Contributor

@mergify mergify bot commented Nov 22, 2021

This is an automatic backport of pull request #17573 done by Mergify.
Cherry-pick of 66e37cc has failed:

On branch mergify/bp/master/pr-17573
Your branch is up to date with 'origin/master'.

You are currently cherry-picking commit 66e37cc20.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   packages/@aws-cdk/cfnspec/test/libary-creation.test.ts
	modified:   packages/aws-cdk-lib/.gitignore
	modified:   packages/aws-cdk-lib/package.json
	modified:   packages/aws-cdk-lib/scripts/verify-imports-resolve-same.ts
	deleted:    packages/aws-cdk-lib/scripts/verify-readme-import-rewrites.ts
	modified:   packages/aws-cdk-migration/bin/rewrite-imports-v2.ts
	modified:   packages/aws-cdk-migration/lib/rewrite.ts
	modified:   packages/aws-cdk-migration/test/rewrite.test.ts
	modified:   packages/monocdk/.gitignore
	modified:   tools/@aws-cdk/cdk-build-tools/bin/cdk-build.ts
	modified:   tools/@aws-cdk/individual-pkg-gen/transform-packages.ts
	modified:   tools/@aws-cdk/ubergen/bin/ubergen.ts
	modified:   tools/@aws-cdk/ubergen/package.json

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   packages/@aws-cdk/cfnspec/lib/library-creation.ts

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/github/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally


Mergify commands and options

More conditions and actions can be found in the documentation.

You can also trigger Mergify actions by commenting on this pull request:

  • @Mergifyio refresh will re-evaluate the rules
  • @Mergifyio rebase will rebase this PR on its base branch
  • @Mergifyio update will merge the base branch into this PR
  • @Mergifyio backport <destination> will backport this PR on <destination> branch

Additionally, on Mergify dashboard you can:

  • look at your merge queues
  • generate the Mergify configuration with the config editor.

Finally, you can contact us on https://mergify.com

- Adds `rewriteImports` and helper functions `rewriteReadmeImports` and `rewriteMonoPackageImports` to `aws-cdk-migration` package.
- `individual-package-gen` consumes `rewriteReadmeImports` for alpha modules.
- `individual-package-gen` treats rosetta fixtures as source files and rewrites imports there as well.
- Adds `aws-cdk-migration` as a dependency to `ubergen`.
- Refactors `rewriteImports` in `ubergen` to use the API in `aws-cdk-migration`. Has the side affect of removing the string-replace function that was introduced in this [PR](#14255). This changes the readme import style from `import { blah as blah } from 'aws-cdk-lib';` to `import * as blah from 'aws-cdk-lib/blah';`.
- fixes error in `cfnspec` that generated invalid import names for L1 module readmes.
- fixes bug in `cdk-build` that only executed one `post` command.
- fixes `verify-imports` scripts typo introduced previously (that was not caught due to the `cdk-build` bug).

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*

(cherry picked from commit 66e37cc)

# Conflicts:
#	packages/@aws-cdk/cfnspec/lib/library-creation.ts
@gitpod-io
Copy link
Copy Markdown

gitpod-io bot commented Nov 22, 2021

@github-actions github-actions bot added the aws-cdk-lib Related to the aws-cdk-lib package label Nov 22, 2021
@kaizencc kaizencc requested a review from rix0rrr November 22, 2021 21:36
kaizencc
kaizencc previously approved these changes Nov 22, 2021
@mergify mergify bot dismissed kaizencc’s stale review November 22, 2021 21:37

Pull request has been modified.

@kaizencc kaizencc self-assigned this Nov 22, 2021
@aws-cdk-automation
Copy link
Copy Markdown
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject89A8053A-LhjRyN9kxr8o
  • Commit ID: d8bbc85
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify mergify bot merged commit b9b0b05 into master Nov 22, 2021
@mergify mergify bot deleted the mergify/bp/master/pr-17573 branch November 22, 2021 22:20
@mergify
Copy link
Copy Markdown
Contributor Author

mergify bot commented Nov 22, 2021

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

TikiTDO pushed a commit to TikiTDO/aws-cdk that referenced this pull request Feb 21, 2022
…ws#17573) (aws#17635)

This is an automatic backport of pull request aws#17573 done by [Mergify](https://mergify.com).
Cherry-pick of 66e37cc has failed:
```
On branch mergify/bp/master/pr-17573
Your branch is up to date with 'origin/master'.

You are currently cherry-picking commit 66e37cc.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   packages/@aws-cdk/cfnspec/test/libary-creation.test.ts
	modified:   packages/aws-cdk-lib/.gitignore
	modified:   packages/aws-cdk-lib/package.json
	modified:   packages/aws-cdk-lib/scripts/verify-imports-resolve-same.ts
	deleted:    packages/aws-cdk-lib/scripts/verify-readme-import-rewrites.ts
	modified:   packages/aws-cdk-migration/bin/rewrite-imports-v2.ts
	modified:   packages/aws-cdk-migration/lib/rewrite.ts
	modified:   packages/aws-cdk-migration/test/rewrite.test.ts
	modified:   packages/monocdk/.gitignore
	modified:   tools/@aws-cdk/cdk-build-tools/bin/cdk-build.ts
	modified:   tools/@aws-cdk/individual-pkg-gen/transform-packages.ts
	modified:   tools/@aws-cdk/ubergen/bin/ubergen.ts
	modified:   tools/@aws-cdk/ubergen/package.json

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   packages/@aws-cdk/cfnspec/lib/library-creation.ts

```


To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/github/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

---


<details>
<summary>Mergify commands and options</summary>

<br />

More conditions and actions can be found in the [documentation](https://docs.mergify.com/).

You can also trigger Mergify actions by commenting on this pull request:

- `@Mergifyio refresh` will re-evaluate the rules
- `@Mergifyio rebase` will rebase this PR on its base branch
- `@Mergifyio update` will merge the base branch into this PR
- `@Mergifyio backport <destination>` will backport this PR on `<destination>` branch

Additionally, on Mergify [dashboard](https://dashboard.mergify.com/) you can:

- look at your merge queues
- generate the Mergify configuration with the config editor.

Finally, you can contact us on https://mergify.com
</details>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

aws-cdk-lib Related to the aws-cdk-lib package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants