Quien me dice que agregar al bash.bashrc para que al hacer ls se vean las carpetas de colores.........

Imagen de Gatoubb
0 puntos

Miren supe que habia que agregarle algo al /etc/bash.bashrc para que al hacer el ls me muestre las carpetas, los ejecutables, comprimidos,etc de colores este es mi /etc/bash.bashrc :

# System-wide .bashrc file for interactive bash(1) shells.

# If not running interactively, don't do anything
[ -z "$PS1" ] && return

# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize

# set variable identifying the chroot you work in
if [ -z "$debian_chroot" -a -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi

# set a fancy prompt (overwrite the one in /etc/profile)
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w \$ '

# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"'
;;
*)
;;
esac

# enable bash completion in interactive shells
#if [ -f /etc/bash_completion ]; then
# . /etc/bash_completion
#fi

alguien me puede dar las lineas extras para que se vean de colores estos tipos de archivos al hacer el ls plissssssssss

de antemano muchas gracias.....

Imagen de Anónimo
+1
0
-1

Añade simplemente esta línea
alias ls='ls --color=auto'

Un saludo.

+1
0
-1
Imagen de herje
+1
0
-1

Un consejo, es preferible modificar tu .bashrc y no tocar el de etc. Te dejo el mío como ejemplo:

**************
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples

# If not running interactively, don't do anything
[ -z "$PS1" ] && return

# don't put duplicate lines in the history. See bash(1) for more options
#export HISTCONTROL=ignoredups

# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize

# enable color support of ls and also add handy aliases
if [ "$TERM" != "dumb" ]; then
eval `dircolors -b`
alias ls='ls -la --color=auto'
#alias dir='ls --color=auto --format=vertical'
#alias vdir='ls --color=auto --format=long'
fi

# some more ls aliases
alias ll='ls -l -color=auto'
alias la='ls -lA --color=auto'
alias l='ls -CF --color=auto'
alias xx="exit"
alias apts="apt-cache search"
alias ver="apt-cache show"
alias paquetes="dpkg -l"

# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(lesspipe)"

# set variable identifying the chroot you work in
if [ -z "$debian_chroot" -a -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi

# A color and a non-color prompt:
#PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w \$ '

# Comment in the above and uncomment this below for a color prompt
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\] \$ '

# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"'
;;
*)
;;
esac

# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc).
#if [ -f /etc/bash_completion ]; then
# . /etc/bash_completion
#fi
herje@platas ~ $

**********************

Saludos
Herje
http://www.herje.com

+1
0
-1

Saludos
Herje
http://www.herje.com