title: RegEx strip everything except last character
body: <p>I have a line couple of several lines structured similarly to this and i want to remove everything except the last character. Can anyone advice on a regex everything i had found so far was to remove everything after Template and just end up with P,T,U </p>
  
  <p>etc and for all these lines i want to end up with:
  <code>&lt;name&gt;Doc_TEMPLATE_P
  &lt;name&gt;Doc_TEMPLATE_T
  &lt;name&gt;Doc_TEMPLATE_U</code></p>