Skip to content

Conversation

@aemous
Copy link
Contributor

@aemous aemous commented Nov 20, 2025

Description of changes:

  • Updated interactive and auto-fix mode to support multiple linting rules. The main technical complexity with supporting multiple rules is that as we apply fixes to the script, older linter findings become stale and would need to be
    'refreshed'. We avoid this problem by linting the script one-rule-at-a-time.
  • Updated Base64BinaryFormatRule so that it does not require file:// prefix in an argument value to trigger a detection. It now flags all AWS CLI commands.
  • Added PaginationRule that flags all AWS CLI commands, and adds --no-cli-paginate as a fix.
  • Replaced ScriptLinter class with utility functions. Updated their interface to let callers pass in their own AST.
  • Added save and exit mode.
  • Added tests for save-and-exit mode and the new PaginationRule.
  • Misc. refactoring for maintainability/readability.

Description of tests:

  • Ran and passed all tests.
  • Manually tested the tool in interactive and auto-fix mode on the example script, and verified correct behavior.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@aemous aemous changed the title Multiple linting rules testeiifcbncfctiknvurhjditvnhjuvkbrvenhvngirvjgi Multiple linting rules test Nov 20, 2025
@aemous aemous changed the title Multiple linting rules test Support multiple linting rules Nov 20, 2025
@codecov-commenter
Copy link

codecov-commenter commented Nov 20, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (upgrade-linting-tool@6ebbb50). Learn more about missing BASE report.

Additional details and impacted files
@@                   Coverage Diff                   @@
##             upgrade-linting-tool    #9859   +/-   ##
=======================================================
  Coverage                        ?   93.33%           
=======================================================
  Files                           ?      209           
  Lines                           ?    16807           
  Branches                        ?        0           
=======================================================
  Hits                            ?    15687           
  Misses                          ?     1120           
  Partials                        ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@aemous aemous marked this pull request as ready for review November 20, 2025 17:01
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