C NuGet package error in Azure DevOps with image

0 votes

I'm creating a NuGet package to distribute in my organization. Following a post online, the pipeline is working. In Azure DevOps I created the Artifacts, the pipeline buils the NuGet package and push it in the Artifacts as I expected. I'm using Visual Studio 2021.

So, in the property of the project I selected an icon.enter image description here

I committed this change and now Azure DevOps gives me an error. So, I created a folder in the project called Images and here I pasted the image I want to use and updated the path from Visua Studio. The error is the same.

##[error]CSC(0,0): Error CS7064: Error opening icon file /home/vsts/work/1/s/Images/psc_logo.ico -- Could not find a part of the path '/home/vsts/work/1/s/Images/psc_logo.ico'.

Also, in Visual Studio I see the package but the description and the author are different from what I filled in the property.

enter image description here

How can I fix it?

Apr 12, 2022 in Azure by Edureka
• 13,620 points
622 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

According to the error message, it seems you need add the file psc_logo.ico to the source control, the repo.

But, if you want to specify the icon for the package, then the way you are setting the icon is incorrect.

The package settings should be specified in the Package tab.

And for the icon of the package, you could specify following Property in the project file:

<PropertyGroup>
    ...
    <PackageIcon>icon.png</PackageIcon>
    ...
</PropertyGroup>

<ItemGroup>
    ...
    <None Include="images\icon.png" Pack="true" PackagePath="\"/>
    ...
</ItemGroup>
answered Apr 26, 2022 by Edureka
• 12,690 points

edited Mar 5
0 votes

According to the error message, it seems you need add the file psc_logo.ico to the source control, the repo.

But, if you want to specify the icon for the package, then the way you are setting the icon is incorrect.

The package settings should be specified in the Package tab.

And for the icon of the package, you could specify following Property in the project file:

<PropertyGroup>
    ...
    <PackageIcon>icon.png</PackageIcon>
    ...
</PropertyGroup>

<ItemGroup>
    ...
    <None Include="images\icon.png" Pack="true" PackagePath="\"/>
    ...
</ItemGroup>
answered Apr 26, 2022 by Edureka
• 12,690 points

edited Mar 5

Related Questions In Azure

0 votes
1 answer

Error with Azure AD Authentication in Unity for Android

Depending on the version, Unity uses UnityPlayerActivity ...READ MORE

answered Mar 24, 2022 in Azure by Edureka
• 13,620 points
1,071 views
0 votes
1 answer

How to create a service connection for Azure in Azure Devops (with pictures)

to create a service connection for Azure ...READ MORE

answered Mar 29, 2022 in Azure by Edureka
• 12,690 points

edited Jul 4, 2023 by Khan Sarfaraz 9,165 views
0 votes
1 answer
0 votes
1 answer

Difference between Image , VHD and Snapshot in Azure

Is Image the same as the VHD ...READ MORE

answered Mar 24, 2022 in Azure by Edureka
• 12,690 points
1,642 views
0 votes
1 answer

Add image to Azure Devops Dashboard

Markdown is a web writer's text-to-HTML conversion ...READ MORE

answered Mar 26, 2022 in Azure by Edureka
• 12,690 points
1,007 views
0 votes
0 answers
0 votes
0 answers

Azure DevOps NuGet Pack is ignoring csproj package details

I have three separate projects each configured ...READ MORE

Mar 27, 2022 in Other DevOps Questions by Kichu
• 19,040 points
550 views
0 votes
0 answers
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP