All Projects → Cqsi → Lichs

Cqsi / Lichs

Licence: mit
♟ Play chess against real players in your terminal using Lichess

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Lichs

Bytepath
A replayable arcade shooter with a focus on build theorycrafting made using Lua and LÖVE.
Stars: ✭ 1,119 (+1498.57%)
Mutual labels:  terminal
Download
UI mod for Dota 2 Auto Chess that adds several QoL improvements to the UI
Stars: ✭ 65 (-7.14%)
Mutual labels:  chess
Rat
Compose shell commands to build interactive terminal applications
Stars: ✭ 1,158 (+1554.29%)
Mutual labels:  terminal
Webterminal
ssh rdp vnc telnet sftp bastion/jump web putty xshell terminal jumpserver audit realtime monitor rz/sz 堡垒机 云桌面 linux devops sftp websocket file management rz/sz otp 自动化运维 审计 录像 文件管理 sftp上传 实时监控 录像回放 网页版rz/sz上传下载/动态口令 django
Stars: ✭ 1,124 (+1505.71%)
Mutual labels:  terminal
Npmf
Fetch quick info of a npm pacakge using terminal
Stars: ✭ 64 (-8.57%)
Mutual labels:  terminal
Mocha Chrome
☕️ Run Mocha tests using headless Google Chrome
Stars: ✭ 66 (-5.71%)
Mutual labels:  terminal
Rtscli
Python CLI Stocks Ticker + Portfolio Tracker
Stars: ✭ 61 (-12.86%)
Mutual labels:  terminal
Cross Platform Node Guide
📗 How to write cross-platform Node.js code
Stars: ✭ 1,161 (+1558.57%)
Mutual labels:  terminal
Ginseng
C++ REPL Tool Builder
Stars: ✭ 65 (-7.14%)
Mutual labels:  terminal
Viter
A Vim-ish terminal emulator written and expandable in Python.
Stars: ✭ 69 (-1.43%)
Mutual labels:  terminal
Sub Tv Cli
Downloading your series subtitles via terminal 📺
Stars: ✭ 63 (-10%)
Mutual labels:  terminal
Chessli
A free and open source chess improvement app that combines the power of Lichess and Anki.
Stars: ✭ 64 (-8.57%)
Mutual labels:  chess
Nyancat
Nyancat in your terminal, rendered through ANSI escape sequences. This is the source for the Debian package `nyancat`.
Stars: ✭ 1,144 (+1534.29%)
Mutual labels:  terminal
Xterm.dart
💻 xterm.dart is a fast and fully-featured terminal emulator for Flutter, with support for mobile and desktop platforms.
Stars: ✭ 63 (-10%)
Mutual labels:  terminal
Tryjshell
Try JShell on Web
Stars: ✭ 69 (-1.43%)
Mutual labels:  terminal
Ving
🐸 A ping utility with nice output, with powerful traceroute and port probe.
Stars: ✭ 62 (-11.43%)
Mutual labels:  terminal
Pgn2gif
A small tool that generates gif of a chess game
Stars: ✭ 65 (-7.14%)
Mutual labels:  chess
Wirb
Ruby Object Inspection for IRB
Stars: ✭ 69 (-1.43%)
Mutual labels:  terminal
Reminders Cli
Command-line interface to interact with the Reminders.app
Stars: ✭ 67 (-4.29%)
Mutual labels:  terminal
Progress.c
Progress display lib for c
Stars: ✭ 67 (-4.29%)
Mutual labels:  terminal


Lichs (Lichess in the Terminal)

project-active contributions-welcome license-mit pypi-version

Info and requirements

  • Uses Lichess, which means that you need to have a Lichess account
  • Only Classical and Rapid games because the Lichess API doesn't allow anything else (quite frankly, Blitz and Bullet like games wouldn't be a lot of fun since you would have to input the coordinates really fast)
  • This program uses SAN-notation, see the Important-section.

Lichs uses the Lichess API (more exactly berserk) to make it possible for you to play against other real players directly in the terminal on Lichess servers. This project is still in its early stages; there's no chat support, pretty bad graphics, no ranked games and probably some bugs.

If like this project, be sure to also check out Nick Zuber's Chs-project, since it was his project that inspired me to do this in the first place.

Installation

This package is available on PyPi, therefore just run:

$ pip install lichs

and the program will be installed. The next step is to generate a personal API-key.

How to generate a personal API token

  1. Create a Lichess API token, log into Lichess if necessary
  2. Click the button Submit in the lower right corner
  3. Copy the token shown in the brown box
  4. Jump into your terminal and write lichs <api_token> (put your API token instead of <api_token>) and run the command. To get this clear, an example would have been lichs lzRceo5XOUND74Lm. You should then see a message to confirm that the API token has been saved.

Usage

You start playing by typing the command lichs into your terminal:

$ lichs

That will take you to the intro screen:

Welcome to Lichess!

What kind of chess do you want to play?
1. Rapid (10+0)
2. Classical (30+0)

Enter 1 or 2:

That should be pretty self-explanatory, you basically choose between Rapid and Classical (the Lichess API doens't support anything else) by entering either 1 or 2. The timing of the games is also listed there; Rapid is 10min and Classical 30min (without extra-time, I might add support for extra-time later)

When you have input either 1 or 2, the program will start to search after an opponent. It shouldn't take long and the game should start pretty quickly.

Searching after opponent...
An opponent was found!

Then the program will let you know whether you're the color white or black. After that you will start playing; the program will output the board after every move and ask for your move when it's your turn.

r n b q k b n r
p p p p p p p p
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . P . . .
P P P P . P P P
R N B Q K B N R

Above is an example of the board displayed. Note: at the moment the board is always displayed from the white's side, because I don't know how to fix this.

Important

When the program asks for your move, you need to input the move in standard algebraic notation (SAN). Basically, it specifies which piece to move and to where. As an example, to move a knight from g1 to f3, you type in Nf3 (N is for Knight, since Rook uses K). If you want to learn more, click on the link above.

The program will inform you if you can't make the move you have input.

Support for UCI-notation might get added later.

Contributions

See the CONTRIBUTING.md file for how to contribute.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].