{"id":13545988,"url":"https://github.com/avilaton/gtfseditor","last_synced_at":"2025-04-02T17:32:29.846Z","repository":{"id":8113684,"uuid":"9529675","full_name":"avilaton/gtfseditor","owner":"avilaton","description":"wsgi application to be both a standalone gtfs editor or deployed to google app engine/other wsgi compliant hosting.","archived":true,"fork":false,"pushed_at":"2020-08-20T13:31:53.000Z","size":34228,"stargazers_count":22,"open_issues_count":25,"forks_count":12,"subscribers_count":4,"default_branch":"develop","last_synced_at":"2024-11-03T14:34:50.408Z","etag":null,"topics":["flask","gtfs","gtfs-generator","webapp"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/avilaton.png","metadata":{"files":{"readme":"README.md","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":"2013-04-18T19:12:13.000Z","updated_at":"2023-01-28T12:18:31.000Z","dependencies_parsed_at":"2022-08-30T16:42:49.181Z","dependency_job_id":null,"html_url":"https://github.com/avilaton/gtfseditor","commit_stats":null,"previous_names":[],"tags_count":27,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/avilaton%2Fgtfseditor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/avilaton%2Fgtfseditor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/avilaton%2Fgtfseditor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/avilaton%2Fgtfseditor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/avilaton","download_url":"https://codeload.github.com/avilaton/gtfseditor/tar.gz/refs/heads/develop","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246860232,"owners_count":20845631,"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":["flask","gtfs","gtfs-generator","webapp"],"created_at":"2024-08-01T12:00:29.462Z","updated_at":"2025-04-02T17:32:26.632Z","avatar_url":"https://github.com/avilaton.png","language":"JavaScript","funding_links":[],"categories":["Editors"],"sub_categories":[],"readme":"Gtfseditor\n==========\n\nA customizable editor for GTFS files which can be used both as a standalone app \nor deployed to a wsgi compliant hosting.\n\n\nManagement\n----------\nA series of database management scripts are accesible from the command line using\nthe `manage.py` script.\n\nTo initialize the database, use\n```\n$ ./manage.py db upgrade\n```\nIn development mode this will create a file called data-dev.sqlite in the same\ndirectory with a DB looking like the one in production.\n\n\n\nConfiguration\n-------------\nThe main configuration file for the server is located at `config.py`. Environment variables \ncan be overriden by writing them inside a .env file at the root level.\n\n\nDevelopment\n-----------\n\nThe project has two main parts,\n\n- a client application, located at `app/`\n- a API server + some building tools at `server/`\n\nThe client application uses\n\n- require.js to load javascript modules,\n- backbone.js to structure models and views,\n- openlayers.js to create and manage the map components,\n- bootstrap.js for styling, scaffolding and plugins,\n- handlebars.js as a templating engine.\n\n\nThe API server uses\n\n- flask.py for WSGI,\n- SQLAlchemy for database abstraction,\n- transitfeed.py for gtfs building and validation.\n\namong other auxiliary packages.\n\nDatabase\n--------\n\nDevelopment and local usage are best served by using **SQLite** as a db engine. It \nallows for rapid setup and portability. \n\nSome hosted services do not support sqlite as a db engine (heroku), and \n**postgres** can be used.\n\nInstall postgresql and run\n\n```\ncreatedb -T template0 dbname\n```\nYou are now ready to initialize an empty DB by using\n```\nFLASK_CONFIG=dev ./manage.py db upgrade\n```\n\nImporting a DB dump\n-------------------\n\nTo create a database dump use\n```\npg_dump -Fc --no-acl --no-owner dbname \u003e mydb.dump\n```\n\nTo import a DB dump run\n```\npg_restore -d dbname dump.tar\n```\nwhere **dbname** is the name of your database.\n\n\nDeployment to EC2\n=================\n\nSet up an ubuntu instance in Amazon EC2. On it, run\n```\n$ sudo apt-get update\n$ sudo apt-get install python-pip libpq-dev python-dev nginx postgresql postgresql-contrib\n```\n\nConfiguring nginx\n-----------------\n\nCreate a site file in `/etc/nginx/sites-available/` by copying the example file `nginx.site.example` over and editing it appropriately. Once you are done, enable the site using\n```\n$ sudo ln -s \\\n/etc/nginx/sites-available/mydomain.com \\\n/etc/nginx/sites-enabled/mydomain.com\n```\nwhere `mydomain.com` is the name of the file you created.\n\nConfiguring Postgresql\n----------------------\n\nCreate a database user with the same name as your current username\n```\n$ sudo -u postgres createuser --superuser $USER\n```\nand change it's password using\n```\n$ sudo -u postgres psql\n...\npostgres=# \\password $USER\n```\nThis user will not need a password to connect to the DB.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Favilaton%2Fgtfseditor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Favilaton%2Fgtfseditor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Favilaton%2Fgtfseditor/lists"}