{"id":13594524,"url":"https://github.com/paladin8/kfchess","last_synced_at":"2025-04-09T07:32:55.845Z","repository":{"id":30399999,"uuid":"124791861","full_name":"paladin8/kfchess","owner":"paladin8","description":"Kung Fu Chess, a real-time chess game.","archived":false,"fork":false,"pushed_at":"2024-01-14T01:09:50.000Z","size":2850,"stargazers_count":143,"open_issues_count":12,"forks_count":9,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-08-02T16:52:55.658Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://www.kfchess.com","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/paladin8.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,"governance":null,"roadmap":null,"authors":null}},"created_at":"2018-03-11T19:39:51.000Z","updated_at":"2024-07-04T21:31:42.000Z","dependencies_parsed_at":"2023-12-20T11:16:32.642Z","dependency_job_id":"6d1f6b0d-b9ca-4212-9c12-038a15ac3b7e","html_url":"https://github.com/paladin8/kfchess","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paladin8%2Fkfchess","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paladin8%2Fkfchess/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paladin8%2Fkfchess/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paladin8%2Fkfchess/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/paladin8","download_url":"https://codeload.github.com/paladin8/kfchess/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223375367,"owners_count":17135356,"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-01T16:01:35.010Z","updated_at":"2024-11-06T16:31:30.948Z","avatar_url":"https://github.com/paladin8.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# Kung Fu Chess\n\nKung Fu Chess is a real-time chess game where players don't take turns. A player may make a move at any time, but pieces have a travel speed and a cooldown period. The game is hosted at https://www.kfchess.com.\n\n## Contributing\n\nThere are three components to running the Kung Fu Chess system locally: a [PostgreSQL](https://www.postgresql.org/) database, a [Flask](http://flask.pocoo.org/) application server, and a [webpack](https://webpack.js.org/) development server. In production, the first two also exist, but the webpack production bundle is served statically.\n\n### Setting up PostgreSQL\n\nInstall PostgreSQL on your system and create a database called `kfchess`. The schema is in `db/schema.sql` and can be initialized like this: `psql -U postgres -d kfchess \u003c db/schema.sql`.\n\n### Setting up Flask\n\nIt's best to run Python in some sort of [virtual environment](http://docs.python-guide.org/en/latest/dev/virtualenvs/). There are a number of ways to do this, but here is one example of how to set it up. This will install all the necessary dependencies for the application server.\n\n```\nvirtualenv .env\nsource .env/bin/activate\npip install -r requirements.txt\n```\n\nTo get the server to run, provide a `config.py` file in the root of the repository that contains environment-specific configuration. This file should look something like this:\n\n```\nFLASK_SECRET_KEY = 'somerandomstringhere'\n\nGOOGLE_CLIENT_ID = ''\nGOOGLE_CLIENT_SECRET = ''\n\nAWS_REGION = 'us-west-2'\nAWS_ACCESS_KEY = ''\nAWS_SECRET_KEY = ''\n```\n\nWithout the Google Cloud and AWS keys, a few features won't work, namely the login mechanism and uploading profile pictures.\n\nNow use `FLASK_APP=main.py FLASK_DEBUG=1 flask run -h 127.0.0.1 -p 5001` to start it. It listens on port 5001. This server does hot reloading on the python files, so any changes made to the code will restart the server.\n\n### Setting up webpack\n\nAll of the JavaScript code is in the `ui/` directory. From there, run `npm install .` to install all the necessary dependencies for the frontend. Then `npm run dev` will start the webpack development server that hosts the frontend locally.\n\nNow navigate to `http://localhost:8081/` and you should see the Kung Fu Chess site!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaladin8%2Fkfchess","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpaladin8%2Fkfchess","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaladin8%2Fkfchess/lists"}