Skip to content

Commit

Permalink
✨ - Add more PPX skip rules (#105)
Browse files Browse the repository at this point in the history
  • Loading branch information
zth authored Apr 16, 2024
1 parent e6a8406 commit 775b36b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/build/parse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -349,10 +349,15 @@ fn path_to_ast_extension(path: &Path) -> &str {
fn include_ppx(flag: &str, contents: &str) -> bool {
if flag.contains("bisect") {
return std::env::var("BISECT_ENABLE").is_ok();
} else if flag.contains("graphql-ppx") && !contents.contains("%graphql") {
} else if (flag.contains("graphql-ppx") || flag.contains("graphql_ppx")) && !contents.contains("%graphql")
{
return false;
} else if flag.contains("spice") && !contents.contains("@spice") {
return false;
} else if flag.contains("rescript-relay") && !contents.contains("%relay") {
return false;
} else if flag.contains("re-formality") && !contents.contains("%form") {
return false;
}
return true;
}
Expand Down

0 comments on commit 775b36b

Please sign in to comment.