modules/community-builder: allow users to set a shell
This commit is contained in:
parent
f550d11b48
commit
f6a8e5703b
5 changed files with 14 additions and 6 deletions
modules
darwin/community-builder
nixos/community-builder
shared
|
@ -13,6 +13,14 @@
|
||||||
|
|
||||||
environment.etc.motd.text = config.nixCommunity.motd;
|
environment.etc.motd.text = config.nixCommunity.motd;
|
||||||
|
|
||||||
|
programs.bash.enable = true;
|
||||||
|
|
||||||
|
environment.shells = [
|
||||||
|
pkgs.bashInteractive
|
||||||
|
pkgs.fish
|
||||||
|
pkgs.zsh
|
||||||
|
];
|
||||||
|
|
||||||
environment.systemPackages = [
|
environment.systemPackages = [
|
||||||
pkgs.vim
|
pkgs.vim
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
let
|
let
|
||||||
# To add yourself:
|
# To add yourself:
|
||||||
# 1. Add an entry to this list, using the next UID.
|
# 1. Add an entry to this list, using the next UID.
|
||||||
|
@ -329,7 +330,7 @@ in
|
||||||
inherit (u) uid;
|
inherit (u) uid;
|
||||||
home = "/Users/${u.name}";
|
home = "/Users/${u.name}";
|
||||||
createHome = true;
|
createHome = true;
|
||||||
shell = "/bin/zsh";
|
shell = u.shell or "/bin/zsh";
|
||||||
openssh.authorizedKeys.keyFiles = [ u.keys ];
|
openssh.authorizedKeys.keyFiles = [ u.keys ];
|
||||||
};
|
};
|
||||||
}) users
|
}) users
|
||||||
|
|
|
@ -26,10 +26,6 @@
|
||||||
withUtempter = false;
|
withUtempter = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.fish.enable = true;
|
|
||||||
# disable generated completion
|
|
||||||
environment.etc."fish/generated_completions".text = pkgs.lib.mkForce "";
|
|
||||||
|
|
||||||
systemd.services.nixpkgs-clone = {
|
systemd.services.nixpkgs-clone = {
|
||||||
serviceConfig.Type = "oneshot";
|
serviceConfig.Type = "oneshot";
|
||||||
startAt = "daily";
|
startAt = "daily";
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
let
|
let
|
||||||
inherit (pkgs) lib;
|
inherit (pkgs) lib;
|
||||||
|
|
||||||
|
@ -190,6 +190,7 @@ let
|
||||||
extraGroups = userGroups opts;
|
extraGroups = userGroups opts;
|
||||||
createHome = true;
|
createHome = true;
|
||||||
home = "/home/${name}";
|
home = "/home/${name}";
|
||||||
|
shell = opts.shell or config.users.defaultUserShell;
|
||||||
hashedPassword = opts.password or null;
|
hashedPassword = opts.password or null;
|
||||||
openssh.authorizedKeys.keyFiles = [ opts.keys ];
|
openssh.authorizedKeys.keyFiles = [ opts.keys ];
|
||||||
};
|
};
|
||||||
|
|
|
@ -30,6 +30,8 @@
|
||||||
|
|
||||||
programs.nix-index-database.comma.enable = true;
|
programs.nix-index-database.comma.enable = true;
|
||||||
|
|
||||||
|
programs.fish.enable = true;
|
||||||
|
|
||||||
programs.zsh = {
|
programs.zsh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
# https://grml.org/zsh/grmlzshrc.html
|
# https://grml.org/zsh/grmlzshrc.html
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue