Hugo documentation in one long searchable page

Hi. I created a python script to pack the documentation in one long page. I did this to make it easier for myself to search and navigate the docs.

This way I avoid clicking back and forth between pages, and I can CTRL+F for key words. I only included the files I read frequently.

I hope you don’t mind. If anyone wants to use the documentation or tweak the script, feel free.

5 Likes

awesome! I’d love to see this as a feature for hugo in general – I need to print out a PDF of our site for documentation & editing, rather than separate pages.

It wouldn’t be too hard to do if someone wants to add a new command to do it.

I can see how to do that using the list template for a type since that returns all the content for that type or by adding a tag like “include_in_one_long_searchable_page” and creating a layouts/category.terms.html or doing this from the main index.html.

Is there a simpler way without updating Hugo itself?

The other way to get the documentation offline is:
git clone https://github.com/spf13/hugo/
cd hugo
cd docs
hugo server
Server now listens on http://localhost:1313/ with all the information here:
http://localhost:1313/overview/introduction/

1 Like