Clipboard Manager for Touch Bar

Hey there, I managed to write some scripts for a clipboard manager (image attached) but it only works with anything that is copied through ⌘+C, meaning the screenshots overwritten to the clipboard (⌘+⇧+⌃+3), and anything copied through "right-click and copy" won't show up in the touch bar (there are no action trigger for these two in BTT).

Right now, I use a third-party clipboard manager that has a keyboard shortcut capability to recall clipboard history.

Since BTT has a built-in clipboard manager, I was wondering if the devs (@Andreas_Hegenberg) could please add scripting functionality to it so it would be possible to call clipboard history.

(or you could just make a clipboard manager widget for touch bar to make our lives easier :grin:)

Thank you in advance :slight_smile:

I would love this and immediately make a menu bar widget for clipboard history. This is definitely a long-requested feature given that BTT already has clipboard management features.

@GoldenChaos Yeah there is a clipboard manager but it doesn't allow for scripting meaning there is no way to read or recall let's say the 3rd item saved in the clipboard manager.

Since I made the post, I came up with a ghetto solution; I put a conditional statements on the first widget button that constantly compares the current clipboard with the one that was most recently saved into a temporary file (let's call it temp1.txt)

This way you can actually fix the issue of screenshot in the clipboard and "right click and copy" but one issue still persists: if you copy the SAME item twice via "right click and copy" there is no way to know that it's a new entry. In other words, the clipboard history updates but the widget button label does not. Do you have a workaround for that in mind?

I'm already working on a clipboard manager widget for the Touch Bar, it should be out sometime next week.

If you want to paste a specific item from the current clipboard manager (e.g. eh 3rd) you can use the predefined action "Paste specific items from clipboard manager"

3 Likes

You're on fire lately :fire:

@Andreas_Hegenberg thank you! that solves the issue of having to use a third-party app to retrieve the clipboard history, however, the other issue still remains. Regardless, this whole post becomes irrelevant now that you are working on a widget yourself. Thanks again.

cheers :slight_smile:

BTT 3.179 alpha adds a basic clipboard manager widget :slight_smile:

2 Likes

@Andreas_Hegenberg Love it! I'll mess around with it and update you if there are any bugs or suggestions. So far looks very smooth and thorough. Thanks once again!!

Got a menu bar widget and group hooked up for this already :slight_smile: it'll be available in the next experimental version, just gotta make a better icon.

1 Like

@Andreas_Hegenberg I noticed that on tapping an old item, it overwrites it on the current clipboard.

It gets confusing because it overwrites the clipboard but it doesn't bring the tapped item to the first item. A few times, I tried to take a quick glance at the first item of the widget to see what it is before hitting ⌘+V but it pasted the wrong item because the clipboard was actually what I had tapped on earlier.

This especially applies to the favorited text. The whole point of favoriting something is to know that its there in the front and you can insert it with a tap. In a way, it's like getting it out of the way of your clipboard by tapping. why would you wanna overwrite it to the clipboard once you tap on it?

to put it into bullet points:

  • add "insert without overwriting clipboard" to 'On Tap' trigger.
  • on "paste with format, plain text, as file, type content, and one line plain text", bring the tapped item to the first item.
  • reconsider "favorite" functionality. My opinion, tapping a favorited item shouldn't overwrite it to the clipboard at all but you could also add a section for "on tapping favorited items".

Hope it makes sense :grin:
So far I haven't found any bugs. I extensively used it yesterday and it ran very smoothly. :smiling_face_with_three_hearts::smiling_face_with_three_hearts:

Thank you once again for yet another great widget. I see this one as something that many people would use on a regular basis. :laughing:

I added two new options in 3.182:

I think they might help you!

1 Like

yup that does it! thank you! and thank you for making me look stupid by summarizing all I said in two sentences... :pensive::grin:

In 3.185 the clipboard manager widget crashes BTT when tapping on any clipboard item, or when copying something to the clipboard while the clipboard manager widget is displayed.

Crash log for @Andreas_Hegenberg: BetterTouchTool_2019-08-23-083336_Lancer.crash (97.8 KB)

mh seems to work fine here, could you post your config?

I'm triggering build 3.186 which moves something to a different thread and may workaround this. If that doesn't help I'll look into it next week. I'm now offline until Sunday evening.

Here you go! I haven't played around with the settings too much but the checkboxes don't seem to change whether or not it crashes.

EDIT: This is severe enough that I'm going to hold off on my next experimental version until this is fixed, since BTT pretty much crashes whenever I copy something. However, when this is fixed the next experimental build of GC is ready :sunglasses:

EDIT2: Pushed out 3.186 anyway - I'm wondering if it's the 1000-item limit I placed on the widget? Is that too high? I basically just want the widget to infinitely scroll as far as the user is willing to go.

@GoldenChaos works fine for me as well :confused:

@GoldenChaos yup 1000 item causes the crash for me as well. I think it's just too high.

Looks like values higher than 64 crash the widget (@Andreas_Hegenberg). This seems like too specific of a number not to be a bug.

I've edited GC 3.186 to set this value to 64 to prevent crashes in the meantime. If you already installed GC 3.186, simply reinstall it :slight_smile:

Imprint | Privacy Policy