Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default branch name for new repositories #282

Open
FernandoMiguel opened this issue Jan 28, 2021 · 7 comments
Open

Default branch name for new repositories #282

FernandoMiguel opened this issue Jan 28, 2021 · 7 comments

Comments

@FernandoMiguel
Copy link

Community Note

  • Please vote on this issue by adding a 馃憤 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Description

resource to "Default branch name for new repositories" and choose the branch name ("main" or other)

@xuzhang3
Copy link
Collaborator

xuzhang3 commented Feb 1, 2021

Hi @FernandoMiguel azuredevops_git_repository support set the default_branch

resource "azuredevops_git_repository" "repo" {
  project_id = data.azuredevops_project.project.id
  name = "my repo"
  default_branch = "refs/heads/master"
  initialization {
    init_type = "Clean"
  }
}

@FernandoMiguel
Copy link
Author

Then the docs need to be updated

@FernandoMiguel
Copy link
Author

this PR is about a different resource than azuredevops_git_repository

it's about this
image

this is in the project settings

@xuzhang3
Copy link
Collaborator

xuzhang3 commented Feb 3, 2021

@FernandoMigue This API is not a public API, we can not add this resource to ADO based on the current azuredevops-go-SDK

@FernandoMiguel
Copy link
Author

@FernandoMigue This API is not a public API, we can not add this resource to ADO based on the current azuredevops-go-SDK

I understand. Thank you.

@FernandoMiguel
Copy link
Author

Created a feature request with azuredevops-go-SDK
microsoft/azure-devops-go-api#96

@richardgavel
Copy link

@xuzhang3 Even for setting the default branch of a azure_devops_git_repository, if the default_branch CAN be set, the docs are still off. They only reference default_branch as an exported attribute, not as a settable argument.

https://registry.terraform.io/providers/microsoft/azuredevops/latest/docs/resources/git_repository

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants