{"id":16355501,"url":"https://github.com/waveform80/weather","last_synced_at":"2025-06-17T13:33:34.345Z","repository":{"id":5044934,"uuid":"6205452","full_name":"waveform80/weather","owner":"waveform80","description":"A simple demo of using programmatically altered animated SVG in a web-app","archived":false,"fork":false,"pushed_at":"2012-10-19T22:51:04.000Z","size":252,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-20T17:15:13.685Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/waveform80.png","metadata":{"files":{"readme":"README.rst","changelog":"CHANGES.txt","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-10-13T17:24:54.000Z","updated_at":"2020-07-30T22:51:42.000Z","dependencies_parsed_at":"2022-08-06T18:01:04.537Z","dependency_job_id":null,"html_url":"https://github.com/waveform80/weather","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/waveform80/weather","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waveform80%2Fweather","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waveform80%2Fweather/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waveform80%2Fweather/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waveform80%2Fweather/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/waveform80","download_url":"https://codeload.github.com/waveform80/weather/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waveform80%2Fweather/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260369827,"owners_count":22998707,"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-10-11T01:41:00.678Z","updated_at":"2025-06-17T13:33:29.284Z","avatar_url":"https://github.com/waveform80.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":".. -*- rst -*-\n\n=======\nWeather\n=======\n\nThe weather app is a very simple demonstration of programmatically altered\nanimated SVG. It provides a small animation of rain and clouds against a\nbackdrop with the level of clouds and the appearance of the rain user\nadjustable.\n\nTo achieve this, the image contains all elements that can appear in the final\nanimation, but most elements are initially hidden. The server side code simply\nloads the SVG as an XML file, unhides the requested elements and sends the\nresulting SVG back to the client.\n\nThe image was drawn in Inkscape and two versions of it are included in the\nsource: image.svg is the original image, and image_optimized.svg is a version\nof the picture with greatly simplified structure and all editor specific tags\nremoved (cuts the size down from about 300k to 80k even before compression).\n\nThe webapp itself is written with the Pyramid framework and can be run locally\nif you wish to have a play with the code. Installation instructions are\nincluded below.\n\nDevelopment Installation\n========================\n\nRequirements:\n\n * `Inkscape \u003chttp://inkscape.org\u003e`_ (if you wish to edit the image)\n * `Python 2.6+ \u003chttp://python.org\u003e`_ (untested on Python 3.x but *might* run)\n * `Python virtualenv \u003chttp://www.virtualenv.org/en/latest/\u003e`_\n * `Git \u003chttp://git-scm.com/\u003e`_\n\nInstructions::\n\n    # Create a virtualenv to play with\n    $ virtualenv --no-site-packages weatherenv\n\n    # Clone the git repo\n    $ git clone git://github.com/waveform80/weather.git\n\n    # Activate the previously created virtualenv\n    $ source weatherenv/bin/activate\n\n    # Install the application into the vitualenv as a development version\n    (weatherenv)$ cd weather\n    (weatherenv)$ python setup.py develop\n\n    # Run the application with the development configuration (which will\n    # include the debugging toolbar) and automatic reloading of updated\n    # modules (to allow live manipulation)\n    (weatherenv)$ pserve development.ini --reload\n\nAt this point you should have a development copy running locally and you should\nbe able to visit http://localhost:8080/ to see it. The ``--reload`` option\nmeans that you can edit the code while the server is running and it should\nautomatically reload the changed modules (although if the newly saved code\ndoesn't parse correctly you'll most likely find pserve crashes out).\n\nDeployment on Apache\n====================\n\nTo deploy this application on apache, firstly install the following\npre-requisites:\n\n * `Python 2.6+ \u003chttp://python.org\u003e`_ (untested on Python 3.x but *might* run)\n * `Python virtualenv \u003chttp://www.virtualenv.org/en/latest/\u003e`_\n * `Git \u003chttp://git-scm.com/\u003e`_\n * `Apache 2.x \u003chttp://httpd.apache.org/\u003e`_\n * `mod_wsgi \u003chttp://code.google.com/p/modwsgi/\u003e`_\n\nThe following these instructions (and yes, you really need to clone the git\nrepo within the virtualenv - I've no idea why but for some reason it doesn't\nwork otherwise)::\n\n    # Create a virtualenv to contain the code\n    $ virtualenv --no-site-packages weatherenv\n\n    # Clone the git repo into the virtualenv\n    $ cd weatherenv\n    $ git clone git://github.com/waveform80/weather.git\n\n    # Activate the virtualenv\n    $ source ../bin/activate\n\n    # Install the application into the vitualenv\n    (weatherenv)$ cd weather\n    (weatherenv)$ python setup.py install\n\nNow, in the weatherenv directory that was created by virtualenv, create an\nexecutable weather.wsgi script with the following contents (adjust the path as\nnecessary)::\n\n    ini_path = '/path/to/weatherenv/weather/production.ini'\n    setup_logging(ini_path)\n    application = get_app(ini_path, 'main')\n\nAdd the following to the relevant Apache config (again, adjust paths as\nnecessary)::\n\n    WSGIApplicationGroup %{GLOBAL}\n    WSGIPassAuthorization On\n    WSGIDaemonProcess weather user=myuser group=mygroup threads=4 python-path=/path/to/weatherenv/lib/python2.7/site-packages\n    WSGIScriptAlias /weather /path/to/weatherenv/weather.wsgi\n    \u003cDirectory /path/to/weatherenv\u003e\n        WSGIProcessGroup weather\n        Order allow,deny\n        Allow from all\n    \u003c/Directory\u003e\n\nFinally, reload the Apache service and visit /weather on the relevant site::\n\n    $ sudo service apache2 reload\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwaveform80%2Fweather","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwaveform80%2Fweather","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwaveform80%2Fweather/lists"}