How to add date and color to Ubuntu terminal
To add date and color to your terminal in your Linux Ubuntu operating system, follow the commands below in order.
nano ~/.profile
We add the following code to the bottom of the file.
export PS1="\e[0;31m[\d \t] \e[m \e[0;33m[\u@\h:\w ] \e[m$ "
We enter the following command to validate the change in the .profile file we logged into.
source ~/.profile
If your settings are not saved when you close and reopen the terminal, you can change the ~/.bashrc folder instead of ~/.profile.
Can't find the information you're looking for?
You have examined the knowledge base in detail, but if you cannot find the information you need,
Create a Support Ticket-
How to Open Ports in Windows?
1302 2
-
How to Grant Windows Administrator Privileges?
864 0
-
How to install Webmin on Ubuntu?
1451 2
-
Linux SSH Terminal Commands and Explanations
1363 3
-
CentOS Stream 10 Update Commands
1401 1
-
CentOS Stream 9 Update Commands
2234 2
-
CentOS Stream 8 Update Commands
1235 0
-
What is FreeBSD?
1335 2
-
Out: 452 4.3.1 Insufficient system storage
1347 2
-
Turning Off Automatic Updates in Windows Operating Systems
1503 1