Welcome to RaggieScript v1.3 (.rssc)
RaggieScript (v1.3.0, .rssc) is RaggieSoft's open-source (MIT License), gradually typed, capability-sandboxed curly-brace scripting language, declarative Win32 Wizard UI engine, StoreScript trainer DSL, Story Crossroads branching narrative engine, and multi-target SDK powering all ten RaggieSoft Studio developer tools, consumer desktop apps, and standalone zero-dependency Windows x64 and ARM64 micro-applications.
Why RaggieScript Exists
Traditional setup scripting systems force an unpleasant choice between cryptic relational database custom actions, fragile batch/PowerShell wrappers that break on locked corporate machines, or proprietary Domain-Specific Languages lacking modern types, closures, formatters, and Language Servers.
RaggieScript solves those pain points from first principles:
- Familiar Curly-Brace Syntax with Gradual Static Types: Write clean
let/constcode with automatic type inference, or annotatestruct,enum,fn,path, andversion(v"10.0.22000") types checked in under1 ms(RSW710–RSW715). - Compile-Time Wizard Phase Isolation (
RSW701) & Commit-Time Deferred UAC: The compiler statically proveswizard { ... }cannot mutate files, Registry keys, or services—allowinguac: Uac.Deferredsetups to run their entire interactive wizard un-elevated (asInvoker) and request UAC elevation only at commit time when the user clicks Install. - Compile-Time Capability Sandboxing (
RSW702): A script declaringuse training;oruse a11y;is mathematically prevented at compile time from callingfs.*,reg.*,proc.*,msi.*,ffi.*, ornet.*. - Automatic LIFO Transactional Rollback (
.rsw-rollback.jnl): Every mutating call insideinstall { ... }backs up overwritten files to.rswbakand journals previous Registry/service/shortcut states before mutating, rewinding automatically if an error or user cancellation occurs. - Three Verified Execution Targets from One Grammar:
- Native Static
/MTWin32 C++20 Stack VM (RSWBC2) (x64&ARM64, zero external DLLs) - Managed
.NETSDK (RaggieScript.Core) for Accessibility, Localization, Document, and Launcher Studio - CSP-Safe
ES2022JavaScript Module Transpiler (transpile-es2022) for SCORM 1.2 & 2004 courses in Training Studio
60-Second Quick Start
Create hello-setup.rssc and verify, compile, or pack it into a standalone Windows .exe:
use installer;
package "Sainte-Claire Patch Librarian" {
id: "RaggieSoft.SainteClaireLibrarian";
version: v"1.4.0";
publisher: "RaggieSoft";
scope: Scope.Machine;
uac: Uac.Deferred;
style: WizardStyle.FluentMica;
}
param installDir: path = sys.programFiles / "RaggieSoft" / "Patch Librarian";
param acceptEula: bool = false;
wizard {
step Welcome {
ui.welcome(
title: "Welcome to ${product.name}",
subtitle: "Detected Silicon: ${sys.arch()} (Windows Build ${sys.osBuild()})",
body: "This setup installs ${product.name} v${product.version}."
);
}
step License {
ui.license(
text: "MIT License — Copyright (c) 2026 RaggieSoft.",
acceptText: "I &accept the license terms",
bind: ref acceptEula
);
}
step Destination {
ui.folderPicker(label: "&Destination folder:", bind: ref installDir, minFreeMB: 50);
}
step Ready {
ui.readySummary(heading: "Ready to Install ${product.name}", showUacShield: !sys.isAdmin());
}
}
install {
ui.progress(30, "Creating installation directory...");
fs.mkdir(installDir);
fs.writeJson(installDir / "install-receipt.json", {
product: product.name,
version: product.version,
arch: sys.arch()
});
reg.writeString(Hive.HKLM, r"Software\RaggieSoft\PatchLibrarian", "InstallDir", str(installDir));
ui.progress(100, "Installation complete.");
}
Run the standalone CLI (raggiescript.exe):
# 1. Type-check RSW701 Phase Isolation, RSW702 Sandbox & RSW710-RSW715 Types in <1 ms
raggiescript.exe check hello-setup.rssc
# 2. Format source while preserving 100% of // teaching comments
raggiescript.exe fmt --write hello-setup.rssc
# 3. Pack into a single zero-dependency native Windows .exe
raggiescript.exe pack-exe hello-setup.rssc PatchLibrarianSetup.exe
RaggieSoft Reference Portal — Dogfooded with Help Studio
raggiescript.raggiesoft.dev is an official RaggieSoft Reference Portal—our three-column, zero-database technical documentation and API specification format authored as a plain-text .rshp manifest + Markdown topic tree and compiled directly by RaggieSoft Help Studio (rshbuild.exe v0.8.0). A single build emits this searchable Reference Portal (with live TOC filtering, Ctrl+K symbol search, and "In this article" navigation), our offline Windows F1 viewer (RaggieScriptHelp.exe), module.rshm.json, F1 Context-ID SDK headers, llms-full.txt, and an HTML5 VPAT 2.5 report from one source of truth.
Standard Library Map (32 Namespaces)
| Namespace | Capability Profile | Primary Role | Reference |
|---|---|---|---|
| Global Built-Ins & Constants | Always Available | str(), int(), path(), ver(), len(), assert(), def(), Scope, Uac, Hive, RegView, CertStore | View Globals |
Validation.* & compile.* | Always / Build-Time | Field validation closures (Validation.ok/error) and bytecode-embedded JSON/text (compile.json) | View Helpers |
payload.* & feature.* | use installer; | Feature selection states (isSelected, selectPreset) and staged payload paths | View Features |
sys.* | Always (Read) / installer (Reboot) | True ARM64/x64 silicon (IsWow64Process2), un-shimmed RtlGetVersion, UAC, DPI, known folders | View sys.* |
str.*, regex.*, array.*, map.*, time.*, math.*, json.*, ini.*, xml.* | Always (ini/xml writes require installer) | Strings, regex, array (reduce/sort/unique), map.*, time.* (ISO8601/SCORM), math.*, JSON, .ini, & XML | View Data/Math/Time |
fs.* & reg.* | use installer; / showcase | Rollback-journaled filesystem, RSWPAK1 extraction, Authenticode check, & stateless 64/32-bit Registry | View fs & reg |
archive.*, crypto.*, net.*, log.* | crypto/log Always; archive/net Host | 23-method archive.* (.7z, .zip, .rswpak, .iso, .wim), bcrypt.dll SHA-256, WinHTTP + net.isPortFree | View Archive/Net |
proc.*, ffi.*, rm.*, com.*, font.*, sign.*, cert.*, mutex.*, activesetup.*, shortcut.*, shell.*, env.*, arp.*, svc.*, task.*, firewall.*, acl.* | use installer; | Reg-Free COM .manifests, zero-reboot fonts, X.509/Authenticode inspection, mutexes, Active Setup, Services, & ACLs | View System & COM |
msi.*, sql.* & prereq.* | use installer; | Direct 64-bit MSI relational SQL DDL/DML, RsscMsiCa.dll, Zero-DLL sql.* (winsqlite3.dll & odbc32.dll), .NET 8–11 & VcRedist2026 presets | View msi.* & sql.* |
ui.*, wizard.*, showcase.* | use ui; / installer / showcase | 14 declarative in-window Win32 controls, TaskDialogIndirect, 11 themes, & 12 Showcase canvas/UIA methods | View ui.* |
training.*, a11y.*, localization.*, document.*, launcher.*, help.* | Sandboxed Studio Profiles | SCORM 1.2/2004 state, Guided Fix diffs & WebVTT cues, locked token/RTL checks, PDF/UA-1 tables, & F1 routing | View Studio APIs |
storescript.* & crossroads.* | Sandboxed Consumer Profiles | StoreScript binary/JSON save-file trainer DSL (StoreTrainer) & Story Crossroads interactive branching novels | View StoreScript & Crossroads |