refactor(build): unify SDK configuration and release tooling
Pin Flutter with FVM and share local environment loading across IDE, Python, and Dart entrypoints. Keep CI on the verified preinstalled SDK and skip local overrides. Extract common build presets, process execution, and file hashing. Propagate project roots through SDK selection and release commands, and migrate macOS release, signing, and DMG orchestration to Python. Reuse local check suites in CI, support Android source overrides, and update documentation and regression tests.
This commit is contained in:
1 parent
a13a54d5ec
commit
0343e2f723
57 files changed
+1858
-375
No files matched your search
@@ -3,10 +3,14 @@
|
||||
import argparse
|
||||
from functools import partial
|
||||
from http.server import SimpleHTTPRequestHandler, ThreadingHTTPServer
|
||||
import os
|
||||
from pathlib import Path
|
||||
import plistlib
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
sys.path.insert(0, str(Path(__file__).resolve().parents[1]))
|
||||
from project_tools import project_environment
|
||||
from release import sign_app
|
||||
|
||||
from macos_updates import configure, publish
|
||||
|
||||
@@ -24,6 +28,7 @@ class UpdateHandler(SimpleHTTPRequestHandler):
|
||||
def prepare(source, root, tools, port):
|
||||
repository = Path(__file__).resolve().parents[2]
|
||||
root = root.resolve()
|
||||
environment = project_environment()
|
||||
public = root / 'public'
|
||||
keys = root / 'keys'
|
||||
if (root / 'installed').exists() or public.exists():
|
||||
@@ -43,8 +48,7 @@ def prepare(source, root, tools, port):
|
||||
bundle['CFBundleVersion'] = version
|
||||
path.write_bytes(plistlib.dumps(bundle))
|
||||
configure(app, feed, public_key, local=True)
|
||||
subprocess.run(['bash', str(repository / 'tool/macos/sign_macos_app.sh'), str(app)],
|
||||
env={**os.environ, 'CUTDEX_CODESIGN_IDENTITY': '-'}, check=True)
|
||||
sign_app(app, environment={**environment, 'CUTDEX_CODESIGN_IDENTITY': '-'})
|
||||
publish(root / 'candidate/cutdex.app', public, f'http://localhost:{port}',
|
||||
tools.resolve(), keys / 'private.key', local=True)
|
||||
print(f'Open: {root / "installed/cutdex.app"}', flush=True)
|
||||
|
||||
Reference in new issue
Block a user