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

Error with Add-Member in Get-GitStatus on PowerShell Core beta.9 on Windows 10 #500

Closed
rkeithhill opened this issue Oct 30, 2017 · 0 comments
Assignees
Milestone

Comments

@rkeithhill
Copy link
Collaborator

System Details

  • posh-git version/path: 0.7.1 ~\Documents\PowerShell\Modules\posh-git\0.7.1
  • PowerShell version: 6.0.0-beta.9
  • Git version: 2.14.2.windows.2
  • Operating system name and version: Windows 10 FCU (1709)

Issue Description

I am experiencing a problem with...
Executing Get-GitStatus is emitting a non-terminating error:

C:\Users\Keith\GitHub\rkeithhill\PowerShell [master ↓44 +1 ~0 -0 !]> Get-GitStatus
Add-Member : Cannot add a member with the name "Added" because a member with that name already exists. To overwrite
the member anyway, add the Force parameter to your command.
At C:\Users\Keith\Documents\PowerShell\Modules\posh-git\0.7.1\GitUtils.ps1:298 char:13
+             Add-Member -PassThru NoteProperty Added    $indexAdded.To ...
+             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:PSObject) [Add-Member], InvalidOperationException
    + FullyQualifiedErrorId : MemberAlreadyExists,Microsoft.PowerShell.Commands.AddMemberCommand
rkeithhill added a commit that referenced this issue Dec 31, 2017
This adds the -Force paramteter as recommended by the error message.
@rkeithhill rkeithhill added this to the v0.7.2 milestone Dec 31, 2017
@rkeithhill rkeithhill self-assigned this Dec 31, 2017
@dahlbyk dahlbyk closed this as completed in 364aa25 Jan 1, 2018
dahlbyk added a commit that referenced this issue Jan 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant