Duplicate file is getting created in linux : <p>I created a file called <code>file2.txt</code> in Linux, opened it in text editor and saved it. When I closed the text editor I see two files <code>file2.txt</code> and <code>file2.txt~</code></p>

<p>I guess <code>file2.txt~</code> is temporary file created when I am editing the <code>file2.txt</code> but it should get removed when I finished saving and closed text editor.</p>
