title: Code Blocks(New project/Rename main file)
body: <p>When I create a new project in code blocks <code>File-&gt;New-&gt;project-&gt;console application-&gt;Go-&gt;C++-&gt;&lt;project title&gt;-&gt;GNU compiler-&gt;finish</code> (both debug and release box are checked), Then a project is created having <code>.cpp</code> file with name of <code>main</code>.</p>
  
  <p>My question is how to rename this main file.</p>
  
  <p>Before asking this question I have tried to solve it, but it includes many steps.</p>
  
  <p>I have tried two ways (one way gives me a solution, and the other way indicates that file has been corrupted).</p>
  
  <p>Actually I want to find a quick way to rename this main file?
  If there is any method please tell me.</p>
  
  <p>Two methods which I used(mentioning below)</p>
  
  <ol>
  <li><p><code>File-&gt;New-&gt;project-&gt;console application-&gt;Go-&gt;C++-&gt;&lt;project title&gt;-&gt;GNU compiler-&gt;finish</code>
  then go to local disc (where project is saved) rename <code>main</code> file. Open project again in code blocks. Open main file it says file does not exist.
  This method was quick but failed to rename main.</p></li>
  <li><p><code>File-&gt;New-&gt;project-&gt;console application-&gt;Go-&gt;C++-&gt;&lt;project title&gt;-&gt;GNU compiler-&gt;finish.
  then in code blocks at left side bar Sources/main/right click on main/remove file from project (then code blocks indicate you have deleted this main file but actually its not when I checked in local disk, main file was there). Then I create a new</code>.cpp` file as File/New/File and next simple steps.</p></li>
  </ol>
  
  <p>So finally I got what I want. A new project with <code>.cpp</code> file (name of <code>.cpp</code> file that I want). But I'm not satisfied, I want a quick method.</p>