-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Feat/ls headers #951
Feat/ls headers #951
Conversation
}, | ||
Marshalers: cmds.MarshalerMap{ | ||
cmds.Text: func(res cmds.Response) (io.Reader, error) { | ||
output := res.Output().(*LsOutput).Objects | ||
|
||
output := res.Output().(*LsOutput) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can get the request object and the options from the response here. Not sure if thats the right way to do it, but its what ive been doing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah that's the right way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so,
headers, _, err := res.Request().Option("headers").Bool()
here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah okay, will do.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed in 79f2792
@cryptix just fixed it! dont worry :) 👍 thanks for this PR! |
i'll squash (to make sure every commit passes) when these tests pass. |
- added tests for 'ipfs ls --headers' - comments from CR (opts) - sharness: fix ls test whitespace
Inspired by #372, this fixes #893 .