{"id":13395065,"url":"https://github.com/teal-language/tl","last_synced_at":"2025-05-14T03:10:19.750Z","repository":{"id":37540372,"uuid":"168815289","full_name":"teal-language/tl","owner":"teal-language","description":"The compiler for Teal, a typed dialect of Lua","archived":false,"fork":false,"pushed_at":"2025-05-05T13:35:49.000Z","size":4172,"stargazers_count":2372,"open_issues_count":94,"forks_count":124,"subscribers_count":46,"default_branch":"master","last_synced_at":"2025-05-05T14:48:17.520Z","etag":null,"topics":["compiler","lua","teal","type-checking"],"latest_commit_sha":null,"homepage":"https://teal-language.org","language":"Lua","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/teal-language.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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,"zenodo":null}},"created_at":"2019-02-02T09:23:42.000Z","updated_at":"2025-05-05T13:35:54.000Z","dependencies_parsed_at":"2024-10-26T00:37:45.751Z","dependency_job_id":"4d264dae-1377-4c6e-8dbd-933647bb1110","html_url":"https://github.com/teal-language/tl","commit_stats":{"total_commits":1453,"total_committers":44,"mean_commits":33.02272727272727,"dds":0.1582931865106676,"last_synced_commit":"0a6294ede62f573001be6c50c826213185f97810"},"previous_names":[],"tags_count":36,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/teal-language%2Ftl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/teal-language%2Ftl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/teal-language%2Ftl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/teal-language%2Ftl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/teal-language","download_url":"https://codeload.github.com/teal-language/tl/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254059511,"owners_count":22007769,"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":["compiler","lua","teal","type-checking"],"created_at":"2024-07-30T17:01:40.856Z","updated_at":"2025-05-14T03:10:14.735Z","avatar_url":"https://github.com/teal-language.png","language":"Lua","readme":"\nTeal\n====\n[![Build Status](https://github.com/teal-language/tl/actions/workflows/ci.yml/badge.svg)](https://github.com/teal-language/tl/actions/workflows/ci.yml)\n[![Join the chat at https://gitter.im/teal-language/community](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/teal-language/community?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge\u0026utm_content=badge)\n\nThis is the repository of **tl**, the compiler for Teal, a typed dialect of Lua.\n\nThe core compiler has no dependencies and is implemented as a single `tl.lua`\nfile which you can load into your projects. Running `tl.loader()` will add\nTeal support to your package loader, meaning that `require()` will be able to\nrun `.tl` files.\n\n## Introduction\n\nHere are videos of talks given at FOSDEM 2019, 2020 and 2021 which discuss the\nhistory of Lua and types, outline the motivations behind Teal and talk about\nthe project's progress:\n\n* [Minimalism versus types (2019)](https://www.youtube.com/watch?v=OPyBQRndLUk)\n* [Minimalistic typed Lua is here (2020)](https://www.youtube.com/watch?v=HfnjUCRzRKU)\n* [What's next for Teal (2021)](https://www.youtube.com/watch?v=OqXbnaDR8QY)\n\nAnd here's an update from early 2024, describing the process that eventually\nresulted in Teal Spring '24, later in the year:\n\n* [Five years of Teal: minimalism versus growth in language design (2024)](https://www.youtube.com/watch?v=68F5Qs91izQ)\n\nCheck also the [tutorial](docs/tutorial.md) to get started with an overview of\nthe language.\n\n## Installing\n\n### Via LuaRocks\n\nInstall Lua and LuaRocks, then run:\n\n```\nluarocks install tl\n```\n\nThis should put a `tl` command in your `$PATH` (run `eval $(luarocks path)` if\nthe LuaRocks-installed binaries are not in your `$PATH`).\n\nTeal works with Lua 5.1-5.4, including LuaJIT.\n\n### Binaries\n\nAlternatively, you can find pre-compiled binaries for Linux x86_64 and Windows\nx86_64 at the [releases](https://github.com/teal-language/tl/releases) page.\nThe packages contain a stand-alone executable that can run Teal programs\n(without the need of a separate Lua installation) and also compile them to Lua.\n\n### Try it from your browser\n\nYou can give Teal a try directly from your browser with the [Teal\nPlayground](https://teal-playground.netlify.app/)! It compiles Teal into Lua using\n[Fengari](https://github.com/fengari-lua/fengari), a Lua VM implemented in\nJavaScript, so everything runs on the client.\n\n## Running\n\n### Using the compiler directly\n\nOnce `tl` is in your path, there are a few subcommands:\n\n* `tl run script.tl` will run a Teal script.\n* `tl check module.tl` will type check a Teal module, report any errors and\n  quit.\n* `tl gen module.tl` will check for syntax errors and\n  generate a `module.lua` file in plain Lua with all type annotations\n  stripped.\n* `tl warnings` will list all warnings the compiler can generate.\n\n`tl` also supports some [compiler options](docs/compiler_options.md).\nThese can either be specified on the command line or inside a tlconfig.lua file at the root of your project.\n\n### Building projects with Cyan\n\nTo build whole projects, you probably won't want to run `tl` on each\nfile individually. We recommend using [Cyan](https://github.com/teal-language/cyan),\nthe build tool designed for Teal.\n\n## Loading Teal code from Lua\n\nYou can either pre-compile your `.tl` files into `.lua`, or you can add\nthe `tl.lua` module into your project and activate the Teal package loader:\n\n```lua\nlocal tl = require(\"tl\")\ntl.loader()\n```\n\nOnce the package loader is activated, your `require()` calls can load and\ncompile `.tl` files on-the-fly.\n\n## Documentation\n\nYou can learn more about programming and using Teal in the [docs/](docs/)\nfolder. The [tutorial](docs/tutorial.md) is a great place to start!\n\n## Type definitions\n\n`tl` supports [declaration files](docs/declaration_files.md), which can be used to annotate the types\nof third-party Lua libraries.\n\nWe have a collaborative repository for declaration files at\nhttps://github.com/teal-language/teal-types — check it out and make your contribution!\n\n## Text editor support\n\nTeal language support is currently available for [Vim](https://github.com/teal-language/vim-teal), [Visual Studio Code](https://github.com/teal-language/vscode-teal), [lite](https://github.com/rxi/lite-plugins/blob/master/plugins/language_teal.lua) with [linter](https://github.com/drmargarido/linters/blob/master/linter_teal.lua) support and [Helix](https://docs.helix-editor.com/lang-support.html#:~:text=teal\u0026text=teal-language-server) with LSP support.\n\n## Community\n\n* Join the chat on [Gitter](https://gitter.im/teal-language/community)!\n  * You can also join via Matrix at [#teal-language_community:gitter.im](https://matrix.to/#/#teal-language_community:gitter.im)\n\nTeal is a project started by [Hisham Muhammad](https://hisham.hm),\ndeveloped by a [growing number of contributors](https://github.com/teal-language/tl/graphs/contributors)\nand is written using Teal itself!\n\n## License\n\nLicense is MIT, the same as Lua.\n","funding_links":[],"categories":["Lua","Uncategorized","Compiler and tools"],"sub_categories":["Uncategorized"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fteal-language%2Ftl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fteal-language%2Ftl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fteal-language%2Ftl/lists"}