intuis / rustmission

TUI for the Transmission daemon
GNU General Public License v3.0
11 stars 3 forks source link

categories/labels #9

Open micielski opened 1 week ago

micielski commented 1 week ago

with default directories to be saved in

micielski commented 1 week ago

Something like this in labels.toml:

[[label]]
name = "Classical Music" # Required (not sure if transmission allows for labels with spaces)
color = "Green" # OPTIONAL, default would be white
default_dir = "/some/directory/" # OPTIONAL, default would be default (transmission's daemon default)

[[label]]
name = "Just another category"
color = "#abc"
default_dir = "/another/dir"

This file would be just next to the config.toml file, created by default but with example labels commented out

micielski commented 1 week ago

It'd introduce a new column "Label", but hidden by default (if labels.is_empty())

micielski commented 1 week ago

It'd introduce a new column "Label", but hidden by default (if labels.is_empty())

Instead of a column there could be also a prefix that would be alongside the name, just added before every torrent name (it would be also colored).

[[label]]
name = "Music"
prefix = "M" # could be also a nerd fonts icon, optional
color = "#abc"
default_dir = "/another/dir"

and in config.toml:

[general]
enable_label_column = true
enable_label_prefix = true

these of course would do nothing if there are no labels

micielski commented 1 week ago

@aidanaden thoughts before i start implementing this?

aidanaden commented 1 week ago

@aidanaden thoughts before i start implementing this?

yep looks good to me - do we want to have a single default/global color for all categories? (makes it easier for theming)

category/label specific colors can be used to override the global/default color