Publication configuration disabled for csproj

Why can't I change these settings shown in the image below? CSProj property windows showing a disabled configuration profile

This is a clickOnce application, and my problem is that I want to change the publication path, assembly name, product name, installation URL and transform some app.config conversions based on the assembly configuration. I can achieve this by manually editing csproj like this

<PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
    <AssemblyName>someApplicationTest</AssemblyName>
    <ProductName>Some Application Test</ProductName>
    <PublishUrl>c:\publish\someApplicationTest\</PublishUrl>
    <InstallUrl>http://sub.example.com/someApplicationTest/</InstallUrl>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
    <AssemblyName>someApplication</AssemblyName>
    <ProductName>Some Application</ProductName>
    <PublishUrl>c:\publish\someApplication\</PublishUrl>
    <InstallUrl>http://sub.example.com/someApplication/</InstallUrl>
</PropertyGroup>

I am just confused why these options are disabled in the visual studio, and if I miss something. Perhaps I was confused, and these controls were not even designed for this purpose.

In addition, I will explore Squirrel.Windows as an alternative later, but for now I wanted to know more about it.

+4
1

. . , . "". , - Release. , .

, .csproj , Notepad . <PropertyGroup>, Condition, . PropertyGroup .

, "" Microsoft , . , , Release. , . , . , .

+1

Source: https://habr.com/ru/post/1615477/


All Articles