File tree Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change 1+ from __future__ import annotations
2+
13import argparse
4+ from typing import Sequence
5+
26import hcl2
37# from typing import Any
4- from typing import Sequence
58
69
710def main (argv : Sequence [str ] | None = None ) -> int :
@@ -11,7 +14,7 @@ def main(argv: Sequence[str] | None = None) -> int:
1114
1215 retval = 0
1316 for filename in args .filenames :
14- if filename == " iam.tf" :
17+ if filename == ' iam.tf' :
1518 continue
1619 with open (filename , 'rb' ) as f :
1720 try :
@@ -23,14 +26,14 @@ def main(argv: Sequence[str] | None = None) -> int:
2326 if resources :
2427 for item in resources :
2528 for keys in item :
26- if key .startswith (" aws_iam" ):
29+ if key .startswith (' aws_iam' ):
2730 print (f'{ filename } : Has { key } resource' )
2831 retval = 1
2932 resources = data .get ('data' )
3033 if resources :
3134 for item in resources :
3235 for keys in item :
33- if key .startswith (" aws_iam" ):
36+ if key .startswith (' aws_iam' ):
3437 print (f'{ filename } : Has { key } data resource' )
3538 retval = 1
3639 return retval
Original file line number Diff line number Diff line change @@ -19,8 +19,8 @@ classifiers =
1919[options]
2020packages = find:
2121install_requires =
22- ruamel.yaml>=0.15
2322 python-hcl2>=4.3.0
23+ ruamel.yaml>=0.15
2424 tomli>=1.1.0; python_version<"3.11"
2525python_requires = >=3.7
2626
You can’t perform that action at this time.
0 commit comments