.. _changelog:
Changelog
=========
1.3.2 (**2012-XX-XX**)
----------------------
:status: in-progress
:branch: beta
news
++++
fixes
+++++
- fixed git protocol issues with repos-groups
- fixed git remote repos validator that prevented from cloning remote git repos
- fixes #370 ending slashes fixes for repo and groups
1.3.1 (**2012-02-27**)
- redirection loop occurs when remember-me wasn't checked during login
- fixes issues with git blob history generation
- don't fetch branch for git in file history dropdown. Causes unneeded slowness
1.3.0 (**2012-02-26**)
- code review, inspired by github code-comments
- #215 rst and markdown README files support
- #252 Container-based and proxy pass-through authentication support
@@ -242,48 +242,53 @@ class ReposGroupsController(BaseControll
raise HTTPInternalServerError()
@HasReposGroupPermissionAnyDecorator('group.admin')
def delete_repos_group_users_group_perm(self, group_name):
"""
DELETE an existing repositories group permission users group
:param group_name:
try:
ReposGroupModel().revoke_users_group_permission(
repos_group=group_name,
group_name=request.POST['users_group_id']
)
Session.commit()
except Exception:
log.error(traceback.format_exc())
h.flash(_('An error occurred during deletion of group'
' users groups'),
category='error')
def show_by_name(self, group_name):
This is a proxy that does a lookup group_name -> id, and shows
the group by id view instead
group_name = group_name.rstrip('/')
id_ = RepoGroup.get_by_group_name(group_name).group_id
return self.show(id_)
@HasReposGroupPermissionAnyDecorator('group.read', 'group.write',
'group.admin')
def show(self, id, format='html'):
"""GET /repos_groups/id: Show a specific item"""
# url('repos_group', id=ID)
c.group = RepoGroup.get(id)
if c.group:
c.group_repos = c.group.repositories.all()
else:
return redirect(url('home'))
#overwrite our cached list with current filter
gr_filter = c.group_repos
c.cached_repo_list = self.scm_model.get_repos(all_repos=gr_filter)
c.repos_list = c.cached_repo_list
c.repo_cnt = 0
@@ -71,53 +71,59 @@ def recursive_replace(str_, replace=' ')
if str_.find(replace * 2) == -1:
return str_
str_ = str_.replace(replace * 2, replace)
return recursive_replace(str_, replace)
def repo_name_slug(value):
"""Return slug of name of repository
This function is called on each creation/modification
of repository to prevent bad names in repo
slug = remove_formatting(value)
slug = strip_tags(slug)
for c in """=[]\;'"<>,/~!@#$%^&*()+{}|: """:
slug = slug.replace(c, '-')
slug = recursive_replace(slug, '-')
slug = collapse(slug, '-')
return slug
def get_repo_slug(request):
return request.environ['pylons.routes_dict'].get('repo_name')
_repo = request.environ['pylons.routes_dict'].get('repo_name')
if _repo:
_repo = _repo.rstrip('/')
return _repo
def get_repos_group_slug(request):
return request.environ['pylons.routes_dict'].get('group_name')
_group = request.environ['pylons.routes_dict'].get('group_name')
if _group:
_group = _group.rstrip('/')
return _group
def action_logger(user, action, repo, ipaddr='', sa=None, commit=False):
Action logger for various actions made by users
:param user: user that made this action, can be a unique username string or
object containing user_id attribute
:param action: action to log, should be on of predefined unique actions for
easy translations
:param repo: string name of repository or object containing repo_id,
that action was made on
:param ipaddr: optional ip address from what the action was made
:param sa: optional sqlalchemy session
if not sa:
sa = meta.Session
if hasattr(user, 'user_id'):
user_obj = user
elif isinstance(user, basestring):
Status change: