rehanvdm/cdk-express-pipeline-github-diff
Outputs the CDK Express Pipeline diff on a GitHub PR
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
Inputs
| name | description | required | default |
|---|---|---|---|
| mode | The mode to run the action in. Options are: - `generate`: Generates, saves the diff of the CDK Express Pipeline to file and caches it. - `print`: Reads all the generated diffs from cache and updates the PR description with the diff. | yes | — |
| diff-name | The name of the CDK Cloud Assembly. Used to differentiate between multiple assemblies when printing diffs. This is the h2 header in the PR diff description. Required for `mode: print` Defaults to 'CDK Diff' | no | — |
| cloud-assembly-directory | The directory containing the CDK Cloud Assembly. Required for: - `mode: generate` - `mode: print` or alternatively use the `cloud-assembly-directories` property. Defaults to 'cdk.out' if `cloud-assembly-directories` is not specified in `mode: print`. | no | — |
| cloud-assemblies | An array of of objects indicating the CDK Cloud Assembly directories and the header to use when printing them. Can be specified instead of `cloud-assembly-directory` in mode `mode: print` when you want to diff multiple assemblies or change the default header. Format: ```yaml cloud-assemblies: | - header: CDK Diff Development directory: cdk.out/dev - header: CDK Diff Production directory: cdk.out/prod ``` | no | — |
| stack-selectors | The stack selectors to use for the CDK diff. Multiple selectors can be provided as a comma-separated list. Required for `mode: generate` Defaults to '**' (all stacks). | no | — |
| github-token | GitHub token for API access to read PR action/job info, update the PR description and read & write to the cache | yes | — |
| job-name | The name property of the job, to correctly link to the action/job logs when generating the summaries. Optional for `mode: generate` | no | — |
| diff-rules | An array of objects indicating rules to apply to the diff output on the PR description. Optional for `mode: generate`. Format: ```yaml diff-rules: | - name: hide-all-sns-resources type: HIDE_RESOURCE path: AWS::SNS::Topic.* - name: hide-all-sns-property-changes type: HIDE_PROPERTIES path: AWS::SNS::Topic.* ``` Properties: - `name`: The name of the rule shown next to the hidden resource/properties in the diff. - `type`: The type of rule. Options are: - `HIDE_RESOURCE`: Hides the entire resource diff if any property changes match the path - `HIDE_PROPERTIES`: Hides only the property changes that match the path, but shows the resource and other property changes - `HIDE_RESOURCE_IF_EMPTY`: Does not hide any properties itself. After all other rules have run, if the matched resource has no visible children remaining, hides the resource header too. Combine with `HIDE_PROPERTIES` rules to suppress both the properties and the now-empty resource header. - `path`: A glob pattern to match on the path with format: "ResourceName.ResourceId.Property.NestedProperty.NestedProperty...." If a ResourceId has / in its name, it will be replaced with _ to avoid issues with glob matching | no | — |
| display-timezones | A YAML array of IANA timezone names to display alongside the UTC time in the "Generated At" timestamp. Optional for `mode: generate` and `mode: print`. Format: ```yaml display-timezones: | - America/New_York - Europe/Paris - Asia/Tokyo ``` The time will be shown compactly as: `YYYY-MM-DD HH:MM:SS (UTC) | HH:MM:SS (TZ) | ...` If a timezone falls on a different calendar date than UTC, a relative day offset is appended: `HH:MM:SS (+1d) (TZ)` or `HH:MM:SS (-1d) (TZ)` | no | — |
| expand-diff | Whether to auto-expand the `<details>` section in the PR description. Optional for `mode: print`. Defaults to 'true'. | no | — |
Outputs
no outputs