Skip to content

fix(config): dynamic config version#127

Closed
shivros wants to merge 0 commit intohyprland-community:mainfrom
shivros:mw/126-config-template-version
Closed

fix(config): dynamic config version#127
shivros wants to merge 0 commit intohyprland-community:mainfrom
shivros:mw/126-config-template-version

Conversation

@shivros
Copy link
Collaborator

@shivros shivros commented Jun 19, 2025

Description

This touches on 2 things:

  1. I forgot to bump the cargo version when releasing 1.1.16.
  2. The default config version was hardcoded at 1.1.14.

This updates the config to use a dynamic version so that the config won't get out of sync in the future.

Fixes #126

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

I generated a new config using:

./target/debug/hyprland-autoname-workspaces -c new-config.toml 

The contents:

version = "1.1.16"

# [format]
# Deduplicate icons if enable.
# A superscripted counter will be added.
# dedup = false
# dedup_inactive_fullscreen = false # dedup more
# window delimiter
# delim = " "
# max_clients = 30 # you should not need this

# available formatter:
# {counter_sup} - superscripted count of clients on the workspace, and simple {counter}, {delim}
# {icon}, {client}
# workspace formatter
# workspace = "{id}:{delim}{clients}" # {id}, {delim} and {clients} are supported
# workspace_empty = "{id}" # {id}, {delim} and {clients} are supported
# client formatter
# client = "{icon}"
# client_active = "*{icon}*"

# deduplicate client formatter
# client_fullscreen = "[{icon}]"
# client_dup = "{client}{counter_sup}"
# client_dup_fullscreen = "[{icon}]{delim}{icon}{counter_unfocused}"
# client_dup_active = "*{icon}*{delim}{icon}{counter_unfocused}"

[class]
# Add your icons mapping
# use double quote the key and the value
# take class name from 'hyprctl clients'
"DEFAULT" = " {class}: {title}"
"(?i)Kitty" = "term"
"[Ff]irefox" = "browser"
"(?i)waydroid.*" = "droid"

[class_active]
DEFAULT = "*{icon}*"
"(?i)ExampleOneTerm" = "<span foreground='red'>{icon}</span>"

# [initial_class]
# "DEFAULT" = " {class}: {title}"
# "(?i)Kitty" = "term"

# [initial_class_active]
# "(?i)Kitty" = "*TERM*"

[title_in_class."(?i)kitty"]
"(?i)neomutt" = "neomutt"
# regex captures support is supported
# "emerge: (.+?/.+?)-.*" = "{match1}"

[title_in_class_active."(?i)firefox"]
"(?i)twitch" = "<span color='purple'>{icon}</span>"

# [title_in_initial_class."(?i)kitty"]
# "(?i)neomutt" = "neomutt"

# [initial_title_in_class."(?i)kitty"]
# "(?i)neomutt" = "neomutt"

# [initial_title_in_initial_class."(?i)kitty"]
# "(?i)neomutt" = "neomutt"

# [initial_title."(?i)kitty"]
# "zsh" = "Zsh"

# [initial_title_active."(?i)kitty"]
# "zsh" = "*Zsh*"

# Add your applications that need to be exclude
# The key is the class, the value is the title.
# You can put an empty title to exclude based on
# class name only, "" make the job.
[exclude]
"" = "^$" # prevent displaying icon for empty class
"(?i)fcitx" = ".*" # will match all title for fcitx
"(?i)TestApp" = "" # will match all title for TestApp
aProgram = "^$" # will match null title for aProgram
"[Ss]team" = "^(Friends List.*)?$" # will match Steam friends list plus all popups (empty titles)

[workspaces_name]
0 = "zero"
1 = "one"
2 = "two"
3 = "three"
4 = "four"
5 = "five"
6 = "six"
7 = "seven"
8 = "eight"
9 = "nine"
10 = "ten"

@shivros shivros requested a review from cyrinux June 19, 2025 01:46
@shivros shivros closed this Jun 19, 2025
@shivros shivros force-pushed the mw/126-config-template-version branch from 0320858 to ad84da7 Compare June 19, 2025 01:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] default config template in the code is still set to 1.1.14

1 participant