Change color prompt

Procédure pour personaliser le prompt Bash

$ export PS1="[\\u@\\h \\W \\@]\\$"
[linodadmin@centos-01 ~ 01:50 PM]$

Pour le rendre Permanent copier-coler PS1 Value dans le .bashrc à la fin du fichier

Exemple (config srv)

$ export PS1="[[\033[01;33m]\u@\h[\033[00m] ~ [\033[01;30m]\w[\033[00m]] $"

Docs:

How to Change Bash Shell Prompt Colorful and Attractive in Linux

Change command line color in centos


Revision #3
Created 6 June 2020 12:13:50 by Lauris_Adm
Updated 29 March 2023 11:54:35 by Lauris_Adm