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

Update Docs:CLI related with Account Management #165

Merged
merged 7 commits into from
Sep 9, 2024

Conversation

sigmaith
Copy link
Contributor

@sigmaith sigmaith commented Sep 2, 2024

What this PR does / why we need it?

I have updated the CLI command information documentation following the changes related to the user-related CLI in yorkie-team/yorkie.

Any background context you want to provide?

This is related to this issue. yorkie-team/yorkie#983

What are the relevant tickets?

Fixes #

Checklist

  • Added relevant tests or not required
  • Didn't break anything

Summary by CodeRabbit

  • New Features

    • Updated the command syntax for logging into the server using the Yorkie CLI, enhancing security by prompting for the password interactively.
    • Introduced new commands for changing the password and deleting the account.
    • Updated the logout command to align with the new command structure.
  • Documentation

    • Improved clarity in documentation regarding the new login command, account creation, and security practices.

@CLAassistant
Copy link

CLAassistant commented Sep 2, 2024

CLA assistant check
All committers have signed the CLA.

Copy link

coderabbitai bot commented Sep 2, 2024

Warning

Rate limit exceeded

@hackerwins has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 22 minutes and 14 seconds before requesting another review.

How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

Commits

Files that changed from the base of the PR and between b55513f and 09d12bb.

Walkthrough

The command syntax for logging into the Yorkie server via the CLI has been updated. The password parameter has been removed from the command line, and users will now be prompted to enter their password interactively. The logout command has been modified to align with the new structure, and new commands for changing the password and deleting the account have also been introduced, enhancing overall functionality.

Changes

File Change Summary
docs/cli.mdx Updated login command syntax to $ yorkie user login -u <username> --rpc-addr api.yorkie.dev:443. Removed password parameter from command line and added instruction for interactive password entry. Updated logout command to $ yorkie user logout. Introduced new commands for changing password and deleting account.

Poem

In the meadow, hopping free,
A new command brings joy to me!
No more typing passwords in sight,
Just a prompt, oh what a delight!
Security’s the name of the game,
With each login, it’s never the same! 🐇✨


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between d6ec525 and 01822c4.

Files selected for processing (1)
  • docs/cli.mdx (1 hunks)
Additional comments not posted (2)
docs/cli.mdx (2)

115-116: LGTM!

The changes to the login command are approved. The new command simplifies the login process and improves security by not exposing the password in the command line.


117-121: LGTM!

The added information about the password prompt enhances the user experience by setting the right expectations. The information is clear and consistent with the actual behavior of the CLI.

Copy link
Contributor

@chacha912 chacha912 left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution. Please check the comments below.

  1. The command $ yorkie logout should be updated to $ yorkie user logout.
  2. Please include usage instructions for the following commands:
    • yorkie user delete-account -u <username>
    • yorkie user change-password -u <username>
  3. Ensure proper spacing throughout the documentation to improve readability.

@sigmaith sigmaith changed the title Update CLI login info Update CLI related with user info Sep 2, 2024
coderabbitai[bot]

This comment was marked as resolved.

@sigmaith sigmaith requested a review from chacha912 September 2, 2024 09:07
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Outside diff range, codebase verification and nitpick comments (1)
docs/cli.mdx (1)

137-161: LGTM with a minor suggestion!

The changes to the logout command and the addition of the change password and delete account commands look good. They enhance the CLI's functionality and user experience.

The static analysis tool has flagged a style issue about repetitive phrasing in the change password and delete account sections. Consider rephrasing the following sentences to add variety to the writing:

  • "If you want to change your password, you can use the command change-password."
  • "If you want to delete your account, you can use the command delete-account."

For example, you could rephrase them as:

  • "To change your password, use the change-password command."
  • "To delete your account, use the delete-account command."
Tools
LanguageTool

[style] ~146-~146: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...UgofYg ``` ### Change Password If you want to change your password, you can use the c...

(REP_WANT_TO_VB)


[style] ~154-~154: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...ssword: Enter New Password: ``` If you want to delete your account, you can use the co...

(REP_WANT_TO_VB)

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 845c02c and 3d2f920.

Files selected for processing (1)
  • docs/cli.mdx (2 hunks)
Additional context used
LanguageTool
docs/cli.mdx

[style] ~146-~146: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...UgofYg ``` ### Change Password If you want to change your password, you can use the c...

(REP_WANT_TO_VB)


[style] ~154-~154: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...ssword: Enter New Password: ``` If you want to delete your account, you can use the co...

(REP_WANT_TO_VB)

Additional comments not posted (3)
docs/cli.mdx (3)

115-116: LGTM!

The changes to the login command look good. Removing the password parameter from the command line and prompting for it interactively improves security.


119-119: LGTM!

The note about the password entry is a helpful addition for users.


123-123: LGTM!

The note about logging in to a self-hosted server is a helpful addition for users.

@hackerwins
Copy link
Member

@sigmaith Could you sign up the CLA?

@sigmaith
Copy link
Contributor Author

sigmaith commented Sep 3, 2024

Oh, I missed it. I just signed it!

@hackerwins
Copy link
Member

@sigmaith
In the last commit, the interface was changed by removing user. Can you reflect this in the document?
yorkie-team/yorkie@dffc44c

@sigmaith
Copy link
Contributor Author

sigmaith commented Sep 9, 2024

Thank you for mention. I'll do it.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 3

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 3d2f920 and 094755e.

Files selected for processing (1)
  • docs/cli.mdx (2 hunks)
Additional context used
LanguageTool
docs/cli.mdx

[style] ~155-~155: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...ofYg ``` ### Change Password If you want to change your password, you can use the c...

(REP_WANT_TO_VB)


[grammar] ~155-~155: Use a predeterminer before a determiner. Did you mean “both The”? Possibly, a hyphen is missing, as in ‘an all-dance show’.
Context: ...word, you can use the command passwd. The both passwords will not be visible, which is...

(DT_PDT)


[style] ~166-~166: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...sword: ``` ### Delete Account If you want to delete your account, you can use the co...

(REP_WANT_TO_VB)


[grammar] ~177-~177: A verb may be missing. Did you mean “it has”, “it is” or “it does”?
Context: ...operation fails, please double-check if it the account exists and whether the pass...

(IF_YOU_ANY)

Additional comments not posted (1)
docs/cli.mdx (1)

142-152: Logout command documentation updated.

The logout command documentation has been updated to reflect the new structure. This change aligns with the modifications made to the login process, ensuring consistency across the documentation.

docs/cli.mdx Outdated Show resolved Hide resolved
docs/cli.mdx Outdated Show resolved Hide resolved
docs/cli.mdx Outdated Show resolved Hide resolved
@sigmaith sigmaith self-assigned this Sep 9, 2024
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 094755e and 934a1d2.

Files selected for processing (1)
  • docs/cli.mdx (2 hunks)
Additional context used
LanguageTool
docs/cli.mdx

[style] ~155-~155: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...ofYg ``` ### Change Password If you want to change your password, you can use the c...

(REP_WANT_TO_VB)


[style] ~166-~166: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...sword: ``` ### Delete Account If you want to delete your account, you can use the co...

(REP_WANT_TO_VB)

Additional comments not posted (2)
docs/cli.mdx (2)

117-121: Update login command documentation to reflect interactive password entry.

The documentation has been updated to reflect the new login command syntax which enhances security by not exposing the password in the command line. This is a significant improvement in terms of security best practices.


142-144: Logout command documentation updated.

The logout command documentation has been updated to reflect the new structure. This change aligns with the login command's security enhancements.

docs/cli.mdx Outdated Show resolved Hide resolved
docs/cli.mdx Outdated Show resolved Hide resolved
@sigmaith sigmaith changed the title Update CLI related with user info Update Docs:CLI related with Account Management Sep 9, 2024
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 3

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 934a1d2 and b55513f.

Files selected for processing (1)
  • docs/cli.mdx (2 hunks)
Additional context used
LanguageTool
docs/cli.mdx

[style] ~149-~149: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...ofYg ``` ### Change Password If you want to change your password, you can use the c...

(REP_WANT_TO_VB)


[style] ~160-~160: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...sword: ``` ### Delete Account If you want to delete your account, you can use the co...

(REP_WANT_TO_VB)

docs/cli.mdx Show resolved Hide resolved
docs/cli.mdx Show resolved Hide resolved
docs/cli.mdx Show resolved Hide resolved
@hackerwins hackerwins force-pushed the change-cli-about-user branch from b55513f to b6cff07 Compare September 9, 2024 05:59
@hackerwins hackerwins force-pushed the change-cli-about-user branch from b6cff07 to 09d12bb Compare September 9, 2024 06:00
@hackerwins hackerwins self-requested a review September 9, 2024 06:01
Copy link
Member

@hackerwins hackerwins left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution.

@hackerwins hackerwins merged commit 286d5cb into main Sep 9, 2024
2 checks passed
@hackerwins hackerwins deleted the change-cli-about-user branch September 9, 2024 06:01
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.

4 participants