klesh commented on issue #4331: URL: https://github.com/apache/incubator-devlake/issues/4331#issuecomment-1418636196
## Root cause: The commit URLs pointing to **bitbucket** are different from those from **gitlab**: ``` https://gitlab.com/merico-dev/ee/ee-frontend/-/commit/a50227e06abd28033b27b4859c2426000f7f9c6c https://github.com/apache/incubator-devlake/commit/a58b109e8c37c6c4fe4ec0df5a42fddb174cdec8 https://bitbucket.org/narro2/nirvana/commits/5080b020be36256b5334b869cf8db505cfdee1dc ``` However, the `repo_url` extraction logic is hardcoded:  ## Problem Obviously, the current implementation is problematic since we can count on other code-hosting platforms likely to have different URL formats other than the above. We need to find another solution so that users may specify the `repo_url` part out of the `commit_url` by `regex` (maybe) assuming the `repo_url` is part of the `commit_url`. ## Solution 1. Add another field to `JiraTransformationRule` for users to specify the `regex` for `repo_url` 2. Enhance the existing `RemotelinkCommitShaPattern` to accept `submatch`, one for `repo_url`, one for `commit_sha` either by Order or [Naming](https://stackoverflow.com/a/20751656/20763223) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
