Concatenating a variable and a string literal without a space in PowerShell -


how can write variable console without space after it? there problems when try:

$myvariable = "some text" write-host "$myvariablenospaces" 

i'd following output:

some textnospaces 

another option , possibly more canonical way use curly braces delineate name:

$myvariable = "some text" write-host "${myvariable}nospaces" 

this particular handy paths e.g. ${projectdir}bin\$config\images. however, if there \ after variable name, enough powershell consider not part of variable name.


Comments

Popular posts from this blog

python - Why doesn't list have safe "get" method like dictionary? -

razor - Is this a bug in WebMatrix PageData? -

sql server - Stored procedure -