A CLI sliding puzzle game
Project description
CLI Sliding Puzzle Game
A command-line interface sliding puzzle game built with Python.
Installation
To install the game, you need Python 3.7 or higher and pip. Then run:
pip install cli-sliding-puzzle
Playing the Game
After installation, run the game by typing:
sliding-puzzle
Use arrow keys to move tiles. Press 'q' to quit.
Development
Setup
-
Clone the repository: git clone https://github.com/yourusername/cli-sliding-puzzle.git cd cli-sliding-puzzle
-
Create a virtual environment: python -m venv venv source venv/bin/activate # On Windows, use
venv\Scripts\activate -
Install development dependencies: pip install build twine setuptools_scm
Building and Publishing
-
Ensure all changes are committed to git.
-
List existing tags to determine the next version number:
git tag --list
-
Create a new git tag for the version:
git tag -a vX.X.X -m "Release version X.X.X" git push origin vX.X.X
-
Clean up the dist directory:
rm -rf dist/*
-
Build the package:
python -m build
-
Test the package locally:
# List the contents of the dist directory ls dist/ # Install the latest version (replace X.X.X with the latest version number you see) pip install dist/cli_sliding_puzzle-X.X.X-py3-none-any.whl
-
Upload to TestPyPI:
twine upload --repository testpypi dist/*
-
Test the TestPyPI upload:
# Create a new virtual environment for testing python -m venv test_venv source test_venv/bin/activate # On Windows, use `test_venv\Scripts\activate` # Install the package from TestPyPI pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple cli-sliding-puzzle # Test the installed package sliding-puzzle # Deactivate the test environment when done deactivate
-
If everything works, upload to PyPI:
twine upload dist/*
License
This project is licensed under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file cli_sliding_puzzle-0.1.4.post0.tar.gz.
File metadata
- Download URL: cli_sliding_puzzle-0.1.4.post0.tar.gz
- Upload date:
- Size: 4.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1f4049a6218862216c05a3fd525b0f7d5de7db5923bb706316e0e3a5c5e720fd
|
|
| MD5 |
dc7262b4662428e0f81fdce2309a5e3a
|
|
| BLAKE2b-256 |
3fb6758af83c861cf4d4791a175de002304bee1158a3b0fb6334e0b1ff3aade0
|
File details
Details for the file cli_sliding_puzzle-0.1.4.post0-py3-none-any.whl.
File metadata
- Download URL: cli_sliding_puzzle-0.1.4.post0-py3-none-any.whl
- Upload date:
- Size: 4.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1fbe0158cb6cecb6ec73168640f2503264426f46344119b1b31d69332df62a2f
|
|
| MD5 |
0d187d6fab534a3115dedc70a5c6d72f
|
|
| BLAKE2b-256 |
872f1576fc9392fcccd073c6ee77d5818c182e94b305c6ddab4e5706cd458988
|