update the readme
This commit is contained in:
parent
f65b9f007d
commit
22a8c48888
95
README.md
95
README.md
@ -8,27 +8,88 @@ whatever you like with it.
|
|||||||
|
|
||||||
## Requirements
|
## Requirements
|
||||||
|
|
||||||
- C90 compliant compiler (tested with gcc -std=c90 -pedantic -Wpedantic)
|
### Unix/Linux/macOS
|
||||||
- Standard C library
|
- C90 compliant compiler (gcc recommended)
|
||||||
- Ncurses
|
- ncurses library
|
||||||
|
- GNU Make
|
||||||
|
|
||||||
|
### DOS
|
||||||
|
- DJGPP or Borland C compiler
|
||||||
|
- PDCurses library
|
||||||
|
- GNU Make (for DJGPP)
|
||||||
|
|
||||||
|
See [DOS_BUILD.md](DOS_BUILD.md) for detailed DOS build instructions.
|
||||||
|
|
||||||
## Build
|
## Build
|
||||||
|
|
||||||
|
### Using Make (Recommended)
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ make
|
||||||
```
|
```
|
||||||
|
|
||||||
|
This will:
|
||||||
|
- Compile all source files with C90 compliance flags
|
||||||
|
- Create the `cordle` executable in `build/`
|
||||||
|
- Copy wordlists to `build/wordlists/`
|
||||||
|
|
||||||
|
### Alternative: Using build.sh
|
||||||
|
|
||||||
|
```bash
|
||||||
$ ./build.sh
|
$ ./build.sh
|
||||||
Building application.
|
Building application.
|
||||||
Compile successful. Copying wordlists...
|
Compile successful. Copying wordlists...
|
||||||
Build completed.
|
Build completed.
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Other Make Targets
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ make help # Show all available targets
|
||||||
|
$ make clean # Remove build artifacts
|
||||||
|
$ make rebuild # Clean and rebuild from scratch
|
||||||
|
$ make install # Install system-wide to /usr/local
|
||||||
|
$ make uninstall # Remove installed files
|
||||||
|
```
|
||||||
|
|
||||||
|
## Install
|
||||||
|
|
||||||
|
### System-wide Installation (Unix/Linux/macOS)
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ sudo make install
|
||||||
|
```
|
||||||
|
|
||||||
|
This installs:
|
||||||
|
- Binary to `/usr/local/bin/cordle`
|
||||||
|
- Wordlists to `/usr/local/share/cordle/wordlists/`
|
||||||
|
|
||||||
|
The game will automatically find wordlists in:
|
||||||
|
1. `wordlists/` (relative to current directory)
|
||||||
|
2. `/usr/local/share/cordle/wordlists/`
|
||||||
|
3. `$HOME/.local/share/cordle/wordlists/`
|
||||||
|
4. Custom path via `--wordlist` option
|
||||||
|
|
||||||
|
### Manual Installation
|
||||||
|
|
||||||
|
Copy the binary and wordlists to your preferred location:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ cp build/cordle ~/bin/
|
||||||
|
$ cp -R wordlists ~/bin/
|
||||||
|
```
|
||||||
|
|
||||||
|
### DOS Installation
|
||||||
|
|
||||||
|
See [DOS_BUILD.md](DOS_BUILD.md) for DOS-specific installation instructions.
|
||||||
|
|
||||||
## Run
|
## Run
|
||||||
|
|
||||||
```
|
```bash
|
||||||
$ cd build/cordle
|
$ cordle --help
|
||||||
$ ./cordle -h
|
|
||||||
cordle - C90 Wordle Game
|
cordle - C90 Wordle Game
|
||||||
|
|
||||||
Usage: ./cordle [OPTIONS]
|
Usage: cordle [OPTIONS]
|
||||||
|
|
||||||
Difficulty Levels:
|
Difficulty Levels:
|
||||||
--easy Common everyday words (default)
|
--easy Common everyday words (default)
|
||||||
@ -45,9 +106,19 @@ Custom:
|
|||||||
--wordlist FILE Use custom word list
|
--wordlist FILE Use custom word list
|
||||||
|
|
||||||
Examples:
|
Examples:
|
||||||
./cordle --easy
|
cordle --easy
|
||||||
./cordle --techy
|
cordle --techy
|
||||||
./cordle --wordlist mywords.txt
|
cordle --wordlist mywords.txt
|
||||||
|
```
|
||||||
|
|
||||||
|
### After Installation
|
||||||
|
|
||||||
|
If installed system-wide, run from anywhere:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ cordle
|
||||||
|
$ cordle --medium
|
||||||
|
$ cordle --hard
|
||||||
```
|
```
|
||||||
|
|
||||||
## Screenshots
|
## Screenshots
|
||||||
@ -63,7 +134,3 @@ Examples:
|
|||||||
**Lose Game**
|
**Lose Game**
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
## Install
|
|
||||||
|
|
||||||
Just copy the `cordle` binary in the build directory to your `$PATH`. If you want to use the supplied wordlists, copy the `wordlists` directory to your binary directory as well. Or supply your own wordlist path using the command line options.
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user