Skip to content

JSON Not created correctly #9

@mattnield

Description

@mattnield

I tried creating a simple JSON file with the following content:

{
  "auth": {
    "user": "",
    "password": ""
  }
}

To do this I created a repository variable containing the above JSON and then tried to call it in my deploy job. This is for a .NET application and looks as follows:

      - name: Create App Settings
        id: create-json
        uses: jsdaniell/create-json@v1.2.3
        with:
          name: 'appsettings.json'
          json: ${{ vars.APP_SETTINGS }}

What I see being created though is a file that looks like this:

auth:
 user:
 password:

What's causing this formatting issue?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions