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 config option to ignore code blocks for word count #2599

Merged
merged 3 commits into from
Aug 9, 2024

Conversation

Walnut356
Copy link
Contributor

@Walnut356 Walnut356 commented Aug 6, 2024

Sanity check:

  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?

Code changes

(Delete or ignore this section for documentation changes)

  • Are you doing the PR on the next branch?

If the change is a new feature or adding to/changing an existing one:

  • Have you created/updated the relevant documentation page(s)?

Some articles with lots of code (usually meant to be skimmed, or only optionally read/referenced via <details>) end up having hugely inflated word-counts. In one case, due to a particularly nasty ASM block in <details>, code blocks account for 1/3rd to 1/2 of the ~10k words reported for the article.

@Keats
Copy link
Collaborator

Keats commented Aug 6, 2024

I think I would just skip the code blocks without providing an option in the config.

@Keats Keats merged commit 5e67227 into getzola:next Aug 9, 2024
5 checks passed
@Keats
Copy link
Collaborator

Keats commented Aug 9, 2024

Thanks!

reujab pushed a commit to reujab/zola that referenced this pull request Aug 14, 2024
* update docs

* add config option, logic, and tests

* remove config option
Keats pushed a commit that referenced this pull request Aug 15, 2024
* update docs

* add config option, logic, and tests

* remove config option
welpo added a commit to welpo/osc.garden that referenced this pull request Aug 16, 2024
It no longer counts code blocks with Zola 0.19.2: getzola/zola#2599
berdandy pushed a commit to berdandy/azola that referenced this pull request Sep 17, 2024
* update docs

* add config option, logic, and tests

* remove config option
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