ben-gibson / GitLink

A Jetbrains plugin that opens a local file under Git version control in its remote host using the default browser.
https://plugins.jetbrains.com/plugin/8183-gitlink
MIT License
671 stars 58 forks source link

Feature Request: Default platform setting #276

Open Malaber opened 1 year ago

Malaber commented 1 year ago

Hey, first of all I love using GitLink!

It would be nice to set a default Platform as I have to set it to GitLab on every new project I open the first time (which is quite a lot sadly) Even cooler would be an option to set the default per folder, as I keep my locally cloned repositories separated by git server.

Thanks for considering this.

dwightmulcahy commented 1 year ago

Same, we recently moved to GitLab and having to change that for each repo is annoying...

ben-gibson commented 1 year ago

In the plugin settings (Settings -> Tools -> GitLink -> Domain Registry) you can register custom domains against each host. If you add the domain your using for GitLab, it will automatically detect GitLab as the host when opening a new project.

Malaber commented 1 year ago

Oh, yeah, I found that afterwards but forgot to close this thread. Thanks for the help, maybe others will find it better now.

Also: it does not seem to sync to other IDEs via the official settings sync. (I had to register our gitlab in every IDE manually) This is really no big deal, but maybe that can be changed?

dwightmulcahy commented 1 year ago

Yeah, I noticed I was using 3.3.6 from the IntelliJ Marketplace instead of manually installing the latest version...

Move along; nothing to see here.

gelin commented 1 year ago

It's nice to have a domain alias. For example, in case of GitHub I have to use an alias in ~/.ssh/config:

Host github-work
   HostName github.com
   IdentityFile ~/.ssh/work
   IdentitiesOnly yes

In this case GitLink gives URLs like https://github-work/.... However, it must be https://github.com/....

GitHub always sits in github.com. I just want GitLink to understand that github-work in my case is an alias for github.com.

noel-yap commented 10 months ago

While there's a workaround for this specific issue, I would still like to be able to set a default configuration that specifies the Platform, Fallback Branch (we're still using master), and Remote (since we have a large monorepo, I create one local clone from which other I clone others).