title: ASP.Net 5 Console Application Entry Point
body: <p>I've been trying to build a console application in ASP.Net 5 and am having some trouble with the entry point. I've looked at the following:
  <a href="https://stackoverflow.com/questions/28938582/entry-point-can-be-marked-with-the-async-modifier-on-coreclr">Entry point can be marked with the &#39;async&#39; modifier on CoreCLR?</a>
  And
  <a href="https://msdn.microsoft.com/en-us/magazine/dn913182.aspx" rel="nofollow noreferrer">https://msdn.microsoft.com/en-us/magazine/dn913182.aspx</a>.
  When I create a Console Application (Package) with Visual Studio 2015 It creates the following Program File</p>
  
  <pre><code>public class Program
  {
      public static void Main(string[] args)
      {
      }
  }
  </code></pre>
  
  <p>However I want to utilise the instance have Main as an instance method so I can add a parameterless constructor of Program and have some Dependency Injection magic.. However when I remove "static" Visual Studio gives me the following error:</p>
  
  <blockquote>
    <p>"Program does not have a static 'Main' method suitable for an entry
    point".</p>
  </blockquote>
  
  <p>I noticed in the project.json file I have the following entry:</p>
  
  <pre><code>"compilationOptions": {
      "emitEntryPoint": true
  }
  </code></pre>
  
  <p>If I change this to false. The application builds but it does not execute the Main method. But it does seem to call my Program Constructor. Am I then supposed to just call Main() manually? I feel like I'm doing something wrong here. I would appreciate any help.</p>