aquasecurity / chain-bench

An open-source tool for auditing your software supply chain stack for security compliance based on a new CIS Software Supply Chain benchmark.
Apache License 2.0
712 stars 63 forks source link

Issue when the sub group has the same name as the repository #130

Closed codekuu closed 8 months ago

codekuu commented 8 months ago

Description

Issue when the sub group has the same name as the repository. Example: https://my-gitlab-instance.com/top-group/sub-group/repo-name/repo-name

getRepoInfo returns:

host: my-gitlab-instance.com
namespace: top-group/sub-group
repo: repo-name
err: %!s(<nil>)

What did you expect to happen?

should return:

host: my-gitlab-instance.com
namespace: top-group/sub-group/repo-name
repo: repo-name
err: %!s(<nil>)

What happened instead?

getRepoInfo returns:

host: my-gitlab-instance.com
namespace: top-group/sub-group
repo: repo-name
err: %!s(<nil>)

Made a PR for this but due to the contribution guidelines I created this issue as well.