-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This is actually a fork of tree-sitter-make because the original author does not seem responsive. See alemuller/tree-sitter-make#19 test plan: ./test-lang make
- Loading branch information
pad
committed
Jul 18, 2023
1 parent
4374124
commit 96fc57e
Showing
12 changed files
with
51 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../Makefile.common |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# File extensions for the target language, one per line. This is used for | ||
# collecting parsing stats from the repos specified in 'projects.txt'. e.g.: | ||
# | ||
# .h | ||
# .c | ||
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
semgrep-grammars/src/tree-sitter-make/LICENSE | ||
semgrep-grammars/src/tree-sitter-make/grammar.js | ||
semgrep-grammars/src/semgrep-make/grammar.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Git URLs of publicly-accessible projects to be used for parsing stats, | ||
# one per line. | ||
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../src/semgrep-make |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../Makefile.common |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
/* | ||
semgrep-make | ||
Extends the standard make grammar with semgrep pattern constructs. | ||
*/ | ||
|
||
const base_grammar = require('tree-sitter-make/grammar'); | ||
|
||
module.exports = grammar(base_grammar, { | ||
name: 'make', | ||
|
||
conflicts: ($, previous) => previous.concat([ | ||
]), | ||
|
||
/* | ||
Support for semgrep ellipsis ('...') and metavariables ('$FOO'), | ||
if they're not already part of the base grammar. | ||
*/ | ||
rules: { | ||
/* | ||
semgrep_ellipsis: $ => '...', | ||
_expression: ($, previous) => choice( | ||
$.semgrep_ellipsis, | ||
...previous.members | ||
), | ||
*/ | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../prep.common |
Empty file.
Submodule tree-sitter-make
added at
03b0c4