linux 误删了home里.bashrc等文件后.....

误删了.bashrc  history等等等等文件后。

ll 失灵了.....ll command not found

各种 字体颜色也没有了。

于是拷贝了一份.bashrc回来。source ~./bashrc后

配置生效。

但是还误删了.profile 这就导致每天我都要source啊!!

你可以用etc/skel/..... 里面找出来.profile文件~ 放在当前用户目录。

如果你找不到。那么内容是以下这样子的。。复制粘贴吧 兄dei~

# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.

# the default umask is set in /etc/profile; for setting the umask
# for ssh logins, install and configure the libpam-umask package.
#umask 022

# if running bash
if [ -n "$BASH_VERSION" ]; then
    # include .bashrc if it exists
    if [ -f "$HOME/.bashrc" ]; then
    . "$HOME/.bashrc"
    fi
fi

# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
    PATH="$HOME/bin:$PATH"
fi
 

猜你喜欢

转载自blog.csdn.net/aiyijava/article/details/86568780