VladRassokhin / intellij-hcl

HCL language support for IntelliJ platform based IDEs
Apache License 2.0
244 stars 47 forks source link

Unknown block type for Nomad job block names #198

Closed andye2004 closed 5 years ago

andye2004 commented 5 years ago

Thank you for opening an issue. In this template paragraph text could be removed, however please retain headers.

Prerequisites

Installation details

Exception

None

Expected Behavior

Nomad job configuration stanza names should be correctly identified / auto-completion suggestions made

Actual Behavior

Lexical analysis states: Unknown block type for Nomad job stanza names

Steps to Reproduce

Please list the steps required to reproduce the issue, for example:

  1. Create a new file called job.nomad and add the below job configuration
job "caller-service-job" {
  datacenters = ["dc1"]
  type = "service"
}
  1. If real time analysis is enabled the job will be highlighted and the Unknown block type... message will be displayed when you hover over it. Alternatively, right click in the file and select Analyze/Inspect Code and then click OK and the Inspection Results tab will appear and with the Unknown block type... results.

NOTE: Unknown block type... is returned for all Nomad job stanza names.

VladRassokhin commented 5 years ago

Normally Terraform-related inspections are disabled for .nomad files. Please ensure that in your IDE 'nomad' files are associated with 'HashiCorp Configuration Language' language, not 'Terraform' one. Could be checked at Preferences -> Editor -> File Types

andye2004 commented 5 years ago

@VladRassokhin, That was exactly the issue. Thanks for the help!

I'm assuming there is no auto-completion for the nomad schema / dictionary?

VladRassokhin commented 5 years ago

For now unfortunately there's no autocompletion and other features for Nomad :(