Skip to content
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions modules/misc/news/2026/04/2026-04-14_18-19-27.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
time = "2026-04-14T12:49:27+00:00";
# condition = pkgs.stdenv.hostPlatform.isLinux;
# condition = config.programs.neovim.enable;
condition = true;
# if behavior changed, explain how to restore previous behavior.
Comment on lines +2 to +7
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
{
time = "2026-04-14T12:49:27+00:00";
# condition = pkgs.stdenv.hostPlatform.isLinux;
# condition = config.programs.neovim.enable;
condition = true;
# if behavior changed, explain how to restore previous behavior.
{config, ...}: {
time = "2026-04-14T12:49:27+00:00";
condition = config.programs.yazi.enable;

message = ''
Added new option for yazi: programs.yazi.vfs

Yazi has a vfs.toml in it's config directory to manage
virtual file systems. The conifguration can now be managed with
programs.yazi.vfs
'';
}
27 changes: 27 additions & 0 deletions modules/programs/yazi.nix
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,30 @@ in
'';
};

vfs = mkOption {
inherit (tomlFormat) type;
default = { };
example = literalExpression ''
{
services = {
my-server = {
host = "1.2.3.4";
port = 22;
type = "sftp";
user = "root";
};
};
}
'';
description = ''
Configuration written to
{file}`$XDG_CONFIG_HOME/yazi/vfs.toml`.

See <https://yazi-rs.github.io/docs/configuration/vfs>
for the full list of options
'';
};

initLua = mkOption {
type = with types; nullOr (either path lines);
default = null;
Expand Down Expand Up @@ -283,6 +307,9 @@ in
"yazi/theme.toml" = mkIf (cfg.theme != { }) {
source = tomlFormat.generate "yazi-theme" cfg.theme;
};
"yazi/vfs.toml" = mkIf (cfg.vfs != { }) {
source = tomlFormat.generate "yazi-vfs" cfg.vfs;
};
"yazi/init.lua" = mkIf (cfg.initLua != null) (
if builtins.isPath cfg.initLua then
{
Expand Down
Loading