trisquel-base-data /etc/bash_completion.d/aliases overrides custom dircolors

Proyecto:Trisquel
Componente:Misc
Categoría:informe de fallo
Prioridad:minor
Asignado:No asignado
Estado:closed
Descripción

At user login /etc/bash_completion.d/aliases is run after the "enable color support of ls" of .bashrc (see ~/.bashrc or /etc/skel/.bashrc) and overrides the custom "~/.dircolors" database.

I noticed that because I have custom colors for my .py files and never could get them after switching to Trisquel (everything worked in Debian)

It is sufficient to change one line from /etc/bash_completion.d/aliases. The proposed patch solves the issue.

--- /etc/bash_completion.d/aliases	2011-11-17 16:12:19.168085523 +0000
+++ aliases.new	2011-11-17 16:13:18.338085525 +0000
@@ -4,7 +4,7 @@
 
 # enable color support of ls and also add handy aliases
 if [ "$TERM" != "dumb" ] && [ -x /usr/bin/dircolors ]; then
-    eval "`dircolors -b`"
+    test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
     alias ls='ls --color=auto'
     alias ll='ls -lh'
     alias la='ls -A'

AdjuntoTamaño
patch.bash_completion.d-aliases.txt454 bytes
Jue, 12/08/2011 - 16:10
Jue, 12/22/2011 - 16:15
Estado:fixed» closed

Automatically closed -- issue fixed for 2 weeks with no activity.