I have the below json file
{
"name": "ca",
"version": "5.2.0"
}
I am extracting the value of version and trying to assign it to a variable ver
$jsonString = Get-Content -Path ./package.json
$jsonObj = $jsonString | ConvertFrom-Json
echo $jsonObj.version
Write-Host "##vso[task.setvariable variable=ver]$jsonObj.version"
echo $ver
Below is the output
5.2.0
I am expecting the value to be printed twice and also get it assigned to the variable ver but it is not getting assigned
vsostuff?