This repository was archived by the owner on Feb 16, 2023. It is now read-only.
Randomize existing tag colors #709
jovandeginste
started this conversation in
General
Replies: 1 comment 2 replies
-
Brilliant solution. So simple. Seems like it was a good idea to get a color picker in there! |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
When I started using Paperless, I auto-created a lot of tags based on folders where my existing documents were living in. All those tags had the same color. Now, there is an almost endless choice for colors, and new tags get random colors suggested. However, I still have those starting-colors for my 150+ tags.
This little Postgres code randomizes the colors in a consistent way:
Basically, take the first 6 characters of the md5-sum of the name, which is hexadecimal and thus maps to a color. Uniqueness is not guaranteed, but not necessary either.
Okay, I lied: this is not randomized 😉
Beta Was this translation helpful? Give feedback.
All reactions