joomla / joomla-developer-docs

Experimental developer documentation for software produced by the Joomla! project.
http://developer.docs.joomla.org
20 stars 24 forks source link

Dynamic menu creation #20

Closed Chris-Jones-Gill closed 10 years ago

Chris-Jones-Gill commented 10 years ago

This reads the folder and file structure from github and creates the menu on the fly, rather than have a static menu file that has to be updated every time a file/folder is added or removed.

See it in action on http://kiss-web-design.github.io/joomla-developer-docs/#/en/home.md

Chris-Jones-Gill commented 10 years ago

Just noticed that the CNAME filename change has been applied to this PR, you would need to revert that change after merging. I need to rename it or the fork doesn't display on github pages as github is trying to resolve the CNAME to 2 repos. Should look at adding CNAME to .gitignore to prevent this in future.

edit

Here is a copy of the email Github sends when there is a CNAME conflict

[joomla-developer-docs] Page build failure

The page build failed with the following error:

CNAME already taken: developer.docs.joomla.org

For information on troubleshooting Jekyll see:

https://help.github.com/articles/using-jekyll-with-pages#troubleshooting

If you have any questions please contact us at https://github.com/contact.

eddieajau commented 10 years ago

So, we only need CNAME in the master branch?

Chris-Jones-Gill commented 10 years ago

That's correct, or every time someone forks the repo they will get this error.

All the visitor sees is a 404 page instead of their copy of the pages, the email comes soon after.

The problem for most people would be that they don't know what the error means, or how to fix it. All they know is that they can't view their changes before sending a PR.

Chris.

On Wednesday, 27 November 2013, Andrew Eddie wrote:

So, we only need CNAME in the master branch?

— Reply to this email directly or view it on GitHubhttps://github.com/joomla/joomla-developer-docs/pull/20#issuecomment-29422746 .

Chris Jones-Gill KISS Web Design Company number: 7486736 VAT Registration: 107800539

eddieajau commented 10 years ago

Oh, I get it! Ok, merged and let's see what happens. I'm not sure I'm completely sold on the new menu but let's see how it goes :)

eddieajau commented 10 years ago

@KISS-Web-Design It broke the site. http://developer.docs.joomla.org

mbabker commented 10 years ago

As he noted above, you need to rename the file back to CNAME and you should be all set.

eddieajau commented 10 years ago

Ok, change reverted (obviously I should NOT drink coffee in the morning). @KISS-Web-Design maybe in your fork try using something with git update-index --assume-unchanged. I've emailed Github support to see if they can provide some advice as well.

eddieajau commented 10 years ago

Ok, so the official word from Github is they are aware of it and they suggest using the git command I mentioned. If someone tries it let me know what the procedure to write up would be, otherwise I'll work something out ... sometime.