From a97fd74399bd7a358f3bcd0badaa4ed3c4b4345d Mon Sep 17 00:00:00 2001 From: Seth Vargo Date: Thu, 18 Dec 2014 17:46:26 -0500 Subject: [PATCH 1/3] Add HCL to languages.yml More information on HCL: https://github.com/hashicorp/hcl --- lib/linguist/languages.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lib/linguist/languages.yml b/lib/linguist/languages.yml index d69b072a..a9f8b858 100644 --- a/lib/linguist/languages.yml +++ b/lib/linguist/languages.yml @@ -1239,6 +1239,14 @@ Harbour: tm_scope: none ace_mode: text +HCL: + type: programming + extensions: + - .hcl + - .tf + ace_mode: javascript + tm_scope: source.json + Haskell: type: programming color: "#29b544" From 296d170ba9644013dba241b2853bd1d653e72853 Mon Sep 17 00:00:00 2001 From: Seth Vargo Date: Thu, 18 Dec 2014 17:52:30 -0500 Subject: [PATCH 2/3] Add sample for HCL --- samples/HCL/example.hcl | 6 ++++++ samples/HCL/example.tf | 13 +++++++++++++ 2 files changed, 19 insertions(+) create mode 100644 samples/HCL/example.hcl create mode 100644 samples/HCL/example.tf diff --git a/samples/HCL/example.hcl b/samples/HCL/example.hcl new file mode 100644 index 00000000..276b171e --- /dev/null +++ b/samples/HCL/example.hcl @@ -0,0 +1,6 @@ +consul = "1.2.3.4" + +// This is a comment +template "foo" { + bar = "zip" +} diff --git a/samples/HCL/example.tf b/samples/HCL/example.tf new file mode 100644 index 00000000..976c2e07 --- /dev/null +++ b/samples/HCL/example.tf @@ -0,0 +1,13 @@ +resource "aws_instance" "web" { + // Copies the myapp.conf file to /etc/myapp.conf + provisioner "file" { + source = "conf/myapp.conf" + destination = "/etc/myapp.conf" + } + + // Copies the configs.d folder to /etc/configs.d + provisioner "file" { + source = "conf/configs.d" + destination = "/etc" + } +} From 5217f19faa8bb1030ce97b6ebe49031bd6fc725d Mon Sep 17 00:00:00 2001 From: Seth Vargo Date: Thu, 18 Dec 2014 17:53:53 -0500 Subject: [PATCH 3/3] Alphabetize order --- lib/linguist/languages.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/linguist/languages.yml b/lib/linguist/languages.yml index a9f8b858..b7df08fa 100644 --- a/lib/linguist/languages.yml +++ b/lib/linguist/languages.yml @@ -1153,6 +1153,14 @@ Groovy Server Pages: tm_scope: text.html.jsp ace_mode: jsp +HCL: + type: programming + extensions: + - .hcl + - .tf + ace_mode: javascript + tm_scope: source.json + HTML: type: markup tm_scope: text.html.basic @@ -1239,14 +1247,6 @@ Harbour: tm_scope: none ace_mode: text -HCL: - type: programming - extensions: - - .hcl - - .tf - ace_mode: javascript - tm_scope: source.json - Haskell: type: programming color: "#29b544"