Skip to content

Commit b8af8b8

Browse files
committed
Update language policy: Add Gleam, Tauri 2.0+, Dioxus
1 parent d2817bd commit b8af8b8

1 file changed

Lines changed: 58 additions & 12 deletions

File tree

.claude/CLAUDE.md

Lines changed: 58 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,70 @@
1+
# CLAUDE.md - AI Assistant Instructions
12

2-
## Language & Security Policy (RSR)
3+
## Language Policy (Hyperpolymath Standard)
34

4-
### Allowed Languages (Primary → Fallback)
5-
- **Systems/ML**: Rust
6-
- **Web/Scripts**: ReScript → TypeScript (legacy only)
7-
- **TUI**: Ada/SPARK
8-
- **WordPress**: PHP (with security CI)
9-
- **LSP**: Java (exception for IDE compatibility)
5+
### ALLOWED Languages & Tools
106

11-
### Banned Languages
12-
- Python (except SaltStack)
13-
- Ruby (use Rust/Ada/Crystal)
14-
- Perl (use Rust)
15-
- New Java/Kotlin (except LSP)
7+
| Language/Tool | Use Case | Notes |
8+
|---------------|----------|-------|
9+
| **ReScript** | Primary application code | Compiles to JS, type-safe |
10+
| **Deno** | Runtime & package management | Replaces Node/npm/bun |
11+
| **Rust** | Performance-critical, systems, WASM | Preferred for CLI tools |
12+
| **Tauri 2.0+** | Mobile apps (iOS/Android) | Rust backend + web UI |
13+
| **Dioxus** | Mobile apps (native UI) | Pure Rust, React-like |
14+
| **Gleam** | Backend services | Runs on BEAM or compiles to JS |
15+
| **Bash/POSIX Shell** | Scripts, automation | Keep minimal |
16+
| **JavaScript** | Only where ReScript cannot | MCP protocol glue, Deno APIs |
17+
| **Python** | SaltStack only | No other Python permitted |
18+
| **Nickel** | Configuration language | For complex configs |
19+
| **Guile Scheme** | State/meta files | STATE.scm, META.scm, ECOSYSTEM.scm |
20+
| **Julia** | Batch scripts, data processing | Per RSR |
21+
| **OCaml** | AffineScript compiler | Language-specific |
22+
| **Ada** | Safety-critical systems | Where required |
23+
24+
### BANNED - Do Not Use
25+
26+
| Banned | Replacement |
27+
|--------|-------------|
28+
| TypeScript | ReScript |
29+
| Node.js | Deno |
30+
| npm | Deno |
31+
| Bun | Deno |
32+
| pnpm/yarn | Deno |
33+
| Go | Rust |
34+
| Python (general) | ReScript/Rust |
35+
| Java/Kotlin | Rust/Tauri/Dioxus |
36+
| Swift | Tauri/Dioxus |
37+
| React Native | Tauri/Dioxus |
38+
| Flutter/Dart | Tauri/Dioxus |
39+
40+
### Mobile Development
41+
42+
**No exceptions for Kotlin/Swift** - use Rust-first approach:
43+
44+
1. **Tauri 2.0+** - Web UI (ReScript) + Rust backend, MIT/Apache-2.0
45+
2. **Dioxus** - Pure Rust native UI, MIT/Apache-2.0
46+
47+
Both are FOSS with independent governance (no Big Tech).
48+
49+
### Enforcement Rules
50+
51+
1. **No new TypeScript files** - Convert existing TS to ReScript
52+
2. **No package.json for runtime deps** - Use deno.json imports
53+
3. **No node_modules in production** - Deno caches deps automatically
54+
4. **No Go code** - Use Rust instead
55+
5. **Python only for SaltStack** - All other Python must be rewritten
56+
6. **No Kotlin/Swift for mobile** - Use Tauri 2.0+ or Dioxus
1657

1758
### Package Management
59+
1860
- **Primary**: Guix (guix.scm)
1961
- **Fallback**: Nix (flake.nix)
62+
- **JS deps**: Deno (deno.json imports)
2063

2164
### Security Requirements
65+
2266
- No MD5/SHA1 for security (use SHA256+)
2367
- HTTPS only (no HTTP URLs)
2468
- No hardcoded secrets
69+
- SHA-pinned dependencies
70+
- SPDX license headers on all files

0 commit comments

Comments
 (0)