shalupov / idea-cloudformation

AWS CloudFormation plugin for IntelliJ-based IDEs (IntelliJ IDEA, RubyMine, WebStorm, PhpStorm, PyCharm, AppCode, Android Studio, DataGrip, CLion)
https://teamcity.jetbrains.com/viewType.html?buildTypeId=IdeaAwsCloudFormation_Master_Build&guest=1
Apache License 2.0
136 stars 27 forks source link

reference to resource are not resolved inside metadata/cloudformationinit section #113

Open gchiesa opened 6 years ago

gchiesa commented 6 years ago

It seems that inside a Metadata / CloudFormation::Init resource the ref functionality is not working properly. The IDE does not propose any suggestion or check for a valid existing resource. Example of code:

{
  "AWS::CloudFormation::Init": {
    "config": {
      "files": {
        "file1": {
          "mode": "0600",
          "owner": "root",
          "group": "root",
          "content": {
            "Fn::Join": [
              "\n", [
                { "Fn::Sub": [ "account_id: ${a}", { "a": { "Ref": "AWS::AccountId" } } ] }
              ]
            ]
          }
        }
      }
    }
  }
}

in the code above the { "Ref": "AWS::AccountId" } is not either autocompleted or flagged invalid if a not existing resource is mentioned.

CloudFormationPlugin version: 0.5.41