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

Allow to custom sort pins #342

Open
p0deje opened this issue Dec 27, 2021 · 25 comments
Open

Allow to custom sort pins #342

p0deje opened this issue Dec 27, 2021 · 25 comments
Labels
enhancement New feature or request

Comments

@p0deje
Copy link
Owner

p0deje commented Dec 27, 2021

I would like to suggest a feature. Could you please add the ability to custom sort the saved pins? If this is not possible, maybe they could sort by the shortcut letter? Or they can sort by the title of the pin alphabetically?

@p0deje p0deje added the enhancement New feature or request label Dec 27, 2021
@dr-dimitru
Copy link

Please add support for sorting pressing control + + arrow key up/down
In the same way as sorting works in Notes.app and Sublime Text.app

@p0deje
Copy link
Owner Author

p0deje commented Aug 17, 2022

@dr-dimitru I tried pressing this in Notes.app and it didn't change sorting for notes at all. Can you be more specific?

@dr-dimitru
Copy link

  1. Create a list in a note
  2. Sort pressing control + + arrow key up/down

@p0deje
Copy link
Owner Author

p0deje commented Aug 17, 2022

But this list is unsorted, whilst pins are sorted in the same way as all other records based on Preferences / Storage / Sory by setting.

@dr-dimitru
Copy link

You're right, what I described called "reordering".
I'd be glad having reordering implemented, should I create separate issue?

@dr-dimitru
Copy link

I found #441 initially and "manual sorting" sounds like "reordering" and I thought that's what I was looking for

@p0deje
Copy link
Owner Author

p0deje commented Aug 18, 2022

What if it's just sorted alphabetically by pin letter?

@dr-dimitru
Copy link

I'd vote for default sorting based on usage

@p0deje
Copy link
Owner Author

p0deje commented Aug 18, 2022

Usage meaning what? Number of copies?

@dr-dimitru
Copy link

Number of copies?

Exactly

@p0deje
Copy link
Owner Author

p0deje commented Aug 18, 2022

Have you tried enabling this in Preferences?

@dr-dimitru
Copy link

@p0deje I don't see such option. I'm on Version 0.23.0 (12) from AppStore

@p0deje
Copy link
Owner Author

p0deje commented Aug 18, 2022

It's in Preferences / Storage. It would apply to all history items - not just pins.

@dr-dimitru
Copy link

It would apply to all history items - not just pins.

This is the reason why I have it OFF

@GerZah
Copy link

GerZah commented Feb 22, 2023

I'd like to unearth this issue. My use-case is that Maccy is disabled at all times, unless I'd like to add a new text-blob. I've got <10 to choose from. I've pinned them, to prevent accidental deletion.

Looking at the sqlite database, like so:

sqlite3 ~/Library/Containers/org.p0deje.Maccy/Data/Library/Application\ Support/Maccy/Storage.sqlite "select * from ZHISTORYITEM order by Z_PK desc;"

presents the items in the exact same order as given in the menu.

I would just love to be able to re-order the items. As someone said above: control + + arrow key up/down would be just awesome.


… Suggestion: If I'd have to code that, I'd add a Z_WEIGHT field to the ZHISTORYITEM table, and use that as a potential sort order for pinned items.

@mithunsridharan
Copy link

What if it's just sorted alphabetically by pin letter?

This is a feature I'd vote for.

@Wild5au
Copy link

Wild5au commented Oct 6, 2023

Thank you for the quick response! So sorry, it's still not clear to me how this feature is accessible - is it the suggested CTRL + COMMAND + arrow up or down combination? I can't seem to get that to work when I select a pin in the Preferences/Pins panel.

@p0deje
Copy link
Owner Author

p0deje commented Oct 6, 2023

@Wild5au This feature is not implemented yet.

@Wild5au
Copy link

Wild5au commented Oct 6, 2023

Got it - thank you kindly for clarifying.

@The111
Copy link

The111 commented Feb 17, 2024

Huuuuuge +1 to this feature request. My use case is that I have around 30 long complex strings I want to save for frequent access. I want them to ALWAYS appear in the same order, and I cannot do this with any of the 3 existing sort options. I have an idea for a hack that might make this easier. Is the stored data editable by the user? If so I can just edit the "first copied time" of any of my pins to force them into the order I want. Please let me know where this userdata is located, I'm having a hard time finding it, I don't know the MacOS file layout very well. Thanks! Other than the sorting issue, this is an amazing tool.

@The111
Copy link

The111 commented Feb 20, 2024

Update to the above, I was able to edit the sqlite files and force reordering in the way that I want by changing the ZFIRSTCOPIEDDAT values. This is a hack, but it works. Now a new shortcoming seems to be that I can only have 26 pins, since they seem to be required to have a keybinding. Why? Can this requirement be removed please?

@p0deje
Copy link
Owner Author

p0deje commented Feb 23, 2024

Why? Can this requirement be removed please?

There shouldn't be a requirement like that - after you're out of letters, there is supposed to be letterless pins available. Can you please record a video showing the problem?

@The111
Copy link

The111 commented Feb 23, 2024

Thanks for the response! Unfortunately I can't record a video since all my pins are strings that can't be publicly shared. But I will note that if I have 26 pins lettered a-z, and I try to pin a 27th thing, it does indeed work as a "letterless pin" as you say... but only for the remainder of that app session. If I close and reopen the app, the new 27th pin is no longer there. Maybe this is related to the fact that I've mucked with the DB manually (as I've noticed if I do that mucking carelessly, it can break other things). Not sure.

@p0deje
Copy link
Owner Author

p0deje commented Feb 23, 2024

I've just tried pinning 26+ items and then quitting/opening Maccy, the letterless pins are still there.

Screenshot 2024-02-23 at 10 32 27

@The111
Copy link

The111 commented Feb 23, 2024

Thanks for confirming that. Sounds like it probably is related to my DB hacking. By really strange coincidence, I happen to have exactly 26 pins now, and these pins are pretty much the only reason I'm using Maccy. I don't care about ephemeral strings. So my request for more than 26 was basically future-looking.

I had to try my DB hacking multiple times to finally get to the state I'm in now where it works perfectly with the 26 things I have pinned (in the order that I want them). Any time I screwed up the DB, I had to wipe it and start over. So I'm not keen to mess with it anymore, it sounds like I'll have to be content with what I have.

But I'll note that if you added the ability to assign a manual fixed sort order to your pins, then I wouldn't have to do these hacks. Thanks again for your consideration! It is working great for me even with my current issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

6 participants