Add-GitHubVariableSelectedRepository¶
SYNOPSIS¶
Add selected repository to an organization variable.
SYNTAX¶
__AllParameterSets¶
Add-GitHubVariableSelectedRepository [-Owner] <string> [-Name] <string> [-RepositoryID] <ulong>
 [[-Context] <Object>] [<CommonParameters>]
ALIASES¶
This cmdlet has the following aliases, {{Insert list of aliases}}
DESCRIPTION¶
Adds a repository to an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to 'selected'. Authenticated users must have collaborator access to the repository to create, update, or read secrets. OAuth and classic personal access tokens require the 'admin:org' scope. For private repositories, the 'repo' scope is also required. Fine-grained tokens must have 'Variables' organization permission (write) and 'Metadata' repository permission (read).
EXAMPLES¶
EXAMPLE 1¶
Add-GitHubVariableSelectedRepository -Owner 'my-org' -Name 'API_KEY' -RepositoryID '654321'
Adds the repository 'test-repo' to the 'API_KEY' variable in the organization 'my-org'.
PARAMETERS¶
-Context¶
The context to run the command in. Used to get the details for the API call. Can be either a string or a GitHubContext object.
Type: System.Object
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 3
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-Name¶
The name of the variable.
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 1
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-Owner¶
The account owner of the repository. The name is not case sensitive.
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 0
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-RepositoryID¶
The ID of the repository to add to the variable.
Type: System.UInt64
DefaultValue: 0
SupportsWildcards: false
Aliases:
- DatabaseID
- ID
ParameterSets:
- Name: (All)
  Position: 2
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: true
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
CommonParameters¶
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
INPUTS¶
System.UInt64¶
{{ Fill in the Description }}
OUTPUTS¶
System.Void¶
{{ Fill in the Description }}
NOTES¶
Add selected repository to an organization variable