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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Org Option to issue_label #2052

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

ikegentz
Copy link

@ikegentz ikegentz commented Dec 9, 2023

Resolves #1840


Before the change?

  • There was no way with the github_issue_label resource to specify an Organization in which the repo you wanted to create the label for, lived

After the change?

  • This adds an org attribute to the github_issue_label resource that lets the end-user explicitly specify where the repo lives they want to add the label to

Pull request checklist

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been reviewed and added / updated if needed (for bug fixes / features)

NOTE: I updated the docs in website/docs/r/, because they matched what I see on the resource's documentation page but do I need to update something in website/docs/d/? What is that directory for?

Does this introduce a breaking change?

Nothing I'm aware of!

  • Yes
  • No

@ikegentz ikegentz changed the title Ikegentz/1840 Add Org Option to issue_label Dec 9, 2023
Copy link
Member

@kfcampbell kfcampbell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution! I'm a little torn as to whether we want to standardize on owner instead of org here. I think it would be better to be consistent with the keywords we use at the provider level...what do you think?

@nickfloyd nickfloyd added the Status: Blocked Some technical or requirement is blocking the issue label Aug 6, 2024
@ikegentz
Copy link
Author

Thanks for the contribution! I'm a little torn as to whether we want to standardize on owner instead of org here. I think it would be better to be consistent with the keywords we use at the provider level...what do you think?

Wow I totally forgot about this PR, sorry for the delay!

Hm, IMO the current version of the provider is confusing because an owner of a repo doesn't have to be an organization, it could be an individual too.

So on https://registry.terraform.io/providers/integrations/github/latest/docs#authentication, we have this example:

provider "github" {
  owner = var.github_organization
  app_auth {
    id              = var.app_id              # or `GITHUB_APP_ID`
    installation_id = var.app_installation_id # or `GITHUB_APP_INSTALLATION_ID`
    pem_file        = var.app_pem_file        # or `GITHUB_APP_PEM_FILE`
  }
}

specifically, owner = var.github_organization. IMO, this is currently confusing, so I suppose I like how I've got it here in this PR.

That said, perhaps there are some other implications to doing this I am not considering outside of the current context of this PR. Look forward to your thoughts on this @kfcampbell

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Blocked Some technical or requirement is blocking the issue
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[MAINT]: issue_label doesn't work for Organizations
3 participants