Support installing extensions from git URLs
- Dominant language
- TypeScript
- Stars
- 193k
- Forks
- 42.4k
- PR merge metrics
- PR metrics pending
Description
## Feature Request
### Description
Allow VS Code to install extensions directly from git URLs, similar to how modern package managers (npm, pip, cargo, etc.) support installing dependencies from git repositories.
### Current Behavior
Currently, extensions can only be installed from:
- The VS Code Marketplace
- Local VSIX files
- The command line using a marketplace extension ID
### Desired Behavior
Users should be able to install extensions directly from git repositories using a git URL, similar to:
```
code --install-extension git+https://github.com/user/vscode-extension.git?gitSubdir=/ext/#branch-or-tag
```
Or configured in a `.vscode/extensions.json` manifest:
```json
{
"extensions": [
"ms-python.python",
"git+https://github.com/user/custom-extension.git?gitSubdir=/ext/#branch-or-tag"
]
}
```
### Use Cases
- Installing extensions from forks or development branches
- Installing private extensions from private repositories
- Installing unreleased or experimental extensions
- Managing corporate/team-specific extensions outside the marketplace
- Enabling reproducible development environments with specific extension versions
### Benefits
- **Flexibility**: Developers can use cutting-edge or customized extensions
- **Reproducibility**: Teams can pin exact git commits or tags
- **Privacy**: Private extensions can be versioned and distributed via git
- **Development**: Easier local testing and contribution to extension development
### Examples
This pattern is already well-established in popular package managers:
- **npm**: `"package": "git+https://github.com/user/repo.git#commit/branch/tag"`
- **pip**: `package @ git+https://github.com/user/repo.git@tag`
- **Cargo**: `package = { git = "https://github.com/user/repo.git", tag = "v0.1.0" }`
- **Go**: `require github.com/user/repo v0.0.0-20240101120000-abc123def456`
### Implementation Considerations
- Support standard git URLs (https://, ssh://, git+https://)
- Support branch, tag, and commit references
- Handle authentication for private repositories
- This could be handled automatically by ssl?
- Validate extension integrity
- Cache downloaded extensions appropriately
- Update mechanism for git-sourced extensions along with deep dependencies with git
- Semver tag wildcard?
Contributor guide
Assessment
This issue has not been assessed yet.