I’m currently having issues setting up permalinks on a group of pages on my jekyll site using defaults in _config.yml.
Essentially I’m trying to map pages in directories like docs/v1/some-article.md to a url like /someArticle (masking away the docs/v1). Here’s my _config.yml:
---
layout: page
title: Some Page
slug: somePage
---
Some content
I’m expecting the compiled result to yield a URL of /somePage, however instead Jekyll is rendering it as /:slug/index.html (it’s not parsing the permalink template variable).
Any ideas as to what I’m doing wrong here? Thanks in advance!
try switching it to permalink: /:title/ just to see if it works. It should, and then I think the problem will be that /::slug is not available in that context?
I am not clear on what you mean by using title in your output example - are you saying that literally the name you see is title? rather than the actual title?
Not sure what you mean, there should not be a colon in the directory name.
I’m not sure we are talking about the same things.
ah, maybe it is not possible to do that type of syntax in the defaults?
this is a little old, and I want to say the other day that I saw something where someone did do what you wanted and it works - I think that was on stackoverflow, I’ll see if i can find that again.