repositories

NixDaemon

NixOS pentest workstation as one flake — IceBreaker's successor

clonegit clone https://git.daemon-sec.xyz/NixDaemon.git
config.ron316 lines11.2 KiBraw download
#![enable(implicit_some)]
#![enable(unwrap_newtypes)]
#![enable(unwrap_variant_newtypes)]
(
    address: "/run/user/1000/mpd/socket",
    password: None,
    theme: "rose-pine",
    cache_dir: None,
    on_song_change: ["~/.config/rmpc/scripts/fetch-lyrics"],
    lyrics_dir: "~/.local/share/rmpc/lyrics",
    volume_step: 5,
    max_fps: 60,
    scrolloff: 3,
    wrap_navigation: false,
    enable_mouse: true,
    scroll_amount: 1,
    enable_config_hot_reload: true,
    enable_lyrics_hot_reload: true,
    status_update_interval_ms: 500,
    rewind_to_start_sec: None,
    keep_state_on_song_change: true,
    reflect_changes_to_playlist: false,
    select_current_song_on_change: false,
    ignore_leading_the: false,
    browser_song_sort: [Disc, Track, Artist, Title],
    directories_sort: SortFormat(group_by_type: true, reverse: false),
    auto_open_downloads: true,
    album_art: (
        method: Auto,
        max_size_px: (width: 1200, height: 1200),
        disabled_protocols: ["http://", "https://"],
        vertical_align: Center,
        horizontal_align: Center,
    ),
    cava: (
        framerate: 60,
        autosens: true,
        input: (
            method: Fifo,
            source: "/run/user/1000/mpd/fifo",
            sample_rate: 44100,
            channels: 2,
            sample_bits: 16,
        ),
        smoothing: (
            noise_reduction: 77,
            monstercat: true,
            waves: false,
        ),
    ),
    keybinds: (
        global: {
            "q":          Quit,
            "?":          ShowHelp,
            ":":          CommandMode,
            "oI":         ShowCurrentSongInfo,
            "oo":         ShowOutputs,
            "op":         ShowDecoders,
            "od":         ShowDownloads,
            "oP":         Partition(),
            "z":          ToggleRepeat,
            "x":          ToggleRandom,
            "c":          ToggleConsume,
            "v":          ToggleSingle,
            "p":          TogglePause,
            "s":          Stop,
            ">":          NextTrack,
            "<":          PreviousTrack,
            "f":          SeekForward,
            "b":          SeekBack,
            ".":          VolumeUp,
            ",":          VolumeDown,
            "<Tab>":      NextTab,
            "gt":         NextTab,
            "<S-Tab>":    PreviousTab,
            "gT":         PreviousTab,
            "1":          SwitchToTab("Queue"),
            "2":          SwitchToTab("Now Playing"),
            "3":          SwitchToTab("Directories"),
            "4":          SwitchToTab("Artists"),
            "5":          SwitchToTab("Album Artists"),
            "6":          SwitchToTab("Albums"),
            "7":          SwitchToTab("Genre"),
            "8":          SwitchToTab("Playlists"),
            "9":          SwitchToTab("Search"),
            "0":          SwitchToTab("Lyrics"),
            "L":          SwitchToTab("Lyrics"),
            "<C-u>":      Update,
            "<C-U>":      Rescan,
            "R":          AddRandom,
        },
        navigation: {
            "<C-c>":      Close,
            "<Esc>":      Close,
            "<CR>":       Confirm,
            "k":          Up,
            "<Up>":       Up,
            "j":          Down,
            "<Down>":     Down,
            "h":          Left,
            "<Left>":     Left,
            "l":          Right,
            "<Right>":    Right,
            "<C-w>k":     PaneUp,
            "<C-Up>":     PaneUp,
            "<C-w>j":     PaneDown,
            "<C-Down>":   PaneDown,
            "<C-w>h":     PaneLeft,
            "<C-Left>":   PaneLeft,
            "<C-w>l":     PaneRight,
            "<C-Right>":  PaneRight,
            "K":          MoveUp,
            "J":          MoveDown,
            "<C-u>":      UpHalf,
            "<C-d>":      DownHalf,
            "<C-b>":      PageUp,
            "<PageUp>":   PageUp,
            "<C-f>":      PageDown,
            "<PageDown>": PageDown,
            "gg":         Top,
            "G":          Bottom,
            "<Space>":    Select,
            "<C-Space>":  InvertSelection,
            "/":          EnterSearch,
            "n":          NextResult,
            "N":          PreviousResult,
            "a":          Add,
            "A":          AddAll,
            "D":          Delete,
            "<C-r>":      Rename,
            "i":          FocusInput,
            "oi":         ShowInfo,
            "<C-z>":      ContextMenu(),
            "<C-s>s":     Save(kind: Modal(all: false, duplicates_strategy: Ask)),
            "<C-s>a":     Save(kind: Modal(all: true, duplicates_strategy: Ask)),
            "r":          Rate(),
        },
        queue: {
            "d":          Delete,
            "D":          DeleteAll,
            "<CR>":       Play,
            "C":          JumpToCurrent,
            "X":          Shuffle,
        },
    ),
    search: (
        case_sensitive: false,
        ignore_diacritics: false,
        search_button: false,
        mode: Contains,
        tags: [
            (value: "any",         label: "Any Tag"),
            (value: "artist",      label: "Artist"),
            (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,
        album_date_tags: [Date],
    ),
    tabs: [
        (
            name: "Queue",
            pane: Split(
                direction: Horizontal,
                panes: [
                    (
                        size: "40%",
                        borders: "ALL",
                        border_symbols: Rounded,
                        pane: Pane(AlbumArt),
                    ),
                    (
                        size: "60%",
                        pane: Split(
                            direction: Vertical,
                            panes: [
                                (
                                    size: "3",
                                    borders: "ALL",
                                    border_symbols: Inherited(parent: Rounded, bottom_left: "├", bottom_right: "┤"),
                                    pane: Split(
                                        direction: Horizontal,
                                        panes: [
                                            (size: "1", pane: Pane(Empty())),
                                            (size: "100%", pane: Pane(QueueHeader())),
                                        ],
                                    ),
                                ),
                                (
                                    size: "100%",
                                    borders: "LEFT | RIGHT | BOTTOM",
                                    border_symbols: Rounded,
                                    pane: Split(
                                        direction: Horizontal,
                                        panes: [
                                            (size: "1", pane: Pane(Empty())),
                                            (size: "100%", pane: Pane(Queue)),
                                        ],
                                    ),
                                ),
                                (
                                    size: "35%",
                                    borders: "ALL",
                                    border_symbols: Rounded,
                                    border_title: [(kind: Text(" Visualiser "))],
                                    border_title_alignment: Right,
                                    pane: Pane(Cava),
                                ),
                            ],
                        ),
                    ),
                ],
            ),
        ),
        (
            name: "Now Playing",
            pane: Split(
                direction: Horizontal,
                panes: [
                    (
                        size: "42%",
                        borders: "ALL",
                        border_symbols: Rounded,
                        pane: Pane(AlbumArt),
                    ),
                    (
                        size: "58%",
                        pane: Split(
                            direction: Vertical,
                            panes: [
                                (
                                    size: "65%",
                                    borders: "ALL",
                                    border_symbols: Rounded,
                                    border_title: [(kind: Text(" Synced Lyrics "))],
                                    border_title_alignment: Center,
                                    pane: Pane(Lyrics),
                                ),
                                (
                                    size: "35%",
                                    borders: "ALL",
                                    border_symbols: Rounded,
                                    border_title: [(kind: Text(" Visualiser "))],
                                    border_title_alignment: Right,
                                    pane: Pane(Cava),
                                ),
                            ],
                        ),
                    ),
                ],
            ),
        ),
        (
            name: "Directories",
            pane: Split(
                direction: Vertical,
                panes: [(pane: Pane(Directories), size: "100%", borders: "ALL", border_symbols: Rounded)],
            ),
        ),
        (
            name: "Artists",
            pane: Split(
                direction: Vertical,
                panes: [(pane: Pane(Artists), size: "100%", borders: "ALL", border_symbols: Rounded)],
            ),
        ),
        (
            name: "Album Artists",
            pane: Split(
                direction: Vertical,
                panes: [(pane: Pane(AlbumArtists), size: "100%", borders: "ALL", border_symbols: Rounded)],
            ),
        ),
        (
            name: "Albums",
            pane: Split(
                direction: Vertical,
                panes: [(pane: Pane(Albums), size: "100%", borders: "ALL", border_symbols: Rounded)],
            ),
        ),
        (
            name: "Genre",
            pane: Split(
                direction: Vertical,
                panes: [(pane: Pane(Browser(root_tag: "genre")), size: "100%", borders: "ALL", border_symbols: Rounded)],
            ),
        ),
        (
            name: "Playlists",
            pane: Split(
                direction: Vertical,
                panes: [(pane: Pane(Playlists), size: "100%", borders: "ALL", border_symbols: Rounded)],
            ),
        ),
        (
            name: "Search",
            pane: Split(
                direction: Vertical,
                panes: [(pane: Pane(Search), size: "100%", borders: "ALL", border_symbols: Rounded)],
            ),
        ),
        (
            name: "Lyrics",
            pane: Split(
                direction: Vertical,
                panes: [(pane: Pane(Lyrics), size: "100%", borders: "ALL", border_symbols: Rounded)],
            ),
        ),
    ],
)