Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Algolia remark #28

Merged
merged 2 commits into from
Feb 5, 2023
Merged

Add Algolia remark #28

merged 2 commits into from
Feb 5, 2023

Conversation

Carlgo11
Copy link
Member

@Carlgo11 Carlgo11 commented Jan 10, 2023

Algolia requires open source projects to in some way display on the page that Algolia provides the search functionality. I think this way is a non-intrusive way of doing that.

In exchange for using Algolia for free, we ask that you place a small "Search by Algolia" logo in your search results or on your site where people can see it. The logo should link to https://algolia.com.

Source: https://www.algolia.com/for-open-source/

Screenshots

Unfocused:

Focused:

@phallobst
Copy link
Member

When I tested this locally, the /algolia.svg image got a 404 (so the link is there, but invisible). I checked with hugo --renderToDisk, but the file was not present inside the target directory. Not sure if something is missing or wrong on my side... 🤷‍♂️

@Carlgo11
Copy link
Member Author

Carlgo11 commented Feb 5, 2023

That's very odd. I cloned the branch again and it works for me.
What hugo version is that? I don't see a --renderToDisk argument for hugo 0.110.0.
I used the following build script:

#!/usr/bin/env sh

# Generate content
echo "Generating content"
ruby scripts/generate_entries.rb &
ruby scripts/generate_regions.rb &
wait

# Build site
echo "Building static site"
hugo serve
2023-02-05.21-38-18.mp4

@Carlgo11 Carlgo11 enabled auto-merge (squash) February 5, 2023 20:51
@phallobst
Copy link
Member

I had version 0.92.0 before - now I installed version 0.110.0 and get this error when building:

Error building site: [...] execute of template failed: template: partials/regions.html:3:12: executing "partials/regions.html" at <sort . "name">: error calling sort: sequence must be provided

Weird...

@Carlgo11
Copy link
Member Author

Carlgo11 commented Feb 5, 2023

I had a similar issue earlier. Solved it by running scripts/generate_entries.rb and scripts/generate_regions.rb.

@Carlgo11 Carlgo11 merged commit 745772c into 2factorauth:master Feb 5, 2023
@Carlgo11 Carlgo11 deleted the algolia-remark branch February 5, 2023 23:46
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