The core of asp.net and including shared content files

I have a collaborative project project that contains some content files like JSON etc.

I have a number of major ASP.Net projects and I want to include / share some of these JSON files. Very simple with the "Link to file" option in VS, but it is not available in major ASP.Net projects.

I tried playing with buildOptions / copyToOutput as follows, but this does not seem to work, and there were no errors or warnings during the build process.

"copyToOutput": {
    "include": [ "../Common.Includes/mysettings*.json" ] }

Any ideas gratefully accepted?

thank

Donal

+4
source share
1 answer

copyToOutput ( , dotnet 1.0.0-preview3-003171 Windows). , , copyToOutput - tath, A, B, .

- . Linux :

> ln -s ../Common.Includes common

Windows ( ) :

> mklink /J common ..\Common.Includes

dotnet :

"scripts": {
    "precompile": "cmd /C mklink /J common ..\\Common.Includes"
}

RC1 , "" "prerestore", , dotnet "" "".

script , , . init.ps1 Powershell script:

if (!(Test-Path "common")) {
    cmd /C mklink /J "common" "..\Common.Includes"
}

"":

"scripts": {
    "precompile": "init.ps1"
}
0

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


All Articles