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

Don't add a new line at end of "Copy ... to clipboard" #153

Open
Altair31 opened this issue Jul 21, 2017 · 5 comments
Open

Don't add a new line at end of "Copy ... to clipboard" #153

Altair31 opened this issue Jul 21, 2017 · 5 comments

Comments

@Altair31
Copy link

Hi,
I'm facing a little problem with this amazing plugin, it always adds a new line at the end of the clipboard entry.
So when I paste my bash script path in a console, the command is immediately run.

It will be a little (I hope) but useful enhancement to remove this trailing new line character.

OS: Centos 7.3
Eclipse Neon.3 Release (4.6.3)
EasyShell: 2.1.0.v20170508-1844

@anb0s
Copy link
Owner

anb0s commented Jul 24, 2017

Hi, thanks for reporting this!

You can edit the command or create new one with the needed change. Just select "Window -> Preferences -> EasyShell -> (1) Menu -> Copy Full Path to Clipboard". If you want change the behaviour of the original command use "Edit..." (for menu) and again "Edit..." (for command it self). If you want an additional entry for this case use "Copy..." (for menu) and again "Copy..." (for command it self). Now remove the ${easyshell:line_separator} from "Command:"

The original ${easyshell:resource_loc}${easyshell:line_separator}:
image

will be ${easyshell:resource_loc} and you can change the name, e.g. to Full Path (no new line):
image

So if you used "Copy..." then it looks like:
image

You can change all or add new commands in this way!

@anb0s
Copy link
Owner

anb0s commented Jul 24, 2017

... Just want to give the information why i prefer using new-line or some other delimiter in all clipboard commands: I'm using them with one or more selected resources and the resources pathes are delimited by line separator. It can change if future versions if #73 is implemented and delimiter is added as own field with the option "add only if more then one resource selected"...

@Altair31
Copy link
Author

Thanks, I did not see there are some preferences

@jpstotz
Copy link
Contributor

jpstotz commented Aug 25, 2023

Even if this can be configured the default setting is wrong. The command is named "Copy Full Path" and not "Copy Full path and newline". Therefore in my opinion the default newline should be removed as it is unexpected.

For me this feature is important as I want to copy a file path to clipboard and paste it into Java code string. The additional newline is really a pain.

And I don't want to manually configure this for every new Eclipse installation or workspace.

@anb0s anb0s reopened this Aug 31, 2023
@anb0s anb0s added this to the TBD milestone Aug 31, 2023
@anb0s anb0s pinned this issue Aug 31, 2023
@anb0s
Copy link
Owner

anb0s commented Aug 31, 2023

I'm not using eclipse in my daily work anymore and therefore cannot allocate time for it -> any contribution is welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants