Commit 63254fe4 authored by Rafael Monnerat's avatar Rafael Monnerat

erp5_forge: Display failure to push as error

See merge request nexedi/erp5!1812
parents c2a7e1e8 e5e7c834
...@@ -381,15 +381,18 @@ class Git(WorkingCopy): ...@@ -381,15 +381,18 @@ class Git(WorkingCopy):
self.git('reset', '--soft', '@{%u}' % reset) self.git('reset', '--soft', '@{%u}' % reset)
if isinstance(e, GitLoginError): if isinstance(e, GitLoginError):
raise raise
portal_status_message = str(e) keep_items_dict = dict(
portal_status_message = str(e),
portal_status_level = 'error'
)
else: else:
head = self.git('rev-parse', '--short', 'HEAD') head = self.git('rev-parse', '--short', 'HEAD')
portal_status_message = translateString( keep_items_dict = dict(
'Files committed successfully in revision ${revision}', portal_status_message = translateString(
mapping=dict(revision=head)) 'Files committed successfully in revision ${revision}',
return context.Base_redirect('view', keep_items={ mapping=dict(revision=head))
'portal_status_message': portal_status_message )
}) return context.Base_redirect('view', keep_items=keep_items_dict)
def log(self, path='.'): def log(self, path='.'):
log = [] 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