Thanks for selecting Azure Cli Code-gen as approach to onboarding Azure Cli for your RP. If you want add a new feature to existing PR or onboard a new RP, then this document will provide the guideline for your on-boarding process.
AME team use github issue as a centralized entry point to trigger the process for new RP onboarding or add feature in existing RP. Please go to Azure-Cli to create a new github issue and following the onboarding template first. With the selection result in template, a contact person will be assigned to provide help during the whole process. if you select Azure cli Code-gen as the approach, you will be re-direct back to this document later.
** we are improving the process here with Azure CLI team soon
If it is your first time to use Azure Cli code-gen, please prepare initial readme files for your RP Preparing Readme. Then, discuss with the contact person. He/She will:
- Do a quick validation on your swagger.
- Follow up with you for any questions and support needed during the service onboarding.
- There are 3 ways to generate code now, you can pick the one you prefer. Details can be found at Generating Guide
- Try the generated command to see whether it meets your need. Further customization is supported if needed. Detail can be found at FAQ.
- Test will also be generated based on the examples in swagger. Run these tests and make sure all of them can pass. (Refer to here for how to run test). Customization is also supported for test if needed. Detail can be found at here
- Add more test if the generated test is not enough. Detail can be found at here
- Run linter and style check for the code generated and make sure all of them can pass. (Refer to here for how to run linter and style check)
- After you have made sure
azdev test --live --discover <extension-name>
run successfully, you can see there're test recordings (*.yaml files) in your az-output-folder. You need to submit those test recordings as they are needed in CI tests. - Add the codeowner for your CLI extension here https://github.com/Azure/azure-cli-extensions/blob/master/.github/CODEOWNERS
- Discusses with your contact person to ask for code review of the Az Cli code.
- Follow azure-cli guide to onboard to azure-cli
** we are improving the process here with Azure CLI team soon