caffeinated/codex — pull request #9 by tyler-sommer (2014-11-06 04:20:42+00:00)
Title: Prototype git-based implementation

This is just as an example implementation for #2, don't merge it, there are quite a few issues:

* URLs must now be relative to the current markdown file. This is in line with other Markdown->Web renderers like GitHub and GitLab so I think this change should make it in no matter what. See this: https://github.com/veonik/sample-docs/blob/master/toc.md compared to https://github.com/caffeinated/codex/blob/master/public/docs/codex/1.0/toc.md
* I ruined the Markdown helper's interface by added a `$pathPrefix` parameter. This can be solved by adding a layer between Markdown and the Codex to transform URLs.
* In a similar vein to the previous point, the regex inside the Markdown helper is atrocious. It may be the best way, however...
* This is not going to work for multiple users. Since this implementation is physically checking out a tag with each web request, problems will arise very quickly. This needs to be solved.

I've made some [installation instructions in my fork](https://github.com/veonik/codex) if you want to take a go at running this implementation. I forked the docs and added some tags and threw them in https://github.com/veonik/sample-docs so you just clone those and you should be off to the races.

Let me know what your thoughts are. Again, I did this as fast as possible just as an example. We can work out any functional or even code-aesthetics flaws if you think this would be a fit for the Codex project. This could be labeled as "Advanced Usage" or similar, and we could work to ensure that the two different kinds of configurations (folder based and git based versioning) do not deviate too much.