Package: base-files Version: 6.0squeeze2 Severity: wishlist Tags: patch -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
This is a solution to bug #571086 (now closed) which keeps /etc/login.defs as the only place to set PATH, by computing the set there value on the fly using only grep and coreutils (both essential packages and thus guaranteed to be always present). The benefit of using it is that there is no need to sync the two PATH values; any change to /etc/login.defs will be immediately applied to subsequent logins. regards George Zarkadas - -- System Information: Debian Release: 6.0.2 APT prefers stable-updates APT policy: (500, 'stable-updates'), (500, 'proposed-updates'), (500, 'stable'), (450, 'testing-proposed-updates'), (450, 'testing'), (400, 'unstable') Architecture: amd64 (x86_64) Kernel: Linux 2.6.32-5-amd64 (SMP w/4 CPU cores) Locale: LANG=el_GR.utf8, LC_CTYPE=el_GR.utf8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Versions of packages base-files depends on: ii gawk [awk] 1:3.1.7.dfsg-5 GNU awk, a pattern scanning and pr ii mawk [awk] 1.3.3-15 a pattern scanning and text proces base-files recommends no packages. base-files suggests no packages. - -- no debconf information -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQEcBAEBAgAGBQJOFIriAAoJEJWXIVmJ5BwWy4UH/RX8WAriNj/tVBXXdlr9rfOh zvAkDynCJygZZuyKa44cA8taNzpiSnphQOgtoWufbxt6TNN637G037HJQmBGKkjy ELzT3tcO3SpEIxX+m7+QgWhbc04Or/p96Khmy5xbyAqw1bUl9XK37EAlrj3j3IyN 8aAjbvnYaT3rASqX1oxlYSdCJBcaL0RATcBP9PMvmG8VJxWDDAbUV9PfGy5PG1HA fSJtDYlcOEy71PqF5Ojr/Tbh9PUR5eVgn9sD/yqETgXgdW0O0y3VGF0j6u57eRfF PF05H9wneOxt9hkfWEdykcUdtSDo9+/9f/lZ2yzntM482EGY4vBWSEOjL5Iy4so= =/I6N -----END PGP SIGNATURE-----
--- /etc/profile 2010-08-06 20:42:50.000000000 +0300 +++ /etc/profile 2011-07-06 18:40:59.187069301 +0300 @@ -1,10 +1,12 @@ # /etc/profile: system-wide .profile file for the Bourne shell (sh(1)) # and Bourne compatible shells (bash(1), ksh(1), ash(1), ...). +# Presence of /etc/login.defs and ENV_xxx are mandatory. Thus do not check +# or provide alternative action to avoid duplicating PATH definitions. if [ "`id -u`" -eq 0 ]; then - PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" + PATH=`grep 'ENV_SUPATH.*PATH=' /etc/login.defs | cut -d= -f2` else - PATH="/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games" + PATH=`grep 'ENV_PATH.*PATH=' /etc/login.defs | cut -d= -f2` fi export PATH