config for bak.fbh

This commit is contained in:
fengbh 2025-04-19 16:09:17 +08:00
parent 2fd2f2516a
commit 92e51f2cef
3 changed files with 14 additions and 6 deletions

View File

@ -3,15 +3,21 @@
请把下面的代码添加到你的`.bashrc`
```bash
#========================================
# user config
#========================================
# ~/.bashrc (用户实际使用的文件)
# 1. 加载公共配置
if [ -f ~/.bashrc_common ]; then
source ~/.bashrc_common
else
echo "Can't find ~/..bashrc_common";
fi
# 2. 加载主机特定配置(根据主机名自动选择)
HOSTNAME=$(hostname -s) # 获取主机名
HOST_RC="$HOME/.bashrc_$HOSTNAME"
HOST_RC="$HOME/.bashrc_host"
if [ -f "$HOST_RC" ]; then
source "$HOST_RC"
fi```
else
echo "Can't find $HOST_RC";
fi

4
setup.sh Normal file → Executable file
View File

@ -3,7 +3,7 @@
# License : MIT
# Author : Feng Bohan <1953356163@qq.com>
# Date : 2025-04-18 09:02:16
# Last Modified Date: 2025-04-18 11:47:01
# Last Modified Date: 2025-04-19 16:00:47
# Last Modified By : Feng Bohan <1953356163@qq.com>
# -----
# Copyright © 2025 Feng Bohan. All Rights Reserved.
@ -19,7 +19,7 @@ if [ ! -f ~/.vim/autoload/plug.vim ]; then
fi
# 安装插件
vim -c "PlugInstall | q | q"
echo "请手动执行命令:PlugInstall 安装插件"
echo "开始配置bashrc"

View File

@ -3,7 +3,7 @@
" License : MIT
" Author : Feng Bohan <1953356163@qq.com>
" Date : 2025-04-18 08:39:57
" Last Modified Date: 2025-04-18 08:54:03
" Last Modified Date: 2025-04-19 15:40:57
" Last Modified By : Feng Bohan <1953356163@qq.com>
" File : .vimrc
" Author : Feng Bohan <fengbohan@fmsh.com.cn>
@ -98,6 +98,8 @@ nnoremap <C-k> :bp<CR>
nnoremap <C-h> :bwipe<CR>
map <C-L> <Esc>:set guifont=Monospace\ 16<Enter>
map <C-M> <Esc>:set guifont=Monospace\ 14<Enter>
nnoremap <Leader>t :below terminal<CR>
nnoremap <C-s> :w<CR>
" 特殊配置
let g:polyglot_disabled = ['verilog_systemverilog']