{"id":16469260,"url":"https://github.com/cluelang/clue","last_synced_at":"2025-05-16T07:04:16.535Z","repository":{"id":36954600,"uuid":"420525135","full_name":"ClueLang/Clue","owner":"ClueLang","description":"C/Rust like programming language that compiles into Lua code","archived":false,"fork":false,"pushed_at":"2024-10-12T08:00:31.000Z","size":1466,"stargazers_count":348,"open_issues_count":18,"forks_count":14,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-04-13T22:39:35.089Z","etag":null,"topics":["cluelang","compiler","hacktoberfest","language","lua","programming-language","rust","transpiler"],"latest_commit_sha":null,"homepage":"https://crates.io/crates/clue","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ClueLang.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":"2021-10-23T21:17:39.000Z","updated_at":"2025-04-09T15:41:12.000Z","dependencies_parsed_at":"2023-01-17T08:01:54.334Z","dependency_job_id":"e119bf5e-4706-4593-a5e8-8b7dd2b27346","html_url":"https://github.com/ClueLang/Clue","commit_stats":{"total_commits":1099,"total_committers":10,"mean_commits":109.9,"dds":"0.18926296633303008","last_synced_commit":"78ce10c1d7a985b294ce7d08ef03565cc956e3c1"},"previous_names":[],"tags_count":39,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClueLang%2FClue","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClueLang%2FClue/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClueLang%2FClue/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClueLang%2FClue/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ClueLang","download_url":"https://codeload.github.com/ClueLang/Clue/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254485054,"owners_count":22078767,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["cluelang","compiler","hacktoberfest","language","lua","programming-language","rust","transpiler"],"created_at":"2024-10-11T12:06:31.639Z","updated_at":"2025-05-16T07:04:16.515Z","avatar_url":"https://github.com/ClueLang.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# The Clue programming language\n\n![image](https://user-images.githubusercontent.com/87673997/156028540-7a94db51-dd90-4bc6-9718-96e056d24cab.png)  \n[![Crates.io](https://img.shields.io/crates/v/clue?logo=rust\u0026style=for-the-badge)](https://crates.io/crates/clue)\n[![Crates.io](https://img.shields.io/crates/d/clue?logo=rust\u0026style=for-the-badge)](https://crates.io/crates/clue)\n[![GitHub](https://img.shields.io/github/v/release/ClueLang/Clue?logo=github\u0026color=181717\u0026display_name=release\u0026include_prereleases\u0026sort=semver\u0026style=for-the-badge)](https://github.com/ClueLang/Clue)\n[![AUR](https://img.shields.io/aur/version/clue?color=1793d1\u0026logo=arch-linux\u0026style=for-the-badge)](https://aur.archlinux.org/packages/clue/)\n\nClue is a programming language that compiles blazingly fast into Lua code with a syntax similar to languages like C or Rust.\n\nClue tries to be almost as simple as Lua (with only a slightly more advanced syntax) but adds many optional features that can make code look better or make some things (like metatables) easier to code.\n\nClue does not compile to a specific version of Lua: flags can be toggled to alter the output to allow most if not all versions or modifications of Lua to be compiled to with Clue.\n\n## General syntax differences\n- Code blocks are now inside `{}` instead of `then`/`do`/`repeat` and `end`/`until`\n- Comments are made with `// ...` or `/* ... */`\n\nIf you want a complete documentation of every change and addition in Clue check [the wiki](https://github.com/ClueLang/Clue/wiki).\n\n## Example code\n```rs\n@ifos linux {\n\t@define GREETING \"Hello, Linux user \"\n} @else_ifos macos {\n\t@define GREETING \"Hello, MacOS user \"\n} @else {\n\t@define GREETING \"Hello, Windows user \"\n}\n  \n@macro GREET(target) { $GREETING .. $target .. \"!\" }\n  \nprint($GREET!(\"Maiori\"))\n\nlocal fn add(x = 0, y = 0) {\n    return x + y\n}\n\nglobal n = 1\n\nwhile n \u003c 10 {\n    n += add($, $)\n    match n {\n        3 =\u003e {\n            continue\n        }\n        4 if x =\u003e {\n            break\n        }\n        default =\u003e {\n            print(n \u003c 3 ? n : -n)\n        }\n    }\n}\n```\nMore examples can be found in:\n- the [wiki](https://github.com/ClueLang/Clue/wiki)\n- the [Examples directory](https://github.com/ClueLang/Clue/tree/main/examples)\n- a [game made with LÖVE](https://github.com/Maiori44/ip-please)\n- Clue's [MessagePack library](https://github.com/Maiori44/msgpack-clue)\n- a [simple graph visualizer made with LÖVE](https://github.com/ClueLang/Clue-example)\n\n## How to install\n\n### Using Cargo\n1. Paste and run this command in the console: `cargo install clue`\n2. Type `clue` in the console to run the compiler, it will explain the rest\n\nClue supports extra features that can be toggled when installing:\n* `interpreter`: adds the `--execute` flag to let Clue run the generated output using [mlua](https://github.com/khvzak/mlua)\n* `rpmalloc`: uses [rpmalloc](https://github.com/EmbarkStudios/rpmalloc-rs) to improve performance, not available on all platforms\n\nBy default Clue enables both features.\n\n### Using Linux packages\nThese can be downloaded in the [latest release](https://github.com/ClueLang/Clue/releases/latest).\n* .deb\n```\nsudo dpkg -i clue_\u003cversion\u003e_\u003carch\u003e.deb\n```\n* .rpm\n```\nsudo rpm -i clue-\u003cversion\u003e.\u003carch\u003e.rpm\n```\n\n### Using the [AUR](https://aur.archlinux.org/clue)\n* With paru\n```sh\nparu -S clue\n```\n* With yay\n```\nyay -S clue\n```\n* With makepkg\n```sh\ngit clone https://aur.archlinux.org/clue.git\ncd clue\nmakepkg -si\n```\n\n### Manual installation\n1. Download the [latest release](https://github.com/ClueLang/Clue/releases/latest) and save it somewhere\n2. Open your system environment variables\n3. Add the path to the directory that contains `clue.exe` in the PATH variable\n4. Type `clue` in your cmd/PowerShell to run the compiler, it will explain the rest\n\n## More coming soon!\nThere are still features that I'm considering adding and others that will be added soon.\nThe most likely ones to be added in the future are:\n- type system (coming in 4.0)\n- better error messages (coming in 4.0)\n- proper language server support (coming in 4.0)\n\nFor any suggestion or bug you can make a github issue.\nIf you need help with the language itself, you can check out the [Discord server](https://discord.gg/EQsnWpqN3C).\n\nI hope Clue will be useful to you :)\n\n## Why is Clue named Clue?\n~~I have no *clue*.~~\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcluelang%2Fclue","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcluelang%2Fclue","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcluelang%2Fclue/lists"}