1

BASH Prompt PS1 Directory Size and File Count

view story
linux-howto

http://crunchbanglinux.org – Hello everyone, after a few days of inactivity i'm finally back!Anyhow, down to business...I am trying to find out how to display the current visible directory and file count (as one number), and also display the current directory size in my PS1. Currently, I have it displaying the count, but for some odd reason it does not update the count when I cd to a different directory (regardless of permissions).Here is an excerpt from my bashrc. This is everything that deals with my prompt.#Prompt Command PROMPT_COMMAND='CurDir=`pwd|sed -e "s!$HOME!~!"|sed -re "s!([^/])[^/]+/!\ (HowTos)