Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions .claude/CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ The following files in `.machine_readable/` contain structured project metadata:

| Language/Tool | Use Case | Notes |
|---------------|----------|-------|
| **ReScript** | Primary application code | Compiles to JS, type-safe |
| **** | Primary application code | Compiles to JS, type-safe |
| **Deno** | Runtime & package management | Replaces Node/npm/bun |
| **Rust** | Performance-critical, systems, WASM | Preferred for CLI tools |
| **Tauri 2.0+** | Mobile apps (iOS/Android) | Rust backend + web UI |
| **Dioxus** | Mobile apps (native UI) | Pure Rust, React-like |
| **Gleam** | Backend services | Runs on BEAM or compiles to JS |
| **Bash/POSIX Shell** | Scripts, automation | Keep minimal |
| **JavaScript** | Only where ReScript cannot | MCP protocol glue, Deno APIs |
| **JavaScript** | Only where cannot | MCP protocol glue, Deno APIs |
| **Python** | SaltStack only | No other Python permitted |
| **Nickel** | Configuration language | For complex configs |
| **Guile Scheme** | State/meta files | .machine_readable/6a2/STATE.a2ml, .machine_readable/6a2/META.a2ml, .machine_readable/6a2/ECOSYSTEM.a2ml |
Expand All @@ -38,13 +38,13 @@ The following files in `.machine_readable/` contain structured project metadata:

| Banned | Replacement |
|--------|-------------|
| TypeScript | ReScript |
| | |
| Node.js | Deno |
| npm | Deno |
| Bun | Deno |
| pnpm/yarn | Deno |
| Go | Rust |
| Python (general) | ReScript/Rust |
| Python (general) | /Rust |
| Java/Kotlin | Rust/Tauri/Dioxus |
| Swift | Tauri/Dioxus |
| React Native | Tauri/Dioxus |
Expand All @@ -54,14 +54,14 @@ The following files in `.machine_readable/` contain structured project metadata:

**No exceptions for Kotlin/Swift** - use Rust-first approach:

1. **Tauri 2.0+** - Web UI (ReScript) + Rust backend, MIT/Apache-2.0
1. **Tauri 2.0+** - Web UI () + Rust backend, MIT/Apache-2.0
2. **Dioxus** - Pure Rust native UI, MIT/Apache-2.0

Both are FOSS with independent governance (no Big Tech).

### Enforcement Rules

1. **No new TypeScript files** - Convert existing TS to ReScript
1. **No new files** - Convert existing TS to
2. **No package.json for runtime deps** - Use deno.json imports
3. **No node_modules in production** - Deno caches deps automatically
4. **No Go code** - Use Rust instead
Expand All @@ -82,15 +82,15 @@ Both are FOSS with independent governance (no Big Tech).
- SHA-pinned dependencies
- SPDX license headers on all files

### TypeScript Exemptions (Approved)
### Exemptions (Approved)

The hyperpolymath "no new TypeScript" policy has the following approved exemptions in this repo. These are *not* policy violations — they are documented carve-outs.
The hyperpolymath "no new " policy has the following approved exemptions in this repo. These are *not* policy violations — they are documented carve-outs.

