Skip to content

Allow extra searchable metadata in package - #234

Merged
ericmj merged 1 commit into
hexpm:masterfrom
mobileoverlord:meta_search
Jun 16, 2016
Merged

ericmj merged 1 commit into
hexpm:masterfrom
mobileoverlord:meta_search

Conversation

@mobileoverlord

@mobileoverlord mobileoverlord commented May 31, 2016 •

Copy link
Copy Markdown
Contributor

WIP. This needs to get tracked alongside associated commits in hex_web.

The idea is that we would like to allow passing extra metadata about the package which can be searched upon using the search api on hex_web.

For example,

defmodule ReleaseMeta.Mixfile do
  def project do
    [app: :release_c, version: "0.0.3",
     description: "foo",
     package: [files: ["myfile.txt", "missing.txt", "missing/*"],
       licenses: ["Apache"],
       links: %{"a" => "b"},
       maintainers: ["maintainers"],
       extra: %{"bar" => "baz"}]]
  end
end

It seems that in order to apply a search index to additional meta keys, we would have to apply it to a known key like :extra. This also reduces complexity of the top level spec.

To search this data we would construct a search path like path: "extra/bar", search: "baz".

Tracked alongside
hexpm/specifications#6

@ericmj

ericmj commented May 31, 2016

Copy link
Copy Markdown
Member

Looks good. Will wait with merging until we are ready on the server side also.

Along with updates to hex_web we need to update this file in the specs with the new optional attribute: https://github.com/hexpm/specifications/blob/master/package_metadata.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants