Skip to content

Set-BuildEnvironment Errors #37

Closed
Closed

Description

@midacts

I am changing to the root directory of the module i want to test and running
Set-BuildEnvironment.
I have tried with -Force as well.

Are these error expected,
Maybe I am doing something wrong.

Exception calling "Start" with "0" argument(s): "The system cannot find the file specified"
At C:\Program Files\Windows PowerShell\Modules\Modules\BuildHelpers\Public\Invoke-Git.ps1:96 char:5

  • $null = $p.Start()
    
  • ~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : NotSpecified: (:) [], MethodInvocationException
    • FullyQualifiedErrorId : Win32Exception

Exception calling "WaitForExit" with "0" argument(s): "No process is associated with this object."
At C:\Program Files\Windows PowerShell\Modules\Modules\BuildHelpers\Public\Invoke-Git.ps1:97 char:5

  • $p.WaitForExit()
    
  • ~~~~~~~~~~~~~~~~
    
    • CategoryInfo : NotSpecified: (:) [], MethodInvocationException
    • FullyQualifiedErrorId : InvalidOperationException

You cannot call a method on a null-valued expression.
At C:\Program Files\Windows PowerShell\Modules\Modules\BuildHelpers\Public\Invoke-Git.ps1:105 char:12

  •     if($stdout = $p.StandardOutput.ReadToEnd())
    
  •        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : InvalidOperation: (:) [], RuntimeException
    • FullyQualifiedErrorId : InvokeMethodOnNull

You cannot call a method on a null-valued expression.
At C:\Program Files\Windows PowerShell\Modules\Modules\BuildHelpers\Public\Invoke-Git.ps1:115 char:12

  •     if($stderr = $p.StandardError.ReadToEnd())
    
  •        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : InvalidOperation: (:) [], RuntimeException
    • FullyQualifiedErrorId : InvokeMethodOnNull

Exception calling "Start" with "0" argument(s): "The system cannot find the file specified"
At C:\Program Files\Windows PowerShell\Modules\Modules\BuildHelpers\Public\Invoke-Git.ps1:96 char:5

  • $null = $p.Start()
    
  • ~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : NotSpecified: (:) [], MethodInvocationException
    • FullyQualifiedErrorId : Win32Exception

Exception calling "WaitForExit" with "0" argument(s): "No process is associated with this object."
At C:\Program Files\Windows PowerShell\Modules\Modules\BuildHelpers\Public\Invoke-Git.ps1:97 char:5

  • $p.WaitForExit()
    
  • ~~~~~~~~~~~~~~~~
    
    • CategoryInfo : NotSpecified: (:) [], MethodInvocationException
    • FullyQualifiedErrorId : InvalidOperationException

You cannot call a method on a null-valued expression.
At C:\Program Files\Windows PowerShell\Modules\Modules\BuildHelpers\Public\Invoke-Git.ps1:105 char:12

  •     if($stdout = $p.StandardOutput.ReadToEnd())
    
  •        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : InvalidOperation: (:) [], RuntimeException
    • FullyQualifiedErrorId : InvokeMethodOnNull

You cannot call a method on a null-valued expression.
At C:\Program Files\Windows PowerShell\Modules\Modules\BuildHelpers\Public\Invoke-Git.ps1:115 char:12

  •     if($stderr = $p.StandardError.ReadToEnd())
    
  •        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : InvalidOperation: (:) [], RuntimeException
    • FullyQualifiedErrorId : InvokeMethodOnNull

Activity

  1. RamblingCookieMonster commented on Aug 9, 2017

    @RamblingCookieMonster
    Collaborator

    Hiyo!

    Looks like I need to adjust things to accommodate environments that don't have git - I suspect if you install git and have it in your $env:path, you'll be good.

    Cheers!

  2. midacts commented on Aug 9, 2017

    @midacts
    Author
  3. RamblingCookieMonster commented on Aug 10, 2017

    @RamblingCookieMonster
    Collaborator

    Hiyo!

    Alrighty - the latest build on powershellgallery or master branch here will have a change that lets you do something like:

    Set-BuildEnvironment -GitPath "C:\path\to\git.exe"

    Hopefully that helps - cheers!

  4. midacts commented on Aug 10, 2017

    @midacts
    Author

    I tried it out this morning and that worked.
    Thanks for taking a look at this and releasing a fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions