Home >Operation and Maintenance >Linux Operation and Maintenance >Linux does not display the current path by default
Solution:
1. Enter the etc directory and modify the profile file
2. At the end Add one line: export PS1='[\u@\h $PWD]\$'
3. After saving, execute: source /etc/profile
You can immediately see that the displayed path has changed and turned into a full path. Then every file directory you go to will display the full path. , which is much more convenient.
Recommended tutorial: linux tutorial
The above is the detailed content of Linux does not display the current path by default. For more information, please follow other related articles on the PHP Chinese website!