{"action":"opened","issue":{"url":"https://api.github.com/repos/dotnet/roslyn/issues/3026","labels_url":"https://api.github.com/repos/dotnet/roslyn/issues/3026/labels{/name}","comments_url":"https://api.github.com/repos/dotnet/roslyn/issues/3026/comments","events_url":"https://api.github.com/repos/dotnet/roslyn/issues/3026/events","html_url":"https://github.com/dotnet/roslyn/issues/3026","id":79515346,"number":3026,"title":"Analyzer .nuspec file hardcodes values that should come from assembly attributes","user":{"login":"lgolding","id":11762653,"avatar_url":"https://avatars.githubusercontent.com/u/11762653?v=3","gravatar_id":"","url":"https://api.github.com/users/lgolding","html_url":"https://github.com/lgolding","followers_url":"https://api.github.com/users/lgolding/followers","following_url":"https://api.github.com/users/lgolding/following{/other_user}","gists_url":"https://api.github.com/users/lgolding/gists{/gist_id}","starred_url":"https://api.github.com/users/lgolding/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lgolding/subscriptions","organizations_url":"https://api.github.com/users/lgolding/orgs","repos_url":"https://api.github.com/users/lgolding/repos","events_url":"https://api.github.com/users/lgolding/events{/privacy}","received_events_url":"https://api.github.com/users/lgolding/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-05-22T16:21:15Z","updated_at":"2015-05-22T16:21:15Z","closed_at":null,"body":"Repro:\r\n1. Create a project from the \"Analyzer with Code Fix (NuGet + VSIX)\" template.\r\n2. Build the project.\r\n3. In the output directory, rename the .nupkg to .zip, open the zip file, and examine the .nuspec file. Note that it specifies version=1.0.0.0 and authors={project name}.\r\n4. Modify AssemblyInfo.cs, setting (for example) AssemblyVersion=2.0.* and AssemblyCompany=Contoso\r\n5. Rebuild the project.\r\n6. Again examine the .nuspec file in the generated .nupkg.\r\n\r\nExpected: The version and authors metadata should match the corresponding assembly attributes.\r\n\r\nActual: The metadata is unchanged.\r\n\r\nThis is because the postbuild step that creates the .nupkg specifies the .nuspec file as input, and the .nuspec file hardcodes the metadata.\r\n\r\nIf instead the postbuild step specified the project file $(MSBuildThisFileFullPath), and the .nuspec file used placeholders for the metadata (such as $version$ and $author$), then the .nupkg would automatically carry the metadata specified in the assembly attributes."}}