Modify editor patch branch name generation
What does this MR do?
When a user does does not have permission to push to the target branch when using the Single File Editor, a patch branch name is generated and suggested to them.
This strategy/pattern used to generate the name is different in the SFE to the WebIDE and this MR fixes that to make them the same.
This coincidentally should reduce the number of branch name conflicts that can also occur with the existing implementation, (which just increments a count of existing patch branches) by switching to using time sinch epoch.
The pattern should look like:
{username}-{target-ref}-patch-{time-since-epoch}
More information is available in the related issue, #235512 (closed)
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry - [-] Documentation (if required)
-
Code review guidelines -
Merge request performance guidelines -
Style guides - [-] Database guides
- [-] Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process.
Screenshots
Before | After |
---|---|
Edited by Vijay Hawoldar