Commit e5e7c834 authored by Rafael Monnerat's avatar Rafael Monnerat

erp5_forge: Display failure to push as error

   Redirect with error level, to display the notification properly displayed as error
parent c2a7e1e8
......@@ -381,15 +381,18 @@ class Git(WorkingCopy):
self.git('reset', '--soft', '@{%u}' % reset)
if isinstance(e, GitLoginError):
raise
portal_status_message = str(e)
keep_items_dict = dict(
portal_status_message = str(e),
portal_status_level = 'error'
)
else:
head = self.git('rev-parse', '--short', 'HEAD')
portal_status_message = translateString(
'Files committed successfully in revision ${revision}',
mapping=dict(revision=head))
return context.Base_redirect('view', keep_items={
'portal_status_message': portal_status_message
})
keep_items_dict = dict(
portal_status_message = translateString(
'Files committed successfully in revision ${revision}',
mapping=dict(revision=head))
)
return context.Base_redirect('view', keep_items=keep_items_dict)
def log(self, path='.'):
log = []
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment