0
  - task: DotNetCoreCLI@2
displayName: Build X (DotNet)
inputs:
  command: 'build'
  projects: '$(X)'
  arguments: '-c "Release" /p:Platform="x64" --output $(Build.ArtifactStagingDirectory)\X'

once I adding the output (--output $(Build.ArtifactStagingDirectory)\X') argument for be able to PublishArtifact after that the build results.

I got error from solution of missing's files in the Build Solution: error MSB3073

and if I remove the output is work good but I have no option to publishArtifact the results

to some 1 have suggestion how can I publish the results to artifact without output? or to solve the output issue

1

1 Answer 1

0

I am not sure if the --output parameter is available. You can alternatively build your solution using your task and add a separate powershell task to copy build directory to your requested folder. For example:

- task: PowerShell@2
  displayName: Copy code output to artifactsStagingDirectory
  inputs:
    targetType: 'inline'
    script: 'Move-Item "$(Build.SourcesDirectory)/src/solutionName/bin/Debug" "$(Build.ArtifactStagingDirectory)/X"'
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.