r/applescript • • Feb 03 '21

Automate copy-pasting with AppleScript?

Hi all! This has been haunting me for a long time. So at my job (luckily it’s remote) I have to do a stupid amount of copy-pasting. Years after clicking cmd+c and v (and other shortcuts) has resulted in issues with my left hands fingers and tendons. I’m trying to find ways to do copy-paste without having to press cmd c/v.

Right click copy/paste doesn’t work because it’s too slow and some of the work software don’t support right click. So I thought about automating the keystroke but idk how I can efficiently execute this script so it makes sense.

Ive also tried using gaming mouse with customizable keys but that didn’t work and I’m not about to pay 90-100 bucks on a mouse.

So I know in the settings for Mighty Mouse you can select application as an action for the buttons. So I made a script to simply keystroke command c and another for v but it didn’t seem to execute when it’s from the Mighty Mouse.

Has anyone automated this basic function so that it can be done from the right hand rather than your left?

8 Upvotes

11 comments sorted by

View all comments

Show parent comment

1

u/[deleted] Feb 04 '21

Think you might be out of luck with Mighty Mouse stuff, but I’m fairly confident that the Logitech mice (like the MX Master, MX 3) keys can be mapped through its own application.

You can map three finger clicks in a Magic Mouse with better-touch-tool if you have one.

Also know that in macOS, a lot of times you can just drag selected text.