From 67bd7ca2c360156fcaf4f1ef156f24bb4fa94d0e Mon Sep 17 00:00:00 2001 From: Puskar-Roy Date: Fri, 27 Dec 2024 20:56:44 +0530 Subject: [PATCH] fix : typo --- .env.example | 3 ++- .github/workflows/main.yml | 2 +- .gitignore | 1 + README.md | 1 + docs/Rules.md | 1 + lib/syntax.py | 1 + main.py | 1 - requirements.txt | 2 ++ scripts/__init__.py | 4 ++++ setup.sh | 1 - src/interpreter/__init__.py | 3 +++ src/lexer/__init__.py | 1 + src/lexer/token_types/__init__.py | 2 +- src/parser/__init__.py | 3 +++ 14 files changed, 21 insertions(+), 5 deletions(-) diff --git a/.env.example b/.env.example index 2674ae0..f1da507 100644 --- a/.env.example +++ b/.env.example @@ -1,2 +1,3 @@ PRINT_COMMAND="Your Print Command!" -VARIABLE_DECLARE="Your Variable declaration Command!" \ No newline at end of file +VARIABLE_DECLARE="Your Variable declaration Command!" + diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 68ab9b6..dd5f7af 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1 +1 @@ -name: DuckLang \ No newline at end of file +name: DuckLang diff --git a/.gitignore b/.gitignore index 021802b..68d005f 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ venv .env + __pycache__/ *.pyc diff --git a/README.md b/README.md index 986cf9e..c085630 100644 --- a/README.md +++ b/README.md @@ -51,6 +51,7 @@ ## 🛠️ Prerequisites + - [Python](https://nodejs.org/) installed on your machine 🐍 - [Git](https://git-scm.com/) installed on your machine 🐙 diff --git a/docs/Rules.md b/docs/Rules.md index 50d650f..2413669 100644 --- a/docs/Rules.md +++ b/docs/Rules.md @@ -1,3 +1,4 @@ ## KeyWords - For Print -> ```quack``` (eg. quack Hello World ) + diff --git a/lib/syntax.py b/lib/syntax.py index 4ffcc4d..b80b63e 100644 --- a/lib/syntax.py +++ b/lib/syntax.py @@ -8,6 +8,7 @@ var_command = os.getenv("VARIABLE_DECLARE", "UNKNOWN") + syntax = { "name": name, "PRINT_COMMAND": print_command, diff --git a/main.py b/main.py index 22b81b3..77cb5c1 100644 --- a/main.py +++ b/main.py @@ -5,7 +5,6 @@ -# Test code source_code = ''' quack("Hello World") duck my_int = 42 diff --git a/requirements.txt b/requirements.txt index 3324f44..2e097a3 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1 +1,3 @@ python-dotenv==1.0.1 + + diff --git a/scripts/__init__.py b/scripts/__init__.py index e69de29..7a2251a 100644 --- a/scripts/__init__.py +++ b/scripts/__init__.py @@ -0,0 +1,4 @@ +def printName(values): + return values + + diff --git a/setup.sh b/setup.sh index 44ed3c6..39ce8d3 100755 --- a/setup.sh +++ b/setup.sh @@ -1,6 +1,5 @@ #!/bin/bash - detect_os() { case "$(uname -s)" in Linux*) echo "Linux";; diff --git a/src/interpreter/__init__.py b/src/interpreter/__init__.py index e69de29..b28b04f 100644 --- a/src/interpreter/__init__.py +++ b/src/interpreter/__init__.py @@ -0,0 +1,3 @@ + + + diff --git a/src/lexer/__init__.py b/src/lexer/__init__.py index 3eaee54..e191a59 100644 --- a/src/lexer/__init__.py +++ b/src/lexer/__init__.py @@ -5,6 +5,7 @@ # Importing token types dictionary from src.lexer.token_types import TOKEN_TYPES + # Retrieve the print command syntax from the syntax dictionary print_command = syntax.get("PRINT_COMMAND", "No Name Defined") # Retrieve the variable declaration command syntax from the syntax dictionary diff --git a/src/lexer/token_types/__init__.py b/src/lexer/token_types/__init__.py index e2ca63e..ac4bc62 100644 --- a/src/lexer/token_types/__init__.py +++ b/src/lexer/token_types/__init__.py @@ -16,4 +16,4 @@ "IDENTIFIER": 'IDENTIFIER', "EQUALS": 'EQUALS', "UNKNOWN": 'UNKNOWN' -} \ No newline at end of file +} diff --git a/src/parser/__init__.py b/src/parser/__init__.py index e69de29..b28b04f 100644 --- a/src/parser/__init__.py +++ b/src/parser/__init__.py @@ -0,0 +1,3 @@ + + +