Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding support for persistant cookies via cookie jar argument. #149

Merged
merged 6 commits into from
Dec 3, 2013

Conversation

cphoover
Copy link
Contributor

@cphoover cphoover commented Dec 2, 2013

This adds support for persistent cookies across requests by adding a

--cookie-jar=cookies.json

argument switch to the command.
Implemented with fs phantom module, cookies are serialized as JSON.

@@ -62,6 +63,8 @@ var phantomas = function(params) {
// parse script CLI parameters
this.params = params;

this.cookieJar = params['cookie-jar'] || false;

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use tabs for indenting :)

@macbre
Copy link
Owner

macbre commented Dec 2, 2013

@cphoover, nice one!

Looks fine. I've left some minor inline comments.

@ghost ghost assigned macbre Dec 2, 2013
@cphoover
Copy link
Contributor Author

cphoover commented Dec 2, 2013

Ok will fix up and send it back to you, when I get back from work.

@cphoover cphoover closed this Dec 2, 2013
@macbre macbre reopened this Dec 2, 2013
@macbre
Copy link
Owner

macbre commented Dec 3, 2013

@cphoover, thanks for the fixes. I'll take a look at this later today and merge it.

@cphoover
Copy link
Contributor Author

cphoover commented Dec 3, 2013

cool

macbre added a commit that referenced this pull request Dec 3, 2013
Adding support for persistant cookies via cookie jar argument.
@macbre macbre merged commit d977a3c into macbre:master Dec 3, 2013
macbre added a commit that referenced this pull request Dec 18, 2013
This reverts commit d977a3c, reversing
changes made to e1cf972.
@macbre macbre mentioned this pull request Dec 18, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants