git-scm.com icon indicating copy to clipboard operation
git-scm.com copied to clipboard

search covers only dynamic content

Open peff opened this issue 8 years ago • 6 comments

We index the book and manpage content for the search feature, but not any of the static content. So searching for "trademark", for example, will not turn up the trademark page (nor will "downoad" find the download page, etc).

We probably could feed the static pages into the index, but I'm not sure of the details.

peff avatar Jan 04 '18 03:01 peff

There are a few search related topics from a deprecated TODO file that should be considered when addressing this issue (https://github.com/git/git-scm.com/blob/2c4281d6bfd1fab54cf6f1c8a47318f3c49607f1/TODO.txt) :

  • weighting
    • weigh porcelain over plumbing
    • weigh by total views
  • add book content to search
  • add video shownotes to search
  • add stackoverflow to search
  • search internal pages, too

Probably a few can be discarded (adding stackoverflow to search seems an overkill for instance), but let's reflect on them when implementing

pedrorijo91 avatar Feb 21 '18 22:02 pedrorijo91

Hi. What does the search in the upper right of the site? It always returns Sorry, no search matches no matter the browser used and what I search. It is a bug ? Thanks.

cornel001 avatar Nov 23 '18 11:11 cornel001

thanks for reporting @cornel001 , it seems like a bug.

@peff I have a vague memory of we having a similar problem due to the ES instance being down?

pedrorijo91 avatar Nov 23 '18 13:11 pedrorijo91

I never figured out the exact reason, but yes, a year or so ago the search database stopped working, which was solved by doing a rake search_clear && rake search_index && rake search_index_book. Unfortunately, that doesn't seem to work anymore, as the tire gem depends on an outdated rest-client (I get KeyError: key not found: :ciphers; some searching reveals that this is fixed in more recent versions).

The tire gem itself is deprecated. I suspect the right path forward is moving to a better supported elasticsearch client gem.

peff avatar Nov 26 '18 18:11 peff

on the Tire README file they recommend to look at https://github.com/elastic/elasticsearch-rails

pedrorijo91 avatar Nov 26 '18 18:11 pedrorijo91