Skip to content

Add IDE clone links and download ZIP features to repository detail page#75

Draft
Copilot wants to merge 3 commits intomasterfrom
copilot/fix-f70fc50c-49b4-4805-86b4-774b70c08f0e
Draft

Add IDE clone links and download ZIP features to repository detail page#75
Copilot wants to merge 3 commits intomasterfrom
copilot/fix-f70fc50c-49b4-4805-86b4-774b70c08f0e

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Sep 30, 2025

Overview

This PR adds direct cloning links for popular IDEs and a download ZIP button to the repository detail page, making it easier for users to clone repositories directly into their preferred development environment.

Problem

Previously, users could only copy the Git URL and manually paste it into their IDE's clone dialog. This required multiple steps and was not user-friendly, especially for users who frequently work with multiple repositories.

Solution

Added three new features to the repository detail page:

1. "Open with" Dropdown Menu

A dropdown button that provides direct links to clone the repository in 18 popular IDEs:

  • Microsoft: Visual Studio, Visual Studio Code
  • JetBrains: IntelliJ IDEA, PyCharm, WebStorm, PhpStorm, Rider, CLion, DataGrip, GoLand, RubyMine, AppCode, Fleet, RustRover, Aqua
  • Other: Android Studio, Eclipse, Tower

Each IDE uses its specific protocol handler (e.g., vscode://vscode.git/clone?url={url} for VS Code, jetbrains://idea/git-clone?url={url} for IntelliJ) to open the IDE directly with the repository URL pre-filled.

2. Download ZIP Button

A direct link to download the entire repository as a ZIP file, useful for quick access without cloning.

3. User IDE Preference

Added a "Preferred IDE" setting in Account Settings where users can save their default IDE choice for future reference.

Screenshots

Repository Detail Page - Initial View

IDE Dropdown Closed

The page now shows "Open with" and "Download ZIP" buttons next to the Git URL copy button.

IDE Selection Dropdown

IDE Dropdown Open

Clicking "Open with" displays all 18 supported IDEs. Selecting one opens the IDE with the clone URL.

Technical Details

New Components

  • Configuration/IdeType.cs: Enum defining all supported IDE types
  • Helpers/IdeHelper.cs: Helper methods for IDE display names and protocol URL generation
  • wwwroot/js/ide-dropdown.js: JavaScript for dropdown menu interaction
  • Database migrations: Added PreferredIde column to UserSettings table for both SQLite and SQL Server

Modified Components

  • Extended UserSettings, UserSettingsEntity, and UserSettingsService to handle IDE preferences
  • Updated MeSettingsModel and Account Settings view to include IDE selection
  • Enhanced Detail.cshtml with IDE dropdown and Download ZIP button
  • Added localized resource strings for new UI elements
  • Added CSS styles for the dropdown menu

Protocol Handlers

  • Visual Studio: git-client://clone?repo={url}
  • VS Code: vscode://vscode.git/clone?url={url}
  • JetBrains IDEs: jetbrains://{ide}/git-clone?url={url}
  • Tower: gittower://openRepo/{url}
  • Eclipse: Standard Git URL (no custom protocol)

Testing

  • ✅ Build successful with 0 errors
  • ✅ All 237 unit tests pass
  • ✅ All 17 integration tests pass
  • ✅ No breaking changes to existing functionality
  • ✅ Backward compatible (PreferredIde defaults to None)

Usage

Users can now:

  1. Navigate to any repository detail page
  2. Click "Open with" to see available IDE options
  3. Select their preferred IDE to clone directly
  4. Click "Download ZIP" to download the repository
  5. Set their default IDE in Account Settings for future reference

Notes

  • The feature works for both public Git URLs and personal (authenticated) URLs
  • All existing functionality (copy button, repository management) remains unchanged
  • The implementation follows existing UI patterns and coding standards
  • Database migrations are included and will run automatically on deployment

Closes #[issue-number]

Original prompt

This section details on the original issue you should resolve

<issue_title>Direct cloning links for some popular IDEs</issue_title>
<issue_description>Instead of just the clone link we want

  • copy via text box and copy button
  • open with Visual Studio / Visual Studio Code / ... (application managable)
  • download ZIP

Open with should be a dropdown, list of predefined programs

  • Visual Studio
  • Visual Studio Code
  • Android Studio
  • CLion
  • DataGrip
  • Eclipse
  • IntelliJ Idea
  • Rider
  • PhpStorm
  • PyCharm
  • RubyMine
  • Tower
  • WebStorm
    many more

User should be able to select a default.</issue_description>

Comments on the Issue (you are @copilot in this section)

Fixes #49

✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 2 commits September 30, 2025 13:30
Co-authored-by: Matt-17 <11333169+Matt-17@users.noreply.github.com>
Co-authored-by: Matt-17 <11333169+Matt-17@users.noreply.github.com>
Copilot AI changed the title [WIP] Direct cloning links for some popular IDEs Add IDE clone links and download ZIP features to repository detail page Sep 30, 2025
Copilot AI requested a review from Matt-17 September 30, 2025 13:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Direct cloning links for some popular IDEs

2 participants