This repository was archived by the owner on Jun 21, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Use `GitHub.OpenFromUrl <url>` from the VS Command Window to clone a target URL. This spike uses existing `ShowReCloneDialog` method.
Expect Owner="github", RepositoryName="VisualStudio" from: https://github.com/github/VisualStudio/blob/master/README.md Not Owner="master", RepositoryName="README.md"
Only files on master branch are currently supported.
Trim line number when using FindPath.
Prototype this using the happy path where we use the default repository location.
If we're already in an appropriate context, simply open the target file.
The following URL will now have an owner of "owner": https://github.com/owner Previously it would make a repository name of "owner".
Add code to parse window titles and find the GitHub context from the topmost Chrome browser.
If there is no URL in the paste buffer, use the GitHub context from the topmost browser.
When browser is in the context of a file, open a file with the same name after repository is opened.
OpenFromUrlCommand now works with GitHubContext objects rather than directly with URLs.
Visual Studio line numbers are zero based.
Assume that branch names don't contain a '/' (sic).
Navigate to line when line number information is available.
Search for Chrome then Firefox windows. Need to find a way to search in order of height.
Previously highlighting only worked when a range was selected. Use VsShellUtilities.OpenDocument instead of DTE.ItemOperations.OpenFile. Factor TryOpenFile into GitHubContextService.
Don't continue to column 0 on the line below.
GitHub URLs combine branches/SHAs and tree paths. For example: https://github.com/github/visualstudio/tree/master/src Git would represent "master/src" as the tree-ish "master:src". Because looking at the URL we don't know where the branch stops and the tree starts, "master/src" is being stored as the TreeishPath property.
This enables round tripping between `Copy link to clipboard` and `Open from GitHub`.
This is a mirror of `GitHub.CopyLink`.
Check that object exists before navigating.
Currently doesn't support opening/cloning repo so show message instead.
Interface shouldn't depend on LibGit2Sharp and return stale GitObject.
This will let us give user more meaningful warnings.
Warn if there have been chances to the target file between when the permalink was created and the working copy.
We don't want to navigate to a stale source file, so show the original blob using the AnnotateFile view.
This method only knows how to resolve blobs (not commits or trees).
Everything now uses ResolveBlob.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
UPDATE
I need update the description for this PR!
Please use
Code context > GitHub > Open from clipboard
rather thanFile > Open > Open from GitHub
.Original spike
Clone or open any repository, file or PR from a GitHub URL.
How to use:
File > Open > Open from GitHub
This command will:
Currently this will happen with no further user interaction. The repository will be opened from the following default path:
<DefaultClonePath>\GitHubCache\<RepositoryOwner>\<RepositoryName>
The location will be unique and won't stomp over existing repositories. Need to think about UI for selecting a non-default repository location.
Related: #1757