{ "info": { "author": "Khaled Monsoor", "author_email": "k@kmonsoor.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Environment :: Console", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Topic :: Internet :: WWW/HTTP", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "lektor-google-analytics\r\n=======================\r\n\r\n\r\nThis plugin adds support for `Google analytics` to `Lektor CMS`.\r\n\r\nOnce the plugin is enabled, a ``generate_google_analytics()`` function\r\nis available to be included in target ``template`` which automatically\r\ninclude Google-Analytics code in final HTML files rendered by\r\n``Lektor``.\r\n\r\n\r\nBasic Usage\r\n-----------\r\n\r\nEnabling the Plugin\r\n~~~~~~~~~~~~~~~~~~~\r\n\r\nTo enable the plugin add this to your project file:\r\n\r\n.. code:: ini\r\n\r\n [packages]\r\n lektor-google-analytics = 0.1\r\n\r\nConfiguring the Plugin\r\n~~~~~~~~~~~~~~~~~~~~~~\r\n\r\nThe plugin needs a config file with your ``Google analytics`` code in\r\nit.\r\n\r\nJust create a file named ``google-analytics.ini`` into ``./configs``\r\nfolder in your Lektor project\u2019s base directory. And, put the\r\n``GOOGLE_ANALYTICS_ID`` key with target property ID of form\r\n``UA-XXXXXXXX-Y`` which you obtained from:\r\n\r\n.. code:: ini\r\n\r\n GOOGLE_ANALYTICS_ID = UA-XXXXXXXX-Y\r\n\r\nUsing in Templates\r\n~~~~~~~~~~~~~~~~~~\r\n\r\nNow you can add a Google analytics code-snippet in your templates by\r\njust calling the ``generate_google_analytics`` function inside its ``
`` tags.\r\n\r\n.. code:: html\r\n\r\n