{"id":15780238,"url":"https://github.com/shahank42/connect4-cli","last_synced_at":"2026-04-27T23:32:35.416Z","repository":{"id":61364837,"uuid":"538419956","full_name":"shahank42/connect4-cli","owner":"shahank42","description":"Play the popular Connect 4 game directly from your command line! ","archived":false,"fork":false,"pushed_at":"2022-10-13T18:04:29.000Z","size":119,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-10-04T18:41:35.999Z","etag":null,"topics":["c-plus-plus","cli","cli-app","cli-application","cli-game","cmd","command-line","command-line-game","connect-four","connect-four-game","connect4","connect4-cpp","cpp","game","terminal","terminal-game"],"latest_commit_sha":null,"homepage":"","language":"C++","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/shahank42.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":"2022-09-19T09:10:51.000Z","updated_at":"2023-05-03T04:23:27.000Z","dependencies_parsed_at":"2022-10-15T22:54:10.399Z","dependency_job_id":null,"html_url":"https://github.com/shahank42/connect4-cli","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/shahank42/connect4-cli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shahank42%2Fconnect4-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shahank42%2Fconnect4-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shahank42%2Fconnect4-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shahank42%2Fconnect4-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shahank42","download_url":"https://codeload.github.com/shahank42/connect4-cli/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shahank42%2Fconnect4-cli/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32360110,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-27T20:07:02.737Z","status":"ssl_error","status_checked_at":"2026-04-27T20:07:00.910Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["c-plus-plus","cli","cli-app","cli-application","cli-game","cmd","command-line","command-line-game","connect-four","connect-four-game","connect4","connect4-cpp","cpp","game","terminal","terminal-game"],"created_at":"2024-10-04T18:40:57.952Z","updated_at":"2026-04-27T23:32:35.395Z","avatar_url":"https://github.com/shahank42.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# connect4-cli\nPlay the popular Connect 4 game directly from your command line! \n\nTwo people are required to play.\n\n![Demo](https://github.com/shahank42/connect4-cli/blob/main/connect4-cli-demo.gif?raw=true)\n\n## What is Connect 4?\nAccording to Wikipedia, Connect Four is a two-player connection board game, in which the players choose a color and then take turns dropping colored tokens into a seven-column, six-row vertically suspended grid.\n\nThe objective of the game is to be the first to form a horizontal, vertical, or diagonal line of four of one's own tokens.\n\n## Installation Instructions\nNothing. Just download the release and execute the binary to start playing!\n\n## Compilation Instructions\nDownload the source code and go into the directory with the `main.cpp` file.\nExecute the following command for Windows:\n```\ng++ -std=c++17 main.cpp include\\Connect4Board.h src\\connect4Board.cpp include\\Player.h include\\Player.cpp -o bin\\Release\\connect4-cli-v0.1.exe -O3 -NDEBUG -s\n```\nor for Linux:\n```\ng++ -std=c++17 main.cpp include/Connect4Board.h src/connect4Board.cpp include/Player.h include/Player.cpp -o bin/Release/connect4-cli-v0.1.exe -O3 -NDEBUG -s\n```\nto get compile the release binary.\nThen simply execute it (located at `bin/Release`) to start playing.\n\nFor a debug build just remove the compilation flags at the end of the flag.\n\n---\n\nAnother way to compile would be build using Code::Blocks.\n\nBuilding with Visual Studio C++ is not recommended, because of a macro collision error.\n\n## Gameplay Instructions\nThe prompt at the bottom left shows which players turn it is. The corresponding player can enter the column number (from 1 to 7) in which they desire to place their coin.\n\n## Future Update Plans\nThis project, though completely playable, is still not over. I still have plans to:\n\n* Implement player names\n* Implement custom player symbol selection\n* Implement a separate function to handle the entire game loop\n* Fix certain stray implicit type conversions\n* Tidy up the code\n* Add more accurate and meaningful comments\n\nStay tuned!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshahank42%2Fconnect4-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshahank42%2Fconnect4-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshahank42%2Fconnect4-cli/lists"}