Skip to content

Latest commit

 

History

7 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

C4CLI - A simple chess interface for command-line

C4CLI is a bash script to play chess in the command-line.

This use utf8 chars to show the pieces and the board. On tty consoles, it use letters to represent the pieces because some console fonts dont support utf8 chars.

Installation

To install, clone the script, save on '.local/bin' for only your user, or '/usr/local/bin' fo all users on system, and make it executable:

   $ git clone https://github.com/albertguedes/c4cli.git
   $ cd c4cli
   $ sudo cp c4cli.sh ~/.local/bin
   $ sudo chmod +x ~/.local/bin/c4cli.sh

Dont forget to put '~/.local/bin' on your path.

Usage

To execute, type on your terminal:

   $ c4cli.sh

and you will see the game interface

C4CLI Interface

Commands:

  • Type something like 'e2e4' to make a move.
  • Type 'h' or 'help' to show this help message.
  • Type 'q' or 'quit' to quit the game.

And that's it!

Tests

To run the tests, type:

   $ tests/test_c4cli.sh

and you will see the results.

License

MIT License https://opensource.org/licenses/MIT

Notes

  • This script is compatible at least with bash version 5.2.37 or later.
  • There are a simple rules to validate moves, but not all moves are valid, but you can adapt the moves validation to your needs, creating the rules or using a chess engine like gnuchess or stockfish.

References

About

A simples chess interface for command-line

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages