From 9e2a4bee43a7dc12dc4168e68b5e0f30adfdd76c Mon Sep 17 00:00:00 2001 From: aaron-bond Date: Wed, 15 May 2019 15:23:39 +0100 Subject: [PATCH] Adding ColdFusion support, closes #149 --- CHANGELOG.md | 3 ++- README.md | 1 + package.json | 1 + src/parser.ts | 4 ++++ src/test/samples/cfc.cfc | 14 ++++++++++++++ src/test/samples/coldfusion.cfm | 14 ++++++++++++++ 6 files changed, 36 insertions(+), 1 deletion(-) create mode 100644 src/test/samples/cfc.cfc create mode 100644 src/test/samples/coldfusion.cfm diff --git a/CHANGELOG.md b/CHANGELOG.md index b298d4e..333ef27 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,8 @@ ### Features * Adding Markdown support ([54e51fb](https://github.com/aaron-bond/better-comments/commit/54e51fb)), closes [#91](https://github.com/aaron-bond/better-comments/issues/91) * Adding Apex support ([301644e](https://github.com/aaron-bond/better-comments/commit/301644e)), closes [#143](https://github.com/aaron-bond/better-comments/issues/143) -* Adding GenStat support ([XXX](https://github.com/aaron-bond/better-comments/commit/XXX)), closes [#149](https://github.com/aaron-bond/better-comments/issues/149) +* Adding GenStat support ([a14e24c](https://github.com/aaron-bond/better-comments/commit/a14e24c)), closes [#149](https://github.com/aaron-bond/better-comments/issues/149) +* Adding ColdFusion support ([XXX](https://github.com/aaron-bond/better-comments/commit/XXX)), closes [#135](https://github.com/aaron-bond/better-comments/issues/135) ## [2.0.4] (2019-05-14) ### Bug Fixes diff --git a/README.md b/README.md index 414536b..cfc1c83 100644 --- a/README.md +++ b/README.md @@ -71,6 +71,7 @@ The default 5 can be modifed to change the colors, and more can be added. * C * C# * C++ +* ColdFusion * Clojure * COBOL * CoffeeScript diff --git a/package.json b/package.json index 4122059..261d2b3 100644 --- a/package.json +++ b/package.json @@ -30,6 +30,7 @@ "onLanguage:bibtex", "onLanguage:c", "onLanguage:clojure", + "onLanguage:cfml", "onLanguage:COBOL", "onLanguage:coffeescript", "onLanguage:cpp", diff --git a/src/parser.ts b/src/parser.ts index 207cf3a..38e7987 100644 --- a/src/parser.ts +++ b/src/parser.ts @@ -387,6 +387,10 @@ export class Parser { case "genstat": this.setCommentFormat("\\", '"', '"'); break; + + case "cfml": + this.setCommentFormat(""); + break; case "plaintext": this.isPlainText = true; diff --git a/src/test/samples/cfc.cfc b/src/test/samples/cfc.cfc new file mode 100644 index 0000000..d62c4e7 --- /dev/null +++ b/src/test/samples/cfc.cfc @@ -0,0 +1,14 @@ + + + No, it didn't + + + + No, it didn't + + + + No, it didn't + \ No newline at end of file diff --git a/src/test/samples/coldfusion.cfm b/src/test/samples/coldfusion.cfm new file mode 100644 index 0000000..d62c4e7 --- /dev/null +++ b/src/test/samples/coldfusion.cfm @@ -0,0 +1,14 @@ + + + No, it didn't + + + + No, it didn't + + + + No, it didn't + \ No newline at end of file