Cannot publish my project. What coud be a problem?

Hi there
Cannot publish my WEB project. The problem is that it shows “passed” on the CI/CD page but the target directory on my local machine remains empty. My .yml file is as follows:

variables:
NUGET_PATH: ‘C:\DevOpsTools\nuget.exe’
MSBUILD_PATH: ‘C:\Program Files (x86)\MSBuild\14.0\Bin\msbuild.exe’
MSDEPLOY_PATH: ‘c:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe’
PROJECT_PATH: ‘./BBBSilverlight.Web\BBBSilverlight.Web.csproj’
PUBLISH_PATH: ‘E:\GitLab-Runner\LocalBuild’

stages:

  • build

build_job:
stage: build
only:

  • branches
    script:

  • echo “Building Release…”
    -’& “$env:MSBUILD_PATH” “$env:PROJECT_PATH” /p:DeployOnBuild=True /p:DeployDefaultTarget=WebPublish /p:WebPublishMethod=FileSystem /p:DeleteExistingFiles=True /p:publishUrl="$env:PUBLISH_PATH"’

The folder “E:\GitLab-Runner\LocalBuild” remains empty.

If I run a .bat file like

SET PROJECT=“MyDisk:\Development\BBBSilverlight.Web\MyProject.csproj”
SET MSBUILD_PATH=“C:\Program Files (x86)\MSBuild\14.0\Bin”
SET PUBLISH_DIRECTORY=“E:\GitLab-Runner\LocalBuild”

cd /d %MSBUILD_PATH%
MSBuild %PROJECT% /p:DeployOnBuild=True /p:DeployDefaultTarget=WebPublish /p:WebPublishMethod=FileSystem /p:DeleteExistingFiles=True /p:publishUrl=%PUBLISH_DIRECTORY%

it works like a charm.

Why it does not work with my runner?

Thanks.