Commit Graph

77 Commits

Author SHA1 Message Date
Jakub Roztocil
464b7a36da Tests 2013-04-12 10:20:01 -03:00
Jakub Roztocil
674acfe2c2 Cleanup 2013-04-11 16:23:15 -03:00
Jakub Roztocil
7ccdece39f Cleanup 2013-04-11 04:00:41 -03:00
Jakub Roztocil
e53dcba03e Added Content-Range parsing tests.
#104
2013-04-11 03:49:01 -03:00
Jakub Roztocil
6e5c696ac9 --json with no data sets Content-Type as well
Closes #137
2013-04-02 11:07:14 -03:00
Jakub Roztocil
8e6c765be2 Initial --download implementation (#104).
Closes #127
2013-03-03 22:17:09 -03:00
Jakub Roztocil
d7ec7b2217 Fixing tests for Travis. 2013-01-04 03:19:38 +01:00
Jakub Roztocil
7817dfbbcc Fixing tests for Travis. 2013-01-04 03:09:21 +01:00
Jakub Roztocil
238b2e0441 Fixing tests for Travis. 2013-01-04 03:05:36 +01:00
Jakub Roztocil
a93d57b58b Fixed request/response session cookies.
Closes #113.
2013-01-04 02:59:05 +01:00
Jakub Roztocil
1481749c22 Use urlsplit instead of urlparse.
Closes #118.
2013-01-03 14:12:27 +01:00
Jakub Roztocil
53caf6ae72 Cleanup 2012-12-05 05:06:06 +01:00
Jakub Roztocil
8175366f27 PEP8 2012-12-05 04:39:56 +01:00
Jakub Roztocil
d87b2aa0e5 Added support for credentials in URL.
Closes #100 🍰
2012-11-08 22:29:54 +01:00
Jakub Roztocil
5d969852c7 Added --no-option's and made args more config-friendly. 2012-09-24 06:49:12 +02:00
Jakub Roztocil
e25d64a610 0.3.0 2012-09-21 05:50:01 +02:00
Jakub Roztocil
a41dd7ac6d Allow output redirection on Windows.
Closes #88.
2012-09-21 04:30:59 +02:00
Jakub Roztocil
4a6f32a0f4 Documented config.
Also renamed `default_content_type` to `implicit_content_type` .
2012-09-17 03:08:45 +02:00
Jakub Roztocil
548bef7dff Added tests for sessions. 2012-09-17 02:15:00 +02:00
Jakub Roztocil
da0eb7db79 Renamed --allow-redirects to --follow. 2012-09-07 11:58:39 +02:00
Jakub Roztocil
4c0d7d526f Added initial support for persistent sessions. 2012-08-17 23:30:47 +02:00
Jakub Roztocil
bf03937f06 Unified output processing options under --pretty.
* --pretty=none instead of --ugly
* --pretty=all instead of --pretty
* --pretty=colors instead of --colors
* --pretty=format instead of --format
2012-08-17 21:15:37 +02:00
Jakub Roztocil
4660da949f Fixed colorized output on Windows with Python 3.
Closes #87.
2012-08-17 06:35:18 +02:00
Jakub Roztocil
68640a81b3 Use CRLF for headers in the output. 2012-08-10 01:45:07 +02:00
Jakub Roztocil
c01dd8d64a Added exit status for timed-out requests. 2012-08-09 05:24:58 +02:00
Jakub Roztocil
76feea2f68 Added README reStructuredText validation. 2012-08-07 17:20:50 +02:00
Jakub Roztocil
22a10aec4a Added --colors and --format.
Closes #59 and #82.
2012-08-07 16:59:49 +02:00
Jakub Roztocil
f6724452cf Skip tests with redirects on Requests 0.13.6. 2012-08-07 15:08:28 +02:00
Jakub Roztocil
1fbe7a6121 Improved --debug. 2012-08-07 14:50:51 +02:00
Jakub Roztocil
dd2c89412c Compatibility with Requests 0.13.6. 2012-08-07 00:07:04 +02:00
Jakub Roztocil
44e409693b Set JSON Content-Type only with data even with -j. 2012-08-06 22:14:52 +02:00
Jakub Roztocil
4e58a3849a Added exit status constants, cleaned up main(). 2012-08-04 19:22:50 +02:00
Jakub Roztocil
c7657e3c4b Streamed terminal output
`--stream` can be used to enable streaming also with `--pretty` and to ensure
a more frequent output flushing.
2012-08-04 16:35:31 +02:00
Jakub Roztocil
52e46bedda Take advantage of streaming.
It's now possible to download huge files with HTTPie, and it's often faster than curl and wget!
2012-08-01 23:21:52 +02:00
Jakub Roztocil
00d85a4b97 Fallback to media subtype if the type is uknown.
Closes #81.
2012-08-01 17:37:23 +02:00
Jakub Roztocil
90d34ffd0d Added tests for binary request data. 2012-08-01 00:52:30 +02:00
Jakub Roztocil
923a8b71bd Revorked output
Binary now works everywhere. Also added `--output FILE` for Windows.
2012-07-30 10:58:16 +02:00
Jakub Roztocil
6eed0d92eb Better error messages. 2012-07-29 07:14:54 +02:00
Jakub Roztocil
f73bfea6b8 Validate "file fields (name@/path) require --form / -f". 2012-07-29 06:58:50 +02:00
Jakub Roztocil
f5bc081fda Send filenames with multipart/form-data file uploads. 2012-07-28 13:24:44 +02:00
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
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
f5cfd0143b Ensure that full querystring is printent with -v.
The `key==value` parameters weren't included in the Request-Line URL.

Also added tests.
2012-07-25 14:32:57 +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
fba3912f2e Fixed tests. 2012-07-23 19:49:38 +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
19f760450f Use local httpbin for all tests if available. 2012-07-21 14:37:05 +02:00