title: SCP file copy and overwrite existing file
body: <p>I have a Bash script where I'm issuing an SCP command to copy a text file to a remote server. I want subsequent files of the same name to overwrite the existing remote file. However, the copy does not replace the file but generate copies with a time/date stamp.</p>
  
  <p>Code:</p>
  
  <pre><code>expect &lt;&lt;EOF
      set timeout -1
      spawn scp stats.txt user@192.168.0.188:/stats.txt
      expect "*word:*"
      send "user\r"
      expect eof
  EOF
  </code></pre>
  
  <p>How can I fix this?</p>