-
Notifications
You must be signed in to change notification settings - Fork 37
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
base URL #7
Comments
I understand the issue, but I don't have a good solution immediately. I would like to keep the concepts that the locally generated site is deployed to production unchanged, and that links are root-relative. Anyone with ideas? |
I think the best solution is to introduce a parameter |
+1 to the solution above. So, congratulations for Jan. Urubu is very good. |
The other option is to leave all URLs relative instead of having them assume '/' or some base url. |
From what I read there are good reasons to avoid relative URLs. Certainly root-relative is simpler and a natural fit to systems like Urubu (with local testing and remote deployment). Another idea: would it be possible to keep the desired feature out of Urubu by some clever redirection trick on a server? |
I don't know that kind of trick, but as the feature is capital to me, I've added an optionnal root: parameter in _site.yml. Don't specify it, the behaviour stays the same, specify it and it gets appended at the beginning of every internal link. If you accept this pull, I could write the appropriate doc modifications. |
Also, Urubu is great ! Just the lean python tool I needed to NOT create a static blog. |
Many people who hit this problem aren't going to have access to the Apache configurations to do URL re-writing, since it will depend on the admin giving them access to mod_rewrite. If you do have access to mod_rewrite, you can add something like this to your
This tells Apache to rewrite URLs as the pages are served so that But the idea of a |
Ok - the proposed pull request seems ok to me, have you reviewed it and do you agree? |
To be honest, I haven't tested functionalities outside the quickstart default. Could you send me a template with tags and any other functionality worth testing ? I haven't found out how to use them in the manual... |
Mm, my question was intended for @SoftwareMaven to have a 2nd opinion. |
So I just got a chance to review it. The only things I would change:
|
I tried the pull request, and my problem is that I cannot test a |
If you are on a *nix flavor, after you create a build with
Now, The alternative is to manually move the contents of
This would probably be a slightly better test, as it would cause 404's for anything without the proper |
I see - do the required modifications outside of Urubu, e.g. in the Makefile. Fine. I don't have much time, but if someone wants to update the pull request taking into account your earlier comments, I will gladly accept it. |
Jekyll has a |
I am OK with the solution as outlined in this thread. All it takes is for someone to update PR #15 or raise a new one accordingly. (I have no need/time for this feature.) |
I will probably have a go at re-writing that PR soon because I'm currently unable to deploy to gh-pages without some kind of prefix/root option. As for the server, I wrote this little script that starts a Tornado static file server with an optional prefix: https://gist.github.com/jiffyclub/043a44b524859a3cf70b I can do |
I've opened PRs at #18 and jandecaluwe/urubu-quickstart#2 adding a base URL feature. It's working great for me. |
Works fine. With bash extended blogging, the _build fix can be done with |
Just add some documentation (copied from the PR) so this should be ready to go. |
👍 Thanks! |
If anyone is still looking for a way to preview their site with the |
Could be interesting to add the prefix question + possible local solutions (i.e. patching |
If I am, say, at a university where my webspace is at http://univ.edu/~name/, is there a way to prefix all internal reflinks by that URL? It seems now that urubu assumes it lives at the base directory.
The text was updated successfully, but these errors were encountered: