Commit Graph

10 Commits

Author SHA1 Message Date
Jakub Roztocil
098e1d3100 Fixed multipart requests output; binary support.
* Bodies of multipart requests are correctly printed (closes #30).
* Binary requests and responses should always work (they are also suppressed
  for terminal output). So things like this work::

     http www.google.com/favicon.ico > favicon.ico
2012-07-28 05:50:12 +02:00
Jakub Roztocil
a8ddb8301d Default to https:// if invoked as `https'. 2012-07-27 18:08:33 +02:00
Jakub Roztocil
f45cc0eec0 Added docstrings, refactored input. 2012-07-26 07:23:00 +02:00
Jakub Roztocil
26a76e8243 Clean-up 2012-07-26 00:50:39 +02:00
Jakub Roztocil
7af08b6faa Allow multiple fields with the same name.
Applies to form data and URL params:

    http -f url a=1 a=2
    http url a==1 a==2
2012-07-24 17:00:02 +02:00
Jakub Roztocil
9944def703 Switched to "==" a the separator for URL params.
Also refactored item escaping.
2012-07-24 14:56:53 +02:00
Jakub Roztocil
2646ebaaed Replaced --ignore-http-status with --check-status.
The default behaviour now is to exit with 0 on HTTP errors
unless --check-status is set.
2012-07-24 01:09:14 +02:00
Jakub Roztocil
0572158ba1 Added exit codes for HTTP 3xx, 4xx, 5xx (3, 4, 5).
Also added `--ignore-http-status` to ensure 0 exit status.

HTTP 3xx result in 0 exit status when `--allow-redirects` is set.
2012-07-23 19:40:50 +02:00
Jakub Roztocil
0a673613ef Fixed colorama initialization (#36). 2012-07-21 15:08:28 +02:00
Jakub Roztocil
87042f65c9 Added models.Environment().
Refactoring and general cleanup.
2012-07-21 03:14:01 +02:00