18 lines
363 B
Bash
Executable File
18 lines
363 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# 自动检查并提交 git 修改
|
|
|
|
cd ~/.openclaw
|
|
git add -A
|
|
if ! git diff --cached --quiet; then
|
|
git commit -m "自动同步: $(date '+%Y-%m-%d %H:%M')"
|
|
git push origin main
|
|
fi
|
|
|
|
cd ~/.openclaw/extensions
|
|
git add -A
|
|
if ! git diff --cached --quiet; then
|
|
git commit -m "自动同步: $(date '+%Y-%m-%d %H:%M')"
|
|
git push origin main
|
|
fi
|