{"id":13558055,"url":"https://github.com/hyde/hyde-old","last_synced_at":"2025-04-03T12:31:41.519Z","repository":{"id":479542,"uuid":"105063","full_name":"hyde/hyde-old","owner":"hyde","description":"Static website generator inspired by Jekyll","archived":false,"fork":true,"pushed_at":"2011-10-06T20:17:16.000Z","size":9209,"stargazers_count":875,"open_issues_count":31,"forks_count":81,"subscribers_count":35,"default_branch":"master","last_synced_at":"2024-11-04T08:37:11.610Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://ringce.com/hyde","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"lethain/aym-cms","license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hyde.png","metadata":{"files":{"readme":"README.markdown","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2009-01-11T04:28:46.000Z","updated_at":"2024-10-31T12:52:25.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/hyde/hyde-old","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hyde%2Fhyde-old","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hyde%2Fhyde-old/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hyde%2Fhyde-old/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hyde%2Fhyde-old/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hyde","download_url":"https://codeload.github.com/hyde/hyde-old/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247002427,"owners_count":20867462,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T12:04:42.863Z","updated_at":"2025-04-03T12:31:36.510Z","avatar_url":"https://github.com/hyde.png","language":"Python","funding_links":[],"categories":["Python","others"],"sub_categories":[],"readme":"**Note:**\nWhile this remains the most complete and functional version of hyde, the new\nversion (potentially 1.0) is [under heavy development](https://github.com/hyde/hyde).\n\n# HYDE\n\n0.5.3\n\nThis document should give enough information to get you up and running. Check\nthe [wiki](http://wiki.github.com/lakshmivyas/hyde) for detailed documentation.\nTo use Clyde, the online content editor for hyde see the\n[clyde readme](http://github.com/lakshmivyas/hyde/tree/master/clydeweb/).\n\nHyde is a static website generator with the power of Django templates behind it.\nYou can read more about its conception, history and features [here][1] and\n[here][2].\n\n[1]: http://www.ringce.com/products/hyde/hyde.html\n[2]: http://www.ringce.com/blog/2009/introducing_hyde.html\n\n\n## Basic Installation\n\nGet the hyde source by cloning this repository.\n\nThe very basic installation of hyde only needs Django, Markdown and pyYAML. More\npython goodies are needed based on the features you may use.\n\n    pip install -r requirements.txt\n\n\n## Running with Hyde\n\nThe hyde engine has three entry points:\n\n1. Initializer\n\n        python hyde.py -i -s path/to/your/site [-t template_name = default] [-f]\n\n    During initialization hyde creates a basic website by copying the specified\n    template (or default). This template contains the skeleton site layout, some\n    content pages and settings.py.\n\n    Be careful with the -f setting, though: it will overwrite your website.\n\n\n2. Generator\n\n        python hyde.py -g -s path/to/your/site [-d deploy_dir=path/to/your/site/deploy] [-k]\n\n    This will process the content and media and copy the generated website to your deploy directory.\n\n    If the -k option is specified, hyde will monitor the source folder for changes and automatically process them when the changes are encountered. This option is very handy when tweaking css or markup to quickly check the results. Note of caution: This option does not update listing files or excerpt files. It is recommended that you run -g again before you deploy the website.\n\n    If you are on Mac OS X and would like to get Growl notifications, just set the GROWL setting to the `growlnotify` script path.\n\n3. Web Server\n\n        python hyde.py -w -s path/to/your/site [-d deploy_dir=path/to/your/site/deploy]\n\n    This will start an instance of a cherrypy server and serve the generated website at localhost:8080.\n\n\n## Site structure\n\n* layout - Template files that are used as base templates for content. None of the files in the layout folder are copied over to the deploy directory.\n* content - Any file that is not prefixed with \\_, . or suffixed with ~ are processed by running through the template engine.\n* media - Contains site media, css, js and images.\n* settings.py - Django and hyde settings.\n\n### Recommended conventions\n\nThese conventions will make it easier to configure hyde plugins.\n\n* Prefix files in layout and other template files in content with underscores\n* Keep media folder organized by file type[css, flash, js, images].\n\n## Configuring your website\n\nMost of the boilerplate configuration comes as a part of the initialized website. The only setting you _have to_ override is the SITE_NAME setting.\n\n\n### Media Processors\n\nMedia processors are defined in the following format:\n\n    {\u003cfolder\u003e:{\n        \u003cfile_extension_with_dot\u003e:(\u003cprocessor_module_name1\u003e, \u003cprocessor_module_name2\u003e)}\n    }\n\nThe processors are executed in the order in which they are defined. The output from the first processor becomes the input of the next.\n\nA \\* instead of folder will apply the setting to all folders. There is no wildcard support for folder name yet, \\* is just a catch all special case.\n\nFile extensions should be specified as .css, .js, .png etc. Again no wildcard support yet.\n\nHyde retains the YUI Compressor, Clever CSS and HSS processors from aym-cms.\n\n#### Template Processor\n\nTemplate processor allows the use of context variables inside your media files.\n\n#### YUI Compressor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.YUICompressor'`` and compresses them.\n\n[yuic]: http://developer.yahoo.com/yui/compressor/\n\nIn the settings file, set ``YUI_COMPRESSOR`` to\nthe path of a [YUI Compressor][yuic] jar on your computer.\n\n#### Closure Compiler\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.ClosureCompiler'`` and compresses them.\n\n[closure]: http://closure-compiler.googlecode.com/\n\nIn the settings file, set ``CLOSURE_COMPILER`` to\nthe path of [Closure Compiler][closure] jar on your computer\nif you don't want to use the hosted Google Closure Compiler service.\n\n#### UglifyJS\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.UglifyJS'`` and compresses them.\n\n[uglifyjs]: http://marijn.haverbeke.nl/uglifyjs/\n\nIn the settings file, set ``UGLIFYJS`` to\nthe path of [UglifyJS][uglifyjs] script on your computer\nif you don't want to use the hosted UglifyJS service.\n\n#### Clever CSS Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.CleverCSS'`` and converts them to css.\n\nYou need to install Clever CSS using ``sudo easy_install CleverCSS`` command for this processor to work.\n\n[clever_css]: http://sandbox.pocoo.org/clevercss/\n\n#### HSS Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.HSS'`` and converts them to css.\n\nYou need to download HSS from [the project website][hss] and set the ``HSS_PATH`` variable to the downloaded path. A version for OS X is installed in the ``lib`` folder by default. To use it, just uncomment the ``HSS_PATH`` line in the settings.py file of your template.\n\n[hss]: http://ncannasse.fr/projects/hss\n\n#### SASS Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.SASS'`` and converts them to css.\n\nYou need to install SASS (see [the project website][sass]) and set the ``SASS_PATH`` variable to the path to the ``sass`` script.\n\n[sass]: http://sass-lang.com/\n\n#### Less CSS Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.LessCSS'`` and converts them to css.\n\nYou need to install Less (see [the project website][lesscss]) and set the ``LESS_CSS_PATH`` variable to the path to the ``lessc`` script.\n\n[lesscss]: http://lesscss.org/\n\n#### Stylus Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.Stylus'`` and converts them to css.\n\nYou need to install Stylus (see [the project website][stylus]) and set the ``STYLUS_PATH`` variable to the path to the ``stylus`` script.\n\n[stylus]: http://learnboost.github.com/stylus/\n\n#### CSSPrefixer Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.CSSPrefixer'`` and adds vendor prefixed versions of CSS3 rules.\n\nYou need to install [CSSPrefixer][cssprefixer] using ``sudo easy_install cssprefixer`` command\nif you don't want to use the hosted CSSPrefixer service.\n\n[cssprefixer]: http://cssprefixer.appspot.com\n\n#### CSSmin Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.CSSmin'`` and minifies them.\n\nYou need to install [cssmin][cssmin] using ``sudo easy_install cssmin`` command for this processor to work.\n\n[cssmin]: http://github.com/zacharyvoase/cssmin\n\n#### CoffeeScript Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.CoffeeScript'`` and converts them to javascript.\n\nYou need to install CoffeeScript (see [the project website][coffeescript]) and set the ``COFFEE_PATH`` variable to the path to the ``coffee`` script.\n\n[coffeescript]: http://jashkenas.github.com/coffee-script/\n\n#### JSmin Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.JSmin'`` and minifies them.\n\nYou need to install [jsmin][jsmin] using ``sudo easy_install jsmin`` command for this processor to work.\n\n[jsmin]: http://pypi.python.org/pypi/jsmin\n\n#### Thumbnail Processor\n\nRuns through the all the files defined in the configuration associated with ``'hydeengine.media_processors.Thumbnail'`` and creates small \"thumbnailed\" copies. The aspect ratios of the images will be preserved.\n\nYou need to install the [Python Imaging Library][PIL] with the ``sudo easy_install PIL`` command.\n\nYou also need to set the ``THUMBNAIL_MAX_WIDTH`` and ``THUMBNAIL_MAX_HEIGHT`` variables.\n\nYou can set the ``THUMBNAIL_FILENAME_POSTFIX`` to change the string that is appended to the filename of thumbnails. By default this is ``-thumb`` (i.e. the thumbnail of ``my-image.png`` will be called ``my-image-thumb.png``).\n\nYou can optionally set the ``THUMBNAIL_JPEG_QUALITY`` (between 0 and 100) to control the JPEG compression quality.\n\n[PIL]: http://www.pythonware.com/products/pil/\n\n### Content Processors\n\nContent processors are run against all files in the content folder whereas the media processors are run against the media folder. No content processors have been created yet.\n\n\n## Page Context Variables\n\nPages can define their own context variables that are passed to the entire template hierarchy when the page is processed. This is accomplished by using a special tag at the top of the content page(after any extends tags you may have).\n\n    {%hyde\n        \u003cYour variables\u003e\n    %}\n\nEvery page in the template hierarchy gets these context variables: ``site`` and ``page``. The site variable contains information about the entire site. The ``page`` variable represents the current content page that is being processed. The variables defined at the top of the content pages using the {% hyde %} tags are available through the page variable as attributes.\n\nOn your content pages you can define the page variables using the standard YAML format.\n\n    {%hyde\n        title: A New Post\n        list:\n            - One\n            - Two\n            - Three\n    %}\n\n## Template Tags\n\nHyde retains the markdown and syntax template tags from aym_cms. Additionally hyde introduces a few tags for excerpts. These tags are added to the Django built in tags so there is no need for the load statements.\n\n### Markdown\n\nRequires markdown to be installed.\n\n    sudo easy_install markdown\n\n``markdown`` renders the enclosed text as [Markdown](http://daringfireball.net/projects/markdown/) markup.\nIt is used as follows:\n\n    \u003cp\u003e I love templates. \u003c/p\u003e\n    {% markdown %}\n    Render this **content all in Markdown**.\n\n    \u003e\u003e Writing in Markdown is quicker than\n    \u003e\u003e writing in HTML.\n\n    1.  Or at least that is my opinion.\n    2.  What about you?\n    {% endmarkdown %}\n\n#### Markdown2\n\nHyde also supports markdown2 with the `{%markdown2%}{%endmarkdown2%}` block template tag.\n\n\n### Textile\n\nRequires textile to be installed.\n\n    sudo easy_install textile\n\n``textile`` renders the enclosed text as [Textile](http://www.textism.com/tools/textile/) markup.\nIt is used as follows:\n\n    \u003cp\u003e I love templates. \u003c/p\u003e\n    {% textile %}\n    Render this *content all in Textile*.\n\n    bq.  Writing in Textile is also quicker than\n         writing in HTML.\n\n    # Or at least that is my opinion.\n    # What about you?\n\n    {% endtextile %}\n\n\n### reStructuredText\n\nRequires docutils to be installed.\n\n    sudo easy_install docutils\n\n``restructuredtext`` renders the enclosed text as [reStructuredText](http://docutils.sourceforge.net/rst.html) markup.\nIt is used as follows:\n\n    \u003cp\u003e I love templates. \u003c/p\u003e\n    {% restructuredtext %}\n    Render this **content all in reStructuredText**.\n\n         Writing in reStructuredText is also quicker than\n         writing in HTML.\n\n    #. Or at least that is my opinion.\n    #. What about you?\n\n    {% endrestructuredtext %}\n\nThe default reStructuredText settings may be changed by assigning a dictionary of setting names and values to the ``RST_SETTINGS_OVERRIDES`` setting in the settings file.  For information on the various configuration options, see the [docutils configuration documentation](http://docutils.sourceforge.net/docs/user/config.html).\n\n\n### asciidoc\n\nRequires asciidoc to be installed.\n\n``asciidoc`` renders the enclosed text as [asciidoc](http://www.methods.co.nz/asciidoc/) markup.\nIt is used as follows:\n\n    \u003cp\u003e I love templates. \u003c/p\u003e\n    {% asciidoc %}\n    Render this *content all in asciidoc*.\n\n    ________________________________________\n    Writing in asciidoc is also quicker than\n    writing in HTML.\n    ________________________________________\n\n    . Or at least that is my opinion.\n    . What about you?\n\n    {% endasciidoc %}\n\n\n### Syntax\n\nRequires Pygments.\n\n    sudo easy_install Pygments\n\n``syntax`` uses Pygments to render the enclosed text with\na code syntax highlighter. Usage is:\n\n    \u003cdel\u003e{% load aym %}\u003c/del\u003e\n    \u003cp\u003e blah blah blah \u003c/p\u003e\n    {% syntax objc %}\n    [obj addObject:[NSNumber numberWithInt:53]];\n    return [obj autorelease];\n    {% endsyntax %}\n\nTo generate the corresponding CSS, first list the available styles\n\n    python\n    \u003e\u003e\u003e from pygments.styles import get_all_styles\n    \u003e\u003e\u003e list(get_all_styles())\n    ['manni', 'perldoc', 'borland', 'colorful', 'default', 'murphy', 'vs', 'trac', 'tango', 'fruity', 'autumn', 'bw', 'emacs', 'pastie', 'friendly', 'native']\n\nThen choose a style and generate a style sheet\n\n    pygmentize -f html -S native -a .highlight \u003e pygments.css\n\nThey are both intended to make writing static content\nquicker and less painful.\n\n### Hyde\n\nThe ``{%hyde%}`` tag is used for the page variables, as a template tag all it does is swallow the contents and prevent them from showing up in the html. The even safer approach is to define this tag outside of all blocks so that it is automatically ignored.\n\n### Excerpt\n\nThe ``{%excerpt%}{%endexcerpt%}`` tag decorates the output with html comments that mark the excerpt area. Excerpts marked in this manner can be referenced in other pages using the ``{%render_excerpt%}`` or the ``{%latest_excerpt%}`` tag.\n\n### Render Excerpt\n\nRender Excerpt takes a page variable and optional number of words argument to render the excerpt from the target page.\n\n### Latest Excerpt\n\nLatest Excerpt takes a content folder path and optional number of words as input. It parses through the content pages looking for page variables named ``created`` and gets the page with the maximum value and renders the excerpt from that page.\n\n### Article\n\nThe ``{%article%}{%endarticle%}`` tags mark content enclosed in them to be included as inline content when the atom feed is generated.\n\n### Render Article\n\nRender Article renders the html content bracketed by the `{%article%}` tag from the given page.\n\n### Typogrify\n\nTo enable Typogrify, use ``{% filter typogrify %}`` in your code. Typogrify is \"a collection of Django template filters that help prettify your web typography by preventing ugly quotes and widows\", according to the [project web site][typogrify_site]. It is automatically enabled in the default template. Some features require you to have [smartypants] installed.\n\n[typogrify_site]:http://code.google.com/p/typogrify/\n[smartypants]:http://web.chad.org/projects/smartypants.py/\n\n\n## Preprocessors\n\nMain information about preprocessors can be found in\n[hyde wiki]:https://github.com/lakshmivyas/hyde/wiki/Site-Preprocessors\n\n### Properties inclusion\n\nIs preprocessor that includes new properties into nodes.\nSimple configuration:\n  SITE_PRE_PROCESSORS = {\n      '/': {\n        'hydeengine.site_pre_processors.TranslationManager': {\n          'include' : {\n             'node_field': {'field':'page_field','fallback':'node_field2'}\n          }\n        }\n    }\n  }\n\nProcessors find listing page for node and then include page.field into node.node_field, and if there is no title it falls back to node.node_field2 field.\nOne can use it for translation, for example use field: page_field on native language and the use node field in template (to overcome node.name) or even add additiona menu_title to give title name to module.\nN.B. you should explisitly create listing page otherwise preprocessor will not add any attribute to node.\n\n## Base Templates\n\nThere are two layouts currently available: default and simple.\n\nThe default site layout contains templates for basic site structure, navigation, breadcrumbs, listing, posts and Atom feed and a very basic stylesheet.\n\n\n# Examples\n\nThe following websites are built using hyde and are open sourced.\n\n* [SteveLosh.com][stevelosh]\n* [The Old Ringce Website][ringce]\n\n[stevelosh]:http://github.com/sjl/stevelosh\n[ringce]:http://github.com/lakshmivyas/ringce\n\n\n# CONTRIBUTORS\n\n(Please let me know if I have missed someone here.)\n\n- [lakshmivyas](http://github.com/lakshmivyas)\n- [joshrosen](http://github.com/JoshRosen)\n- [Harry Lachenmayer](http://github.com/h3yl9r)\n- [Kailoa Kadano](http://github.com/kailoa)\n- [Tom von Schwerdtner](http://github.com/tvon)\n- [montecristo](http://github.com/montecristo)\n- [dbr/Ben](https://github.com/dbr)\n- [Valentin Jacquemin](http://github.com/poxd)\n- [Johannes Reinhard](http://github.com/SpeckFleck)\n- [Steve Losh](http://github.com/sjl)\n- [William Amberg](http://github.com/wamberg)\n- [James Clarke](http://github.com/jc)\n- [Benjamin Pollack](http://github.com/bpollack)\n- [Andrey](http://github.com/andrulik)\n- [Toby White](http://github.com/tow)\n- [Tim Freund](http://github.com/timfreund)\n- [Russell Haering](http://github.com/russellhaering)\n- [timo](http://github.com/timo)\n- [Alex Schworer](http://github.com/schworer)\n- [holmboe](http://github.com/holmboe)\n- [James Wilcox](http://github.com/snorp)\n- [Hugo Vincent](http://github.com/hugovincent)\n- [Örjan Persson](http://github.com/op)\n- [Ken](http://github.com/xythian)\n- [Nico Mandery](http://github.com/nmandery)\n- [Chetan Surpur](http://github.com/chetan51)\n- [Pascal Widdershoven](https://github.com/PascalW)\n- [Kai](https://github.com/limist)\n- [myfreeweb](http://github.com/myfreeweb)\n- [Paul Bonser](https://github.com/pib)\n- [Yoann Pigné](https://github.com/pigne)\n- [Hubert HANGHOFER](https://github.com/brewbert)\n- [sirex](https://github.com/sirex)\n- [Alexander Vershilov](https://github.com/qnikst)\n- [Boris Smus](https://github.com/borismus)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhyde%2Fhyde-old","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhyde%2Fhyde-old","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhyde%2Fhyde-old/lists"}