az repos

Manage Azure DevOps repos. Part of azure-cli (also known as az). More information: https://learn.microsoft.com/cli/azure/repos.

az repos list --project {{project_name}}

az repos policy merge-strategy create --repository-id {{repository_id_in_repos_list}} --branch {{branch_name}} --blocking --enabled --allow-no-fast-forward false --allow-rebase true --allow-rebase-merge true --allow-squash true

az repos policy build create --repository-id {{repository_id}} --build-definition-id {{build_pipeline_id}} --branch main --blocking --enabled --queue-on-source-update-only true --display-name {{name}} --valid-duration {{minutes}}

az repos pr list --project {{project_name}} --repository {{repository_name}} --status active