{"id":20728964,"url":"https://github.com/hellojwilde/comp50cp-project","last_synced_at":"2025-09-14T16:47:28.028Z","repository":{"id":22891482,"uuid":"26239800","full_name":"hellojwilde/comp50cp-project","owner":"hellojwilde","description":null,"archived":false,"fork":false,"pushed_at":"2014-12-16T18:33:54.000Z","size":800,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-11T09:49:46.683Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Erlang","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/hellojwilde.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2014-11-05T21:06:59.000Z","updated_at":"2019-02-11T23:46:06.000Z","dependencies_parsed_at":"2022-08-21T15:31:15.090Z","dependency_job_id":null,"html_url":"https://github.com/hellojwilde/comp50cp-project","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/hellojwilde/comp50cp-project","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellojwilde%2Fcomp50cp-project","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellojwilde%2Fcomp50cp-project/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellojwilde%2Fcomp50cp-project/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellojwilde%2Fcomp50cp-project/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hellojwilde","download_url":"https://codeload.github.com/hellojwilde/comp50cp-project/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hellojwilde%2Fcomp50cp-project/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269654977,"owners_count":24454351,"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","status":"online","status_checked_at":"2025-08-09T02:00:10.424Z","response_time":111,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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-11-17T04:40:46.494Z","updated_at":"2025-08-10T00:06:40.452Z","avatar_url":"https://github.com/hellojwilde.png","language":"Erlang","funding_links":[],"categories":[],"sub_categories":[],"readme":"# \"presidential fanfiction\"\n\n## Setup\n\nYou'll need the following installed on your computer:\n\n- Erlang.\n- [Rebar](https://github.com/rebar/rebar), a package manager for Erlang. \n  Get it with the appropriate system package.\n\nYou can then use rebar to install the Erlang dependencies:\n\n    $ rebar get-deps\n    $ rebar compile\n\n## Running the Server\n\nIn order to point `erl` at all of the deps we installed via Rebar, we have to \nrun it with:\n\n    erl -pa ebin deps/*/ebin\n\nThen, from there, run:\n\n    manager:init().\n\nYou can then go to the following URL on your local machine provided port 8888 \nis not already bound to some other process and play with it:\n\n    http://localhost:8888\n\n## File Structure Overview\n\n- `include/` - record declarations\n    + `vote.hrl` - frontend server config record\n- `src/` - source files\n    + `vote.app.src` - tells rebar what to compile\n    + `booth.erl` - routes votes between UI and talliers\n    + `frontend.erl` - configures and starts YAWS\n        * `frontent_config.erl` - unpacks `vote.hrl`\n        * `frontend_sup.erl` - supervises YAWS started in `frontend.erl`\n        * `result_events.erl` - sends events from `winner_collector.erl`\n        * `winner_collector.erl` - collects winners from talliers, \n          maintaining list of most recent winners, and allowing others to\n          subscribe for notifications on changes\n    + `manager.erl` - starts everything, informs modules about each other\n    + `registrar.erl` - assigns passwords and voting locations to others,\n      prevents duplicate registations, notifies booths of valid passwords\n    + `tally.erl` - implements talliers\n        * `count_map.erl` - maps, whose values are numbers, which are \n          combined by adding values\n        * `pairwise.erl` - computes the graph of pairwise differences \n          between candidates\n        * `point_scheme.erl` - implements four schemes which assign points \n          to candidates\n        * `schultze.erl` - **the best voting scheme**\n        * `vote_count.erl` - counts votes\n        * `all_votes.erl` - lists all votes\n        * `debug.erl` - collection of debug utilities\n- `www/` - YAWS view files\n    + `index.yaws` - list of major pages in the web UI\n    + `magic.yaws` - contains buttons to flush and simulate votes\n    + `register.yaws` - contains registration form\n        * `register_post.yaws` - processes registration form,\n          shows success/fail messages\n    + `vote.yaws` - contains vote form\n        * `vote_post.yaws` - processes vote, shows success/fail messages\n    + `winners.yaws` - displays winners\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhellojwilde%2Fcomp50cp-project","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhellojwilde%2Fcomp50cp-project","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhellojwilde%2Fcomp50cp-project/lists"}