Skip to content

Commit

Permalink
Thanks to a regex, comments are now supported. Close #4
Browse files Browse the repository at this point in the history
  • Loading branch information
ColinFay committed Mar 6, 2018
1 parent 3d8072f commit 49dae37
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion R/knitr_engine.R
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ set_neo4j_engine <- function(neo4j_home,
if (options$eval) {
options$code_to_eval <- clean_input(options$code)
out <- encypher_for_knitr(options)
#out <- options$code
#out <- options$code_to_eval
}
engine_output(options, options$code, out)
})
Expand Down
1 change: 1 addition & 0 deletions R/utils.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
clean_input <- function(vec){
vec <- gsub("^\\/\\/.+$", "\n", vec, perl = TRUE)
vec <- paste(gsub("\n", " ", vec), collapse = " ")
vec <- gsub(";", ";%", vec)
vec <- gsub("\'", "\"", vec)
Expand Down

0 comments on commit 49dae37

Please sign in to comment.