docs: update README with installation instructions, usage examples and new logo
This commit is contained in:
3 files changed
+28
-101
No files matched your search
@@ -1,5 +1,5 @@
|
|||||||
<div align="center">
|
<div align="center">
|
||||||
<img src="assets/sample-logo-470x235.png" alt="Project Logo">
|
<img src="assets/logo.png" alt="Project Logo">
|
||||||
|
|
||||||
# KeyVibe
|
# KeyVibe
|
||||||
|
|
||||||
@@ -43,41 +43,43 @@ KeyVibe listens to your keyboard events and plays high‑quality switch sounds w
|
|||||||
- libevdev-dev
|
- libevdev-dev
|
||||||
- libudev-d
|
- libudev-d
|
||||||
|
|
||||||
## 🛠️ Build
|
## 🚀 Installation
|
||||||
|
|
||||||
|
### Arch Linux
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
make -j$(nproc)
|
yay -S keyvibe-git
|
||||||
|
```
|
||||||
|
|
||||||
|
### 🛠️ Build From Source
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://github.com/S4NKALP/KeyVibe.git
|
||||||
|
cd KeyVibe
|
||||||
|
make
|
||||||
sudo make install
|
sudo make install
|
||||||
```
|
```
|
||||||
|
|
||||||
## 💡 Usage
|
## 💡 Usage
|
||||||
|
|
||||||
```bash
|
Usage: keyvibe [OPTIONS]
|
||||||
./keyvibe --list # List available sound packs (system + user)
|
|
||||||
|
|
||||||
./keyvibe # Run with defaults
|
Options:
|
||||||
|
-S, --sound SOUND_NAME Select sound pack (default: eg-oreo)
|
||||||
|
-V, --volume VOLUME Set volume [0-100] (default: 50)
|
||||||
|
-c --override-config Use CLI values for this run
|
||||||
|
-d --daemon Run as a background daemon
|
||||||
|
-s --stop Stop the background daemon
|
||||||
|
-m --mute Mute sound
|
||||||
|
-u --unmute Unmute sound
|
||||||
|
-l, --list List available sound packs
|
||||||
|
-h, --help Show this help message
|
||||||
|
-v, --verbose Enable verbose output
|
||||||
|
|
||||||
./keyvibe -c -s `sound_pack` -V 60 # Select pack and volume, override persisted config for this run
|
Notes:
|
||||||
|
|
||||||
./keyvibe --daemon # Background daemon mode
|
- First run creates `~/.keyvibe.json`. Subsequent runs use it unless `-c` is supplied.
|
||||||
|
- In daemon mode, editing `~/.keyvibe.json` will automatically reload.
|
||||||
./keyvibe --stop # Stop daemon
|
|
||||||
|
|
||||||
```
|
|
||||||
|
|
||||||
> config file will be create at `$HOME` as `.keyvibe.json`
|
|
||||||
|
|
||||||
```
|
|
||||||
|
|
||||||
Flags:
|
|
||||||
|
|
||||||
- `-s, --sound <name>`: sound pack name
|
|
||||||
- `-V, --volume <0-100>`: volume percent
|
|
||||||
- `-c, --override-config`: use CLI values for this run
|
|
||||||
- `-l, --list`: list sound packs
|
|
||||||
- `--daemon | --stop | --reload`
|
|
||||||
- `-v, --verbose`
|
|
||||||
```
|
|
||||||
|
|
||||||
## 🎵 Sound Packs
|
## 🎵 Sound Packs
|
||||||
|
|
||||||
@@ -97,81 +99,6 @@ Resolution order when selecting `-s <name>`:
|
|||||||
|
|
||||||
List shows `(user)` or `(system)` source next to each pack.
|
List shows `(user)` or `(system)` source next to each pack.
|
||||||
|
|
||||||
### config.json structure (custom packs)
|
|
||||||
|
|
||||||
KeyVibe supports two modes via `key_define_type`: `single` and `multi`.
|
|
||||||
|
|
||||||
- `single`: one long audio file; per-key plays a segment `[start_ms, duration_ms]`.
|
|
||||||
- `multi`: separate audio files; per-key maps to its own press/release files; also supports a set of generic press sounds and a generic release.
|
|
||||||
|
|
||||||
Minimal schemas and examples:
|
|
||||||
|
|
||||||
```json
|
|
||||||
// Single mode (one audio file, sliced by key)
|
|
||||||
{
|
|
||||||
"key_define_type": "single",
|
|
||||||
"sound": "purple.ogg", // relative to the pack dir
|
|
||||||
"defines": {
|
|
||||||
"30": [120, 80], // key_code 30: start_ms=120, duration_ms=80
|
|
||||||
"48": [300, 100]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
```json
|
|
||||||
// Multi mode (separate files, optional generic patterns)
|
|
||||||
{
|
|
||||||
"key_define_type": "multi",
|
|
||||||
// Generic press sound(s): can be one file, a printf-like pattern, or a {0-4} pattern
|
|
||||||
// Examples:
|
|
||||||
// "GENERIC.mp3"
|
|
||||||
// "GENERIC_R%d.mp3" // expands R0..R4 if files exist
|
|
||||||
// "GENERIC_R{0-4}.mp3" // also expands to R0..R4
|
|
||||||
"sound": "GENERIC_R{0-4}.mp3",
|
|
||||||
|
|
||||||
// Optional generic release sound
|
|
||||||
"soundup": "release/GENERIC.mp3",
|
|
||||||
|
|
||||||
// Per-key overrides (key codes from libinput/libevdev)
|
|
||||||
// For release-specific files, append "-up" to the key code string
|
|
||||||
"defines": {
|
|
||||||
"57": "press/SPACE.mp3", // SPACE press
|
|
||||||
"57-up": "release/SPACE.mp3", // SPACE release
|
|
||||||
"28": "press/ENTER.mp3",
|
|
||||||
"14": "press/BACKSPACE.mp3"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
Notes:
|
|
||||||
|
|
||||||
- All paths in `config.json` are relative to the sound pack directory.
|
|
||||||
- In multi mode, if a key press isn’t mapped, a random generic press file is chosen if provided.
|
|
||||||
- In multi mode, if a key release isn’t mapped, `soundup` is used if provided.
|
|
||||||
- In single mode, only presses are played; releases are ignored.
|
|
||||||
|
|
||||||
## Available Sound Packs:
|
|
||||||
|
|
||||||
- nk-cream
|
|
||||||
- cherrymx-black-abs
|
|
||||||
- cherrymx-red-pbt
|
|
||||||
- cherrymx-blue-abs
|
|
||||||
- eg-oreo
|
|
||||||
- cherrymx-brown-pbt
|
|
||||||
- eg-crystal-purple
|
|
||||||
- cherrymx-brown-abs
|
|
||||||
- topre-purple-hybrid-pbt
|
|
||||||
- cream-travel
|
|
||||||
- holy-pandas
|
|
||||||
- mxbrown-travel
|
|
||||||
- cherrymx-red-abs
|
|
||||||
- mxblack-travel
|
|
||||||
- cherrymx-black-pbt
|
|
||||||
- turquoise
|
|
||||||
- cherrymx-blue-pbt
|
|
||||||
- mxblue-travel
|
|
||||||
- banana-split-lubed
|
|
||||||
|
|
||||||
## 🤝 Contributing
|
## 🤝 Contributing
|
||||||
|
|
||||||
PRs welcome. Please keep code modular and readable, and prefer small, focused changes.
|
PRs welcome. Please keep code modular and readable, and prefer small, focused changes.
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 1.4 MiB |
Binary file not shown.
|
Before Width: | Height: | Size: 5.9 KiB |
Reference in new issue
Block a user