GithubHelp home page GithubHelp logo

thomas-mauran / chess-tui Goto Github PK

View Code? Open in Web Editor NEW
313.0 2.0 17.0 2.48 MB

A chess TUI implementation in rust 🦀

Home Page: https://crates.io/crates/chess-tui

License: MIT License

Rust 99.64% Dockerfile 0.17% Shell 0.19%
chess game linux-game ratatui rust tui

chess-tui's Introduction

Welcome to my github profile ! 🛰️

Alt Text

About Me

Hi there! I'm Thomas Mauran, a passionate apprentice engineer in DevOps. When I'm not immersed in code, you can find me exploring the latest in technology or enjoying outdoor adventures. 🚀

  • 🌱 I’m currently learning Kotlin, micro services and assembly

  • 🔭 All of my projects are available on github or on my portfolio

  • 📫 How to reach me Linkedin

Skills

Dev: Rust, C, TypeScript, Python, Go, Kotlin, Java

Ops: Kubernetes, Docker, Github Action, Grafana, ArgoCD, Helm

Frameworks / Libs: React, VueJS, NestJS

Databases: Postgresql, MongoDB, Elasticsearch

OS: Ubuntu, Debian, Mac OS

GitHub Stats

GitHub Stats GitHub Streak

chess-tui's People

Contributors

0323pin avatar charley04310 avatar jeromeschmied avatar jhauris avatar joshka avatar kuruyia avatar rustmilian avatar thomas-mauran avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

chess-tui's Issues

Material difference

Problem

Material difference is not shown.

Solution

Display material difference in History.

Additional context

I guess Lichess has support for this too.

feat(board): make border transparent

Problem

the boards automatically creates border for the cells to be the same size, but the borders aren´t looking great everytime

Solution

We could use cross term to get the color of the terminal and set in ui the border color to this background color

Error : No such file or directory

Tried to use the docker image, and see this error in the logs.
Are any volume mappings necessary for this to work ?

Am I correct to assume that I will be able to play the game via browser if the container is up and running ?
I dont see a mention of any ports, so I assume its port 80 by default ?

Error: Os { code: 2, kind: NotFound, message: "No such file or directory" }
Error: Os { code: 11, kind: WouldBlock, message: "Resource temporarily unavailable" }
Error: Os { code: 11, kind: WouldBlock, message: "Resource temporarily unavailable" }
Error: Os { code: 11, kind: WouldBlock, message: "Resource temporarily unavailable" }
Error: Os { code: 11, kind: WouldBlock, message: "Resource temporarily unavailable" }

Config file storage

Description

As for now, the config file (containing chess-engine path) seems to be stored under $HOME/.chess-tui.

Expected behavior

It would be a lot better to store it under $HOME/.config/chess-tui/chess-engine.toml or something. The dirs crate fits the purpose to resolve this issue I think.

Environment

  • OS: Arch Linux
  • Terminal Emulator: Alacritty
  • Font: Recursive (patched)
  • Crate version: latest git
  • Backend: crossterm

feat: pgn import

Import a pgn game position

Be able to select a file to import as a new game position

Add "Escape" event to helper menu

Problem

First try, I didn't know how to deselect the piece selected by mistake.

Solution

Add this following line into ui.rs:

Line::from("ESCAPE : Deselect a piece or cancel a move"),
``

fix(historic): line 8 is translated to 0

Description

When moving a piece from the 8th row (black first one) the historic indicates a 0 instead of an 8.

To Reproduce

  • move a piece from the 8th row and check the historic

Expected behavior

display 8 instead of 0

Screenshots

image

Keyboard shortcuts for moves

Problem

You have to manually select a square to move a piece, which is a bit tedious.

Solution

It would be good to be able to quickly use the keyboard for this (e.g a5 or Nc3).

feat: home menu

Home menu

Implement a home menu when starting the game with the following options:

  • New game
  • Play against a bot
  • Import a game

Takeback

Problem

Sometimes enter gets pressed accidentally, which is kind of annoying.

Solution

A character like backspace could be assigned to takeback.

Additional context

As far as I'm concerned lichess has a feature like this too, so it is useful when lichess integration is done.

feat: pgn export

Implement a pgn export method

Solution

  • Create a new method to convert move_history into pgn
  • store it into a file

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.