terminal-chess


Nameterminal-chess JSON
Version 0.0.2 PyPI version JSON
download
home_page
SummaryA minimalistic python terminal-chess application
upload_time2023-02-04 01:06:07
maintainer
docs_urlNone
author
requires_python>=3.8
licenseMIT License Copyright (c) 2022 Kevin Tarta Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords chess terminal console interactive
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # terminal-chess
A python based terminal chess application. Uses ANSI escape sequences to print board squares and clear the screen – for reprinting. Visual UI likely to vary based on terminal and terminal settings/preferences.

![A screenshot of the starting game board](https://github.com/elveskevtar/terminal-chess/blob/mainline/game.png "Starting Game Board")
*Initial game board, waiting for first player's input*

Input to this application is standard [algebraic notation](https://en.wikipedia.org/wiki/Algebraic_notation_(chess)). Long/fully-expanded algebraic notation, ICCF numeric notation, PGN, minimal/abbreviated algebraic notation are not supported yet, but may be in the future.

## Bug/Issue Reporting
Submit these to Github [issues](https://github.com/elveskevtar/terminal-chess).

Some things to keep in mind:
1. Prevent duplicates - search existing open and even closed issues before submitting
2. Rule out local issues - could this be an issue with your terminal/settings/preferences?
3. Provide steps to reproduce - e.g. if this is a bug in chess logic, provide the input that produces the bug
4. Provide environment details - if applicable, provide information like OS, terminal emulator, python version, terminal settings/preferences
5. Be respectful - this is a place for fun and collaboration :) keep it clean and respectful

Failure to follow these may result in your issue/bug report being immediately closed or ignored until the relevant details are provided.

## Feature Requests
Submit these to Github [issues](https://github.com/elveskevtar/terminal-chess). Please consider that this project is being worked on in the maintainer's free time so you are much more likely to have your feature if you make it yourself! See [Development](#development). Please cross-reference your feature request with items [In Development](#in-development) which have already been considered and likely to be picked up at some point.

## In Development
These are some of the items that have been thought of as potential next features/improvements to the current implementation. This list does not necessarily guarantee that the feature will ever be implemented but they have been considered.

1. General refactoring of the logic, initial implementation was done as a quick MVP focusing on correctness and not maintainability or future development. This is a high priority item.
2. Better UI/UX: this includes listing the moves already played, ~~the pieces captured per player~~, an option to flip the board display each turn, better help messages, etc.
3. Serialization and ability to save/continue a game
4. Draws/surrenders
5. Turn/game clock and different game modes like bullet, etc.
6. A hardy test suite
7. Allow other input notations and support formats like PGN
8. A simple AI

Writing a network module is something that I want to do but will take significant effort. It's on the long-term roadmap though.

## Development
Submit pull requests to Github. This project utilizes `pipenv` for development. Run `pipenv shell` to create and activate the virtual environment and use `pipenv install --dev` to install the necessary development dependencies.

* Start python virtual environment
```bash
/project-root> pipenv shell
```

* Install development dependencies
```bash
/project-root> pipenv install --dev
```

Please use flake8 to handle linting issues before submitting PRs. This includes linting for test files.

* Run linter
```bash
/project-root> flake8
```

Please run tests to ensure nothing was broken. Also, write tests for your changes if applicable.

* Run tests
```bash
/project-root> pytest
```

If you want to install the package to validate the script.

* Install terminal-chess package
```bash
/project-root> pip install .
```

* Run game from script after install
```bash
/project-root> pychess
``` 

## Tenets
A list of tenets that this project goes by:
1. Avoid unnecessary dependencies - this is a relatively minimal implementation of chess for the terminal
2. Maintainable and expandable - changes over time should promote and make future development easier & reduce tech debt; this includes linting, sufficient testing, and using proper design patterns
3. Avoid boilerplate/setup hell - avoid any changes that complicate future development or further restrict useable environments to run/develop on
4. Open source - engage the community and promote collaboration on this project

## License
`terminal-chess` is published under the MIT license; see [LICENSE](LICENSE).

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "terminal-chess",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": "Kevin Tarta <kevtar@gmail.com>",
    "keywords": "chess,terminal,console,interactive",
    "author": "",
    "author_email": "Kevin Tarta <kevtar@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/51/99/57f165f69b40a5f4439056b95b66581f24940f9c418e8bc6476a9a792bf7/terminal-chess-0.0.2.tar.gz",
    "platform": null,
    "description": "# terminal-chess\nA python based terminal chess application. Uses ANSI escape sequences to print board squares and clear the screen \u2013 for reprinting. Visual UI likely to vary based on terminal and terminal settings/preferences.\n\n![A screenshot of the starting game board](https://github.com/elveskevtar/terminal-chess/blob/mainline/game.png \"Starting Game Board\")\n*Initial game board, waiting for first player's input*\n\nInput to this application is standard [algebraic notation](https://en.wikipedia.org/wiki/Algebraic_notation_(chess)). Long/fully-expanded algebraic notation, ICCF numeric notation, PGN, minimal/abbreviated algebraic notation are not supported yet, but may be in the future.\n\n## Bug/Issue Reporting\nSubmit these to Github [issues](https://github.com/elveskevtar/terminal-chess).\n\nSome things to keep in mind:\n1. Prevent duplicates - search existing open and even closed issues before submitting\n2. Rule out local issues - could this be an issue with your terminal/settings/preferences?\n3. Provide steps to reproduce - e.g. if this is a bug in chess logic, provide the input that produces the bug\n4. Provide environment details - if applicable, provide information like OS, terminal emulator, python version, terminal settings/preferences\n5. Be respectful - this is a place for fun and collaboration :) keep it clean and respectful\n\nFailure to follow these may result in your issue/bug report being immediately closed or ignored until the relevant details are provided.\n\n## Feature Requests\nSubmit these to Github [issues](https://github.com/elveskevtar/terminal-chess). Please consider that this project is being worked on in the maintainer's free time so you are much more likely to have your feature if you make it yourself! See [Development](#development). Please cross-reference your feature request with items [In Development](#in-development) which have already been considered and likely to be picked up at some point.\n\n## In Development\nThese are some of the items that have been thought of as potential next features/improvements to the current implementation. This list does not necessarily guarantee that the feature will ever be implemented but they have been considered.\n\n1. General refactoring of the logic, initial implementation was done as a quick MVP focusing on correctness and not maintainability or future development. This is a high priority item.\n2. Better UI/UX: this includes listing the moves already played, ~~the pieces captured per player~~, an option to flip the board display each turn, better help messages, etc.\n3. Serialization and ability to save/continue a game\n4. Draws/surrenders\n5. Turn/game clock and different game modes like bullet, etc.\n6. A hardy test suite\n7. Allow other input notations and support formats like PGN\n8. A simple AI\n\nWriting a network module is something that I want to do but will take significant effort. It's on the long-term roadmap though.\n\n## Development\nSubmit pull requests to Github. This project utilizes `pipenv` for development. Run `pipenv shell` to create and activate the virtual environment and use `pipenv install --dev` to install the necessary development dependencies.\n\n* Start python virtual environment\n```bash\n/project-root> pipenv shell\n```\n\n* Install development dependencies\n```bash\n/project-root> pipenv install --dev\n```\n\nPlease use flake8 to handle linting issues before submitting PRs. This includes linting for test files.\n\n* Run linter\n```bash\n/project-root> flake8\n```\n\nPlease run tests to ensure nothing was broken. Also, write tests for your changes if applicable.\n\n* Run tests\n```bash\n/project-root> pytest\n```\n\nIf you want to install the package to validate the script.\n\n* Install terminal-chess package\n```bash\n/project-root> pip install .\n```\n\n* Run game from script after install\n```bash\n/project-root> pychess\n``` \n\n## Tenets\nA list of tenets that this project goes by:\n1. Avoid unnecessary dependencies - this is a relatively minimal implementation of chess for the terminal\n2. Maintainable and expandable - changes over time should promote and make future development easier & reduce tech debt; this includes linting, sufficient testing, and using proper design patterns\n3. Avoid boilerplate/setup hell - avoid any changes that complicate future development or further restrict useable environments to run/develop on\n4. Open source - engage the community and promote collaboration on this project\n\n## License\n`terminal-chess` is published under the MIT license; see [LICENSE](LICENSE).\n",
    "bugtrack_url": null,
    "license": "MIT License  Copyright (c) 2022 Kevin Tarta  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.",
    "summary": "A minimalistic python terminal-chess application",
    "version": "0.0.2",
    "split_keywords": [
        "chess",
        "terminal",
        "console",
        "interactive"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f34f8be727ec3843dee96ab79db18e3d4d213b10c27e64f4fe44bdef0675b209",
                "md5": "521bc18f75032eb7e63479abcba98f92",
                "sha256": "a2e59d3242ecf8fcb73510328aa21d543acc9d26eb4f853b71b8d57ee0818696"
            },
            "downloads": -1,
            "filename": "terminal_chess-0.0.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "521bc18f75032eb7e63479abcba98f92",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 10650,
            "upload_time": "2023-02-04T01:06:05",
            "upload_time_iso_8601": "2023-02-04T01:06:05.503308Z",
            "url": "https://files.pythonhosted.org/packages/f3/4f/8be727ec3843dee96ab79db18e3d4d213b10c27e64f4fe44bdef0675b209/terminal_chess-0.0.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "519957f165f69b40a5f4439056b95b66581f24940f9c418e8bc6476a9a792bf7",
                "md5": "c1a6f6cbdde92a44753a93a8402ad8ca",
                "sha256": "c293c10a648a7846ce5825cfe5b9745c86649449ed7f7af4b87054792c1041d2"
            },
            "downloads": -1,
            "filename": "terminal-chess-0.0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "c1a6f6cbdde92a44753a93a8402ad8ca",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 12663,
            "upload_time": "2023-02-04T01:06:07",
            "upload_time_iso_8601": "2023-02-04T01:06:07.257385Z",
            "url": "https://files.pythonhosted.org/packages/51/99/57f165f69b40a5f4439056b95b66581f24940f9c418e8bc6476a9a792bf7/terminal-chess-0.0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-02-04 01:06:07",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "lcname": "terminal-chess"
}
        
Elapsed time: 0.03934s