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 checks that drafts are not added to the sitemap.xml #36

Closed
wants to merge 1 commit into from
Closed

Add checks that drafts are not added to the sitemap.xml #36

wants to merge 1 commit into from

Conversation

DeonHeyns
Copy link

If you have any drafts in your _posts folder they will be added to the sitemap and potentially indexed by the bots

@benbalter
Copy link
Contributor

Any way we could use the new where filter? Perhaps we should implement a where_not filter or similar to support the negative case?

@parkr
Copy link
Member

parkr commented Aug 1, 2014

Good catch! A couple things:

  1. Drafts go in the _drafts directory. Unpublished posts (published: false) != drafts
  2. Drafts will be added to site.posts only if show_drafts: true is set in the _config.yml or if the --drafts flag is filtered. Usually neither is set outside local development

Definitely agree that where could be used more judiciously. As-is, this PR is unmergable, however, as it doesn't represent drafts in Jekyll.

@kleinfreund
Copy link

Note that posts with published: false are not included in the sitemap.

@DeonHeyns
Copy link
Author

Thanks for the feedback, was not aware of the published flag.

@DeonHeyns DeonHeyns closed this Aug 2, 2014
@jekyll jekyll locked and limited conversation to collaborators Feb 27, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants