-
Notifications
You must be signed in to change notification settings - Fork 0
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
feat!: refactor API for simpler usage (v1.x) #11
Changes from all commits
359494c
764510a
6550a97
14bd8bd
0c2813f
d067500
02ef695
0e6d0f1
2a1f799
bdb7d2f
7f34479
d9d1618
8de02de
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,15 @@ | ||
import { ProjenStruct, Struct } from "@mrgrain/jsii-struct-builder"; | ||
import { ReleasableCommits, awscdk } from "projen"; | ||
import { ProseWrap } from "projen/lib/javascript"; | ||
|
||
const project = new awscdk.AwsCdkConstructLibrary({ | ||
author: "Ben Limmer", | ||
authorAddress: "[email protected]", | ||
cdkVersion: "2.1.0", | ||
cdkVersion: "2.73.0", // Released in April 2023 | ||
defaultReleaseBranch: "main", | ||
name: "@blimmer/cdk-circleci-oidc", | ||
repositoryUrl: "https://github.com/blimmer/cdk-circleci-oidc.git", | ||
majorVersion: 1, | ||
|
||
projenrcTs: true, | ||
|
||
|
@@ -19,20 +21,25 @@ const project = new awscdk.AwsCdkConstructLibrary({ | |
module: "cdk_circleci_oidc", | ||
}, | ||
|
||
// deps: [], | ||
devDeps: ["@mrgrain/jsii-struct-builder"], | ||
depsUpgrade: false, | ||
|
||
eslintOptions: { | ||
dirs: ["src"], | ||
ignorePatterns: ["src/generated/*.ts"], // ignore generated files | ||
}, | ||
prettier: true, | ||
prettierOptions: { | ||
settings: { | ||
printWidth: 120, | ||
proseWrap: ProseWrap.ALWAYS, | ||
}, | ||
}, | ||
|
||
// deps: [], /* Runtime dependencies of this module. */ | ||
// description: undefined, /* The description is just a string that helps people understand the purpose of the package. */ | ||
// devDeps: [], /* Build dependencies for this module. */ | ||
// packageName: undefined, /* The "name" in package.json. */ | ||
}); | ||
|
||
new ProjenStruct(project, { name: "RoleProps", filePath: "src/generated/IamRoleProps.ts" }).mixin( | ||
Struct.fromFqn("aws-cdk-lib.aws_iam.RoleProps").omit("assumedBy").withoutDeprecated(), | ||
); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. JSII can't handle statements like: type MyRoleProps = Omit<RoleProps, 'assumedBy'>; So I'm using jsii-struct-builder to accomplish the same thing. |
||
|
||
project.synth(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since I'm using
jsii-struct-builder
toextend RoleProps
, I'm bumping to a more modern minimum CDK version. This was released one year ago, so it feels reasonable to ask people to be on at least this version when upgrading.