Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: Close diff and open working file... #236

Closed
joerohde opened this issue Dec 21, 2017 · 5 comments
Closed

Request: Close diff and open working file... #236

joerohde opened this issue Dec 21, 2017 · 5 comments
Assignees
Labels
feature New feature or request

Comments

@joerohde
Copy link

  • GitLens Version: 7.00
  • VSCode Version: 1.19.1
  • OS Version: Win 10, OSX 10.13.2

When a diff is open, it would be ideal to have a command that can close it and replace with the working file. If this exists, I'm missing it. 'Git.openfile' only works if the diff window contains the working file. Once you start rummaging around in diff this command become a no-op.

Even if I just had 'gitlens.openWorkingFile' I would be happy since I could write an extension to grab the current document url, run the command and close the previous diff doc.

Alternatively, if there is any way for an extension to grab the working file info/url from a gitlens diff that would also work, but once the diff has 2 temp file urls, I don't see a reasonable way to derive what working file they are sourced from (if any).

Thanks - love the extension.

@eamodio eamodio self-assigned this Dec 21, 2017
@eamodio eamodio added this to the Soon™ milestone Dec 21, 2017
@eamodio eamodio added the feature New feature or request label Dec 21, 2017
@eamodio
Copy link
Member

eamodio commented Dec 21, 2017

@joerohde Excellent suggestion! I find myself wanting the same all the time! :)

@joerohde
Copy link
Author

Thanks - I have tremendous respect for your work. Several times I've dropped down to writing an extension because there was something I wanted to do from the 'diff window' or with the SCM model thinking 'surely there is going to be something hanging off the document' or 'surely I can get info/metadata about the 2 sides of the diff pane'. While these things may be possible, I have usually run screaming into the night. As near as I can see the vscode team seems to have a strong desire to eventually expose a general SCM api, but it's hit the stage of 'always going to prioritized under current work, but we aren't going to expose what we have since it's not general enough'.

@eamodio
Copy link
Member

eamodio commented Dec 21, 2017

Appreciate the kind words. Yeah, there are definitely challenges with the current api (mainly just need more exposed), but the vscode team is thoughtful and methodical when it comes to the apis they want to support. We'll get there eventually ;)

@joerohde
Copy link
Author

Working great - Thanks!

@eamodio eamodio removed this from the Soon™ milestone Jul 19, 2019
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants