사용자 정의 NuGet 패키지를 설치하면 작동하지만 VS에있는 출력 창은 파일을 두 번 추가하려고 시도하고 이미 존재했음을 보여줍니다. 이 게시물에서 출력이 더 내려갑니다.사용자 정의 NuGet 패키지 출력 창 메시지 설치
여기 갤러리를 호스팅하는 서버에 NuGet 개인 저장소가 있습니다. 출력 창에 아래 메시지가 표시 되더라도 설치 및 제거가 작동합니다. spec 파일의 <files>
태그에 대해 궁금합니다. 다른 방법이 있다면이 작업을 수행해야합니다. 나는 문서를 기반으로 여러 방법을 시도했다. 내 버전은 NuGet 사이트에서 최신 버전으로 설치되었습니다. 사이트에서
:
항목/플러그인/CustomNuGet/CSS/사용자 정의 :
The latest version of the nuget.exe command-line tool is always available from http://nuget.org/nuget.exe
Specifying files to include in the package
출력 창 설치 패키지 CustomNuGet을에이 같은 일을 보여줍니다. CSS가 이미 있습니다.
/Plugins/CustomNuGet/Scripts/custom.js 항목이 이미 있습니다.
/Plugins/CustomNuGet/Views/custom.cshtml 항목이 이미 있습니다. 항목 /Plugins/CustomNuGet/CSS/custom.css가 작업 공간에
를 찾을 수 없습니다 :
출력 창 제거 - 패키지 CustomNuGet에이 같은 일을 보여줍니다.
/Plugins/CustomNuGet/Scripts/custom.js 항목을 작업 영역에서 찾을 수 없습니다.
/Plugins/CustomNuGet/Views/custom.cshtml 항목을 작업 영역에서 찾을 수 없습니다.
명령 줄 도구를 사용하여 사용자 지정 Nuget 패키지를 만들었습니다. 폴더는 다음과 같습니다
/CustomNuGet
CustomNuGet.nuspec
CustomNuGet.0.1.1.nupkg
/content
/lib
CustomNuGet.dll
/Plugins
/Views
custom.cshtml
/Scripts
custom.js
/CSS
custom.css
사양 파일을 사용하여 만든 : nuget spec
및 설명서에 따라 루트 CustomeNuGet 폴더에 패키지 nuget pack
합니다. 다음은 스펙 파일입니다
<?xml version="1.0"?>
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
<metadata>
<id>CustomNuGet</id>
<version>0.1.1</version>
<authors>CustomNuGet</authors>
<owners>CustomNuGet</owners>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>CustomNuGet</description>
<tags>CustomNuGet</tags>
<references>
<reference file="CustomNuGet.dll" />
</references>
<dependencies>
<dependency id="WebActivatorEx" version="2.0.0" />
</dependencies>
</metadata>
<files>
<file src="content\lib\CustomNuGet.dll" target="lib"/>
<file src="content\Plugins\**" target="content\Plugins" />
</files>
</package>
내가 너무 잘하면 다른 사람이 이런 일이 있었이 정확한 문제에 대한 어떤 게시물을 보지 못했어요 그리고 내가 놓친 만 설정합니다.
솔루션이 TFS 소스 컨트롤에 연결되어 있습니까? – Rhumborl
예. 우리의 repos는 TFS에 있습니다. – area28
팩에서 생성 한 .nupkg 파일을 열어 보았습니까? 그것은 단지 zip 파일이므로 7-zip과 같은 프로그램이 열립니다 ([NuGet Package Explorer] (http://npe.codeplex.com/)와 같은 도구를 사용할 수도 있습니다).어느 쪽이든, 패키지를 찾아보고 파일이 두 번 포함되어 있는지 아니면 다른 것으로 보이는 지 모두 알 수있는 방법을 모두 확인할 수 있습니다. – NextInLine