Skip to content

Commit 7bbcec2

Browse files
committed
Add debug mode documentation (--debug and WHATSMY_DEBUG)
1 parent 51a1559 commit 7bbcec2

1 file changed

Lines changed: 21 additions & 2 deletions

File tree

README.md

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,27 @@ extern "C" {
3535
}
3636
```
3737
38+
**Return codes:**
39+
- `0` = Success
40+
- `1` = General error
41+
- `2+` = Custom error codes
42+
43+
**Error handling & platform detection:** See `plugin.cpp` for complete examples.
44+
45+
## Debugging
46+
47+
Enable verbose output to troubleshoot your plugin:
48+
49+
```bash
50+
export WHATSMY_DEBUG=1
51+
whatsmy myplugin
52+
```
53+
54+
Or use the debug flag:
55+
```bash
56+
whatsmy --debug myplugin
57+
```
58+
3859
## Build
3960

4061
**Linux/macOS:**
@@ -60,8 +81,6 @@ cmake --build . --config Release
6081
2. Download binaries from GitHub Actions artifacts
6182
3. Submit PR to [plugins repository](https://github.com/whatsmycli/plugins)
6283

63-
See [plugin API docs](https://github.com/whatsmycli/docs) for advanced features.
64-
6584
## License
6685

6786
GPLv3

0 commit comments

Comments
 (0)