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

archive/zip: improve Writer.Create documentation on how to add directories #24018

Closed
gonutz opened this issue Feb 21, 2018 · 6 comments
Closed
Labels
Documentation FrozenDueToAge help wanted NeedsFix The path to resolution is known, but the work has not been done.
Milestone

Comments

@gonutz
Copy link

gonutz commented Feb 21, 2018

I tried to add an empty folder to a zip.Writer with zip.Writer.Create. From the docs it is not clear how to do this. There is a google group post that provides the solution, which is to add a slash at the end of the path given to zip.Writer.Create.

I suggest adding this detail to the documentation comment on zip.Writer.Create, e.g. "... To create a folder instead of a file, add a trailing slash to the path.".

@bradfitz bradfitz added this to the Go1.11 milestone Feb 21, 2018
@bradfitz
Copy link
Contributor

/cc @dsnet

@bradfitz bradfitz changed the title archive/zip: improve documentation archive/zip: improve Writer.Create documentation on how to add directories Feb 21, 2018
@bradfitz bradfitz added help wanted NeedsFix The path to resolution is known, but the work has not been done. labels Feb 21, 2018
@gopherbot
Copy link

Change https://golang.org/cl/97057 mentions this issue: archive/zip: improve Writer.Create documentation on how to add directories

@gonutz gonutz closed this as completed Feb 25, 2018
@dsnet
Copy link
Member

dsnet commented Feb 25, 2018

Why did you close this issue?

@gonutz
Copy link
Author

gonutz commented Feb 25, 2018

The changeset contains the fix. I do not know how that Gerrit or review tool works, should I re-open the issue and let you guys close it?

@gonutz gonutz reopened this Feb 25, 2018
@ianlancetaylor
Copy link
Contributor

@gonutz The changelist says "Fixes #24018", so this issue will be automatically closed when the changelist is submitted. Best practice is to wait for that to happen, since the changelist might not be submitted for one reason or another. Thanks.

@gonutz
Copy link
Author

gonutz commented Feb 26, 2018

OK I see, thanks for the clarification.

@golang golang locked and limited conversation to collaborators Feb 26, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Documentation FrozenDueToAge help wanted NeedsFix The path to resolution is known, but the work has not been done.
Projects
None yet
Development

No branches or pull requests

5 participants