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

Copy File Path to the Clipboard (Relative) #466

Closed
edridgedsouza opened this issue Feb 23, 2021 · 3 comments
Closed

Copy File Path to the Clipboard (Relative) #466

edridgedsouza opened this issue Feb 23, 2021 · 3 comments
Assignees
Labels
feature request Feature request nice to have A feature request that is nice to have (lower priority)
Milestone

Comments

@edridgedsouza
Copy link

edridgedsouza commented Feb 23, 2021

When examining a given commit, sometimes you'll want to use the command line to run git show REVISION:path/to/file. Currently, it's easy to copy the full commit hash to the terminal for this purpose. However, if you click the button for "Copy File Path to the Clipboard" within a given commit, it gives the absolute path rather than the relative path for the repository, which is what git show expects. This is relatively minor, and you can get this from the file tree anyway with some effort, but an extra option to copy the relative path in addition to the file path would be convenient since it'd be right in the git graph window next to the revisions you care about.

Providing examples for a Jupyter notebook, which I wanted to inspect in my terminal since "View File at this Revision" kept trying to run the VSCode jupyter extension (which isn't working for past revisions apparently) instead of opening it as plaintext.

image
image
image
image

@edridgedsouza edridgedsouza added the improvement An improvement to existing functionality label Feb 23, 2021
@mhutchie mhutchie changed the title "Copy File Path to the Clipboard" should include option for relative path Copy File Path to the Clipboard (Relative) Feb 23, 2021
@mhutchie mhutchie added feature request Feature request nice to have A feature request that is nice to have (lower priority) and removed improvement An improvement to existing functionality labels Feb 23, 2021
@mhutchie mhutchie added this to the v1.30.0 milestone Feb 23, 2021
@mhutchie
Copy link
Owner

Hi @edridgedsouza,

Thanks for raising this feature request, it would definitely be useful to have the option to copy the relative path of a file, in addition to the absolute path!

I'll include this in an upcoming release of Git Graph.

mhutchie added a commit that referenced this issue Feb 28, 2021
@mhutchie
Copy link
Owner

mhutchie commented Mar 3, 2021

This will be available in v1.30.0.

If you'd like to use it before the next release, you can download v1.30.0-beta.0, and install it following the instructions provided here.

@mhutchie mhutchie closed this as completed Mar 3, 2021
@mhutchie
Copy link
Owner

mhutchie commented Mar 3, 2021

I've added the option to the right-click context menu for files in the Commit Details / Comparison Views:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Feature request nice to have A feature request that is nice to have (lower priority)
Projects
None yet
Development

No branches or pull requests

2 participants