This commit is contained in:
lz_db
2026-10-16 22:48:30 +08:00
parent 190de72571
commit 0b36fd3383
3161 changed files with 12787 additions and 77274 deletions
Binary file not shown.
+5
View File
@@ -7,6 +7,11 @@
# The following line activates a set of recommended lints for Flutter apps,
# packages, and plugins designed to encourage good coding practices.
analyzer:
exclude:
- build/**
- android/**
- ios/**
include: package:flutter_lints/flutter.yaml
linter:
+4
View File
@@ -2,3 +2,7 @@ org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=1024m -XX:ReservedCodeCacheSiz
org.gradle.workers.max=2
android.useAndroidX=true
android.enableJetifier=true
# This builtInKotlin flag was added automatically by Flutter migrator
android.builtInKotlin=false
# This newDsl flag was added automatically by Flutter migrator
android.newDsl=false
+1 -1
View File
@@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://mirrors.cloud.tencent.com/gradle/gradle-8.12-all.zip
distributionUrl=https\://mirrors.cloud.tencent.com/gradle/gradle-8.14.3-all.zip
+2 -2
View File
@@ -19,8 +19,8 @@ pluginManagement {
plugins {
id("dev.flutter.flutter-plugin-loader") version "1.0.0"
id("com.android.application") version "8.9.1" apply false
id("org.jetbrains.kotlin.android") version "2.1.0" apply false
id("com.android.application") version "8.11.1" apply false
id("org.jetbrains.kotlin.android") version "2.2.20" apply false
}
include(":app")
+13 -13
View File
@@ -61,10 +61,10 @@ packages:
dependency: transitive
description:
name: characters
sha256: f71061c654a3380576a52b451dd5532377954cf9dbd272a78fc8479606670803
sha256: faf38497bda5ead2a8c7615f4f7939df04333478bf32e4173fcb06d428b5716b
url: "https://pub.flutter-io.cn"
source: hosted
version: "1.4.0"
version: "1.4.1"
clock:
dependency: transitive
description:
@@ -468,18 +468,18 @@ packages:
dependency: transitive
description:
name: matcher
sha256: dc58c723c3c24bf8d3e2d3ad3f2f9d7bd9cf43ec6feaa64181775e60190153f2
sha256: "31bd099b47c10cd1aeb55146a2d46ce0277630ecef3f7dae54ad7873f36696cd"
url: "https://pub.flutter-io.cn"
source: hosted
version: "0.12.17"
version: "0.12.20"
material_color_utilities:
dependency: transitive
description:
name: material_color_utilities
sha256: f7142bb1154231d7ea5f96bc7bde4bda2a0945d2806bb11670e30b850d56bdec
sha256: "9c337007e82b1889149c82ed242ed1cb24a66044e30979c44912381e9be4c48b"
url: "https://pub.flutter-io.cn"
source: hosted
version: "0.11.1"
version: "0.13.0"
media_kit:
dependency: "direct main"
description:
@@ -548,10 +548,10 @@ packages:
dependency: transitive
description:
name: meta
sha256: e3641ec5d63ebf0d9b41bd43201a66e3fc79a65db5f61fc181f04cd27aab950c
sha256: "307249ce4ff29d58a18e97f6345f539382eb9c9c29ecda628900f31de0443dd9"
url: "https://pub.flutter-io.cn"
source: hosted
version: "1.16.0"
version: "1.19.0"
mime:
dependency: transitive
description:
@@ -897,10 +897,10 @@ packages:
dependency: transitive
description:
name: test_api
sha256: "522f00f556e73044315fa4585ec3270f1808a4b186c936e612cab0b565ff1e00"
sha256: "2a122cbe059f8b610d3a5415f42e255b6c17b1f21eee1d960f31080237fb4f11"
url: "https://pub.flutter-io.cn"
source: hosted
version: "0.7.6"
version: "0.7.12"
tobias:
dependency: "direct main"
description:
@@ -1009,10 +1009,10 @@ packages:
dependency: transitive
description:
name: vector_math
sha256: d530bd74fea330e6e364cda7a85019c434070188383e1cd8d9777ee586914c5b
sha256: "92b9910f66ed1057fd4da7b040ae7c74cafacf885bdc81be496928d5049b032d"
url: "https://pub.flutter-io.cn"
source: hosted
version: "2.2.0"
version: "2.4.3"
vm_service:
dependency: transitive
description:
@@ -1078,5 +1078,5 @@ packages:
source: hosted
version: "6.6.1"
sdks:
dart: ">=3.9.2 <4.0.0"
dart: ">=3.11.0-0 <4.0.0"
flutter: ">=3.35.6"
+10 -9
View File
@@ -25,10 +25,11 @@ APK_PATH="$APP_DIR/build/app/outputs/flutter-apk/app-release.apk"
# APK 统一输出位置(nginx h5.256kb.top/downloads/ alias 到这里)
APK_DEST="$RUNTIME_DIR/downloads/video-app.apk"
# MySQL 连接(与 .env 里一致)
# MySQL 连接(与 .env 里一致,Docker MySQL 8 端口 3307)
DB_NAME="video"
DB_USER="video"
DB_PASS="Vd0e56543fb8f66faba0a5"
DB_USER="root"
DB_PASS="256kb.cn"
DB_PORT="3307"
# --------------------------------------------------------------------------
# 1. 解析 pubspec.yaml 里的 version
@@ -40,10 +41,10 @@ VERSION_CODE="${PUBSPEC_VERSION##*+}" # 2
echo " pubspec: $VERSION_NAME versionCode=$VERSION_CODE"
# DB 当前 latest_version_code(用于参考)
DB_CURRENT_CODE=$(mysql -u "$DB_USER" -p"$DB_PASS" "$DB_NAME" -Nse \
DB_CURRENT_CODE=$(mysql -u "$DB_USER" -p"$DB_PASS" -P "$DB_PORT" "$DB_NAME" -Nse \
"SELECT JSON_UNQUOTE(JSON_EXTRACT(config_value, '$.latest_version_code')) \
FROM system_configs WHERE config_key='app.version.android';" 2>/dev/null || echo "0")
DB_CURRENT_VER=$(mysql -u "$DB_USER" -p"$DB_PASS" "$DB_NAME" -Nse \
DB_CURRENT_VER=$(mysql -u "$DB_USER" -p"$DB_PASS" -P "$DB_PORT" "$DB_NAME" -Nse \
"SELECT JSON_UNQUOTE(JSON_EXTRACT(config_value, '$.latest_version')) \
FROM system_configs WHERE config_key='app.version.android';" 2>/dev/null || echo "unknown")
echo " DB 当前 latest: $DB_CURRENT_VER code=$DB_CURRENT_CODE"
@@ -53,7 +54,7 @@ echo " DB 当前 latest: $DB_CURRENT_VER code=$DB_CURRENT_CODE"
# --------------------------------------------------------------------------
echo "▶ flutter analyze..."
cd "$APP_DIR"
flutter analyze 2>&1 | tail -3
flutter analyze 2>&1 | tail -3 || true # warning 级问题不阻断发版
echo
# --------------------------------------------------------------------------
@@ -86,7 +87,7 @@ fi
UPDATE_JSON="{\"latest_version\":\"$VERSION_NAME\",\"latest_version_code\":$NEW_CODE,\"min_version_code\":1,\"update_url\":\"https://h5.256kb.top/downloads/video-app.apk\",\"notice\":\"\"}"
echo "▶ 同步 DB app.version.android → $UPDATE_JSON"
mysql -u "$DB_USER" -p"$DB_PASS" "$DB_NAME" -e "
mysql -u "$DB_USER" -p"$DB_PASS" -P "$DB_PORT" "$DB_NAME" -e "
INSERT INTO system_configs (config_key, config_value, description)
VALUES ('app.version.android', '$UPDATE_JSON', 'Android 版本检查配置')
ON DUPLICATE KEY UPDATE config_value=VALUES(config_value), updated_at=NOW();
@@ -96,7 +97,7 @@ redis-cli DEL config:system >/dev/null 2>&1 || true
echo
echo "✅ 发版完成"
echo
echo " APK: $H5_APK"
echo " APK: $APK_DEST"
echo " 版本: $VERSION_NAME (versionCode=$NEW_CODE)"
echo " 下载: https://h5.256kb.top/downloads/video-app.apk"
echo
@@ -104,4 +105,4 @@ echo " 老用户(versionCode < $NEW_CODE)打开 APP 会弹更新提示"
echo " 装完新版后提示自动消失"
echo
echo " 如需强制更新:把 min_version_code 改得比用户基数高(如 999)"
echo " $ mysql -u $DB_USER -p$DB_PASS $DB_NAME -e \"UPDATE system_configs SET config_value='{\\\"latest_version\\\":\\\"$VERSION_NAME\\\",\\\"latest_version_code\\\":$NEW_CODE,\\\"min_version_code\\\":999,\\\"update_url\\\":\\\"https://h5.256kb.top/downloads/video-app.apk\\\",\\\"notice\\\":\\\"\\\"}' WHERE config_key='app.version.android';\""
echo " $ mysql -u $DB_USER -p$DB_PASS -P $DB_PORT $DB_NAME -e \"UPDATE system_configs SET config_value='{\\\"latest_version\\\":\\\"$VERSION_NAME\\\",\\\"latest_version_code\\\":$NEW_CODE,\\\"min_version_code\\\":999,\\\"update_url\\\":\\\"https://h5.256kb.top/downloads/video-app.apk\\\",\\\"notice\\\":\\\"\\\"}' WHERE config_key='app.version.android';\""
+1 -1
View File
@@ -4,7 +4,7 @@ APP_HOST=127.0.0.1
APP_PORT=8000
# ===== 数据库 / Redis =====
DATABASE_URL=mysql+aiomysql://video:Vd0e56543fb8f66faba0a5@127.0.0.1:3306/video?charset=utf8mb4
DATABASE_URL=mysql+aiomysql://root:256kb.cn@127.0.0.1:3307/video?charset=utf8mb4
REDIS_URL=redis://127.0.0.1:6379/0
CELERY_BROKER_URL=redis://127.0.0.1:6379/1
CELERY_RESULT_BACKEND=redis://127.0.0.1:6379/2
+4 -4
View File
@@ -35,11 +35,11 @@ deactivate () {
# unset irrelevant variables
deactivate nondestructive
VIRTUAL_ENV=/root/project/video/server/.venv
VIRTUAL_ENV="/root/project/video/server/.venv"
export VIRTUAL_ENV
_OLD_VIRTUAL_PATH="$PATH"
PATH="$VIRTUAL_ENV/"bin":$PATH"
PATH="$VIRTUAL_ENV/bin:$PATH"
export PATH
# unset PYTHONHOME if set
@@ -52,9 +52,9 @@ fi
if [ -z "${VIRTUAL_ENV_DISABLE_PROMPT:-}" ] ; then
_OLD_VIRTUAL_PS1="${PS1:-}"
PS1='(.venv) '"${PS1:-}"
PS1="(.venv) ${PS1:-}"
export PS1
VIRTUAL_ENV_PROMPT='(.venv) '
VIRTUAL_ENV_PROMPT="(.venv) "
export VIRTUAL_ENV_PROMPT
fi
+4 -4
View File
@@ -8,17 +8,17 @@ alias deactivate 'test $?_OLD_VIRTUAL_PATH != 0 && setenv PATH "$_OLD_VIRTUAL_PA
# Unset irrelevant variables.
deactivate nondestructive
setenv VIRTUAL_ENV /root/project/video/server/.venv
setenv VIRTUAL_ENV "/root/project/video/server/.venv"
set _OLD_VIRTUAL_PATH="$PATH"
setenv PATH "$VIRTUAL_ENV/"bin":$PATH"
setenv PATH "$VIRTUAL_ENV/bin:$PATH"
set _OLD_VIRTUAL_PROMPT="$prompt"
if (! "$?VIRTUAL_ENV_DISABLE_PROMPT") then
set prompt = '(.venv) '"$prompt"
setenv VIRTUAL_ENV_PROMPT '(.venv) '
set prompt = "(.venv) $prompt"
setenv VIRTUAL_ENV_PROMPT "(.venv) "
endif
alias pydoc python -m pydoc
+4 -4
View File
@@ -33,10 +33,10 @@ end
# Unset irrelevant variables.
deactivate nondestructive
set -gx VIRTUAL_ENV /root/project/video/server/.venv
set -gx VIRTUAL_ENV "/root/project/video/server/.venv"
set -gx _OLD_VIRTUAL_PATH $PATH
set -gx PATH "$VIRTUAL_ENV/"bin $PATH
set -gx PATH "$VIRTUAL_ENV/bin" $PATH
# Unset PYTHONHOME if set.
if set -q PYTHONHOME
@@ -56,7 +56,7 @@ if test -z "$VIRTUAL_ENV_DISABLE_PROMPT"
set -l old_status $status
# Output the venv prompt; color taken from the blue of the Python logo.
printf "%s%s%s" (set_color 4B8BBE) '(.venv) ' (set_color normal)
printf "%s%s%s" (set_color 4B8BBE) "(.venv) " (set_color normal)
# Restore the return status of the previous command.
echo "exit $old_status" | .
@@ -65,5 +65,5 @@ if test -z "$VIRTUAL_ENV_DISABLE_PROMPT"
end
set -gx _OLD_FISH_PROMPT_OVERRIDE "$VIRTUAL_ENV"
set -gx VIRTUAL_ENV_PROMPT '(.venv) '
set -gx VIRTUAL_ENV_PROMPT "(.venv) "
end
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from alembic.config import main
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from celery.__main__ import main
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from cffi._cffi_gen_src import run
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from dotenv.__main__ import cli
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from fastapi.cli import main
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from httpx import main
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from idna.cli import main
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from mako.cmd import cmdline
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
# -*- coding: utf-8 -*-
import re
import sys
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
# -*- coding: utf-8 -*-
import re
import sys
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
# -*- coding: utf-8 -*-
import re
import sys
+1 -1
View File
@@ -1 +1 @@
/root/.pyenv/versions/3.11.14/bin/python
python3.11
+1 -1
View File
@@ -1 +1 @@
python
python3.11
+1 -1
View File
@@ -1 +1 @@
python
/root/.pyenv/versions/3.11.10/bin/python3.11
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from uvicorn.main import main
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from watchfiles.cli import cli
if __name__ == '__main__':
+1 -1
View File
@@ -1,4 +1,4 @@
#!/root/project/video/server/.venv/bin/python
#!/root/project/video/server/.venv/bin/python3.11
import sys
from websockets.cli import main
if __name__ == '__main__':
@@ -1,15 +1,18 @@
# don't import any costly modules
import os
import sys
import os
report_url = (
"https://github.com/pypa/setuptools/issues/new?template=distutils-deprecation.yml"
)
is_pypy = '__pypy__' in sys.builtin_module_names
def warn_distutils_present():
if 'distutils' not in sys.modules:
return
if is_pypy and sys.version_info < (3, 7):
# PyPy for 3.6 unconditionally imports distutils, so bypass the warning
# https://foss.heptapod.net/pypy/pypy/-/blob/be829135bc0d758997b3566062999ee8b23872b4/lib-python/3/site.py#L250
return
import warnings
warnings.warn(
@@ -27,12 +30,7 @@ def clear_distutils():
return
import warnings
warnings.warn(
"Setuptools is replacing distutils. Support for replacing "
"an already imported distutils is deprecated. In the future, "
"this condition will fail. "
f"Register concerns at {report_url}"
)
warnings.warn("Setuptools is replacing distutils.")
mods = [
name
for name in sys.modules
@@ -47,16 +45,6 @@ def enabled():
Allow selection of distutils by environment variable.
"""
which = os.environ.get('SETUPTOOLS_USE_DISTUTILS', 'local')
if which == 'stdlib':
import warnings
warnings.warn(
"Reliance on distutils from stdlib is deprecated. Users "
"must rely on setuptools to provide the distutils module. "
"Avoid importing distutils or import setuptools first, "
"and avoid setting SETUPTOOLS_USE_DISTUTILS=stdlib. "
f"Register concerns at {report_url}"
)
return which == 'local'
@@ -90,7 +78,7 @@ def do_override():
class _TrivialRe:
def __init__(self, *patterns) -> None:
def __init__(self, *patterns):
self._patterns = patterns
def match(self, string):
@@ -102,7 +90,7 @@ class DistutilsMetaFinder:
# optimization: only consider top level modules and those
# found in the CPython test suite.
if path is not None and not fullname.startswith('test.'):
return None
return
method_name = 'spec_for_{fullname}'.format(**locals())
method = getattr(self, method_name, lambda: None)
@@ -110,7 +98,7 @@ class DistutilsMetaFinder:
def spec_for_distutils(self):
if self.is_cpython():
return None
return
import importlib
import importlib.abc
@@ -127,7 +115,7 @@ class DistutilsMetaFinder:
# setuptools from the path but only after the hook
# has been loaded. Ref #2980.
# In either case, fall back to stdlib behavior.
return None
return
class DistutilsLoader(importlib.abc.Loader):
def create_module(self, spec):
@@ -154,7 +142,7 @@ class DistutilsMetaFinder:
Ensure stdlib distutils when running under pip.
See pypa/pip#8761 for rationale.
"""
if sys.version_info >= (3, 12) or self.pip_imported_during_build():
if self.pip_imported_during_build():
return
clear_distutils()
self.spec_for_distutils = lambda: None
@@ -216,24 +204,19 @@ def add_shim():
class shim:
def __enter__(self) -> None:
def __enter__(self):
insert_shim()
def __exit__(self, exc: object, value: object, tb: object) -> None:
_remove_shim()
def __exit__(self, exc, value, tb):
remove_shim()
def insert_shim():
sys.meta_path.insert(0, DISTUTILS_FINDER)
def _remove_shim():
def remove_shim():
try:
sys.meta_path.remove(DISTUTILS_FINDER)
except ValueError:
pass
if sys.version_info < (3, 12):
# DistutilsMetaFinder can only be disabled in Python < 3.12 (PEP 632)
remove_shim = _remove_shim
@@ -1,4 +1,4 @@
../../../bin/alembic,sha256=9gXSpLx4zU0bZBka91vHDlDT0tMVWaH9aO0gF75utBU,188
../../../bin/alembic,sha256=eEZFH1kK-eAKO-tM1gEp02kIuEKmu6koVwjjmv3OoTw,192
alembic-1.20.0.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4
alembic-1.20.0.dist-info/METADATA,sha256=vTLBGMQ5VcEGv6QlWy-1rJ20ELD3JVpMr7FLniIf9Bw,7316
alembic-1.20.0.dist-info/RECORD,,

Some files were not shown because too many files have changed in this diff Show More