Skip to content
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

fix(aws-codecommit): make the CodePipeline Action CloudWatch Event re… #1320

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
],
"detail": {
"event": [
"referenceCreated",
"referenceUpdated"
],
"referenceName": [
Expand Down Expand Up @@ -386,4 +387,4 @@
}
}
}
}
}
6 changes: 3 additions & 3 deletions packages/@aws-cdk/aws-codecommit/lib/repository.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ export abstract class RepositoryRef extends cdk.Construct {

/**
* Defines a CloudWatch event rule which triggers when a reference is
* created (i.e. a new brach/tag is created) to the repository.
* created (i.e. a new branch/tag is created) to the repository.
*/
public onReferenceCreated(name: string, target?: events.IEventRuleTarget, options?: events.EventRuleProps) {
const rule = this.onStateChange(name, target, options);
Expand All @@ -114,11 +114,11 @@ export abstract class RepositoryRef extends cdk.Construct {

/**
* Defines a CloudWatch event rule which triggers when a reference is
* updated (i.e. a commit is pushed to an existig branch) from the repository.
* updated (i.e. a commit is pushed to an existing or new branch) from the repository.
*/
public onReferenceUpdated(name: string, target?: events.IEventRuleTarget, options?: events.EventRuleProps) {
const rule = this.onStateChange(name, target, options);
rule.addEventPattern({ detail: { event: [ 'referenceUpdated' ] } });
rule.addEventPattern({ detail: { event: [ 'referenceCreated', 'referenceUpdated' ] } });
return rule;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
],
"detail": {
"event": [
"referenceCreated",
"referenceUpdated"
],
"referenceName": [
Expand Down Expand Up @@ -599,4 +600,4 @@
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
],
"detail": {
"event": [
"referenceCreated",
"referenceUpdated"
],
"referenceName": [
Expand Down Expand Up @@ -289,4 +290,4 @@
}
}
}
}
}