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

init.ps1 fails if the repo is stored in a path that has spaces in the name #1244

Closed
JesseTG opened this issue May 20, 2021 · 0 comments · Fixed by #1254
Closed

init.ps1 fails if the repo is stored in a path that has spaces in the name #1244

JesseTG opened this issue May 20, 2021 · 0 comments · Fixed by #1254
Assignees

Comments

@JesseTG
Copy link
Contributor

JesseTG commented May 20, 2021

Bug description

If you store this git repo in a path that contains a space, running init.ps1 will fail with a series of error messages.

Repro steps

Clone this repository into a directory with a space in the name and run init.ps1.

Expected behavior

init.ps1 runs without errors.

Actual behavior

This:

PS C:\Users\Jesse\Unshared Code\MessagePack-CSharp> ./init -WhatIf
The netcore Credential Provider is already in C:\Users\Jesse\.nuget\plugins
Installing .NET Core SDK and runtimes to C:\Users\Jesse\.dotnet
What if: Performing the operation "Install" on target ".NET Core SDK 3.1.301".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools/dotnet-inst ...
+ ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install" on target ".NET Core runtime 2.1".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools/dotnet-inst ...
+ ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install" on target ".NET Core runtime 3.1".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools/dotnet-inst ...
+ ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install" on target ".NET Core runtime 3.0".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools/dotnet-inst ...
+ ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install" on target ".NET Core runtime 3.1".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools/dotnet-inst ...
+ ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install" on target ".NET Core runtime 2.1".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install" on target ".NET Core runtime 3.1".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools/dotnet-inst ...
+ ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install" on target ".NET Core runtime 2.2".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools/dotnet-inst ...
+ ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install" on target ".NET Core runtime 2.1".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools/dotnet-inst ...
+ ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install" on target ".NET Core runtime 3.1".
C:\Users\Jesse\Unshared : The term 'C:\Users\Jesse\Unshared' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools/dotnet-inst ...
+ ~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\Users\Jesse\Unshared:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

What if: Performing the operation "Install-DotNetSdk.ps1" on target "Set DOTNET environment variables to discover these installed runtimes?".
What if: Performing the operation "Restore" on target "NuGet packages".
Environment variables set:

Name                           Value
----                           -----
PROCDUMP_PATH                  C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools\procdump.0.0.1\bin



What if: Performing the operation "Set Item" on target "Item: PROCDUMP_PATH Value: C:\Users\Jesse\Unshared Code\MessagePack-CSharp\obj\tools\procdump.0.0.1\bin".
PS C:\Users\Jesse\Unshared Code\MessagePack-CSharp>
  • Version used: Commit b652df8
  • Runtime: As follows.
PS C:\Users\Jesse\Code\MessagePack-CSharp> dotnet --info
.NET Core SDK (reflecting any global.json):
 Version:   3.1.301
 Commit:    7feb845744

Runtime Environment:
 OS Name:     Windows
 OS Version:  10.0.19042
 OS Platform: Windows
 RID:         win10-x64
 Base Path:   C:\Users\Jesse\.dotnet\sdk\3.1.301\

Host (useful for support):
  Version: 5.0.1
  Commit:  b02e13abab

.NET SDKs installed:
  3.1.301 [C:\Users\Jesse\.dotnet\sdk]
  5.0.101 [C:\Users\Jesse\.dotnet\sdk]

.NET runtimes installed:
  Microsoft.AspNetCore.App 3.1.5 [C:\Users\Jesse\.dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 5.0.1 [C:\Users\Jesse\.dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 2.1.28 [C:\Users\Jesse\.dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 2.2.7 [C:\Users\Jesse\.dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 3.0.3 [C:\Users\Jesse\.dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 3.1.5 [C:\Users\Jesse\.dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 3.1.15 [C:\Users\Jesse\.dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 5.0.1 [C:\Users\Jesse\.dotnet\shared\Microsoft.NETCore.App]
  Microsoft.WindowsDesktop.App 3.1.5 [C:\Users\Jesse\.dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 5.0.1 [C:\Users\Jesse\.dotnet\shared\Microsoft.WindowsDesktop.App]

To install additional .NET runtimes or SDKs:
  https://aka.ms/dotnet-download
PS C:\Users\Jesse\Code\MessagePack-CSharp> 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants