Added bashrc files to make dircolors/prompt working on xterm/konsole etc.
svn path=/nixos/trunk/; revision=11072
This commit is contained in:
parent
b615a392a2
commit
9ffb0e8ec4
@ -32,7 +32,6 @@ import ../helpers/make-etc.nix {
|
|||||||
inherit (pkgs) stdenv;
|
inherit (pkgs) stdenv;
|
||||||
|
|
||||||
configFiles = [
|
configFiles = [
|
||||||
|
|
||||||
{ # TCP/UDP port assignments.
|
{ # TCP/UDP port assignments.
|
||||||
source = pkgs.iana_etc + "/etc/services";
|
source = pkgs.iana_etc + "/etc/services";
|
||||||
target = "services";
|
target = "services";
|
||||||
@ -104,7 +103,12 @@ import ../helpers/make-etc.nix {
|
|||||||
target = "dhclient-exit-hooks";
|
target = "dhclient-exit-hooks";
|
||||||
}
|
}
|
||||||
|
|
||||||
{ # Script executed when the shell starts.
|
{ # Script executed when the shell starts as a non-login shell (system-wide version).
|
||||||
|
source = ./bashrc;
|
||||||
|
target = "bashrc";
|
||||||
|
}
|
||||||
|
|
||||||
|
{ # Script executed when the shell starts as a login shell.
|
||||||
source = pkgs.substituteAll {
|
source = pkgs.substituteAll {
|
||||||
src = ./profile.sh;
|
src = ./profile.sh;
|
||||||
inherit systemPath wrapperDir modulesTree;
|
inherit systemPath wrapperDir modulesTree;
|
||||||
@ -133,6 +137,11 @@ import ../helpers/make-etc.nix {
|
|||||||
target = "nix.conf"; # will be symlinked from /nix/etc/nix/nix.conf in activate-configuration.sh.
|
target = "nix.conf"; # will be symlinked from /nix/etc/nix/nix.conf in activate-configuration.sh.
|
||||||
}
|
}
|
||||||
|
|
||||||
|
{ # Script executed when the shell starts as a non-login shell (user version).
|
||||||
|
source = ./skel/bashrc;
|
||||||
|
target = "skel/.bashrc";
|
||||||
|
}
|
||||||
|
|
||||||
{ # SSH configuration. Slight duplication of the sshd_config
|
{ # SSH configuration. Slight duplication of the sshd_config
|
||||||
# generation in the sshd service.
|
# generation in the sshd service.
|
||||||
source = pkgs.writeText "ssh_config" ''
|
source = pkgs.writeText "ssh_config" ''
|
||||||
@ -145,7 +154,6 @@ import ../helpers/make-etc.nix {
|
|||||||
'';
|
'';
|
||||||
target = "ssh/ssh_config";
|
target = "ssh/ssh_config";
|
||||||
}
|
}
|
||||||
|
|
||||||
]
|
]
|
||||||
|
|
||||||
# Configuration for ssmtp.
|
# Configuration for ssmtp.
|
||||||
|
@ -11,15 +11,6 @@ export INFOPATH=/var/run/current-system/sw/info:/var/run/current-system/sw/share
|
|||||||
export LOCATE_PATH=/var/cache/locatedb
|
export LOCATE_PATH=/var/cache/locatedb
|
||||||
|
|
||||||
|
|
||||||
# A nice prompt.
|
|
||||||
PROMPT_COLOR="1;31m"
|
|
||||||
let $UID && PROMPT_COLOR="1;32m"
|
|
||||||
PS1="\n\[\033[$PROMPT_COLOR\][\u@\h:\w]$\[\033[0m\] "
|
|
||||||
if test "x$TERM" == "xxterm"; then
|
|
||||||
PS1="\033]2;\h:\u:\w\007$PS1"
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
# Set up secure multi-user builds: non-root users build through the
|
# Set up secure multi-user builds: non-root users build through the
|
||||||
# Nix daemon.
|
# Nix daemon.
|
||||||
if test "$USER" != root; then
|
if test "$USER" != root; then
|
||||||
@ -85,15 +76,9 @@ if test ! -e $HOME/.nix-defexpr -o -L $HOME/.nix-defexpr; then
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Include bashrc settings
|
||||||
|
|
||||||
# Some aliases.
|
source /etc/bashrc
|
||||||
alias ls="ls --color=tty"
|
|
||||||
alias ll="ls -l"
|
|
||||||
alias which="type -p"
|
|
||||||
|
|
||||||
# Help `rpcgen' find `cpp', assuming it's installed in the user's environment.
|
|
||||||
alias rpcgen="rpcgen -Y $HOME/.nix-profile/bin"
|
|
||||||
|
|
||||||
|
|
||||||
# Read system-wide modifications.
|
# Read system-wide modifications.
|
||||||
if test -f /etc/profile.local; then
|
if test -f /etc/profile.local; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user