Skip to content

Commit 1543392

Browse files
authored
Merge pull request #31 from cyrinux/30-regex-support-for-classes
2 parents 94b6163 + 6c9e2dc commit 1543392

File tree

5 files changed

+198
-159
lines changed

5 files changed

+198
-159
lines changed

Cargo.lock

+18-17
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "hyprland-autoname-workspaces"
33
authors = ["Cyril Levis", "Maxim Baz"]
4-
version = "0.3.9"
4+
version = "0.4.0"
55
edition = "2021"
66
categories = ["gui"]
77
keywords = ["linux", "desktop-application", "hyprland","waybar","wayland"]
@@ -12,6 +12,7 @@ homepage = "https://github.com/cyrinux/hyprland-autoname-workspaces"
1212
repository = "https://github.com/cyrinux/hyprland-autoname-workspaces"
1313

1414
[dependencies]
15+
regex = "1"
1516
clap = { version = "4.1.1", features = ["derive"] }
1617
hyprland = "0.3.1"
1718
signal-hook = "0.3.14"

README.md

+7-4
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ $ hyprland-autoname-workspaces --dedup
3838
## Configuration
3939

4040
In the config file `~/.config/hyprland-autoname-workspaces/config.toml`.
41+
42+
_You can use regex everywhere, and its case sensitive by default_
43+
4144
Edit the mapping of applications with `class = "icon"` in the `[icons]` part.
4245

4346
- You can exclude applications in the `[exclude]` with `class = title`.
@@ -50,8 +53,8 @@ Example:
5053
```
5154
...
5255
[exclude]
53-
fcitx = "*"
54-
Steam = "Friends list"
56+
fcitx = ".*"
57+
[Ss]team = "Friends list.*"
5558
```
5659

5760
- You can match on title with `[title.classname]` with `"a word in the title" = "icons"`.
@@ -60,8 +63,8 @@ Example:
6063

6164
```
6265
...
63-
[title.kitty]
64-
neomutt = "neomutt"
66+
[title."(?i)kitty"]
67+
"(?i)neomutt" = "neomutt"
6568
```
6669

6770
No need to restart the applications then, there is an autoreload.

0 commit comments

Comments
 (0)