Add README
This commit is contained in:
parent
0f850b7d77
commit
f27bf90988
88
README.md
88
README.md
@ -1,3 +1,89 @@
|
|||||||
# xdi
|
# xdi
|
||||||
|
|
||||||
X11 Desktop Info
|
Minimal X11 desktop information utility.
|
||||||
|
|
||||||
|
Prints desktop and window information as JSON.
|
||||||
|
|
||||||
|
## Install
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cargo install --git https://git.candifloss.cc/candifloss/xdi.git
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
Print the current state:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
xdi
|
||||||
|
```
|
||||||
|
|
||||||
|
Example output:
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"active_window": {
|
||||||
|
"id": 73400324,
|
||||||
|
"name": "Preview README.md - xdi - Code - OSS",
|
||||||
|
"class": "code-oss"
|
||||||
|
},
|
||||||
|
"workspaces": [
|
||||||
|
{
|
||||||
|
"id": 0,
|
||||||
|
"current": true,
|
||||||
|
"windows": [
|
||||||
|
{
|
||||||
|
"id": 35651587,
|
||||||
|
"name": "~/Projects",
|
||||||
|
"class": "Alacritty"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 73400324,
|
||||||
|
"name": "Preview README.md - xdi - Code - OSS",
|
||||||
|
"class": "code-oss"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 90177540,
|
||||||
|
"name": "Rust CLI Apps - Rust X11 Workspace Tool - Chromium",
|
||||||
|
"class": "Chromium-browser"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 104857698,
|
||||||
|
"name": "JsonPretty - JSON Beautifier and Formatter — Mozilla Firefox",
|
||||||
|
"class": "firefox"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 1,
|
||||||
|
"current": false,
|
||||||
|
"windows": [
|
||||||
|
{
|
||||||
|
"id": 106954755,
|
||||||
|
"name": "~/P/x/src",
|
||||||
|
"class": "Alacritty"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
Follow desktop changes:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
xdi --follow
|
||||||
|
```
|
||||||
|
|
||||||
|
Or:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
xdi -f
|
||||||
|
```
|
||||||
|
|
||||||
|
In follow mode, `xdi` prints a new JSON object whenever the desktop state changes.
|
||||||
|
|
||||||
|
## Requirements
|
||||||
|
|
||||||
|
- X11
|
||||||
|
- An EWMH compatible window manager
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user