-
Notifications
You must be signed in to change notification settings - Fork 1
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 additional commands #6
base: main
Are you sure you want to change the base?
Conversation
|
||
if ($LASTEXITCODE -ne 0) # cSpell: ignore LASTEXITCODE | ||
{ | ||
if($PSBoundParameters.ContainsKey('BranchName')) |
Check warning
Code scanning / PSScriptAnalyzer
If a keyword is followed by a parenthesis, there should be single space between the keyword and the parenthesis. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#one-newline-after-opening-brace Warning
|
||
if ($LASTEXITCODE -ne 0) # cSpell: ignore LASTEXITCODE | ||
{ | ||
if($PSBoundParameters.ContainsKey('BranchName')) |
Check warning
Code scanning / PSScriptAnalyzer
Use space before open parenthesis. Warning
#> | ||
$remoteExists = Test-GitRemote -Name $Name | ||
|
||
if (-not $remoteExists) |
Check warning
Code scanning / PSScriptAnalyzer
Opening brace on if-statements should only be followed by one new line. See https://github.com/PowerShell/DscResources/blob/master/StyleGuidelines.md#one-newline-after-opening-brace Warning
} | ||
|
||
$switchedToDefaultBranch = $true | ||
Write-Error -ErrorRecord $_ -ErrorAction 'Stop' |
Check warning
Code scanning / PSScriptAnalyzer
Write-Error is used to create a terminating error. throw or $pscmdlet.ThrowTerminatingError should be used. Warning
) | ||
) | ||
} | ||
Write-Error -ErrorRecord $_ -ErrorAction 'Stop' |
Check warning
Code scanning / PSScriptAnalyzer
Write-Error is used to create a terminating error. throw or $pscmdlet.ThrowTerminatingError should be used. Warning
$errorMessage = $script:localizedData.New_SamplerGitHubReleaseTag_FailedGetTagsOrMissingTagsInLocalRepository | ||
$errorCode = 'NSGRT0008' # cspell: disable-line | ||
} | ||
Write-Error @errorMessageParameters -ErrorAction 'Stop' |
Check warning
Code scanning / PSScriptAnalyzer
Write-Error is used to create a terminating error. throw or $pscmdlet.ThrowTerminatingError should be used. Warning
} | ||
|
||
Write-Error @errorMessageParameters -ErrorAction 'Stop' |
Check warning
Code scanning / PSScriptAnalyzer
Write-Error is used to create a terminating error. throw or $pscmdlet.ThrowTerminatingError should be used. Warning
$DatabaseName | ||
) | ||
) | ||
Write-Error -ErrorRecord $_ -ErrorAction 'Stop' |
Check warning
Code scanning / PSScriptAnalyzer
Write-Error is used to create a terminating error. throw or $pscmdlet.ThrowTerminatingError should be used. Warning
Switch-GitLocalBranch -BranchName $currentLocalBranchName -Verbose:$VerbosePreference -ErrorAction 'Stop' | ||
} | ||
|
||
Write-Error -ErrorRecord $_ -ErrorAction 'Stop' |
Check warning
Code scanning / PSScriptAnalyzer
Write-Error is used to create a terminating error. throw or $pscmdlet.ThrowTerminatingError should be used. Warning
This function returns a Boolean value indicating whether the branch exists in | ||
the remote repository. | ||
#> | ||
function Test-GitRemoteBranch |
Check warning
Code scanning / PSScriptAnalyzer
Example 1 in function Test-GitRemoteBranch uses invalid parameter BranchName. Warning
Labeling this pull request (PR) as abandoned since it has gone 14 days or more since the last update. An abandoned PR can be continued by another contributor. The abandoned label will be removed if work on this PR is taken up again. |
Pull Request (PR) description
This Pull Request (PR) fixes the following issues
Receive-GitBranch
: New command proposal #5Task list
file CHANGELOG.md. Entry should say what was changed and how that
affects users (if applicable), and reference the issue being resolved
(if applicable).
DSC Community Testing Guidelines.
This change is