[Proposal] Support for arbitrary user-defined tags, on a per gem basis #6342
rubyFeedback
started this conversation in
Ideas
Replies: 1 comment
-
👀 Looks interesting. Any ida how to make this backwards compatible? The only way I was able to find out was to introduce Gem::Specification.new do |spec|
# ...
spec.metadata["tags"] = "science,education"
end |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey there,
I would like to propose to give us gem authors the ability to define custom tags for use in our projects.
I do NOT propose that these custom tags are ENTIRELY arbitrary, but instead to provide a list of
allowed tags, and maintain these in a .yml file or something like that. However had, we should have
an official policy in place when a new tag may be added (or removed, but adding should be easier).
Something like "one person proposing it, two more to support it" or something like that; the initial
listing should be fairly extensive, if possible.
So, what do I mean with this, anyway?
Well - look at ruby toolbox: https://www.ruby-toolbox.com/.
I would like to have something like this for my projects too, to define what my project is about.
For instance, my multimedia_paradise gem is mostly about video and audio related data, so
I'd like to have functionality for a search-entry (on rubygems.org or something like that),
where people searching for a category/tag get results fitting to that theme at hand.
Take one of my other gems, called chemistry_paradise: https://rubygems.org/gems/chemistry_paradise
It started as a chemistry-toolkit, a hobby project (which it still is).
However had, I recently changed it to integrate another project, called weather (or "wetter" in
german).
Today as I am working on some different assignment tasks, I have to do various calculations in
regards to physics. So I thought of adding ruby code that helps me here. But ... where do I want to
put it? Normally I dump this stuff into my main gem (roebe), but it does not fit there. I'd rather
group this into science/math since it is just calculations really.
I decided I want to rename chemistry_paradise into science_paradise or something like that
eventually, at a later point in time, where I can bundle all, or most of my, science-related code. At
the least chemistry AND physics. But for that I'd have to deprecate/abandon chemistry_paradise. Users
may not find the new gem name because it is different. (I could maintain the old gem, but I hate
maintaining dead projects; I'd rather work on my forked off project as-is.)
Via tags I could tag "science" onto it, which is correct IMO, and then people could search
for it - on ruby toolbox, or better, on rubygems.org. So this suggestion also tries to
combine a better SEARCH functionality for rubygems.org, but I first want gem itself
to allow support of tags.
Optionally we could bypass the restriction of tags described above, but some people will
tag their gem with garbage, and then other users get garbage results too. So I dunno,
perhaps we should also add a limitation how many tags can be used, and we approve
new tags in a semi-loose policy, e. g. "if you have a valid use case, that means it is
ok to add a tag". Or something like that.
Anyway - the important TL;DR here is that we should get a way to tag our gems.
Something like different categories, a bit how the ruby toolbox works.
Beta Was this translation helpful? Give feedback.
All reactions