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

Categories & tags show locally but not on github pages #329

Closed
trevorstephens opened this issue May 29, 2016 · 14 comments
Closed

Categories & tags show locally but not on github pages #329

trevorstephens opened this issue May 29, 2016 · 14 comments
Assignees

Comments

@trevorstephens
Copy link

As the title says, when I build locally the category and tags display at the bottom of the post, but when I push to github, they are missing. Repo here.

Example outputs:

Locall y @ http://127.0.0.1:4000/ramblings/a-journey-begins/:

untitled

Github:

untitled2

@trevorstephens
Copy link
Author

BTW, really love the theme 👍 thanks for all your hard work!

Also worth mentioning, the tags/categories are being recognized by the archive pages:

@mmistakes
Copy link
Owner

Quick glance at your repo and nothing is standing out to me. Not sure what's going on. The fact that it works locally and not when pushed is strange, I'm stumped.

The only thing I can think of is the Liquid conditonals that trigger category and tag lists aren't being met. The GitHub Pages gem was recently updated so maybe something changed or broke. But I doubt it since they're working fine for the MM theme demo that is hosted on GH same as your site.

You don't get any error reports or anything when pushing?

@trevorstephens
Copy link
Author

Thanks for the quick response Mike!

Nope, all green on the settings page of the repo. Not sure if it is due to not being nested under a baseurl like your demo site?

I snooped over the forks of your repo and see this elsewhere as well: https://github.com/ivyleavedtoadflax/ivyleavedtoadflax.github.io/blob/master/_posts/2016-02-22-infographic3.md which is rendered at http://www.machinegurning.com/rstats/infographic3/ for example.

@trevorstephens
Copy link
Author

Hrmmm. Looks like you are correct on that conditional statement.

trevorstephens/trevorstephens.github.io@eda2cff

http://trevorstephens.github.io/ramblings/a-journey-begins/ gets the 'foo'

@mmistakes
Copy link
Owner

baseurl shouldn't matter. The fact that the pages are created is promising. Pretty sure something is up with the Liquid that shows the tag or category lists that linked to above. When I get a chance I'll repush the demo site since it hasn't been rebuilt since github-pages updated.

To rule out the updated GitHub Pages gem try the following:

  1. bundle update
  2. bundle exec jekyll serve
  3. Verify if categories and tags are there. If they are then I. Really stumped as running Jekyll this way is suppose to mirror the environment on GitHub.

You could also just rip some of the if statements in https://github.com/mmistakes/minimal-mistakes/blob/master/_includes/page__taxonomy.html and possibly some in tag-list.html or category-list.html.

@mmistakes
Copy link
Owner

Sounds like something might have changed then. I'll have to do some testing when I'm in front of a computer. Probably need to modify that conditional if I can reproduce what's going on.

@trevorstephens
Copy link
Author

Thanks again Mike. Updated the bundle packages and the tags are gone locally now as well.

@trevorstephens
Copy link
Author

Getting 'foo' on local build as well.

@trevorstephens
Copy link
Author

The updates were:

Installing minitest 5.9.0 (was 5.8.4)
Installing execjs 2.7.0 (was 2.6.0)
Using jekyll-feed 0.5.1 (was 0.4.0)
Using ethon 0.9.0 (was 0.8.1)
Installing html-pipeline 2.4.1 (was 2.4.0)
Using jekyll-watch 1.4.0 (was 1.3.1)
Installing jekyll 3.1.6 (was 3.0.3)
Using jekyll-github-metadata 1.11.1 (was 1.11.0)
Using jekyll-seo-tag 1.4.0 (was 1.3.3)
Installing github-pages 80 (was 69)

@mmistakes mmistakes self-assigned this May 30, 2016
mmistakes added a commit that referenced this issue May 30, 2016
@mmistakes
Copy link
Owner

mmistakes commented May 30, 2016

I just posted a fix. For whatever reason site.categories.type, site.categories.path, site.tags.type, and site.tags.path were all showing values of null even though they were populated in _config.yml.

This was causing a few things to break. Best I can tell something changed with site.categories and site.tags when the github-pages gem was updated. It's possible its a bug in Jekyll but I figured the best solution was just to rename those variables to avoid any future clashes.

The fix is to update the following 3 files.

@trevorstephens
Copy link
Author

Thanks Mike! Just posted to the githubs and it's looking great! 👍 😄

@mmistakes
Copy link
Owner

Excellent. Thanks for pointing out the bug.

@trevorstephens
Copy link
Author

My pleasure. Thanks for creating such a great theme and taking care of issues so quickly!

@ghost
Copy link

ghost commented Jun 28, 2016

For those landing here and only want this one fix the theme upgrade instructions can be modified as such:

git remote add upstream
git fetch upstream
git cherry-pick 45f3a7a

You'll have some merge conflicts to resolve in _config.yml, but that should be it.

sobkowiak pushed a commit to sobkowiak/sobkowiak.github.io-new that referenced this issue Jul 18, 2016
sobkowiak pushed a commit to sobkowiak/sobkowiak.github.io-new that referenced this issue Jul 18, 2016
haiyang1992 pushed a commit to haiyang1992/haiyang1992.github.io that referenced this issue Jul 26, 2016
cjmadsen pushed a commit to cjmadsen/cjmadsen.github.io that referenced this issue Dec 7, 2016
jluccisano added a commit to jluccisano/jluccisano.github.io that referenced this issue May 6, 2017
makaroniame added a commit to makaroniame/makaroniame-old.github.io that referenced this issue May 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants