brianch / offline-chess-puzzles

Tool to view and solve puzzles from the lichess puzzle database
MIT License
125 stars 17 forks source link

Remember Min, Max, Tactics Theme, Opening #8

Closed Dumuzy closed 1 year ago

Dumuzy commented 1 year ago

I love this software!
And I like to do the same set of puzzles again and again. For that, it would be very helpful, if on the main page the min and max-rating, the tactics theme and the opening would be remebered after pressing Search. And when I open the program next time, these values should be preset alredy.

brianch commented 1 year ago

Hello,

Thanks for the suggestion! This shouldn't be too hard to do, when I find some time I can implement it.

Dumuzy commented 1 year ago

I would even like to help you out - I am a software guy myself. I've cloned your project. But pitily I cannot get it to compile completely. It's builiding dozens of packets (what for I'm wondering?!) But it fails on soloud-sys with the message below. Seems it misses cmake. Indeed, there is no cmake on my system. I'm using VS Code. And the VS compiler pack or whatever was the name. Any idea how to continue?

error: failed to run custom build command for soloud-sys v1.0.2

Caused by: process didn't exit successfully: c:\Daten\Schach\OffChePu\target\debug\build\soloud-sys-d7bfe67dabe37ad2\build-script-main (exit code: 101) --- stdout cargo:rerun-if-changed=build/android.rs cargo:rerun-if-changed=build/link.rs cargo:rerun-if-changed=build/main.rs cargo:rerun-if-changed=build/source.rs cargo:rerun-if-env-changed=CC cargo:rerun-if-env-changed=CXX cargo:rerun-if-env-changed=CFLAGS cargo:rerun-if-env-changed=CXXFLAGS cargo:rerun-if-changed=sys/CMakeLists.txt cargo:rerun-if-changed=sys/soloud_new.cpp cargo:rerun-if-changed=sys/soloud_derives.h cargo:rerun-if-changed=sys/soloud_derives.cpp CMAKE_TOOLCHAIN_FILE_x86_64-pc-windows-msvc = None CMAKE_TOOLCHAIN_FILE_x86_64_pc_windows_msvc = None HOST_CMAKE_TOOLCHAIN_FILE = None CMAKE_TOOLCHAIN_FILE = None CMAKE_GENERATOR_x86_64-pc-windows-msvc = None CMAKE_GENERATOR_x86_64_pc_windows_msvc = None HOST_CMAKE_GENERATOR = None CMAKE_GENERATOR = None CMAKE_PREFIX_PATH_x86_64-pc-windows-msvc = None CMAKE_PREFIX_PATH_x86_64_pc_windows_msvc = None HOST_CMAKE_PREFIX_PATH = None CMAKE_PREFIX_PATH = None CMAKE_x86_64-pc-windows-msvc = None CMAKE_x86_64_pc_windows_msvc = None HOST_CMAKE = None CMAKE = None running: "cmake" "C:\Users\s\.cargo\registry\src\github.com-1ecc6299db9ec823\soloud-sys-1.0.2\sys" "-G" "Visual Studio 17 2022" "-Thost=x64" "-Ax64" "-DWITH_WINMM=ON" "-DCMAKE_EXPORT_COMPILE_COMMANDS=ON" "-DCMAKE_INSTALL_PREFIX=c:\Daten\Schach\OffChePu\target\debug\build\soloud-sys-18ee3ad703849bad\out" "-DCMAKE_C_FLAGS= -nologo -MD -Brepro" "-DCMAKE_C_FLAGS_RELEASE= -nologo -MD -Brepro" "-DCMAKE_CXX_FLAGS= -nologo -MD -Brepro" "-DCMAKE_CXX_FLAGS_RELEASE= -nologo -MD -Brepro" "-DCMAKE_ASM_FLAGS= -nologo -MD -Brepro" "-DCMAKE_ASM_FLAGS_RELEASE= -nologo -MD -Brepro" "-DCMAKE_BUILD_TYPE=Release"

--- stderr fatal: not a git repository (or any of the parent directories): .git thread 'main' panicked at ' failed to execute command: program not found is cmake not installed?

brianch commented 1 year ago

Most dependencies come from the GUI library (iced), you can run cargo tree to take a look at the dependency graph. In Rust it's normal for projects to have many dependencies though.

About the error, yes, you need cmake installed (and in your path) as the error message told you, it's a small download and simple to install. The soloud crate (which is used to play the sound on moves), needs it.

About the feature request, I just implemented it in the last couple commits, please take a look and if you find it ok, I'll close this issue.

Dumuzy commented 1 year ago

As I cannot build it and I can't find a current package, I cannot test.

brianch commented 1 year ago

I don't understand, you just need to install cmake as instructed.

But anyway, since the feature request itself is completed, I'll close this issue.

Dumuzy commented 1 year ago

Hey brianch, because of the trouble building your app and because I don't really know Rust I and because I had some more ideas on what I would like in a chess puzzle training app, I decided to write one in C#. Your app inspired me to this! I thank you very much. If you are interested, see there: https://github.com/Dumuzy/ChessPuzzlePecker