lukesampson/scoop — pull request #194 by scottwillmoore (2014-11-04 10:55:15+00:00)
Title: Add support for cookies

The support is there and has been tested fairly well, in most situations. Unfortunately the implementation is a bit of a hack at the moment, but at least it is working. A new `$cookie` has to be passed through the `dl` functions, because of the lack of a `$manifest` and `$arch` object being passed through therefore the `$cookie` object has to be initialised earlier.

The syntax can be used like so, here are a few examples. Changes may need to be made.

````json
{
"url": "https://download.com/file.zp",
"cookie": {
"license": "accept"
}
}
````

````json
{
"url": "https://download.com/file.zip",
"cookie": {
"license": "accept",
"allow-download": "sure"
}
}
````

````json
{
"url": [
"https://download.com/file.zip",
"https://download.com/file2.zip"
],
"cookie": [
{ "license": "accept" },
{ "allow-download": "sure" }
]
}
````

````json
{
"architecture": {
"64bit": {
"url": "https://download.com/file.zip",
"cookie": {
"license": "accept",
}
}
}
}
````