system: Cleanup bash startup files.
* gnu/system.scm (etc-directory) (bashrc): Rename to 'profile'. * gnu/system/shadow.scm (default-skeletons): Rename '.bashrc' to '.bash_profile'. Don't source /etc/profile.
This commit is contained in:
parent
fecbf86eaa
commit
4e2a21d3d2
|
@ -386,11 +386,10 @@ This is the GNU system. Welcome.\n")
|
||||||
(nsswitch (text-file "nsswitch.conf"
|
(nsswitch (text-file "nsswitch.conf"
|
||||||
"hosts: files dns\n"))
|
"hosts: files dns\n"))
|
||||||
|
|
||||||
;; TODO: Generate bashrc from packages' search-paths.
|
;; Startup file for POSIX-compliant login shells, which set system-wide
|
||||||
(bashrc (text-file* "bashrc" "
|
;; environment variables.
|
||||||
export PS1='\\u@\\h \\w\\$ '
|
(profile (text-file* "profile" "\
|
||||||
|
export LANG=\"" locale "\"
|
||||||
export LC_ALL=\"" locale "\"
|
|
||||||
export TZ=\"" timezone "\"
|
export TZ=\"" timezone "\"
|
||||||
export TZDIR=\"" tzdata "/share/zoneinfo\"
|
export TZDIR=\"" tzdata "/share/zoneinfo\"
|
||||||
|
|
||||||
|
@ -399,11 +398,7 @@ export LINUX_MODULE_DIRECTORY=/run/booted-system/kernel/lib/modules
|
||||||
|
|
||||||
export PATH=$HOME/.guix-profile/bin:/run/current-system/profile/bin
|
export PATH=$HOME/.guix-profile/bin:/run/current-system/profile/bin
|
||||||
export PATH=/run/setuid-programs:/run/current-system/profile/sbin:$PATH
|
export PATH=/run/setuid-programs:/run/current-system/profile/sbin:$PATH
|
||||||
export CPATH=$HOME/.guix-profile/include:" profile "/include
|
|
||||||
export LIBRARY_PATH=$HOME/.guix-profile/lib:" profile "/lib
|
|
||||||
export INFOPATH=$HOME/.guix-profile/share/info:/run/current-system/profile/share/info
|
export INFOPATH=$HOME/.guix-profile/share/info:/run/current-system/profile/share/info
|
||||||
alias ls='ls -p --color'
|
|
||||||
alias ll='ls -l'
|
|
||||||
"))
|
"))
|
||||||
(skel (skeleton-directory skeletons)))
|
(skel (skeleton-directory skeletons)))
|
||||||
(file-union "etc"
|
(file-union "etc"
|
||||||
|
@ -416,7 +411,7 @@ alias ll='ls -l'
|
||||||
("nsswitch.conf" ,#~#$nsswitch)
|
("nsswitch.conf" ,#~#$nsswitch)
|
||||||
("skel" ,#~#$skel)
|
("skel" ,#~#$skel)
|
||||||
("shells" ,#~#$shells)
|
("shells" ,#~#$shells)
|
||||||
("profile" ,#~#$bashrc)
|
("profile" ,#~#$profile)
|
||||||
("hosts" ,#~#$hosts-file)
|
("hosts" ,#~#$hosts-file)
|
||||||
("localtime" ,#~(string-append #$tzdata "/share/zoneinfo/"
|
("localtime" ,#~(string-append #$tzdata "/share/zoneinfo/"
|
||||||
#$timezone))
|
#$timezone))
|
||||||
|
|
|
@ -115,9 +115,13 @@
|
||||||
(copy-file (car (find-files #$guile-wm "wm-init-sample.scm"))
|
(copy-file (car (find-files #$guile-wm "wm-init-sample.scm"))
|
||||||
#$output)))
|
#$output)))
|
||||||
|
|
||||||
(mlet %store-monad ((bashrc (text-file "bashrc" "\
|
(mlet %store-monad ((profile (text-file "bash_profile" "\
|
||||||
# Allow non-login shells such as an xterm to get things right.
|
# Honor per-interactive-shell startup file
|
||||||
test -f /etc/profile && source /etc/profile\n"))
|
if [ -f ~/.bashrc ]; then . ~/.bashrc; fi\n"))
|
||||||
|
(bashrc (text-file "bashrc" "\
|
||||||
|
PS1='\\u@\\h \\w\\$ '
|
||||||
|
alias ls='ls -p --color'
|
||||||
|
alias ll='ls -l'\n"))
|
||||||
(guile-wm (gexp->derivation "guile-wm" copy-guile-wm
|
(guile-wm (gexp->derivation "guile-wm" copy-guile-wm
|
||||||
#:modules
|
#:modules
|
||||||
'((guix build utils))))
|
'((guix build utils))))
|
||||||
|
@ -127,7 +131,8 @@ XTerm*metaSendsEscape: true\n"))
|
||||||
(gdbinit (text-file "gdbinit" "\
|
(gdbinit (text-file "gdbinit" "\
|
||||||
# Tell GDB where to look for separate debugging files.
|
# Tell GDB where to look for separate debugging files.
|
||||||
set debug-file-directory ~/.guix-profile/lib/debug\n")))
|
set debug-file-directory ~/.guix-profile/lib/debug\n")))
|
||||||
(return `((".bashrc" ,bashrc)
|
(return `((".bash_profile" ,profile)
|
||||||
|
(".bashrc" ,bashrc)
|
||||||
(".Xdefaults" ,xdefaults)
|
(".Xdefaults" ,xdefaults)
|
||||||
(".guile-wm" ,guile-wm)
|
(".guile-wm" ,guile-wm)
|
||||||
(".gdbinit" ,gdbinit)))))
|
(".gdbinit" ,gdbinit)))))
|
||||||
|
|
Loading…
Reference in New Issue