title: ASP Core Cannot Set User Secrets in VS 2017
body: <p>With visual studio 2017, when I try to set a user secret I get the following error:</p>
  
  <pre><code>&gt; dotnet user-secrets set Authentication:Google:ClientId mysecretclientid
  &gt; Could not find the global property 'UserSecretsId' in MSBuild project 'c:\test\myproj.csproj'. Ensure this property is set in the project or use the '--id' command line option.
  </code></pre>
  
  <p>I have this in my Startup.cs:</p>
  
  <pre><code>[assembly: UserSecretsId("project-8084c8e7-0000-0000-b266-b33f42dd88c0")]
  
  ...
  
  builder.AddUserSecrets&lt;Startup&gt;();
  </code></pre>
  
  <p>If I add this to my csproj:</p>
  
  <pre><code>  &lt;PropertyGroup&gt;
      &lt;UserSecretsId&gt;project-8084c8e7-0000-0000-b266-b33f42dd88c0&lt;/UserSecretsId&gt;
    &lt;/PropertyGroup&gt;
  </code></pre>
  
  <p>I get an error saying</p>
  
  <pre><code>Duplicate 'Microsoft.Extensions.Configuration.UserSecrets.UserSecretsIdAttribute'
  </code></pre>
  
  <p>What am I doing wrong?</p>