title: Do not append if it already exists
body: <p>I have one file called <code>ClientList.txt</code> that has a output of:</p>
  
  <pre><code>client1.hello.com
  client2.hello.com
  client3.hello.com
  </code></pre>
  
  <p>And I use this script to append the values of the <code>ClientList.txt</code> in a <code>output.txt</code> file. Code:</p>
  
  <pre><code>with open("ClientList.txt", "r") as infile:
    with open("output.txt", "a") as outfile:
      for line in infile:
          outfile.write("".join(["clients name: ",line.strip(), ", clients URL: ", line.strip(), ", service: VIP\n"]))
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>clients name: client1.hello.com, clients URL: client1.hello.com, service: VIP
  clients name: client2.hello.com, clients URL: client2.hello.com, service: VIP
  clients name: client3.hello.com, clients URL: client3.hello.com, service: VIP
  </code></pre>
  
  <p>Question: In the future I would like to update the <code>ClientList.txt</code> with new clients (example: <code>client4.hello.com</code> etc.). Is it possible to not append the value if it already exists in the <code>output.txt</code> file?</p>