w3c / ws-homepage-template

1 stars 5 forks source link

Local testing? #1

Open apowers313 opened 6 years ago

apowers313 commented 6 years ago

The README says:

install jekyll locally (which is probably a good idea for testing)

Can you give a couple hints of how to run jekyll locally for the uninitiated? I tried bundle exec jekyll serve in the root of the repo (based on what I found on the jekyll site), but that only got me Could not locate Gemfile or .bundle/ directory.

Thanks!

iherman commented 6 years ago

My apologies for the late reply, @apowers313.

However, I am not sure I can help. I am not a jekyll expert, and I hardly know anything about ruby (which is the language and environment used for jekyll); however, I have just created a clone of the template, and ran the following command:

bundle exec jekyll serve -P 4002

which is the same as yours (except for an explicit set of the port) and it worked well. Note the the repo does include a Gemfile, are you sure you copied everything...

apowers313 commented 6 years ago

I don't see the Gemfile in the ws-homepage-template repo:

image

Let me know if I'm just being blind or if there was some setup step I missed.

iherman commented 6 years ago

Oh shoot... How come?

I will do it later today (I have a call to attend to now)

iherman commented 6 years ago

Oh shoot... How come?

It seems that the Gemfile (and a correspondingGemfile.lock) is installed by jekyll; see https://jekyllrb.com/docs/ for the documentation. That would install what it calls a "blog" (ie, simply a web site) that must then be populated by the content of this repository.

The installation of git seems to work closely with jekyll in forcing you to do that (I am NOT an expert in all this...). My ~/.gitignore_global does include Gemfile, that is the reason it has not been added to this repo; I have added this (and Gemfile.lock) with the .template suffixes, and you may want to just try those. But a bona fide installation with jekyll is probably the better option.