| Path | Files | Rationale | Unblock condition |
|---|---|---|---|
| `src/wasm-bridge.ts` | 1 | Explicit FFI bridge between TS host and WASM core; thin glue, no application logic. | AffineScript first-class WASM-direct invocation surface. |
| `src/rescript-bridge.ts` | 1 | Explicit bridge between TS host and ReScript layer; thin glue. | Replace ReScript layer with AffineScript core (then bridge dissolves). |
| `src/-bridge.ts` | 1 | Explicit bridge between TS host and layer; thin glue. | Replace layer with AffineScript core (then bridge dissolves). |
| `src/storage.ts` | 1 | Deno-runtime storage interface (KV/Deno.openKv); ecosystem is Deno-native. | AffineScript Deno KV bindings. |
| `src/observability.ts` | 1 | Deno-runtime observability — OpenTelemetry exporters and Deno.metrics. | AffineScript OTel bindings (post Node-target #35). |

Adding to this list requires explicit user approval and an unblock condition. New TypeScript files outside this list are blocked by the RSR antipattern check.
Adding to this list requires explicit user approval and an unblock condition. New files outside this list are blocked by the RSR antipattern check.
7 changes: 0 additions & 7 deletions .github/FUNDING.yml

This file was deleted.

20 changes: 17 additions & 3 deletions .github/funding.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,18 @@
# Funding Configuration
# See: https://docs.github.com/en/repositories/managing-your-repositorys-custom-fields/displaying-a-sponsor-button-in-your-repository
# SPDX-License-Identifier: MPL-2.0 for code
# SPDX-License-Identifier: CC-BY-SA-4.0 for documentation
# SPDX-FileCopyrightText: 2026 Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>

github: metadatastician
# These are supported funding model platforms

buy_me_a_coffee: jonathan.jewell
community_bridge: jonathan-jewell
github: hyperpolymath
indieweb:
issuehunt: hyperpolymath
ko_fi: hyperpolymath
lfx_crowdfunding: hyperpolymath
liberapay: hyperpolymath
open_collective: jonathan-jewell
patreon: cc_studio
polar: hyperpolymath
thanks_dev: hyperpolymath
1 change: 0 additions & 1 deletion .github/workflows/dogfood-gate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -379,4 +379,3 @@ jobs:
*Generated by the [Dogfood Gate](https://github.com/hyperpolymath/rsr-template-repo) workflow.*
*Dogfooding is guinea pig fooding — we test our tools on ourselves.*
EOF

2 changes: 1 addition & 1 deletion .github/workflows/governance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ permissions:

jobs:
governance:
uses: hyperpolymath/standards/.github/workflows/governance-reusable.yml@7fdc2705df74b4e352d2a1cde3e87a5923fdf329
uses: hyperpolymath/standards/.github/workflows/governance-reusable.yml@7fdc2705df74b4e352d2a1cde3e87a5923fdf329
2 changes: 1 addition & 1 deletion .github/workflows/hypatia-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ permissions:

jobs:
scan:
uses: hyperpolymath/standards/.github/workflows/hypatia-scan-reusable.yml@7fdc2705df74b4e352d2a1cde3e87a5923fdf329
uses: hyperpolymath/standards/.github/workflows/hypatia-scan-reusable.yml@7fdc2705df74b4e352d2a1cde3e87a5923fdf329
58 changes: 0 additions & 58 deletions .github/workflows/rescript-deno-ci.yml

This file was deleted.

3 changes: 2 additions & 1 deletion .github/workflows/scorecard.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ on:
permissions:
actions: read
contents: read

security-events: write
id-token: write
jobs:
scorecard:
uses: hyperpolymath/standards/.github/workflows/scorecard-reusable.yml@7fdc2705df74b4e352d2a1cde3e87a5923fdf329
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/secret-scanner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ concurrency:
permissions:
actions: read
contents: read

jobs:
scan:
# The reusable's gitleaks job requests pull-requests: write (PR summary
Expand Down
73 changes: 36 additions & 37 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ variables:
NODE_VERSION: "20"

# Templates
.deno-base:
image: denoland/deno:${DENO_VERSION}
.-base:
image: denoland/:${DENO_VERSION}
before_script:
- deno --version
- --version

.rust-base:
image: rust:${RUST_VERSION}
Expand All @@ -26,12 +26,12 @@ variables:
- rustup target add wasm32-unknown-unknown

# Lint Stage
lint:deno:
extends: .deno-base
lint::
extends: .-base
stage: lint
script:
- deno lint
- deno fmt --check
- lint
- fmt --check
allow_failure: false

lint:rust:
Expand All @@ -44,16 +44,16 @@ lint:rust:
allow_failure: false

# Build Stage
build:rescript:
build::
image: node:${NODE_VERSION}
stage: build
before_script:
- npm install -g rescript
- npm install -g
script:
- rescript build
- build
artifacts:
paths:
- src-rescript/**/*.res.js
- src-/**/*.res.js
expire_in: 1 hour

build:wasm:
Expand All @@ -74,29 +74,29 @@ build:wasm:

# Test Stage
test:unit:
extends: .deno-base
extends: .-base
stage: test
dependencies:
- build:rescript
- build:
- build:wasm
script:
- deno test --allow-read --allow-write tests/
- test --allow-read --allow-write tests/
coverage: '/\d+\.\d+% coverage/'

test:integration:
extends: .deno-base
extends: .-base
stage: test
dependencies:
- build:rescript
- build:
- build:wasm
script:
- deno run --allow-read --allow-write src/cli.ts stats
- deno run --allow-read --allow-write src/cli.ts help
- run --allow-read --allow-write src/cli.ts stats
- run --allow-read --allow-write src/cli.ts help
allow_failure: false

# Verify Stage (RSR Compliance)
verify:rsr-compliance:
extends: .deno-base
extends: .-base
stage: verify
script:
- |
Expand All @@ -121,22 +121,21 @@ verify:rsr-compliance:
# Check build system
echo "Checking build system..."
test -f justfile && echo "✅ justfile" || (echo "❌ justfile missing" && exit 1)
test -f deno.json && echo "✅ deno.json" || (echo "❌ deno.json missing" && exit 1)
test -f .json && echo "✅ .json" || (echo "❌ .json missing" && exit 1)
test -f flake.nix && echo "✅ flake.nix" || (echo "❌ flake.nix missing" && exit 1)

# Check type safety
echo "Checking type safety..."
deno check src/**/*.ts && echo "✅ TypeScript type-safe" || (echo "❌ Type errors found" && exit 1)
test -f wasm/Cargo.toml && echo "✅ Rust WASM present" || (echo "❌ WASM missing" && exit 1)
test -f src-rescript/UbiCity.res && echo "✅ ReScript present" || (echo "❌ ReScript missing" && exit 1)
test -f src-/UbiCity.res && echo "✅ present" || (echo "❌ missing" && exit 1)

echo ""
echo "✅ RSR Compliance: PASSED"
echo "Tier: Bronze (minimum requirements met)"
allow_failure: false

verify:offline-first:
extends: .deno-base
extends: .-base
stage: verify
script:
- |
Expand All @@ -153,17 +152,17 @@ verify:offline-first:
echo "✅ Offline-First: VERIFIED"

verify:security:
extends: .deno-base
extends: .-base
stage: verify
script:
- |
echo "🔒 Security Verification"
echo "======================="

# Check Deno permissions
echo "Checking Deno permission model..."
grep -q "allow-read" deno.json && echo "✅ Explicit read permissions" || echo "⚠️ No read permissions specified"
grep -q "allow-write" deno.json && echo "✅ Explicit write permissions" || echo "⚠️ No write permissions specified"
# Check permissions
echo "Checking permission model..."
grep -q "allow-read" .json && echo "✅ Explicit read permissions" || echo "⚠️ No read permissions specified"
grep -q "allow-write" .json && echo "✅ Explicit write permissions" || echo "⚠️ No write permissions specified"

# Verify no unsafe Rust
echo "Checking Rust safety..."
Expand All @@ -179,12 +178,12 @@ verify:security:

# Deploy Stage (for releases)
deploy:pages:
extends: .deno-base
extends: .-base
stage: deploy
only:
- tags
script:
- deno run --allow-read --allow-write src/visualize.ts
- run --allow-read --allow-write src/visualize.ts
- mkdir -p public
- cp ubicity-data/ubicity-map.html public/index.html
artifacts:
Expand All @@ -196,16 +195,16 @@ deploy:pages:

# Release compilation (for tags)
compile:release:
extends: .deno-base
extends: .-base
stage: deploy
only:
- tags
dependencies:
- build:rescript
- build:
- build:wasm
script:
- deno compile --allow-read --allow-write --output ./bin/ubicity src/cli.ts
- deno compile --allow-read --allow-write --output ./bin/ubicity-capture src/capture.ts
- compile --allow-read --allow-write --output ./bin/ubicity src/cli.ts
- compile --allow-read --allow-write --output ./bin/ubicity-capture src/capture.ts
- ls -lh ./bin/
artifacts:
paths:
Expand All @@ -214,15 +213,15 @@ compile:release:

# Nightly builds
nightly:
extends: .deno-base
extends: .-base
stage: build
only:
- schedules
dependencies:
- build:rescript
- build:
- build:wasm
script:
- deno compile --allow-read --allow-write --output ./bin/ubicity-nightly src/cli.ts
- compile --allow-read --allow-write --output ./bin/ubicity-nightly src/cli.ts
artifacts:
paths:
- bin/
Expand Down
Loading
Loading