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

Only send yaml files to the formatter #231

Merged
merged 1 commit into from
Sep 7, 2022

Conversation

kddejong
Copy link
Contributor

@kddejong kddejong commented Sep 6, 2022

Issue #, if available:
#68

Description of changes:

  • Update the formatter to only process *.yaml or *.yml files

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

@kddejong kddejong merged commit 5be3d9d into aws-cloudformation:master Sep 7, 2022
@kddejong kddejong deleted the fix/issue/68 branch September 7, 2022 00:15
if (/\n?"?Resources"?\s*:/.exec(template)) {
if (/"?Type"?\s*:\s*"?'?[a-zA-Z0-9]{2,64}::[a-zA-Z0-9]{2,64}/.exec(template)) {
// filter out serverless.io templates
if (!(/\nresources:/.exec(template) && /\nprovider:/.exec(template))) {

Choose a reason for hiding this comment

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

I had a small issue that I had commented out the resources section and cfn-lint determined that it's a cloudformation file, perhaps would be better to check functions: & provider:?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants