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

Prepend url, too, in feed.xml. #2319

Merged
merged 2 commits into from May 7, 2014

Conversation

Projects
None yet
4 participants
@parkr
Member

parkr commented May 7, 2014

Per the convo on 2dec333:

@albertogg:

@parkr what about all the variables {{ site.baseurl }} variables used in the feed.xml, _includes/head.html _incluedes/header? do you suggest changing them?

@parkr:

I would prefer not to use them in a perfect world, but this works.

@albertogg:

But they are being used in all those files I stated.

[...]

@troyswanson:

Those ought to be absolute URLs, no?

@parkr:

Yeah.

NOW THEY ARE!!!!!!!!!!

screen shot 2014-05-07 at 12 09 21 am

@troyswanson

This comment has been minimized.

Member

troyswanson commented May 7, 2014

💥 GET A LIFE, @parkr (jk, you're awesome)

@parkr

This comment has been minimized.

Member

parkr commented May 7, 2014

Did we miss anything, @albertogg?

@albertogg

This comment has been minimized.

Member

albertogg commented May 7, 2014

jumm, I'm checking.

@albertogg

This comment has been minimized.

Member

albertogg commented May 7, 2014

I what about _includes/head.html do you prefer absolute URLs?

@troyswanson

This comment has been minimized.

Member

troyswanson commented May 7, 2014

It is kind of weird for that http://yourdomain.com URL to be there on dev. If you prepend all of your stuff with those (like your CSS and JS), then they just won't load.

@albertogg

This comment has been minimized.

Member

albertogg commented May 7, 2014

yes @troyswanson, that's true... and it's what got me thinking

@parkr

This comment has been minimized.

Member

parkr commented May 7, 2014

What if we suggest using a _config_dev.yml file that just contains:

url: "http://localhost:4000"

Then they run jekyll serve -w -c _config.yml,_config_dev.yml in dev. and just jekyll build for production.

@parkr

This comment has been minimized.

Member

parkr commented May 7, 2014

It feels overly complicated to me... I wish we could just run jekyll <subcmd> --dev or something

@albertogg

This comment has been minimized.

Member

albertogg commented May 7, 2014

IMHO think that will complicate things a bit. I will get rid of those prepend things if they aren't needed

@troyswanson

This comment has been minimized.

Member

troyswanson commented May 7, 2014

I was just thinking that, actually. Traditionally, we encouraged folks to add something to the jekyll command, like jekyll <subcmd> --baseurl "", right? I think the only thing people will need to change on dev is that URL business.

@albertogg

This comment has been minimized.

Member

albertogg commented May 7, 2014

Remember that the template is a "base" for people and It doesn't need to be "perfect" just what we consider "best" practice and also be what we consider a good starting point.

@parkr

This comment has been minimized.

Member

parkr commented May 7, 2014

Ok, I just messed around with it for a while – I think I got it perfect.

@albertogg

This comment has been minimized.

Member

albertogg commented May 7, 2014

Question: Isn't the default baseurl = / ? when it's not declared in the _config.yml?

@parkr

This comment has been minimized.

Member

parkr commented May 7, 2014

The default is now "" as of 97e9fb2. We can drop it, but it's nice to have for projects on GHP and to see the difference b/w url and baseurl.

parkr added a commit that referenced this pull request May 7, 2014

@parkr parkr merged commit 0905b2c into master May 7, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details

@parkr parkr deleted the use-urls branch May 7, 2014

parkr added a commit that referenced this pull request May 7, 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.