重开仓库内容:改推五个技能(browser-harness / humanizer / humanizer-zh / product-planning / session-mechanism)
按授权清空原有内容后重新提交(原 oil-ui-pro 一并移出,可从历史恢复)。 browser-harness 剔除 .venv 等运行环境;根 .gitignore 补记 .venv/ 与 node_modules/。
This commit is contained in:
1 parent
9a152a1952
commit
777f7fe5d0
240 files changed
+52518
-4409
No files matched your search
@@ -1,31 +0,0 @@
|
||||
#!/bin/sh
|
||||
# 加载时先找可用的 Python 3;缺少时只提醒一次,继续原任务。
|
||||
script_dir=${0%/*}
|
||||
if [ -n "$OIL_NO_UPDATE_CHECK" ] || [ -e "$script_dir/../.git" ]; then
|
||||
exit 0
|
||||
fi
|
||||
state_base=${XDG_STATE_HOME:-${LOCALAPPDATA:-$HOME/.local/state}}
|
||||
marker="$state_base/oil/update-python-missing"
|
||||
for interpreter in python3 python; do
|
||||
if command -v "$interpreter" >/dev/null 2>&1 && "$interpreter" -c 'import sys; sys.exit(0 if sys.version_info[0] == 3 else 1)' >/dev/null 2>&1; then
|
||||
rmdir "$marker" 2>/dev/null
|
||||
exec "$interpreter" "$script_dir/check_update.py"
|
||||
fi
|
||||
done
|
||||
# mkdir 的独占创建同时防止连续加载与并发加载重复提醒。
|
||||
missing_python_notice() {
|
||||
case ${LC_ALL:-${LC_MESSAGES:-$LANG}} in
|
||||
en*|EN*) printf '%s\n' 'Automatic updates need Python 3. This update check did not run.' ;;
|
||||
*) printf '%s\n' '自动更新需要 Python 3,本次没有检查更新。' ;;
|
||||
esac
|
||||
}
|
||||
mkdir -p "$state_base/oil" 2>/dev/null
|
||||
if mkdir "$marker" 2>/dev/null; then
|
||||
missing_python_notice
|
||||
elif [ -d "$marker" ]; then
|
||||
printf '%s\n' 'OIL_UPDATE_CHECK_SKIPPED: missing_python'
|
||||
else
|
||||
# 状态目录不可写时,由宿主记住这次提醒。
|
||||
missing_python_notice
|
||||
fi
|
||||
exit 0
|
||||
Reference in new issue
Block a user