Compare commits
24 Commits
0fbbb30e5b
...
8106f4d2df
| Author | SHA1 | Date | |
|---|---|---|---|
| 8106f4d2df | |||
| 86113d9573 | |||
| 224939feaf | |||
| de801eda78 | |||
| f2301f9317 | |||
| eb76ca81db | |||
| 2b72e7bf5a | |||
| 15e11f7450 | |||
| 6d611a7be7 | |||
| 15a0e87407 | |||
| eee7362551 | |||
| 0a98db6e27 | |||
| 6456f34290 | |||
| 6b96e58748 | |||
| 440f1cc3a7 | |||
| 4f1809be4e | |||
| 5628c9bacb | |||
| 4492ce9739 | |||
| 728b633385 | |||
| 5ed4ee537c | |||
| 4f10f38917 | |||
| e06aa63092 | |||
| 75ed62875f | |||
| fd80ed39c9 |
@@ -66,7 +66,7 @@ jobs:
|
|||||||
-H "Content-Type: application/json" \
|
-H "Content-Type: application/json" \
|
||||||
-d "{
|
-d "{
|
||||||
\"tag_name\": \"$TAG\",
|
\"tag_name\": \"$TAG\",
|
||||||
\"name\": \"$REPO_NAME $TAG\",
|
\"name\": \"$TAG\",
|
||||||
\"body\": \"Language pack release version $TAG for the foreignthon transpiler framework.\",
|
\"body\": \"Language pack release version $TAG for the foreignthon transpiler framework.\",
|
||||||
\"draft\": false,
|
\"draft\": false,
|
||||||
\"prerelease\": false
|
\"prerelease\": false
|
||||||
|
|||||||
38
README.md
38
README.md
@@ -0,0 +1,38 @@
|
|||||||
|
|
||||||
|
# foreignthon-ta
|
||||||
|
|
||||||
|
Tamil language pack for ForeignThon.
|
||||||
|
|
||||||
|
## Install
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pip install foreignthon foreignthon-ta
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
```py
|
||||||
|
fpy run main.ta.py
|
||||||
|
```
|
||||||
|
|
||||||
|
## What's translated
|
||||||
|
|
||||||
|
- **Keywords** — {keywords}
|
||||||
|
- **Builtins** — {builtins}
|
||||||
|
- **Exceptions** — {exceptions}
|
||||||
|
- **Stdlib** — {stdlib}
|
||||||
|
|
||||||
|
{postfix_section}
|
||||||
|
|
||||||
|
## Documentation
|
||||||
|
|
||||||
|
→ https://foreignthon.keshavanand.net/
|
||||||
|
|
||||||
|
## Contributing
|
||||||
|
|
||||||
|
Found a missing translation or a better keyword choice? Open an issue or PR — no core access needed.
|
||||||
|
|
||||||
|
## License
|
||||||
|
|
||||||
|
GPL
|
||||||
|
|
||||||
|
|||||||
@@ -3,28 +3,26 @@ requires = ["hatchling"]
|
|||||||
build-backend = "hatchling.build"
|
build-backend = "hatchling.build"
|
||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "foreignthon-template" # TODO: Modify to language code
|
name = "foreignthon-ta"
|
||||||
version = "0.0.0"
|
version = "0.2.3"
|
||||||
description = "[Template] language pack for ForeignThon." # TODO: Replace [Template]
|
description = "Tamil language pack for ForeignThon."
|
||||||
license = { text = "GPL v3" }
|
license = { text = "GPL v3" }
|
||||||
requires-python = ">=3.9"
|
requires-python = ">=3.9"
|
||||||
authors = [
|
authors = [{ name = "Keshav Anand", email = "keshavanand.dev@gmail.com" }]
|
||||||
{ name = "John Doe", email = "loremipsum@example.com" } # TODO: Swap with real information
|
keywords = ["foreignthon", "tamil", "தமிழ்"]
|
||||||
]
|
dependencies = ["foreignthon>=0.5.3"]
|
||||||
keywords = ["foreignthon", "template", "template"] # TODO: Swap with real information
|
|
||||||
dependencies = ["foreignthon>=0.5.3"] # TODO: Update Version to Latest
|
|
||||||
|
|
||||||
classifiers = [
|
classifiers = [
|
||||||
"Programming Language :: Python :: 3",
|
"Programming Language :: Python :: 3",
|
||||||
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
|
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
|
||||||
"Operating System :: OS Independent",
|
"Operating System :: OS Independent",
|
||||||
|
"Topic :: Software Development :: Compilers",
|
||||||
]
|
]
|
||||||
|
|
||||||
[project.urls]
|
[project.urls]
|
||||||
Homepage = "https://git.keshavanand.net/foreign-thon/foreignthon-template" # TODO: Update URL
|
Homepage = "https://git.keshavanand.net/foreign-thon/foreignthon-ta"
|
||||||
|
|
||||||
[project.entry-points."foreignthon.langs"]
|
[project.entry-points."foreignthon.langs"]
|
||||||
template = "foreignthon_template" # TODO: Swap in format "code = foreignthon_code"
|
ta = "foreignthon_ta"
|
||||||
|
|
||||||
[tool.hatch.build.targets.wheel]
|
[tool.hatch.build.targets.wheel]
|
||||||
packages = ["src/foreignthon_template"] # TODO: Change to src/foreignthon_code
|
packages = ["src/foreignthon_ta"]
|
||||||
|
|||||||
@@ -25,5 +25,5 @@ except PackageNotFoundError:
|
|||||||
__authors__ = []
|
__authors__ = []
|
||||||
|
|
||||||
def get_pack_path():
|
def get_pack_path():
|
||||||
# TODO: Modify this path
|
# CHANGED: Point to your Tamil JSON file
|
||||||
return files(__name__) / "template.json"
|
return files(__name__) / "ta.json"
|
||||||
139
src/foreignthon_ta/ta.json
Normal file
139
src/foreignthon_ta/ta.json
Normal file
@@ -0,0 +1,139 @@
|
|||||||
|
{
|
||||||
|
"meta": {
|
||||||
|
"name": "Tamil",
|
||||||
|
"native_name": "தமிழ்",
|
||||||
|
"code": "ta"
|
||||||
|
},
|
||||||
|
"keywords": {
|
||||||
|
"ஆனால்": "if",
|
||||||
|
"மற்றபடி": "else",
|
||||||
|
"இல்லைஆனால்": "elif",
|
||||||
|
"ஆக": "for",
|
||||||
|
"வரை": "while",
|
||||||
|
"நிரல்பாகம்": "def",
|
||||||
|
"கோப்பு": "class",
|
||||||
|
"பின்கோடு": "return",
|
||||||
|
"நிறுத்து": "break",
|
||||||
|
"தொடர்": "continue",
|
||||||
|
"கடந்துசெல்": "pass",
|
||||||
|
"முயற்சி": "try",
|
||||||
|
"தவிர": "except",
|
||||||
|
"கடைசியில்": "finally",
|
||||||
|
"எழுப்பு": "raise",
|
||||||
|
"உடன்": "with",
|
||||||
|
"இறக்கு": "import",
|
||||||
|
"இருந்து": "from",
|
||||||
|
"என": "as",
|
||||||
|
"உள்ளே": "in",
|
||||||
|
"ஆகும்": "is",
|
||||||
|
"மற்றும்": "and",
|
||||||
|
"அல்லது": "or",
|
||||||
|
"இல்லை": "not",
|
||||||
|
"நீக்கு": "del",
|
||||||
|
"உலகளாவிய": "global",
|
||||||
|
"உள்ளூர்சாரா": "nonlocal",
|
||||||
|
"உறுதிப்படுத்து": "assert",
|
||||||
|
"வழங்கு": "yield",
|
||||||
|
"காத்திரு": "await",
|
||||||
|
"ஒத்திசைவற்ற": "async",
|
||||||
|
"சிறுசார்பு": "lambda",
|
||||||
|
"உண்மை": "True",
|
||||||
|
"பொய்": "False",
|
||||||
|
"ஒன்றுமில்லை": "None"
|
||||||
|
},
|
||||||
|
"builtins": {
|
||||||
|
"பதிப்பி": "print",
|
||||||
|
"உள்ளீடு": "input",
|
||||||
|
"நீளம்": "len",
|
||||||
|
"வரம்பு": "range",
|
||||||
|
"வகை": "type",
|
||||||
|
"முழுஎண்": "int",
|
||||||
|
"தசமஎண்": "float",
|
||||||
|
"சரம்": "str",
|
||||||
|
"பட்டியல்": "list",
|
||||||
|
"அகராதி": "dict",
|
||||||
|
"கணம்": "set",
|
||||||
|
"தொகுப்பு": "tuple",
|
||||||
|
"உண்மைவகை": "bool",
|
||||||
|
"திற": "open",
|
||||||
|
"எண்ணிட": "enumerate",
|
||||||
|
"மேப்": "map",
|
||||||
|
"வடிகட்டு": "filter",
|
||||||
|
"வரிசைப்படுத்து": "sorted",
|
||||||
|
"கூட்டுத்தொகை": "sum",
|
||||||
|
"குறைந்தபட்சம்": "min",
|
||||||
|
"அதிகபட்சம்": "max",
|
||||||
|
"தனிமதிப்பு": "abs",
|
||||||
|
"சுற்று": "round",
|
||||||
|
"அனைத்தும்": "all",
|
||||||
|
"ஏதாவது": "any",
|
||||||
|
"அடுத்தது": "next",
|
||||||
|
"எண்": "id",
|
||||||
|
"எழுத்து": "chr",
|
||||||
|
"தலைகீழ்": "reversed"
|
||||||
|
},
|
||||||
|
"exceptions": {
|
||||||
|
"விதிவிலக்கு": "Exception",
|
||||||
|
"அடிப்படைவிதிவிலக்கு": "BaseException",
|
||||||
|
"மதிப்புபிழை": "ValueError",
|
||||||
|
"வகைபிழை": "TypeError",
|
||||||
|
"திறவுகோல்பிழை": "KeyError",
|
||||||
|
"குறியீட்டுபிழை": "IndexError",
|
||||||
|
"பண்புபிழை": "AttributeError",
|
||||||
|
"பெயர்பிழை": "NameError",
|
||||||
|
"இறக்குமதிபிழை": "ImportError",
|
||||||
|
"கோப்புகிடைக்கவில்லை": "FileNotFoundError",
|
||||||
|
"இயக்கநேரபிழை": "RuntimeError",
|
||||||
|
"பூஜ்யபிரிவுபிழை": "ZeroDivisionError",
|
||||||
|
"தொடரியல்பிழை": "SyntaxError",
|
||||||
|
"உறுதிப்பாட்டுபிழை": "AssertionError",
|
||||||
|
"நினைவகபிழை": "MemoryError",
|
||||||
|
"மிகைபிழை": "OverflowError",
|
||||||
|
"சுழல்பிழை": "RecursionError",
|
||||||
|
"அனுமதிபிழை": "PermissionError",
|
||||||
|
"நேரமுடிந்தது": "TimeoutError",
|
||||||
|
"கணினிவெளியேறு": "SystemExit",
|
||||||
|
"விசைகுறுக்கீடு": "KeyboardInterrupt"
|
||||||
|
},
|
||||||
|
"error_messages": {
|
||||||
|
"SyntaxError": "தொடரியல் பிழை",
|
||||||
|
"ValueError": "மதிப்பு பிழை",
|
||||||
|
"TypeError": "வகை பிழை",
|
||||||
|
"KeyError": "திறவுகோல் பிழை",
|
||||||
|
"IndexError": "குறியீட்டு பிழை",
|
||||||
|
"AttributeError": "பண்பு பிழை",
|
||||||
|
"NameError": "பெயர் பிழை",
|
||||||
|
"ImportError": "இறக்குமதி பிழை",
|
||||||
|
"FileNotFoundError": "கோப்பு கிடைக்கவில்லை",
|
||||||
|
"ZeroDivisionError": "பூஜ்யத்தால் வகுக்க முடியாது",
|
||||||
|
"RecursionError": "சுழல் பிழை",
|
||||||
|
"RuntimeError": "இயக்க நேர பிழை",
|
||||||
|
"MemoryError": "நினைவக பிழை",
|
||||||
|
"OverflowError": "மிகை பிழை",
|
||||||
|
"AssertionError": "உறுதிப்பாட்டு பிழை",
|
||||||
|
"PermissionError": "அனுமதி பிழை",
|
||||||
|
"TimeoutError": "நேரம் முடிந்தது",
|
||||||
|
"KeyboardInterrupt": "விசை குறுக்கீடு"
|
||||||
|
},
|
||||||
|
"stdlib": {
|
||||||
|
"கணிதம்": "math",
|
||||||
|
"கணினி": "sys",
|
||||||
|
"தேதிநேரம்": "datetime",
|
||||||
|
"நேரம்": "time",
|
||||||
|
"சீரற்ற": "random",
|
||||||
|
"தொகுப்புகள்": "collections",
|
||||||
|
"பாதை": "pathlib",
|
||||||
|
"வழக்கமொழி": "re"
|
||||||
|
},
|
||||||
|
"postfix_keywords": [
|
||||||
|
"if",
|
||||||
|
"elif",
|
||||||
|
"while",
|
||||||
|
"class",
|
||||||
|
"with",
|
||||||
|
"try",
|
||||||
|
"except",
|
||||||
|
"finally",
|
||||||
|
"from"
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -1,132 +0,0 @@
|
|||||||
{
|
|
||||||
"meta": {
|
|
||||||
"name": "Template",
|
|
||||||
"native_name": "Template",
|
|
||||||
"code": "template"
|
|
||||||
},
|
|
||||||
"keywords": {
|
|
||||||
"if": "if",
|
|
||||||
"else": "else",
|
|
||||||
"elif": "elif",
|
|
||||||
"for": "for",
|
|
||||||
"while": "while",
|
|
||||||
"def": "def",
|
|
||||||
"class": "class",
|
|
||||||
"return": "return",
|
|
||||||
"break": "break",
|
|
||||||
"continue": "continue",
|
|
||||||
"pass": "pass",
|
|
||||||
"try": "try",
|
|
||||||
"except": "except",
|
|
||||||
"finally": "finally",
|
|
||||||
"raise": "raise",
|
|
||||||
"with": "with",
|
|
||||||
"import": "import",
|
|
||||||
"from": "from",
|
|
||||||
"as": "as",
|
|
||||||
"in": "in",
|
|
||||||
"is": "is",
|
|
||||||
"and": "and",
|
|
||||||
"or": "or",
|
|
||||||
"not": "not",
|
|
||||||
"del": "del",
|
|
||||||
"global": "global",
|
|
||||||
"nonlocal": "nonlocal",
|
|
||||||
"assert": "assert",
|
|
||||||
"yield": "yield",
|
|
||||||
"await": "await",
|
|
||||||
"async": "async",
|
|
||||||
"lambda": "lambda",
|
|
||||||
"True": "True",
|
|
||||||
"False": "False",
|
|
||||||
"None": "None"
|
|
||||||
},
|
|
||||||
"builtins": {
|
|
||||||
"print": "print",
|
|
||||||
"input": "input",
|
|
||||||
"len": "len",
|
|
||||||
"range": "range",
|
|
||||||
"type": "type",
|
|
||||||
"int": "int",
|
|
||||||
"float": "float",
|
|
||||||
"str": "str",
|
|
||||||
"list": "list",
|
|
||||||
"dict": "dict",
|
|
||||||
"set": "set",
|
|
||||||
"tuple": "tuple",
|
|
||||||
"bool": "bool",
|
|
||||||
"open": "open",
|
|
||||||
"enumerate": "enumerate",
|
|
||||||
"map": "map",
|
|
||||||
"filter": "filter",
|
|
||||||
"sorted": "sorted",
|
|
||||||
"sum": "sum",
|
|
||||||
"min": "min",
|
|
||||||
"max": "max",
|
|
||||||
"abs": "abs",
|
|
||||||
"round": "round",
|
|
||||||
"all": "all",
|
|
||||||
"any": "any",
|
|
||||||
"next": "next",
|
|
||||||
"id": "id",
|
|
||||||
"chr": "chr",
|
|
||||||
"reversed": "reversed"
|
|
||||||
},
|
|
||||||
"exceptions": {
|
|
||||||
"Exception": "Exception",
|
|
||||||
"BaseException": "BaseException",
|
|
||||||
"ValueError": "ValueError",
|
|
||||||
"TypeError": "TypeError",
|
|
||||||
"KeyError": "KeyError",
|
|
||||||
"IndexError": "IndexError",
|
|
||||||
"AttributeError": "AttributeError",
|
|
||||||
"NameError": "NameError",
|
|
||||||
"ImportError": "ImportError",
|
|
||||||
"FileNotFoundError": "FileNotFoundError",
|
|
||||||
"RuntimeError": "RuntimeError",
|
|
||||||
"ZeroDivisionError": "ZeroDivisionError",
|
|
||||||
"SyntaxError": "SyntaxError",
|
|
||||||
"AssertionError": "AssertionError",
|
|
||||||
"MemoryError": "MemoryError",
|
|
||||||
"OverflowError": "OverflowError",
|
|
||||||
"RecursionError": "RecursionError",
|
|
||||||
"PermissionError": "PermissionError",
|
|
||||||
"TimeoutError": "TimeoutError",
|
|
||||||
"SystemExit": "SystemExit",
|
|
||||||
"KeyboardInterrupt": "KeyboardInterrupt"
|
|
||||||
},
|
|
||||||
"error_messages": {
|
|
||||||
"SyntaxError": "SyntaxError",
|
|
||||||
"ValueError": "ValueError",
|
|
||||||
"TypeError": "TypeError",
|
|
||||||
"KeyError": "KeyError",
|
|
||||||
"IndexError": "IndexError",
|
|
||||||
"AttributeError": "AttributeError",
|
|
||||||
"NameError": "NameError",
|
|
||||||
"ImportError": "ImportError",
|
|
||||||
"FileNotFoundError": "FileNotFoundError",
|
|
||||||
"ZeroDivisionError": "ZeroDivisionError",
|
|
||||||
"RecursionError": "RecursionError",
|
|
||||||
"RuntimeError": "RuntimeError",
|
|
||||||
"MemoryError": "MemoryError",
|
|
||||||
"OverflowError": "OverflowError",
|
|
||||||
"AssertionError": "AssertionError",
|
|
||||||
"PermissionError": "PermissionError",
|
|
||||||
"TimeoutError": "TimeoutError",
|
|
||||||
"KeyboardInterrupt": "KeyboardInterrupt"
|
|
||||||
},
|
|
||||||
"stdlib": {
|
|
||||||
"math": "math",
|
|
||||||
"sys": "sys",
|
|
||||||
"datetime": "datetime",
|
|
||||||
"time": "time",
|
|
||||||
"random": "random",
|
|
||||||
"collections": "collections",
|
|
||||||
"pathlib": "pathlib",
|
|
||||||
"re": "re"
|
|
||||||
},
|
|
||||||
|
|
||||||
"postfix_keywords": [
|
|
||||||
|
|
||||||
]
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user