title: how to include "enter key" in python
body: <pre><code>import subprocess
  
  path = '/home/test/net.keystore'
  
  text = subprocess.Popen(['keytool', '-list', '-v', '-keystore', path], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
  file = text.stdout.read().decode().splitlines()
  print file
  </code></pre>
  <blockquote>
  <p>through subprocess i trying to fetch keystore certificate details I
  don't know password for keystore. If i press &quot;enter key&quot; twice then
  output is processing</p>
  <p>Is there any way to automate &quot;Enter key&quot; in python?</p>
  </blockquote>