title: how can I edit RPM spec file before uninstall
body: <p>Description of the question:</p>
  
  <ol>
  <li>I made a rpm package which delete all the files on the uninstall.</li>
  <li>I want to make a rpm package which can handle the upgrade option also (-U)</li>
  <li>So I implement rpm spec file in such a way (on the basis of $1 value), </li>
  </ol>
  
  <p>but as this implementation is not present in the installed release. The previous rpm deletes my all folders.
  I am thinking to edit the previous spec file. but not able to find the path of this spec file.</p>
  
  <p>How can I solved this.</p>
  
  <p>Thanks &amp; Regards,</p>