title: Rshiny publish error: inferAppPrimaryDoc Execution halted
body: <p>I created an Rshiny APP on my Mac and tried to upload to shinyapps.io</p>
  
  <p>However, when I press 'Publish' button at the top right corner, it shows an error.</p>
  
  <pre><code>Preparing to deploy application...DONE
  Uploading bundle for application: 609021...Error in inferAppPrimaryDoc(appPrimaryDoc = appPrimaryDoc, appFiles = appFiles,  : 
    Application mode static requires at least one document.
  Calls: &lt;Anonymous&gt; ... withStatus -&gt; force -&gt; bundleApp -&gt; inferAppPrimaryDoc
  Execution halted
  </code></pre>
  
  <p>This problem has been solved. See the first answer.</p>
  
  <p>But now, I have another problem. </p>
  
  <p>I can publish it, but the app cannot show the graphs. </p>
  
  <p>I check the log and it says, </p>
  
  <pre><code>Warning: Error in : Aesthetics must be either length 1 or the same as the data (1): x, y, label, vjust, fill 
  </code></pre>
  
  <p>Also, there is another warning, </p>
  
  <pre><code>Warning in Ops.factor(Year, start) : ‘&gt;=’ not meaningful for factors. 
  </code></pre>
  
  <p>It is pretty strange because when I run the app on my own laptop, it works super well. Please help...</p>
  
  <p>Thanks,</p>
  
  <p>Weichen</p>