update_organization: Update an organization's properties in GitHub

Description Usage Arguments Details Value Examples

View source: R/organizations.R

Description

This function updates an organization's properties in GitHub. You can only update an organization if you have the appropriate permissions.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
update_organization(
  org,
  name,
  description,
  email,
  location,
  company,
  billing_email,
  has_organization_projects,
  has_repository_projects,
  default_repository_permission,
  members_can_create_repositories,
  ...
)

Arguments

org

(string) The login of the organization.

name

(string, optional) The shorthand name of the company.

description

(string, optional) The description of the company.

email

(string, optional) The publicly visible email address.

location

(string, optional) The location.

company

(string, optional) The company name.

billing_email

(string, optional) Billing email address. This address is not publicized.

has_organization_projects

(boolean, optional) Toggles whether an organization can use organization projects.

has_repository_projects

(boolean, optional) Toggles whether repositories that belong to the organization can use repository projects.

default_repository_permission

(string, optional) Default permission level members have for organization repositories:

  • "read": can pull, but not push to or administer this repository.

  • "write": can pull and push, but not administer this repository.

  • "admin": can pull, push, and administer this repository.

  • "none": no permissions granted by default.

Default: "read".

members_can_create_repositories

(boolean, optional) Toggles the ability of non-admin organization members to create repositories. Can be one of:

  • TRUE: all organization members can create repositories.

  • FALSE: only organization owners can create repositories.

Default: TRUE. Note: A parameter can override this parameter. See members_allowed_repository_creation_type for details.

...

Parameters passed to gh_request().

Details

For more details see the GitHub API documentation:

Value

update_organization() returns a list of the organization's properties.

Organization Properties:

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## Not run: 

  # Update some of your organization properties
  update_organization(
    org                             = "HairyCoos",
    description                     = "We are the Hairy Coos!",
    location                        = "The Highlands",
    default_repository_permission   = "write",
    members_can_create_repositories = FALSE
  )


## End(Not run)

ChadGoymer/githapi documentation built on Oct. 22, 2021, 10:56 a.m.