-
Notifications
You must be signed in to change notification settings - Fork 848
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
[i18n_subsites] Move the default language output also in a subfolder (like a subsite) #182
Comments
Thank you for your fix, will commit it later and will use this approach also for other settings. |
Hm, this fix breaks the feeds. They still point to the old url. You get: |
Nope. I did the thing for the |
I think the culprit here is the Maybe you'll be more lucky :) I'm looking forward to your implementation of the function. I might have a look at it later. |
Here is a rough idea of the redesign of the plugin, needs the Process:
|
I've made a first concept, but the problem is that all URLs used internally by Pelican are always relative to the current Therefore, I propose that this plugin would enable to specify arbitrary SITEURL = 'http://example.com/en'
I18N_SUBSITES = {
'de': { 'SITEURL' : '../de' }
}
If this design is accepted, the site and subsites would have some hierarchal structure and #180 could be implemented using @Scheirle, what do you think? |
@smartass101 I think appending the Also the plugin should simplify the |
@Scheirle, I agree that appending Simplifying them after concatenation should be easy thanks to |
@ingwinlu was so kind and provided a nice way to find the distance of the paths in https://gist.github.com/ingwinlu/20615105bba903ccf0d8, will see if I can use that. |
@saimn was so kind and also provided a solution in https://dpaste.de/7CY4 |
@spiroid, please don't ask for support in issues that may not have anything to do with your problem. I suggest you come to the #pelican IRC channel and ask for help there. And the description you provided is so vague that nobody can help you, so be prepared to give a concrete example on IRC. |
Major highlights ................ - fixed and improved cross-linking (fixes getpelican#333) with URLs containing e.g. localized month names (thanks to issue getpelican/pelican#1198) - support for custom ``SITEURL`` and ``OUTPUT_PATH`` hierarchy (fixes getpelican#182) - sharing of static files (including those of the theme) among subsites (fixes getpelican#180) Technical highlights .................... - added a test suite (works with pelican 3.4) - translations are installed into Jinja2 environments of all generators - old locale is restored after generation, fixes autoreload The documentation has been updated and improved (mostly in terms of formatting). Known issues ............ - due to the redesign required for correct cross-linking, older versions of Pelican (<3.4) are not supported, because they lack certain signals - the ``HIDE_UNTRANSLATED_CONTENT`` setting has been deprecated in favor of the ``I18N_UNTRANSLATED_{ARTICLES,PAGES}`` settings which offer more control in order to fix getpelican#211. - the test suite works only with pelican 3.4, later versions add a timezone field to the date
* Change license text to be SPDX and REUSE conformant ref: - <https://reuse.software/practices/2.0/> - <https://spdx.org/> * Fixed link to Google HTML/CSS style guide * New intro, reorganise screenshots * Add Kate swap file to gitignore * Clarify documentation status * Updated basic contribution policy - to match the license - to match the new repositories - some basic rewording to make it clearer * Fix missing parts of licensing sentence * Removed Talha Mansoor’s name from the footer as agreed by Talha Mansoor in <Pelican-Elegant/elegant#175> and <Pelican-Elegant/elegant#173 (comment)> * Add AUTHORS * Fix typo in AUTHORS * Fix tiny typo
Major highlights ................ - fixed and improved cross-linking (fixes getpelican/pelican-plugins#333) with URLs containing e.g. localized month names (thanks to issue getpelican/pelicangetpelican/pelican-plugins#1198) - support for custom ``SITEURL`` and ``OUTPUT_PATH`` hierarchy (fixes getpelican/pelican-plugins#182) - sharing of static files (including those of the theme) among subsites (fixes getpelican/pelican-plugins#180) Technical highlights .................... - added a test suite (works with pelican 3.4) - translations are installed into Jinja2 environments of all generators - old locale is restored after generation, fixes autoreload The documentation has been updated and improved (mostly in terms of formatting). Known issues ............ - due to the redesign required for correct cross-linking, older versions of Pelican (<3.4) are not supported, because they lack certain signals - the ``HIDE_UNTRANSLATED_CONTENT`` setting has been deprecated in favor of the ``I18N_UNTRANSLATED_{ARTICLES,PAGES}`` settings which offer more control in order to fix getpelican/pelican-plugins#211. - the test suite works only with pelican 3.4, later versions add a timezone field to the date
It would be nice to have an option to move the generated files for the default language also in a sub folder, and treat it like a subsite.
So instead of this: (tree view output folder)
├── author
├── de
│ ├── author
│ ├── feeds
│ ├── ....
├── feeds
├── ....
You would get this: (tree view output folder)
├── de
│ ├── author
│ ├── feeds
│ ├── ....
├── en
│ ├── author
│ ├── feeds
│ ├── ....
Assuming en is the default language and de a subsite.
With the patch below this is possible:
pelicanconf.py:
Patch:
Note: If you are using the makefile to build your site, you have to remove the -o option.
The text was updated successfully, but these errors were encountered: