diff --git a/rhodecode/controllers/pullrequests.py b/rhodecode/controllers/pullrequests.py
--- a/rhodecode/controllers/pullrequests.py
+++ b/rhodecode/controllers/pullrequests.py
@@ -141,7 +141,7 @@ class PullrequestsController(BaseRepoCon
                              c.default_other_refs, class_='refs')
         }
 
-        # gather forks and add to this list ... even though it is rare to 
+        # gather forks and add to this list ... even though it is rare to
         # request forks to pull their parent
         for fork in org_repo.forks:
             c.other_repos.append((fork.repo_name, fork.repo_name))
diff --git a/rhodecode/lib/vcs/backends/git/changeset.py b/rhodecode/lib/vcs/backends/git/changeset.py
--- a/rhodecode/lib/vcs/backends/git/changeset.py
+++ b/rhodecode/lib/vcs/backends/git/changeset.py
@@ -364,7 +364,7 @@ class GitChangeset(BaseChangeset):
         else:
             frmt = 'tar'
         _git_path = rhodecode.CONFIG.get('git_path', 'git')
-        cmd = '%s archive --format=%s --prefix=%s/ %s' % (_git_path, 
+        cmd = '%s archive --format=%s --prefix=%s/ %s' % (_git_path,
                                                 frmt, prefix, self.raw_id)
         if kind == 'tgz':
             cmd += ' | gzip -9'
diff --git a/rhodecode/templates/admin/repos/repo_edit.html b/rhodecode/templates/admin/repos/repo_edit.html
--- a/rhodecode/templates/admin/repos/repo_edit.html
+++ b/rhodecode/templates/admin/repos/repo_edit.html
@@ -292,10 +292,10 @@
            <div class="fields">
                ${h.submit('remove_%s' % c.repo_info.repo_name,_('Remove this repository'),class_="ui-btn red",onclick="return confirm('"+_('Confirm to delete this repository')+"');")}
               %if c.repo_info.forks.count():
-                    - ${ungettext('this repository has %s fork', 'this repository has %s forks', c.repo_info.forks.count()) % c.repo_info.forks.count()} 
+                    - ${ungettext('this repository has %s fork', 'this repository has %s forks', c.repo_info.forks.count()) % c.repo_info.forks.count()}
                     <input type="radio" name="forks" value="detach_forks" checked="checked"/> <label for="forks">${_('Detach forks')}</label>
                     <input type="radio" name="forks" value="delete_forks" /> <label for="forks">${_('Delete forks')}</label>
-              %endif               
+              %endif
            </div>
            <div class="field" style="border:none;color:#888">
            <ul>
diff --git a/rhodecode/templates/admin/users/user_edit_my_account_pullrequests.html b/rhodecode/templates/admin/users/user_edit_my_account_pullrequests.html
--- a/rhodecode/templates/admin/users/user_edit_my_account_pullrequests.html
+++ b/rhodecode/templates/admin/users/user_edit_my_account_pullrequests.html
@@ -9,7 +9,7 @@
           %if pull_request.is_closed():
               <img src="${h.url('/images/icons/lock_go.png')}" title="${_('Closed')}"/>
           %endif
-          <img src="${h.url('/images/icons/flag_status_%s.png' % str(pull_request.last_review_status))}" />          
+          <img src="${h.url('/images/icons/flag_status_%s.png' % str(pull_request.last_review_status))}" />
           <a href="${h.url('pullrequest_show',repo_name=pull_request.other_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">
           ${_('Pull request #%s opened on %s') % (pull_request.pull_request_id, h.fmt_date(pull_request.created_on))}
           </a>
@@ -36,7 +36,7 @@
         %if pull_request.is_closed():
             <img src="${h.url('/images/icons/lock_go.png')}" title="${_('Closed')}"/>
         %endif
-        <img src="${h.url('/images/icons/flag_status_%s.png' % str(pull_request.last_review_status))}" />          
+        <img src="${h.url('/images/icons/flag_status_%s.png' % str(pull_request.last_review_status))}" />
         <a href="${h.url('pullrequest_show',repo_name=pull_request.other_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">
         ${_('Pull request #%s opened by %s on %s') % (pull_request.pull_request_id, pull_request.author.full_name, h.fmt_date(pull_request.created_on))}
         </a>
diff --git a/rhodecode/templates/base/base.html b/rhodecode/templates/base/base.html
--- a/rhodecode/templates/base/base.html
+++ b/rhodecode/templates/base/base.html
@@ -353,7 +353,7 @@
                <span>${_('Admin')}</span>
                </a>
                 ${admin_menu_simple()}
-            </li>                
+            </li>
             % endif
             ${usermenu()}
         %endif
diff --git a/rhodecode/templates/base/root.html b/rhodecode/templates/base/root.html
--- a/rhodecode/templates/base/root.html
+++ b/rhodecode/templates/base/root.html
@@ -85,7 +85,7 @@
               // routes registration
               pyroutes.register('toggle_following', "${h.url('toggle_following')}");
               pyroutes.register('changeset_info', "${h.url('changeset_info', repo_name='%(repo_name)s', revision='%(revision)s')}", ['repo_name', 'revision']);
-              pyroutes.register('repo_size', "${h.url('repo_size', repo_name='%(repo_name)s')}", ['repo_name']);              
+              pyroutes.register('repo_size', "${h.url('repo_size', repo_name='%(repo_name)s')}", ['repo_name']);
            })
             </script>
         </%def>
diff --git a/rhodecode/templates/index_base.html b/rhodecode/templates/index_base.html
--- a/rhodecode/templates/index_base.html
+++ b/rhodecode/templates/index_base.html
@@ -13,7 +13,7 @@
                         <span>${h.link_to(_('Add repository'),h.url('admin_settings_create_repository',parent_group=c.group.group_id))}</span>
                         %if h.HasPermissionAny('hg.admin')() or h.HasReposGroupPermissionAny('group.admin')(c.group.group_name):
                          <span>${h.link_to(_(u'Add group'),h.url('new_repos_group', parent_group=c.group.group_id))}</span>
-                        %endif                        
+                        %endif
                   %else:
                     <span>${h.link_to(_('Add repository'),h.url('admin_settings_create_repository'))}</span>
                     %if h.HasPermissionAny('hg.admin')():
diff --git a/rhodecode/templates/pullrequests/pullrequest_show.html b/rhodecode/templates/pullrequests/pullrequest_show.html
--- a/rhodecode/templates/pullrequests/pullrequest_show.html
+++ b/rhodecode/templates/pullrequests/pullrequest_show.html
@@ -174,7 +174,7 @@
     pyroutes.register('pullrequest_comment', "${url('pullrequest_comment',repo_name='%(repo_name)s',pull_request_id='%(pull_request_id)s')}", ['repo_name', 'pull_request_id']);
     pyroutes.register('pullrequest_comment_delete', "${url('pullrequest_comment_delete',repo_name='%(repo_name)s',comment_id='%(comment_id)s')}", ['repo_name', 'comment_id']);
     pyroutes.register('pullrequest_update', "${url('pullrequest_update',repo_name='%(repo_name)s',pull_request_id='%(pull_request_id)s')}", ['repo_name', 'pull_request_id']);
-    
+
     </script>
 
     ## diff block
diff --git a/rhodecode/tests/test_libs.py b/rhodecode/tests/test_libs.py
--- a/rhodecode/tests/test_libs.py
+++ b/rhodecode/tests/test_libs.py
@@ -227,10 +227,10 @@ class TestLibs(unittest.TestCase):
       ("ffffffffffff some text traalaa",
        "url[ffffffffffff] some text traalaa"),
        ("""Multi line
-       123123123123 
+       123123123123
        some text 123123123123""",
        """Multi line
-       url[123123123123] 
+       url[123123123123]
        some text url[123123123123]""")
     ])
     def test_urlify_changesets(self, sample, expected):