swaydots

my dotfiles
git clone https://git.awy.one/swaydots.git
Log | Files | Refs | README | LICENSE

commit d71ce91d9ab2fa6871e396019ba80f0ba5d649df
parent c468cf091936b275a4aea652ede01163f4a48e2f
Author: awy <awy@awy.one>
Date:   Fri, 30 May 2025 01:11:07 +0300

rmpc

Diffstat:
M.config/rmpc/config.ron | 148++++++++++++++++++++++++++++++++++++++++++++++++++++++++-----------------------
A.config/rmpc/scripts/statusbar | 2++
A.config/rmpc/themes/def.ron | 238+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 345 insertions(+), 43 deletions(-)

diff --git a/.config/rmpc/config.ron b/.config/rmpc/config.ron @@ -3,27 +3,25 @@ #![enable(unwrap_variant_newtypes)] ( address: "127.0.0.1:6600", - password: None, - theme: "nord", - cache_dir: None, - on_song_change: None, volume_step: 5, - max_fps: 30, - scrolloff: 0, + scrolloff: 2, + max_fps: 60, + wrap_navigation: true, + theme: "def", lyrics_dir: "/mnt/ssd/music", - wrap_navigation: false, - enable_mouse: true, + on_song_change: ["~/.config/rmpc/scripts/statusbar"], + on_resize: None, status_update_interval_ms: 1000, - select_current_song_on_change: false, + enable_mouse: true, + enable_config_hot_reload: true, album_art: ( method: Auto, - max_size_px: (width: 1200, height: 1200), - disabled_protocols: ["http://", "https://"], - vertical_align: Center, + max_size_px: (width: 0, height: 0), + vertical_align: Top, horizontal_align: Center, ), keybinds: ( - global: { + global: { ":": CommandMode, ",": VolumeDown, "s": Stop, @@ -51,8 +49,8 @@ "I": ShowCurrentSongInfo, "O": ShowOutputs, "P": ShowDecoders, - }, - navigation: { + }, + navigation: { "k": Up, "j": Down, "h": Left, @@ -84,16 +82,16 @@ "<Esc>": Close, "K": MoveUp, "D": Delete, - }, - queue: { - "D": DeleteAll, - "<CR>": Play, - "<C-s>": Save, - "a": AddToPlaylist, - "d": Delete, - "i": ShowInfo, - "C": JumpToCurrent, - }, + }, + queue: { + "D": DeleteAll, + "<CR>": Play, + "<C-s>": Save, + "a": AddToPlaylist, + "d": Delete, + "i": ShowInfo, + "C": JumpToCurrent, + }, ), search: ( case_sensitive: false, @@ -104,57 +102,121 @@ (value: "album", label: "Album"), (value: "albumartist", label: "Album Artist"), (value: "title", label: "Title"), - (value: "filename", label: "Filename"), - (value: "genre", label: "Genre"), ], ), - artists: ( - album_display_mode: SplitByDate, - album_sort_by: Date, - ), tabs: [ ( name: "Queue", + border_type: None, pane: Split( - direction: Vertical, - panes: [ - (size: "60%", pane: Split( direction: Horizontal, panes: [ - (size: "40%", pane: Split( - direction: Vertical, - panes: [(size: "70%", pane: Pane(AlbumArt)),(size: "30%", pane: Pane(Lyrics))] - )), - (size: "60%", pane: Pane(Queue)), + ( + size: "40%", + borders: "RIGHT", + pane: Split( + direction: Vertical, + panes: [ + ( + size: "3", + pane: Pane(Lyrics), + ), + ( + size: "100%", + pane: Pane(AlbumArt), + ) + ], + ), + ), + ( + size: "60%", + pane: Pane(Queue), + ), ], - )), - ], - ), + ), ), ( name: "Directories", + border_type: None, pane: Pane(Directories), ), ( name: "Artists", + border_type: None, pane: Pane(Artists), ), ( name: "Album Artists", + border_type: None, pane: Pane(AlbumArtists), ), ( name: "Albums", + border_type: None, pane: Pane(Albums), ), ( name: "Playlists", + border_type: None, pane: Pane(Playlists), ), ( name: "Search", + border_type: None, pane: Pane(Search), ), + ( + name: "Testing", + border_type: Single, + pane: Split( + direction: Horizontal, + panes: [ + ( + size: "40%", + pane: Pane(Queue), + ), + ( + size: "60%", + pane: Split( + direction: Vertical, + panes: [ + ( + size: "50%", + pane: Pane(Directories), + ), + ( + size: "50%", + pane: Split( + direction: Horizontal, + panes: [ + // ( + // size: "40%", + // pane: Pane(AlbumArt), + // ), + ( + size: "60%", + pane: Split( + direction: Vertical, + panes: [ + ( + size: "50%", + pane: Pane(Albums), + ), + ( + size: "50%", + pane: Pane(Artists), + ), + ], + ), + ), + ], + ), + ), + ], + ), + ), + ], + ), + ), ], ) - diff --git a/.config/rmpc/scripts/statusbar b/.config/rmpc/scripts/statusbar @@ -0,0 +1,2 @@ +#!/bin/sh +/usr/bin/pkill -RTMIN+11 i3blocks diff --git a/.config/rmpc/themes/def.ron b/.config/rmpc/themes/def.ron @@ -0,0 +1,238 @@ +#![enable(implicit_some)] +#![enable(unwrap_newtypes)] +#![enable(unwrap_variant_newtypes)] +( + draw_borders: false, + show_song_table_header: true, + background_color: None, + default_album_art_path: None, + header_background_color: None, + modal_background_color: None, + modal_backdrop: true, + text_color: None, + layout: Split( + direction: Vertical, + panes: [ + ( + size: "4", + borders: "ALL", + pane: Split( + direction: Vertical, + panes: [ + ( + size: "1", + direction: Vertical, + pane: Split( + direction: Horizontal, + panes: [ + ( + size: "23", + pane: Pane(Property( + content: [ + (kind: Text("["), style: (fg: "yellow", modifiers: "Bold")), + (kind: Property(Status(StateV2())), style: (fg: "yellow", modifiers: "Bold")), + (kind: Text("]"), style: (fg: "yellow", modifiers: "Bold")), + ], align: Left, + )), + ), + ( + size: "100%", + borders: "LEFT | RIGHT", + pane: Pane(Property( + content: [ + (kind: Property(Song(Filename)), style: (modifiers: "Bold"), + default: (kind: Text("No Song"), style: (modifiers: "Bold"))) + ], align: Center, scroll_speed: 1 + )), + ), + ( + size: "23", + pane: Pane(Property( + content: [ + (kind: Property(Widget(Volume)), style: (fg: "blue", modifiers: "Bold")) + ], align: Right + )), + ), + ], + ), + ), + ( + size: "1", + direction: Vertical, + pane: Split( + direction: Horizontal, + panes: [ + ( + size: "23", + pane: Pane(Property( + content: [ + (kind: Property(Status(Elapsed))), + (kind: Text(" / ")), + (kind: Property(Status(Duration))), + (kind: Group([ + (kind: Text(" (")), + (kind: Property(Status(Bitrate))), + (kind: Text(" kbps)")), + ])), + ], align: Left, + )), + ), + ( + size: "100%", + borders: "LEFT | RIGHT", + pane: Pane(Property( + content: [ + (kind: Property(Song(Artist)), style: (fg: "yellow", modifiers: "Bold"), + default: (kind: Text("Unknown"), style: (fg: "yellow", modifiers: "Bold"))), + (kind: Text(" - ")), + (kind: Property(Song(Album)), default: (kind: Text("Unknown Album"))) + ], align: Center, scroll_speed: 2 + )), + ), + ( + size: "23", + pane: Pane(Property(content: [ + (kind: Property(Status(RepeatV2( + on_label: " ", + off_label: " ", + on_style: (fg: "yellow", modifiers: "Bold"), + off_style: (fg: "blue", modifiers: "Dim"), + )))), + (kind: Property(Status(RandomV2( + on_label: " ", + off_label: " ", + on_style: (fg: "yellow", modifiers: "Bold"), + off_style: (fg: "blue", modifiers: "Dim"), + )))), + (kind: Property(Status(SingleV2( + on_label: "󰑘 ", + off_label: "󰑘 ", + oneshot_label: "󰑘 ", + on_style: (fg: "yellow", modifiers: "Bold"), + off_style: (fg: "blue", modifiers: "Dim"), + oneshot_style: (fg: "red", modifiers: "Bold"), + )))), + (kind: Property(Status(ConsumeV2( + on_label: " ", + off_label: " ", + oneshot_label: "", + on_style: (fg: "yellow", modifiers: "Bold"), + off_style: (fg: "blue", modifiers: "Dim"), + oneshot_style: (fg: "red", modifiers: "Dim"), + )))), + ], align: Right)), + ), + ], + ), + ), + ] + ) + ), + ( + size: "3", + borders: "ALL", + pane: Pane(Tabs), + ), + ( + size: "100%", + borders: "ALL", + background_color: "red", + pane: Pane(TabContent), + ), + ( + size: "3", + borders: "ALL", + pane: Split( + direction: Horizontal, + panes: [ + ( + pane: Pane(Property(content: [(kind: Property(Status(StateV2(playing_label: "  ", paused_label: "  ", stopped_label: "  ", + playing_style: (fg: "blue"), paused_style: (fg: "green"), stopped_style: (fg: "red") + ))))], align: Left)), + size: "3", + ), + ( + size: "100%", + pane: Pane(ProgressBar), + ), + ( + size: "13", + pane: Pane(Property( + content: [ + (kind: Property(Status(Elapsed))), + (kind: Text(" / ")), + (kind: Property(Status(Duration))), + ], align: Right, + )), + ), + ] + ), + ), + ] + ), + symbols: ( + song: "🎵", + dir: "📁", + marker: "\u{e0b0}", + ellipsis: "…" + ), + progress_bar: ( + symbols: ["█", "\u{e0b0}", "█"], + track_style: (fg: "#1e2030"), + elapsed_style: (fg: "blue"), + thumb_style: (fg: "blue", bg: "#1e2030"), + ), + scrollbar: ( + symbols: ["│", "█", "▲", "▼"], + track_style: (), + ends_style: (), + thumb_style: (fg: "blue"), + ), + browser_column_widths: [20, 38, 42], + browser_song_format: [ + ( + kind: Group([ + (kind: Property(Track)), + (kind: Text(" ")), + ]) + ), + ( + kind: Group([ + (kind: Property(Artist)), + (kind: Text(" - ")), + (kind: Property(Title)), + ]), + default: (kind: Property(Filename)) + ), + ], + tab_bar: ( + active_style: (fg: "black", bg: "blue", modifiers: "Bold"), + inactive_style: (), + ), + highlighted_item_style: (fg: "blue", modifiers: "Bold"), + current_item_style: (fg: "black", bg: "blue", modifiers: "Bold"), + borders_style: (fg: "blue", modifiers: "Bold"), + highlight_border_style: (fg: "red"), + song_table_format: [ + ( + prop: (kind: Property(Other("albumartist")), default: (kind: Property(Artist), default: (kind: Text("Unknown")))), + width: "20%", + label: "Artist" + ), + ( + prop: (kind: Property(Title), default: (kind: Text("Unknown"))), + width: "35%", + ), + ( + prop: (kind: Property(Album), default: (kind: Text("Unknown Album"))), + width: "45%", + ), + ( + prop: (kind: Property(Duration),default: (kind: Text("-"))), + width: "5", + alignment: Right, + label: "Len" + ), + ], + header: (rows: []), +)