omc / searchyll

GNU General Public License v3.0
48 stars 15 forks source link

Provide a means to separate collections #32

Open drusellers opened 6 years ago

drusellers commented 6 years ago

I want to have a means to index all of the content in a jekyll site but then filter on collection when searching.

alranel commented 5 years ago

@drusellers you can assign a default value to each collection in Jekyll config:

collections:
  platforms:
     output: true
     permalink: /:path/

defaults:
  -
    scope:
      path: ""
      type: "platforms"
    values:
      toc: true
      layout: platform
      mykey: platform

mykey gets automatically injected to Elasticsearch, so you can filter by that when searching.