Skip to content

Rename GitHubTeam

Howard Wolosky edited this page Oct 5, 2020 · 1 revision

Rename-GitHubTeam

SYNOPSIS

Renames a team within an organization on GitHub.

SYNTAX

TeamSlug (Default)

Rename-GitHubTeam [-OrganizationName] <String> -TeamSlug <String> [-NewTeamName] <String> [-PassThru]
 [-AccessToken <String>] [<CommonParameters>]

TeamName

Rename-GitHubTeam [-OrganizationName] <String> [-TeamName] <String> [-NewTeamName] <String> [-PassThru]
 [-AccessToken <String>] [<CommonParameters>]

DESCRIPTION

Renames a team within an organization on GitHub.

The Git repo for this module can be found here: http://aka.ms/PowerShellForGitHub

EXAMPLES

EXAMPLE 1

Rename-GitHubTeam -OrganizationName PowerShell -TeamName Developers -NewTeamName DeveloperTeam

Renames the 'Developers' GitHub team in the 'PowerShell' organization to be 'DeveloperTeam'.

EXAMPLE 2

$team = Get-GitHubTeam -OrganizationName PowerShell -TeamName Developers
$team | Rename-GitHubTeam -NewTeamName 'DeveloperTeam'

You can also pipe in a GitHub team that was returned from a previous command.

PARAMETERS

-AccessToken

If provided, this will be used as the AccessToken for authentication with the REST Api. Otherwise, will attempt to use the configured value or will run unauthenticated.

Type: System.String
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-NewTeamName

The new name for the team.

Type: System.String
Parameter Sets: (All)
Aliases:

Required: True
Position: 4
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-OrganizationName

The name of the team's organization.

Type: System.String
Parameter Sets: (All)
Aliases:

Required: True
Position: 2
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-PassThru

Returns the updated GitHub Team. By default, this cmdlet does not generate any output. You can use "Set-GitHubConfiguration -DefaultPassThru" to control the default behavior of this switch.

Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-TeamName

The existing name of the team.

Type: System.String
Parameter Sets: TeamName
Aliases:

Required: True
Position: 3
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-TeamSlug

The slug (a unique key based on the team name) of the team to update.

Type: System.String
Parameter Sets: TeamSlug
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

GitHub.Organization

GitHub.Team

OUTPUTS

GitHub.Team

NOTES

This is a helper/wrapper for Set-GitHubTeam which can also rename a GitHub Team.

RELATED LINKS

PowerShellForGitHub

Docs

PowerShellForGitHub

Functions

Clone this wiki locally