##// END OF EJS Templates
fixed spelling mistakes, and some minor docs bugs
marcink -
r860:5f7731e3 beta
parent child Browse files
Show More
@@ -64,9 +64,7 b' class LdapSettingsController(BaseControl'
64 force_defaults=True,)
64 force_defaults=True,)
65
65
66 def ldap_settings(self):
66 def ldap_settings(self):
67 """
67 """POST ldap create and store ldap settings"""
68 POST ldap create and store ldap settings
69 """
70
68
71 settings_model = SettingsModel()
69 settings_model = SettingsModel()
72 _form = LdapSettingsForm()()
70 _form = LdapSettingsForm()()
@@ -100,7 +98,7 b' class LdapSettingsController(BaseControl'
100 encoding="UTF-8")
98 encoding="UTF-8")
101 except Exception:
99 except Exception:
102 log.error(traceback.format_exc())
100 log.error(traceback.format_exc())
103 h.flash(_('error occured during update of ldap settings'),
101 h.flash(_('error occurred during update of ldap settings'),
104 category='error')
102 category='error')
105
103
106 return redirect(url('ldap_home'))
104 return redirect(url('ldap_home'))
@@ -120,7 +120,7 b' class PermissionsController(BaseControll'
120 encoding="UTF-8")
120 encoding="UTF-8")
121 except Exception:
121 except Exception:
122 log.error(traceback.format_exc())
122 log.error(traceback.format_exc())
123 h.flash(_('error occured during update of permissions'),
123 h.flash(_('error occurred during update of permissions'),
124 category='error')
124 category='error')
125
125
126 return redirect(url('edit_permission', id=id))
126 return redirect(url('edit_permission', id=id))
@@ -107,7 +107,7 b' class ReposController(BaseController):'
107
107
108 except Exception:
108 except Exception:
109 log.error(traceback.format_exc())
109 log.error(traceback.format_exc())
110 msg = _('error occured during creation of repository %s') \
110 msg = _('error occurred during creation of repository %s') \
111 % form_result.get('repo_name')
111 % form_result.get('repo_name')
112 h.flash(msg, category='error')
112 h.flash(msg, category='error')
113 if request.POST.get('user_created'):
113 if request.POST.get('user_created'):
@@ -206,7 +206,7 b' class ReposController(BaseController):'
206
206
207 except Exception, e:
207 except Exception, e:
208 log.error(traceback.format_exc())
208 log.error(traceback.format_exc())
209 h.flash(_('An error occured during deletion of %s') % repo_name,
209 h.flash(_('An error occurred during deletion of %s') % repo_name,
210 category='error')
210 category='error')
211
211
212 return redirect(url('repos'))
212 return redirect(url('repos'))
@@ -222,7 +222,7 b' class ReposController(BaseController):'
222 repo_model = RepoModel()
222 repo_model = RepoModel()
223 repo_model.delete_perm_user(request.POST, repo_name)
223 repo_model.delete_perm_user(request.POST, repo_name)
224 except Exception, e:
224 except Exception, e:
225 h.flash(_('An error occured during deletion of repository user'),
225 h.flash(_('An error occurred during deletion of repository user'),
226 category='error')
226 category='error')
227 raise HTTPInternalServerError()
227 raise HTTPInternalServerError()
228
228
@@ -237,14 +237,14 b' class ReposController(BaseController):'
237 repo_model = RepoModel()
237 repo_model = RepoModel()
238 repo_model.delete_stats(repo_name)
238 repo_model.delete_stats(repo_name)
239 except Exception, e:
239 except Exception, e:
240 h.flash(_('An error occured during deletion of repository stats'),
240 h.flash(_('An error occurred during deletion of repository stats'),
241 category='error')
241 category='error')
242 return redirect(url('edit_repo', repo_name=repo_name))
242 return redirect(url('edit_repo', repo_name=repo_name))
243
243
244 @HasPermissionAllDecorator('hg.admin')
244 @HasPermissionAllDecorator('hg.admin')
245 def repo_cache(self, repo_name):
245 def repo_cache(self, repo_name):
246 """
246 """
247 INVALIDATE exisitings repository cache
247 INVALIDATE existing repository cache
248 :param repo_name:
248 :param repo_name:
249 """
249 """
250
250
@@ -1,7 +1,8 b''
1 # -*- coding: utf-8 -*-
1 # -*- coding: utf-8 -*-
2 """
2 """
3 package.rhodecode.controllers.admin.settings
3 rhodecode.controllers.admin.settings
4 ~~~~~~~~~~~~~~
4 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
5
5 settings controller for rhodecode admin
6 settings controller for rhodecode admin
6
7
7 :created_on: Jul 14, 2010
8 :created_on: Jul 14, 2010
@@ -87,7 +87,7 b' class UsersController(BaseController):'
87 encoding="UTF-8")
87 encoding="UTF-8")
88 except Exception:
88 except Exception:
89 log.error(traceback.format_exc())
89 log.error(traceback.format_exc())
90 h.flash(_('error occured during creation of user %s') \
90 h.flash(_('error occurred during creation of user %s') \
91 % request.POST.get('username'), category='error')
91 % request.POST.get('username'), category='error')
92 return redirect(url('users'))
92 return redirect(url('users'))
93
93
@@ -144,7 +144,7 b' class UsersController(BaseController):'
144 except (UserOwnsReposException, DefaultUserException), e:
144 except (UserOwnsReposException, DefaultUserException), e:
145 h.flash(str(e), category='warning')
145 h.flash(str(e), category='warning')
146 except Exception:
146 except Exception:
147 h.flash(_('An error occured during deletion of user'),
147 h.flash(_('An error occurred during deletion of user'),
148 category='error')
148 category='error')
149 return redirect(url('users'))
149 return redirect(url('users'))
150
150
@@ -1,7 +1,7 b''
1 # -*- coding: utf-8 -*-
1 # -*- coding: utf-8 -*-
2 """
2 """
3 package.rhodecode.controllers.error
3 rhodecode.controllers.error
4 ~~~~~~~~~~~~~~
4 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
5
5
6 RhodeCode error controller
6 RhodeCode error controller
7
7
@@ -1,7 +1,7 b''
1 # -*- coding: utf-8 -*-
1 # -*- coding: utf-8 -*-
2 """
2 """
3 package.rhodecode.controllers.summary
3 rhodecode.controllers.summary
4 ~~~~~~~~~~~~~~
4 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
5
5
6 Summary controller for Rhodecode
6 Summary controller for Rhodecode
7
7
@@ -113,6 +113,7 b' def action_logger(user, action, repo, ip'
113 def get_repos(path, recursive=False, initial=False):
113 def get_repos(path, recursive=False, initial=False):
114 """
114 """
115 Scans given path for repos and return (name,(type,path)) tuple
115 Scans given path for repos and return (name,(type,path)) tuple
116
116 :param prefix:
117 :param prefix:
117 :param path:
118 :param path:
118 :param recursive:
119 :param recursive:
@@ -137,7 +138,7 b' def get_repos(path, recursive=False, ini'
137
138
138 def check_repo_fast(repo_name, base_path):
139 def check_repo_fast(repo_name, base_path):
139 """
140 """
140 Check given path for existance of directory
141 Check given path for existence of directory
141 :param repo_name:
142 :param repo_name:
142 :param base_path:
143 :param base_path:
143
144
@@ -233,8 +234,8 b" def make_ui(read_from='file', path=None,"
233
234
234
235
235 def set_rhodecode_config(config):
236 def set_rhodecode_config(config):
236 """
237 """Updates pylons config with new settings from database
237 Updates pylons config with new settings from database
238
238 :param config:
239 :param config:
239 """
240 """
240 from rhodecode.model.settings import SettingsModel
241 from rhodecode.model.settings import SettingsModel
@@ -244,10 +245,10 b' def set_rhodecode_config(config):'
244 config[k] = v
245 config[k] = v
245
246
246 def invalidate_cache(cache_key, *args):
247 def invalidate_cache(cache_key, *args):
247 """
248 """Puts cache invalidation task into db for
248 Puts cache invalidation task into db for
249 further global cache invalidation
249 further global cache invalidation
250 """
250 """
251
251 from rhodecode.model.scm import ScmModel
252 from rhodecode.model.scm import ScmModel
252
253
253 if cache_key.startswith('get_repo_cached_'):
254 if cache_key.startswith('get_repo_cached_'):
@@ -269,10 +270,10 b' class EmptyChangeset(BaseChangeset):'
269
270
270 @LazyProperty
271 @LazyProperty
271 def raw_id(self):
272 def raw_id(self):
272 """
273 """Returns raw string identifying this changeset, useful for web
273 Returns raw string identifying this changeset, useful for web
274 representation.
274 representation.
275 """
275 """
276
276 return self._empty_cs
277 return self._empty_cs
277
278
278 @LazyProperty
279 @LazyProperty
@@ -289,8 +290,7 b' class EmptyChangeset(BaseChangeset):'
289 return 0
290 return 0
290
291
291 def repo2db_mapper(initial_repo_list, remove_obsolete=False):
292 def repo2db_mapper(initial_repo_list, remove_obsolete=False):
292 """
293 """maps all found repositories into db
293 maps all found repositories into db
294 """
294 """
295
295
296 sa = meta.Session()
296 sa = meta.Session()
@@ -443,10 +443,10 b' def add_cache(settings):'
443 beaker.cache.cache_regions[region] = region_settings
443 beaker.cache.cache_regions[region] = region_settings
444
444
445 def get_current_revision():
445 def get_current_revision():
446 """
446 """Returns tuple of (number, id) from repository containing this package
447 Returns tuple of (number, id) from repository containing this package
448 or None if repository could not be found.
447 or None if repository could not be found.
449 """
448 """
449
450 try:
450 try:
451 from vcs import get_repo
451 from vcs import get_repo
452 from vcs.utils.helpers import get_scm
452 from vcs.utils.helpers import get_scm
General Comments 0
You need to be logged in to leave comments. Login now