Files
herolib/examples/hero/heromodels/heroserver_example.vsh
Mahmoud-Emad e59ff8b63f feat: enhance server documentation and configuration
- Add HTML homepage and JSON handler info endpoints
- Implement markdown documentation generation for APIs
- Introduce auth_enabled flag for server configuration
- Improve documentation generation with dynamic base URLs
- Refactor server initialization and handler registration
2025-09-18 12:10:49 +03:00

20 lines
503 B
GLSL
Executable File

#!/usr/bin/env -S v -n -w -gc none -cc tcc -d use_openssl -enable-globals -no-skip-unused run
import freeflowuniverse.herolib.hero.heromodels.rpc
import freeflowuniverse.herolib.hero.heromodels
import time
fn main() {
// Start the server in a background thread with authentication disabled for testing
spawn fn () {
rpc.start(port: 8080, auth_enabled: false) or {
panic('Failed to start HeroModels server: ${err}')
}
}()
// Keep the main thread alive
for {
time.sleep(time.second)
}
}