{"id":21107312,"url":"https://github.com/ninjascl/wren-baron","last_synced_at":"2026-04-24T18:10:57.454Z","repository":{"id":240435251,"uuid":"802593422","full_name":"NinjasCL/wren-baron","owner":"NinjasCL","description":"🦾 スーパーウェブフレームワーク Wren Baron ","archived":false,"fork":false,"pushed_at":"2024-05-18T20:51:21.000Z","size":2008,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-12-31T06:43:35.134Z","etag":null,"topics":["framework","web","wren"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/NinjasCL.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-18T18:21:38.000Z","updated_at":"2024-05-18T21:00:46.000Z","dependencies_parsed_at":"2024-05-18T21:27:33.912Z","dependency_job_id":"44d31026-a744-4a82-a602-157222ed1984","html_url":"https://github.com/NinjasCL/wren-baron","commit_stats":null,"previous_names":["ninjascl/wren-baron"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/NinjasCL/wren-baron","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NinjasCL%2Fwren-baron","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NinjasCL%2Fwren-baron/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NinjasCL%2Fwren-baron/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NinjasCL%2Fwren-baron/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/NinjasCL","download_url":"https://codeload.github.com/NinjasCL/wren-baron/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NinjasCL%2Fwren-baron/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32234906,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-24T13:21:15.438Z","status":"ssl_error","status_checked_at":"2026-04-24T13:21:15.005Z","response_time":64,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["framework","web","wren"],"created_at":"2024-11-20T00:38:36.038Z","updated_at":"2026-04-24T18:10:52.437Z","avatar_url":"https://github.com/NinjasCL.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Super Web Framework Wren Baron\n\n![Red Baron](redbaron.jpg)\n\nスーパーウェブフレームワーク Wren Baron\n\nThis is a small proof of concept to execute [Wren Scripts](https://wren.io)\ninside a web environment.\n\nThis is made using `PHP` as a bridge in a `cgi-bin` executable.\n\nFirst create a new directory and put `index.php` in with the the code.\n\nWe are using [Wren Console](https://github.com/joshgoebel/wren-console) for additional modules such as _JSON_ support.\n\n**index.php**\n\nThe _PHP_ script simply encodes a _JSON_ object with environment variables such as GET and POST params and then pass them to the `wren` script as an argument.\n\nAlso the final `2\u003e\u00261` enables debugging the _Wren_ scripts so they output errors as well.\n\n```php\n\u003c?php\n\nsession_start();\n\n$env = escapeshellarg(json_encode([\n    \"get\" =\u003e $_GET,\n    \"post\" =\u003e $_POST,\n    \"server\" =\u003e $_SERVER,\n    \"session\" =\u003e session_id(),\n    \"pwd\" =\u003e getcwd()\n    ]));\n\n$wren = \"../wrenc index.wren $env 2\u003e\u00261\";\n\npassthru($wren);\n?\u003e\n```\n\n**index.wren**\n\nThis file will get the enviroment as a JSON string and parse it\nto obtain the `GET` params.\n\n```wren\nimport \"runtime\" for Runtime\nimport \"os\" for Process\nimport \"json\" for JSON\n\nvar args = Process.allArguments\nvar env = JSON.parse(args[2])\nvar name = env[\"get\"][\"name\"]\n\nSystem.print(\"\u003ch1\u003eHello From Wren %(Runtime.WREN_VERSION)\u003c/h1\u003e\")\nSystem.print(\"\u003ch2\u003eThis is rendered from \u003cstrong\u003eWren\u003c/strong\u003e\u003c/h2\u003e\")\nSystem.print(\"\u003cp\u003eHello \u003cstrong\u003e%(name)\u003c/strong\u003e\u003c/p\u003e\")\n```\n\nThe URL can now use the `name` param in a `GET` request.\n\n```text\ncgi-bin/hello/?name=Camilo\n```\n\n![Screenshot](screenshot.png)\n\n## Wren Console Compilation\n\nThe version provided here was dynamically linked with `libc 2.17` since that was the available in the shared hosting.\n\nIf we want to check the libc version, you can use\n\n```bash\n$ ldd --version\nldd (GNU libc) 2.17\nCopyright (C) 2012 Free Software Foundation, Inc.\n```\n\nIf we try to use `wrenc` in an enviroment that does not have the correct libc we will see an error similar to this:\n\n```bash\n./wrenc: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by ./wrenc)\n```\n\nThe provided `make` command builds the `wrenc` binary for this linux environment\n\n```bash\n$ make install\n```\n\nWe use an old Ubuntu for the Dockerfile that already has libc 2.17.\n\n```dockerfile\nFROM ubuntu:13.04\n\nRUN sed -i 's/archive.ubuntu/old-releases.ubuntu/g' /etc/apt/sources.list\nRUN apt-get update\nRUN apt-get install build-essential -y\n\nCOPY . /wrenc\n\nWORKDIR /wrenc/projects/make/\nRUN make config=release_64bit\n\nRUN /wrenc/bin/wrenc -v\n\n# So we can execute commands\n# and do not exits\nCMD tail -f /dev/null\n```\n\n## Credits\n\n\u003cp\u003e\n  Made with \u003ci class=\"fa fa-heart\"\u003e\u0026#9829;\u003c/i\u003e by\n  \u003ca href=\"https://ninjas.cl\"\u003e\n    Ninjas.cl\n  \u003c/a\u003e.\n\u003c/p\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fninjascl%2Fwren-baron","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fninjascl%2Fwren-baron","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fninjascl%2Fwren-baron/lists"}