Skip to content

Commit

Permalink
Merge pull request #212 from naps62/lua
Browse files Browse the repository at this point in the history
Adds support for lua
  • Loading branch information
alstr authored Oct 9, 2024
2 parents b380120 + 94022ce commit 85a6f71
Show file tree
Hide file tree
Showing 5 changed files with 57 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@ Only a single milestone can be specified. If the milestone does not exist, it wi
- Kotlin
- Less
- Liquid
- Lua
- Makefile
- Markdown
- Nix
Expand Down
16 changes: 16 additions & 0 deletions syntax.json
Original file line number Diff line number Diff line change
Expand Up @@ -837,5 +837,21 @@
}
}
]
},
{
"language": "Lua",
"markers": [
{
"type": "line",
"pattern": "--"
},
{
"type": "block",
"pattern": {
"start": "--\\[\\[",
"end": "--\\]\\]"
}
}
]
}
]
17 changes: 17 additions & 0 deletions tests/test_closed.diff
Original file line number Diff line number Diff line change
Expand Up @@ -483,3 +483,20 @@ index 525e25d..ba4e68d 100644
-TODO: Create an issue for TODO
--}
-sum a b = a + b
diff --git a/init.lua b/init.lua
new file mode 100644
index 0000000..0ce9b1a
--- a/init.lua
+++ b/init.lua
@@ -0,0 +1,11 @@
--- TODO: Fix this
--- In the future, make a way to build these and just start the base
--- out with a large supply of each
--- labels: redesign
-local a = 1
-
---[[
- TODO: Fix this todo
- labels: urgent
---]]
-local b = 2
17 changes: 17 additions & 0 deletions tests/test_new.diff
Original file line number Diff line number Diff line change
Expand Up @@ -539,3 +539,20 @@ index 0000000..0ce9b1a
+TODO: Create an issue for TODO
+-}
+sum a b = a + b
diff --git a/init.lua b/init.lua
new file mode 100644
index 0000000..0ce9b1a
--- /dev/null
+++ b/init.lua
@@ -0,0 +1,11 @@
+-- TODO: Fix this
+-- In the future, make a way to build these and just start the base
+-- out with a large supply of each
+-- labels: redesign
+local a = 1
+
+--[[
+ TODO: Fix this todo
+ labels: urgent
+--]]
+local b = 2
6 changes: 6 additions & 0 deletions tests/test_todo_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,9 @@ def test_c_cpp_like_issues(self):
def test_liquid_issues(self):
self.assertEqual(count_issues_for_file_type(self.raw_issues, 'liquid'), 3)

def test_lua_issues(self):
self.assertEqual(count_issues_for_file_type(self.raw_issues, 'lua'), 2)

class ClosedIssueTests(unittest.TestCase):
# Check for removed TODOs across the files specified.
def setUp(self):
Expand Down Expand Up @@ -187,6 +190,9 @@ def test_c_cpp_like_issues(self):
def test_liquid_issues(self):
self.assertEqual(count_issues_for_file_type(self.raw_issues, 'liquid'), 3)

def test_lua_issues(self):
self.assertEqual(count_issues_for_file_type(self.raw_issues, 'lua'), 2)


class IgnorePatternTests(unittest.TestCase):

Expand Down

0 comments on commit 85a6f71

Please sign in to comment.