News for hackers. Stuff that matters.
Re:A New Chat Bot Is a ‘Code Red’ for Google’s Search Business by scarface74 on Saturday December 24, 2022 @12:26AM (#34114257)
I had a JSON file with the following format:

[{“Key”:”Company”},{“Value”:”${company}”},…]

I asked it to write a Python script that replaces any word surrounded by ${} with the value in its corresponding environment variable and accept the path of the file as a command line argument —json-file using argparse. It worked perfectly.

Then I started asking it to write a script to successively do the following

Given the same json file, write a snippet of YML that looks like sample CF templates parameter section that I gave it.

https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGui...

It worked perfectly.

Then I told it to accept an optional argument that generated the corresponding meta data section. It worked flawlessly. I gave it sample expected output

https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGui...

Then I told it to output the format needed to pass those parameters to a nested stack and gave it an example;

Parameters: Company: !Ref company

…

It worked again.

Finally, I needed it to generate the Python code to generate the CodeBuild Environment section and I gave it an example.

https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGui...

There are no comments on this comment yet.