{"action":"created","issue":{"url":"https://api.github.com/repos/dominictarr/JSON.sh/issues/33","labels_url":"https://api.github.com/repos/dominictarr/JSON.sh/issues/33/labels{/name}","comments_url":"https://api.github.com/repos/dominictarr/JSON.sh/issues/33/comments","events_url":"https://api.github.com/repos/dominictarr/JSON.sh/issues/33/events","html_url":"https://github.com/dominictarr/JSON.sh/issues/33","id":59421880,"number":33,"title":"Getting \"EXPECTED value GOT EOF\" for any kind of JSON in Cygwin","user":{"login":"philippgille","id":170670,"avatar_url":"https://avatars.githubusercontent.com/u/170670?v=3","gravatar_id":"","url":"https://api.github.com/users/philippgille","html_url":"https://github.com/philippgille","followers_url":"https://api.github.com/users/philippgille/followers","following_url":"https://api.github.com/users/philippgille/following{/other_user}","gists_url":"https://api.github.com/users/philippgille/gists{/gist_id}","starred_url":"https://api.github.com/users/philippgille/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philippgille/subscriptions","organizations_url":"https://api.github.com/users/philippgille/orgs","repos_url":"https://api.github.com/users/philippgille/repos","events_url":"https://api.github.com/users/philippgille/events{/privacy}","received_events_url":"https://api.github.com/users/philippgille/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-03-01T22:47:41Z","updated_at":"2015-03-06T04:22:23Z","closed_at":null,"body":"I'm using JSON.sh in a Cygwin environment and I'm getting an error when trying to use it for any kind of JSON:\r\n> EXPECTED value GOT EOF\r\n\r\n- Tried with your example: `curl registry.npmjs.org/express | ./JSON.sh | egrep '\\[\"versions\",\"[^\"]*\"\\]'`\r\n- Also tried with: `echo \"{\\\"foo\\\":\\\"bar\\\"}\" | ./JSON.sh`\r\n\r\nMaybe related to #26? Or maybe related to CRLF vs. LF on Windows vs. Linux (note I'm using Cygwin on Windows)?"},"comment":{"url":"https://api.github.com/repos/dominictarr/JSON.sh/issues/comments/77504605","html_url":"https://github.com/dominictarr/JSON.sh/issues/33#issuecomment-77504605","issue_url":"https://api.github.com/repos/dominictarr/JSON.sh/issues/33","id":77504605,"user":{"login":"dominictarr","id":259374,"avatar_url":"https://avatars.githubusercontent.com/u/259374?v=3","gravatar_id":"","url":"https://api.github.com/users/dominictarr","html_url":"https://github.com/dominictarr","followers_url":"https://api.github.com/users/dominictarr/followers","following_url":"https://api.github.com/users/dominictarr/following{/other_user}","gists_url":"https://api.github.com/users/dominictarr/gists{/gist_id}","starred_url":"https://api.github.com/users/dominictarr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dominictarr/subscriptions","organizations_url":"https://api.github.com/users/dominictarr/orgs","repos_url":"https://api.github.com/users/dominictarr/repos","events_url":"https://api.github.com/users/dominictarr/events{/privacy}","received_events_url":"https://api.github.com/users/dominictarr/received_events","type":"User","site_admin":false},"created_at":"2015-03-06T04:22:23Z","updated_at":"2015-03-06T04:22:23Z","body":"right okay. It looks like you don't have a compatible egrep or awk egrep.\r\n\r\nsee this function here:\r\nhttps://github.com/dominictarr/JSON.sh/blob/master/JSON.sh#L63-L91\r\n\r\nwhich picks a suitable grep from what might exist....\r\nhmm, just noticed that it goes and puts a grep inside $GREP but then doesn't use that on the thing that removes the spaces afterwards.\r\n\r\nwhat happens if you change\r\nhttps://github.com/dominictarr/JSON.sh/blob/master/JSON.sh#L90\r\n\r\nto   `$GREP \"$STRING|$NUMBER|$KEYWORD|$SPACE|.\" | $GREP -v \"^$SPACE$\"`\r\n\r\notherwise, what grep _do_ you have?"}}