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

Move reusable options to a dedicated package #386

Merged
merged 18 commits into from
May 19, 2022

Conversation

qweeah
Copy link
Contributor

@qweeah qweeah commented May 16, 2022

This PR

  1. Adds a bug fix for empty ca file path option, as well as a unit test for it.
  2. Adds a package which groups CMD options used in different senarios.

Resolves #385

Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
@qweeah qweeah marked this pull request as draft May 17, 2022 01:42
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
@qweeah qweeah marked this pull request as ready for review May 17, 2022 04:15
@qweeah qweeah changed the title Move reusable options to a common file Move reusable options to a dedicated package May 17, 2022
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Copy link
Contributor

@shizhMSFT shizhMSFT left a comment

Choose a reason for hiding this comment

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

It would be better if all exported methods / types are documented, even if they are internal.

internal/http/certificate.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/applier.go Show resolved Hide resolved
cmd/oras/login.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/credential.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/credential.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/tls.go Outdated Show resolved Hide resolved
cmd/oras/login.go Show resolved Hide resolved
cmd/oras/login.go Outdated Show resolved Hide resolved
cmd/oras/login.go Outdated Show resolved Hide resolved
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
cmd/oras/internal/option/applier.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/applier.go Show resolved Hide resolved
cmd/oras/login.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/tls.go Outdated Show resolved Hide resolved
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
@qweeah qweeah requested a review from shizhMSFT May 19, 2022 04:45
cmd/oras/internal/option/remote.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/remote.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/remote.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/remote.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/remote_test.go Outdated Show resolved Hide resolved
cmd/oras/internal/option/remote_test.go Outdated Show resolved Hide resolved
cmd/oras/login.go Outdated Show resolved Hide resolved
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Signed-off-by: Billy Zha <jinzha1@microsoft.com>
Copy link
Contributor

@shizhMSFT shizhMSFT left a comment

Choose a reason for hiding this comment

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

LGTM

@shizhMSFT shizhMSFT merged commit db86d1c into oras-project:main May 19, 2022
@qweeah qweeah deleted the common-opts branch August 25, 2023 03:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move common options to a common file
3 participants