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

Newlines don't work #3

Open
Unscrewed opened this issue May 25, 2016 · 3 comments
Open

Newlines don't work #3

Unscrewed opened this issue May 25, 2016 · 3 comments

Comments

@Unscrewed
Copy link

Using \n does not work to create a new line. Is this a bug? It would be EXTREMELY useful for me!

@majido
Copy link
Owner

majido commented May 26, 2016

I think the service just dumps the content of clipboard as a single log message which shows up in a single line. It should be fairly straight forward to split the text into lines and log these lines individually.

Do you want to send a pull request to do this? I will merge it in.

On May 25, 2016, at 4:41 PM, Unscrewed notifications@github.com wrote:

Using \n does not work to create a new line. Is this a bug? It would be EXTREMELY useful for me!


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub

@Unscrewed
Copy link
Author

Unscrewed commented May 26, 2016

I think the service just dumps the content of clipboard as a single log message which shows up in a single line. It should be fairly straight forward to split the text into lines and log these lines individually. Do you want to send a pull request to do this? I will merge it in.

@majido Thanks for your fast response! I tried to download android studio and import the project files and do it myself, but I really have no clue what I'm doing to be honest. If you are willing to make this feature, I will surely donate you if you have PayPal! If you are interested of course.

I have a chatbot that needs to reply fast, and now I have to set clipboard, paste, press enter for a new line, set clipboard again with the new line, paste, press enter, etc... which is a painfully long and inefficient process. I'd rather just be able to set all lines at once.

Thanks in advance!

@Spikatrix
Copy link

Newlines already work, you just need to send them properly. Like so:

NL=$'\n'; am broadcast -a clipper.set -e text "Line one${NL}Line two"

or better:

am broadcast -a clipper.set -e text "$(echo "Line one\nLine two")"

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

3 participants