okami.mom/strata
git clone https://git.nkp.pet/okami.mom/strata
64a91dcdc
main
1name : Portable monitor client 2 3on : 4push : 5paths : 6- .github/workflows/terminal-portable-monitor.yml 7- packaging/monitor_bundle.py 8- strata.py 9- strata_cli/** 10- strata_control/** 11- tools/minimal_cli_smoke.py 12- tools/portable_monitor_smoke.py 13- tools/portable_monitor_pty_smoke.py 14- requirements-monitor.txt 15- LICENSE 16pull_request : 17paths : 18- .github/workflows/terminal-portable-monitor.yml 19- packaging/monitor_bundle.py 20- strata.py 21- strata_cli/** 22- strata_control/** 23- tools/minimal_cli_smoke.py 24- tools/portable_monitor_smoke.py 25- tools/portable_monitor_pty_smoke.py 26- requirements-monitor.txt 27- LICENSE 28workflow_dispatch : 29 30permissions : 31contents : read 32 33jobs : 34client : 35name : ${{ matrix.os }} / Python ${{ matrix.python }} 36runs-on : ${{ matrix.os }} 37strategy : 38fail-fast : false 39matrix : 40os : [ ubuntu-latest , windows-latest ] 41python : [ '3.10' , '3.11' ] 42steps : 43- uses : actions/checkout@v7 44with : 45persist-credentials : false 46- uses : actions/setup-python@v7 47with : 48python-version : ${{ matrix.python }} 49- name : Check source CLI without optional packages 50shell : bash 51run : | 52python - <<'PY' 53import os 54import subprocess 55import sys 56from pathlib import Path 57 58report = Path(os.environ['RUNNER_TEMP']) / 'minimal-cli-smoke.json' 59subprocess.run([sys.executable, 'tools/minimal_cli_smoke.py', 60'--report', str(report)], check=True) 61print(report.read_text()) 62PY 63- name : Build and smoke test without site packages 64shell : bash 65run : | 66python - <<'PY' 67import os 68import subprocess 69import sys 70from pathlib import Path 71 72bundle = Path(os.environ['RUNNER_TEMP']) / 'strata-monitor.pyz' 73report = bundle.with_name('monitor-stdlib-smoke.json') 74subprocess.run([sys.executable, 'packaging/monitor_bundle.py', 75'build', str(bundle)], check=True) 76subprocess.run([sys.executable, 'tools/portable_monitor_smoke.py', 77'--bundle', str(bundle), '--report', str(report)], check=True) 78print(report.read_text()) 79PY 80- name : Install optional Textual dependency 81if : matrix.python == '3.11' 82run : python -m pip install -r requirements-monitor.txt 83- name : Smoke test packaged interactive Overview 84if : matrix.python == '3.11' 85shell : bash 86run : | 87python - <<'PY' 88import os 89import subprocess 90import sys 91from pathlib import Path 92 93bundle = Path(os.environ['RUNNER_TEMP']) / 'strata-monitor.pyz' 94report = bundle.with_name('monitor-interactive-smoke.json') 95subprocess.run([sys.executable, 'tools/portable_monitor_smoke.py', 96'--bundle', str(bundle), '--interactive', 97'--report', str(report)], check=True) 98print(report.read_text()) 99PY 100- name : Check POSIX terminal restoration 101if : matrix.os == 'ubuntu-latest' && matrix.python == '3.11' 102shell : bash 103run : | 104 python - <<'PY' 105 import os 106 import subprocess 107 import sys 108 from pathlib import Path 109 110 bundle = Path(os.environ['RUNNER_TEMP']) / 'strata-monitor.pyz' 111 report = bundle.with_name('monitor-pty-smoke.json') 112 subprocess.run([sys.executable, 'tools/portable_monitor_pty_smoke.py', 113 '--bundle', str(bundle), '--report', str(report)], check=True) 114 print(report.read_text()) 115 PY