'-W' needs to be *after* URL prefix argument. README says otherwise. #10

trentm opened this Issue Jan 10, 2011 · 1 comment


None yet
2 participants

trentm commented Jan 10, 2011


At least for me on a Solaris box I've found that this example in the README doesn't work:

. /path/to/resty -W 'https://myhost.com/data*.json'

For the equivalent to work for me, I needed to use the '-W' after the URL prefix argument like so:

. /path/to/resty 'https://myhost.com/data*.json' -W

A concrete example: Here I've added an "echo" statement to show the 'curl' command-line that is being called. Hopefully that gives you enough of a hint:

[root@mybox ~]# . resty/resty -W '*'
[root@mybox ~]# GET /
curl -sLv  -X GET -b /root/.resty/c/-W -c /root/.resty/c/-W http://-W/
[root@mybox ~]# . resty/resty  '*' -W
[root@mybox ~]# GET /
curl -sLv  -X GET -b /root/.resty/c/ -c /root/.resty/c/
  <error>Not authorized
[root@mybox ~]# 

Where, in my case that "..." XML output is the expected response.

Ideas? It is possible this is a Solaris vs. Linux difference, but I haven't traced through the Bash code path handling '-W'.


micha commented Jan 10, 2011

Ah. That was a bug. It should work correctly (as in the README) now. Thanks!

This issue was closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment