Project

General

Profile

unexist.dev

Assorted tidbits and projects

More config changes in r2089

Extended matching
Added by Christoph Kappel over 14 years ago

Over the time the complexity of tag properties steadily increased, it was time for a change. The new format combines regex and match properties and also adds the possibility to add more than one match to a tag.

Old configs are still useable, if there is a regex property found it will be used and a deprecation warning yielded.

Also it is now possible to set window types to tags, so subtle will treat this window as a window of specific type, e.g. as a desktop type window.

Here is a brief overview of the changes:

{{column(:start)}}

Old

tag "test1" do
  regex "test1" 
  match [:role]
end

tag "test2" do
  regex "test2" 
  match [:instance, :class]
end

tag "test3a" do
  regex "test3a" 
end

tag "test3b" do
  regex "test3b" 
  match [:name]
end

{{column(:mid)}}

New

tag "test1" do
  match :role => "test1" 
end

tag "test2" do
  match [:instance, :class] => "test2" 
end

tag "test3" do
  match "test3a" 
  match :name => "test3b" 
end

{{column(:end)}}

And finally the type works like this:

tag "type" do
  type :desktop
end

A complete list and updated docs can be found here.


Comments