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

Path/Name copy options ( Feature request ) #156

Open
ghost opened this issue Nov 10, 2018 · 1 comment
Open

Path/Name copy options ( Feature request ) #156

ghost opened this issue Nov 10, 2018 · 1 comment

Comments

@ghost
Copy link

ghost commented Nov 10, 2018

Would be awesome to be able to copy the path of a highlighted file while navigating without having to open the file itself. Simply navigate around, copy an image files ( Relative path ) for example and then exit out and paste that into your code.

This would be great for web development for those who do not want to install the ide-html etc.. packages.

It could of course have countless other uses.

One package that implements this functionality already is
https://github.com/msansoni/atom-path-copy

It has the options to choose many dif types of paths, file names etc.. all of this functionality via the navigation offered by Advanced open file would make for a great combo.

Would be nice to have options to right click and select copy options similar to the atom-path-copy from within the Advanced open file window as well as be able to set keybinds to do it directly from withing the advanced-open-file window.

To take it even a step further than atom-path-copy, it would be amazing if you could copy the relative path to the file based on the active pane you are in when you activate advanced-open-file.. meaning you could even copy paths up folders like ../../css/styles.css for example.

In atom-path-copy he is calling "Relative path" based on the actual "Project path" and doing something weird for his "Project path" I would scrap his style project path, use "Project path" for the actual project path based on the root of the project, then have a relative path feature as described just above.

To sum it up, these would be the features requested

  • Copy file name ( does not include type: example: test ) [ Ctrl-alt-n]
  • Copy file full name ( includes type: example: test.scss ) [ Ctrl-alt-f]
  • Copy full path ( path based on the desktop or OS root folder ) [ Ctrl-alt-a]
  • Copy relative path ( based on the pane that is active when you activate advanced-open-file ) [ Ctrl-alt-r]
  • Copy project path ( based on the location of the projects root folder ) [ Ctrl-alt-p]
  • It would also be nice if you could choose the trailing slash used, since windows uses \ as default and in some cases a / is required or desired. ;-)

Just a thought for a feature that I think would make advanced-file-open even more amazing!

Thanks for reading!
Slater

@ghost ghost changed the title Path copy options ( Feature request ) Path/Name copy options ( Feature request ) Nov 10, 2018
@Osmose
Copy link
Owner

Osmose commented Nov 11, 2018

Thanks for filing the issue!

I think a keyboard shortcut for copying the full path of the highlighted file is reasonable. The relative path from project root also seems reasonable. The others I'm less interested in.

I won't be working on it but would happily review a patch adding these two shortcuts.

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

No branches or pull requests

1 participant