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

Directories with valid post names should be filtered out #875

Merged
merged 2 commits into from Apr 7, 2013

Conversation

Projects
None yet
4 participants
@parkr
Member

parkr commented Mar 19, 2013

@GrahamDennis ran into a problem (detailed in #488) where directories disguised as posts were read in as posts. Problem is, Post.initialize would crap out and thus Jekyll would be unsuccessful in processing the site.

This patch remedies this problem.

@parkr

This comment has been minimized.

Member

parkr commented Mar 19, 2013

Also, I explored several other options, but this was the one which was "DRYest".

@parkr

This comment has been minimized.

Member

parkr commented Mar 19, 2013

Build error is just the StackOverflowError we see every once in a while. Cucumber is weird.

@tombell

This comment has been minimized.

Contributor

tombell commented Mar 20, 2013

This solution seems fine. 👍

categories = %w(bar baz category foo z_category publish_test win).sort
assert_equal posts.size - 1, @site.posts.size
assert_equal posts.size, @site.posts.size

This comment has been minimized.

@parkr

parkr Mar 20, 2013

Member

@tombell Do you know why it was posts.size - 1 in the previous version? Couldn't figure it out.

This comment has been minimized.

@tombell

tombell Mar 20, 2013

Contributor

I don't look at previous tests unless I wrote them or something broke.

This comment has been minimized.

@parkr

parkr Mar 20, 2013

Member

Neither do I! :-) This one broke, which is weird. The previous test uses posts.size - 1 and passes. Weiiiiiird

@mojombo

This comment has been minimized.

Contributor

mojombo commented Apr 7, 2013

:shipit:

@tombell

This comment has been minimized.

Contributor

tombell commented Apr 7, 2013

👍

parkr added a commit that referenced this pull request Apr 7, 2013

Merge pull request #875 from mojombo/posts-cant-be-dirs
Directories with valid post names should be filtered out

@parkr parkr merged commit 0f2c9d2 into master Apr 7, 2013

1 check passed

default The Travis build passed
Details

@parkr parkr deleted the posts-cant-be-dirs branch Apr 7, 2013

parkr added a commit that referenced this pull request Apr 7, 2013

@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.