Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Support Gitlab subgroups within an extension repo's URL #6352

Open
BradleyChatha opened this issue Apr 8, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@BradleyChatha
Copy link

Describe the Feature You Want

Gitlab supports the ability to nest groups within other groups, for example:

gitlab.com
  - /company
    - /devops
      - /tilt-extensions

It'd be awesome if Tilt could support such structures, e.g.

# Tiltfile
v1alpha1.extension_repo(name="company", url="https://gitlab.com/company/devops/tilt-extensions", ref="main")

As a side note I'd be happy to look into implementing this myself, and I'll probably have a go at it sometime soon.

Current Behavior

Currently when using the above Starlark snippet, Tilt will try to perform the following command:

git clone -- https://gitlab.com/company/devops /Users/___/Library/Application Support/tilt-dev/tilt_modules/gitlab.com/company/devops

Which shows that Tilt is only caring about the first two parts of the URL's path (company/devops), snipping off everything after.

Why Do You Want This?

We'd like to make use of custom extensions but we'd rather not break our current organisation of repositories just to get around a limitation in Tilt.

@nicks
Copy link
Member

nicks commented Apr 16, 2024

thanks for reporting! i think gitlab support was an external contribution, implemented here - tilt-dev/go-get#13

my vague understanding is that MOST VCS providers need some custom handling, but i'm not sure what other tools (e.g., Golang, Terraform) do for gitlab subgroups

@BradleyChatha
Copy link
Author

Thanks for pointing me in a direction I can dig deeper in to. I'll definitely give this a look at at some point, when it becomes a bit higher priority for us.

For reference, Gitlab URLs have a /-/ within their path to signal the split between "describing arbitrary nested subgroups" and "actual API path".

e.g.

https://gitlab.com/company/subgroup-1/subgroup-2/code-repo/-/tree/main

So I believe it's safe to assume that if no "/-/" is found, then the entire URL path can be used as the repo path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants