{"id":21306556,"url":"https://github.com/techmdw/minesweeper","last_synced_at":"2025-07-11T21:31:35.964Z","repository":{"id":151635759,"uuid":"624557945","full_name":"TechMDW/minesweeper","owner":"TechMDW","description":"Minesweeper in the terminal! Written in pure go and does not use any third party package/module","archived":false,"fork":false,"pushed_at":"2023-06-17T12:33:37.000Z","size":125,"stargazers_count":7,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-07-11T02:21:41.331Z","etag":null,"topics":["cli","cli-app","cli-game","minesweeper","minesweeper-cli","minesweeper-terminal","terminal-game"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TechMDW.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,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-04-06T18:32:53.000Z","updated_at":"2023-05-05T14:15:19.000Z","dependencies_parsed_at":"2024-11-21T16:25:15.678Z","dependency_job_id":"09fec330-a41d-4ff5-a6c1-7936c6ef177e","html_url":"https://github.com/TechMDW/minesweeper","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/TechMDW/minesweeper","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TechMDW%2Fminesweeper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TechMDW%2Fminesweeper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TechMDW%2Fminesweeper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TechMDW%2Fminesweeper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TechMDW","download_url":"https://codeload.github.com/TechMDW/minesweeper/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TechMDW%2Fminesweeper/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264902418,"owners_count":23681062,"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":["cli","cli-app","cli-game","minesweeper","minesweeper-cli","minesweeper-terminal","terminal-game"],"created_at":"2024-11-21T16:24:32.834Z","updated_at":"2025-07-11T21:31:35.957Z","avatar_url":"https://github.com/TechMDW.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Minesweeper CLI\n\nThis is a command-line version of the classic Minesweeper game written in Go. Please note that this project is a work in progress (WIP) and may have some bugs or incomplete features.\n\n## How to Play\n\nBefore getting started I recommend checking out the start flags by running `\u003cbinary\u003e -h`. This will allow you to change the \"rules\" of the game.\n\nThe game provides a simple command-line interface for playing Minesweeper. The board is displayed as a grid of cells, with row and column numbers as labels. The game supports the following commands:\n\n- `r \u003crow\u003e \u003ccol\u003e`: Reveal the cell at the specified row and column.\n- `c \u003ccol\u003e \u003crow\u003e`: Reveal the cell at the specified column and row\n- `f \u003crow\u003e \u003ccol\u003e`: Toggle a flag on or off at the specified row and column.\n- `header`: Hide or show the header information.\n- `footer`: Hide or show the footer information.\n- `q`, `quit`, `exit`: Quit the game.\n- `h`, `help`, `imlost`: Display the help message with a list of commands.\n\nThe game continues until all non-mine cells are revealed or a mine is revealed.\n\n## Start flags\n\n### Game options\n\n- `-rows \u003cint\u003e`: Number of rows (default: 10)\n- `-cols \u003cint\u003e`: Number of columns (default: 10)\n- `-mines \u003cint\u003e`: Number of mines (default: 10)\n- `-seed \u003cint64\u003e`: Seed for random number generator (default: current Unix timestamp in nanoseconds)\n\n### Display options\n\n- `-start \u003cint\u003e`: Start index (row and column start at this index, default: 1)\n- `-ansi=\u003ctrue|false\u003e`: Use ANSI escape codes to color the board (default: true)\n\n### Help\n\n- `-h / -help`: Show help (default: false)\n\n### Debug\n\n- `-clear=\u003ctrue|false\u003e`: Automatically clear the screen (default: true)\n\n### Example usage\n\n1. `minesweeper -rows 10 -cols 20 -mines 30`\n2. `minesweeper -h`\n3. `minesweeper -ansi=false -clear=false -seed 50`\n4. `minesweeper -rows 30 -ansi=false`\n\n## Download prebuild package\n\n1. Download the latest version of Minesweeper from the [GitHub releases page](https://github.com/TechMDW/minesweeper/releases/latest).\n2. Open your terminal.\n3. Navigate to the directory where they downloaded the file `cd \u003cpath\u003e` (Linux/macOS/Windows).\n4. Run the game binary with `./minesweeper` (Linux/macOS) or `minesweeper.exe` (Windows).\n\n## Download via `go install`\n\n[Go](https://golang.org/) is required to be installed when following this!\n\nTo install and run the game, you need to have the [Go](https://go.dev/dl/) installed on your system. Once Go is installed, follow these\n\n1. Open a terminal on your computer.\n\n2. Run the following command to download and install the Minesweeper CLI:\n   `go install github.com/TechMDW/minesweeper/cmd/minesweeper@latest`\n   This will download and install the latest version of the Minesweeper CLI on your system.\n\n   OR\n\n   `go install github.com/TechMDW/minesweeper/cmd/minesweeper@\u003cversion\u003e`\n   This will download a specific version if you replace the `\u003cversion\u003e` with an available [releases](https://github.com/TechMDW/minesweeper/releases)\n\n3. Once installation is complete, you can run the Minesweeper CLI from anywhere in your terminal by typing:\n   `minesweeper`\n   This should start the game and display the game board in your terminal.\n\n## Building and Running\n\nTo build and run the game, you need to have the [Go](https://go.dev/dl/) installed on your system. Once Go is installed, follow these steps:\n\n1. Clone the repository or download the source code.\n2. Open a terminal and navigate to the project directory.\n3. Run `go build` to build the game binary.\n4. Navigate to the directory where the binary was built.\n5. Run the game binary with `./minesweeper` (Linux/macOS) or `minesweeper.exe` (Windows).\n\nYou can also run the game directly without building the binary by running `go run main.go` from the project directory.\n\n## Contributing\n\nAs this project is a work in progress, contributions are welcome! Feel free to report bugs, suggest improvements, or submit pull requests.\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftechmdw%2Fminesweeper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftechmdw%2Fminesweeper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftechmdw%2Fminesweeper/lists"}