Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no newline at the end of json output causes shell prompt to be placed on same line as json data. #107

Closed
edaniszewski opened this issue Mar 23, 2018 · 1 comment
Assignees
Labels

Comments

@edaniszewski
Copy link
Contributor

Description

As an example, after doing a curl,

edaniszewski ~ ➜ curl "localhost:5000/synse/2.0/read/rack-1/vec/f52d29fecf05a195af13f14c7306cfed"
{
  "type":"led",
  "data":{
    "state":{
      "value":"off",
      "timestamp":"2018-03-23T19:25:07.2898134Z",
      "unit":null
    },
    "color":{
      "value":"ffffff",
      "timestamp":"2018-03-23T19:25:07.289838Z",
      "unit":null
    },
    "blink":{
      "value":"steady",
      "timestamp":"2018-03-23T19:25:07.2898508Z",
      "unit":null
    }
  }
}edaniszewski ~ ➜

the prompt ends up on the same line as the last line of the JSON ouput. this can get annoying/inconvenient.

Should add a newline to the end of the json (if pretty-printing) so the shell prompt starts on a new line, separate from the JSON data.

@MatthewHink
Copy link
Contributor

Wouldn't worry about it too much. It's typical.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants