colinlienard / gitlight

🐙 GitHub & GitLab notifications on your desktop
https://gitlight.app
MIT License
762 stars 33 forks source link

Repo cannot be added from contributed project #220

Closed nightbikerdev closed 1 year ago

nightbikerdev commented 1 year ago

When trying to add a repo https://gitlab.com/<COMPANY_NAME>/projects/<GROUP_NAME>/<REPO_NAME> I get an error Invalid URL. The access role for this project is 'Maintainer'.

colinlienard commented 1 year ago

I think you can simply do https://gitlab.com/<GROUP_NAME>/<REPO_NAME>, or just go on the page of the project, copy the url and paste it in the app. Beware, the project path can be different from the actual name as written here. Maybe I should add a clarification about that somewhere

For example, I created a group called group-test and a project inside it called project-test. The url of the project is https://gitlab.com/group-test5943045/project-test

Does this help @nightbikerdev?

christoff-linde commented 1 year ago

When trying to add a repo https://gitlab.com/<COMPANY_NAME>/projects/<GROUP_NAME>/<REPO_NAME> I get an error Invalid URL. The access role for this project is 'Maintainer'.

I have this issue as well when trying to add a repo specifically for work (i.e. something like https://gitlab.com/<COMPANY_NAME>/projects/<GROUP_NAME>/<REPO_NAME>).

Could it be because the repo is owned by a company and not a personal account causing some form of permissions issue?

nightbikerdev commented 1 year ago

@colinlienard Unfortunately, it did not help. I think @christoff-linde is right. It seems gitlab does not have a good way to get repositories where user contributed.

colinlienard commented 1 year ago

I may have an idea, I'll test tonight and maybe I'll ask you to test things too if you agree, because I don't have access to private company repositories on GitLab

colinlienard commented 1 year ago

@nightbikerdev @christoff-linde Could you please test again on the website? Not on the app, I didn't make a new release

If it still doesn't work, could you go to https://gitlight.app/gitlab-test and tell me if you see stuff from your companies?

Could you also test the repositories with:

christoff-linde commented 1 year ago

So can confirm that for me it does work with https://gitlab.com/<GROUP_NAME>/<SUB_GROUP_NAME>/<SUB_GROUP_NAME>/<REPO_NAME> (as well as slight variations of this).

christoff-linde commented 1 year ago

I would be kinda cool to have the option to have the repos be added in "bulk" by for e.g., specifying just https://gitlab.com/<GROUP_NAME>/<SUB_GROUP_NAME>, if that is even technically possible. Would especially be useful if one has a lot of repos to keep track of

nightbikerdev commented 1 year ago

Now It works for my case :+1:

colinlienard commented 1 year ago

Nice! Thanks to both of you for helping on this I'll publish a fix soon followed by a new release

I would be kinda cool to have the option to have the repos be added in "bulk" by for e.g., specifying just https://gitlab.com/<GROUP_NAME>/<SUB_GROUP_NAME>, if that is even technically possible. Would especially be useful if one has a lot of repos to keep track of

Good idea, I'll look into it