add bash config

This commit is contained in:
FlintyLemming
2025-12-17 17:15:04 +08:00
parent b60e605a5f
commit 342cbb08cf
2 changed files with 16 additions and 0 deletions

14
bash/.add-on Normal file
View File

@@ -0,0 +1,14 @@
## 更新配置
dotu() {
# 使用 () 包裹命令会在子进程中运行,执行完后当前终端路径不会改变
(
cd "$HOME/.flinty" || exit
if git pull; then
echo "Git updated."
fi
)
# 在主进程刷新配置
source ~/.bashrc
echo "Config reloaded successfully!"
}