code wiki / (root) / nx_pagepub.nx

nx_pagepub.nx

buildroot/runtime/nx_pagepub.nx

4018 B88 linesdepth 3pulls 3 transitivereach 0 importersview sourcekind tool
docsdependenciesstructsconstsfunctions

about

nx_pagepub.nx -- ONE sovereign command to publish a static site page over the mgmt API (2026-07-09; retires the flaky ssh-cat push for pages). Chain: /api/upload (chunked, sha256 fail-closed at stage time -- a truncated transfer can NEVER go live) -> /api/promote_content (atomic .prev-backed swap). Both over sovereign TLS-1.3 with a minted X-Nishi-Session. Targets are the fail-closed md_content_pfx namespace (sites/nishifamily/ {synth,swgpu,factory,world,gsplat}/...). nx_pagepub <target> <localfile> [tokenfile] <target> e.g. sites/nishifamily/world/index.html <localfile> e.g. knowledge/world.html <tokenfile> default mgtok.txt (mint: nx_mgmt_session_mint on the NAS, 24h)

dependencies 1 imports · 0 importers

nx_tool_run.nx nx_pagepub.nx

imports: nx_tool_run.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main pp_puts pp_slen

structs

none

consts

11const K_MAGIC_1048576: i64 = 1048576

functions

13func pp_slen(s: *u8) -> i64 { var i: i64 = 0; while s[i] != (0 as u8) { i = i + 1 } return i }
called by 2: pp_putspp_contains
14func pp_puts(s: *u8) -> i64 { sys_write(1, s, pp_slen(s)); return 0 }
called by 1: main calls 1: pp_slen
16func pp_contains(buf: *u8, n: i64, needle: *u8) -> i64
calls 1: pp_slen
29func pp_run(path: *u8, av: *i64, out: *u8, cap: i64, olen: *i64) -> i64
calls 1: tr_run_capture
34func main(argc: i64, argv: *i64) -> i64
calls 1: pp_puts