Webmasters often use SSH to remotely admin web sites and servers, learn how to make your shell colorful and powerful using my sample .bash_profile and you can be up and running in 30 seconds!

Table of Contents

  1. Introduction
    1. ScreenShot using the custom .bash_profile
    2. Create the Custom Environment
    3. .bash_profile
    4. More Reading

ScreenShot using the custom .bash_profile

Create the Custom Environment

All you have to do is create or edit your ~ root file .bash_profile to get the customization you want. The PS1 variable being exported below is the prompt. I included a few alias commands as well, which explains why the outputs from the 2 screen captures above are different for the ls command.

.bash_profile

Simply copy and paste the below or you can download text file: Custom Pretty DreamHost .bash_profile.

# ~/.bash_profile: executed by bash(1) for login shells.

umask 002

export PS1="ne[1;37m[e[0;32mue[0;35m@e[0;32mhe[1;37m]e[1;37m[e[0;31mwe[1;37m]n$ "
export JAVA_HOME=/usr/local/dh/java

alias dsiz='du -sk * | sort -n --'
alias bash='clear;/bin/bash -l'
alias ls='ls -lahF --color=auto'

More Reading

  • Bash Man Page (html), (txt)
  • HackTux Linux Help - Custom Bash Shell Prompts
  • tldp.org - Advanced Bash-Scripting Guide - (pdf version)
  • tldp.org - Bash Prompt HOWTO
  • Life After Coffee - Customize your Bash Prompt
  • TuxForums.org - Custom Bash Prompt How-To
  • Google search results - "custom bash shell prompt"

Custom Webmaster Shell Environment - AskApache

Charles Torvalds
4 Jul 2007

  • Site Map WireShark GNU Non-GNU Tor Project cURL TLDP - Documentation
  • Htaccess Files Hacking Htaccess Javascript Linux Optimization PHP Security Shell Scripting WordPress
  • Base64 Image Converter Raw HTTP Header Debugger Graphical ASCII Text Generator Mac Address Vendor Lookup Who Am I – Your IP Information Request Method Security Scanner .htpasswd file Generator Compress CSS DNS Tracer
Copyright © 2025 AskApache
  • Site Map
  • Htaccess Files
  • Hacking
  • Htaccess
  • Javascript
  • Linux
  • Optimization
  • PHP
  • Security
  • Shell Scripting
  • WordPress
  • Base64 Image Converter
  • Raw HTTP Header Debugger
  • Graphical ASCII Text Generator
  • Mac Address Vendor Lookup
  • Who Am I – Your IP Information
  • Request Method Security Scanner
  • .htpasswd file Generator
  • Compress CSS
  • DNS Tracer
Exit mobile version