vscode-gitlens icon indicating copy to clipboard operation
vscode-gitlens copied to clipboard

Support specifying a port for remotes

Open bitfield opened this issue 6 years ago • 13 comments

Our GitLab server runs on port 8000, so when you right-click on a file and select 'Open File on Remote', or 'Copy Remote Url to Clipboard', the generated URL doesn't work. It looks like this:

https://gitlab.example.com/example/foo/blob/3146b57606b1e727b4cd70e108df2dd51e3a332f/path/to/file

whereas it should be:

https://gitlab.example.com:8000/example/foo/blob/3146b57606b1e727b4cd70e108df2dd51e3a332f/path/to/file

I can't figure out how to configure this in the GitLens settings. I've tried adding this:

    "gitlens.remotes": [
        {
            "domain": "gitlab.example.com",
            "type": "GitLab",
            "urls": {
                "file": "https://gitlab.example.com:8000/..."
            }
        }
    ],

But this seems to have no effect at all on the generated URL. What am I doing wrong?

bitfield avatar Jan 18 '19 12:01 bitfield