add .vimrc checker

This commit is contained in:
Konano 2023-07-22 15:05:59 +08:00
parent b5e9fed54e
commit cd3261d399
2 changed files with 4 additions and 0 deletions

View File

@ -70,6 +70,8 @@ configure_nano() {
} }
configure_vim() { configure_vim() {
[ -f ~/.vimrc ] && return
read -p "要配置 vim 吗?[Y/n]: " response read -p "要配置 vim 吗?[Y/n]: " response
if [[ -z "$response" ]] || [[ $response =~ ^[Yy]$ ]]; then if [[ -z "$response" ]] || [[ $response =~ ^[Yy]$ ]]; then

View File

@ -70,6 +70,8 @@ configure_nano() {
} }
configure_vim() { configure_vim() {
[ -f ~/.vimrc ] && return
read -p "要配置 vim 吗?[Y/n]: " response read -p "要配置 vim 吗?[Y/n]: " response
if [[ -z "$response" ]] || [[ $response =~ ^[Yy]$ ]]; then if [[ -z "$response" ]] || [[ $response =~ ^[Yy]$ ]]; then