-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Xonsh #5494
base: master
Are you sure you want to change the base?
Xonsh #5494
Conversation
modules/programs/xonsh.nix
Outdated
finalPackage = lib.mkOption { | ||
type = types.package; | ||
internal = true; | ||
description = "Package that will actually gat installed"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
description = "Package that will actually gat installed"; | |
description = "Package that will actually get installed"; |
modules/programs/xonsh.nix
Outdated
home = { | ||
packages = [ cfg.finalPackage ]; | ||
file.".xonshrc" = { | ||
enable = cfg.xonshrc != ""; | ||
text = cfg.xonshrc; | ||
}; | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's better to respect XDG.
home = { | |
packages = [ cfg.finalPackage ]; | |
file.".xonshrc" = { | |
enable = cfg.xonshrc != ""; | |
text = cfg.xonshrc; | |
}; | |
}; | |
home.packages = [ cfg.finalPackage ]; | |
xdg.configFile."xonsh/rc.xsh" = { | |
enable = cfg.xonshrc != ""; | |
text = cfg.xonshrc; | |
}; |
Another option is how #5160 does it: split by files. It's directly supported by xonsh.
Which one is better? I don't know, but you and @inmaldrerah should probably join efforts.
Thanks both!
modules/programs/xonsh.nix
Outdated
cfg.package.override (old: { inherit (cfg) extraPackages; }); | ||
}; | ||
}; | ||
xdg.configFile."xonsh/rc.xsh" = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This xdg.configFile."xonsh/rc.xsh"
entry should be in the previous config
block.
f340f89
to
456cc84
Compare
42b47ba
to
5f24d60
Compare
Description
Checklist
Change is backwards compatible.
Code formatted with
./format
.Code tested through
nix-shell --pure tests -A run.all
ornix develop --ignore-environment .#all
using Flakes.Test cases updated/added. See example.
Commit messages are formatted like
See CONTRIBUTING for more information and recent commit messages for examples.
If this PR adds a new module
Maintainer CC