keyshade-xyz / keyshade

Realtime secret and configuration management tool, with the best in class security and seamless integration support
https://keyshade.xyz
Mozilla Public License 2.0
196 stars 96 forks source link

docs: Add documentation for project in CLI #466

Closed Allan2000-Git closed 6 days ago

Allan2000-Git commented 6 days ago

User description

Description

This PR adds documentation for the new project feature in the CLI, providing users with clear instructions on how to utilize this functionality effectively.

Fixes #456

Dependencies

No new dependencies introduced.

Future Improvements

Consider adding examples for common use cases of the scan feature in future documentation updates.

Mentions

@rajdip-b

Screenshots of relevant screens

N/A

Developer's checklist

If changes are made in the code:

Documentation Update


PR Type

Documentation


Description


Changes walkthrough πŸ“

Relevant files
Documentation
project.md
Add documentation for `project` command in CLI                     

docs/cli/project.md
  • Added comprehensive documentation for the project command in the CLI.
  • Detailed usage instructions for each subcommand: create, delete, fork,
    get, list-forks, list, sync, unlink, update.
  • Included options and arguments for each subcommand.
  • Provided examples for command usage.
  • +235/-0 

    πŸ’‘ PR-Agent usage: Comment /help "your question" on any pull request to receive relevant information

    codiumai-pr-agent-free[bot] commented 6 days ago

    PR Reviewer Guide πŸ”

    ⏱️ Estimated effort to review: 2 πŸ”΅πŸ”΅βšͺβšͺβšͺ
    πŸ§ͺ No relevant tests
    πŸ”’ No security concerns identified
    ⚑ No key issues to review
    codiumai-pr-agent-free[bot] commented 6 days ago

    PR Code Suggestions ✨

    CategorySuggestion                                                                                                                                    Score
    Best practice
    Provide a warning about the potential consequences of hard sync ___ **Add a note about the potential consequences of hard sync, such as overwriting local
    changes, to ensure users understand the implications of this option.** [docs/cli/project.md [183]](https://github.com/keyshade-xyz/keyshade/pull/466/files#diff-51dda6d0363b68d5edcb22cfc3132d3f133bf9ac2bc7c0d2233c9e10c4585b6bR183-R183) ```diff -Upserts a new copy of the parent onto the child. Defaults to soft sync. +Upserts a new copy of the parent onto the child. Defaults to soft sync. Note: Hard sync may overwrite local changes in the forked project. ``` - [ ] **Apply this suggestion**
    Suggestion importance[1-10]: 9 Why: This suggestion is crucial as it warns users about the potential data loss when using hard sync, which is important for preventing accidental overwrites.
    9
    Enhancement
    Add descriptions for each access level option to improve clarity ___ **Consider adding a brief description or example for each access level (GLOBAL,
    PRIVATE, INTERNAL) to help users understand the implications of each choice.** [docs/cli/project.md [63]](https://github.com/keyshade-xyz/keyshade/pull/466/files#diff-51dda6d0363b68d5edcb22cfc3132d3f133bf9ac2bc7c0d2233c9e10c4585b6bR63-R63) ```diff -Access level of the project. Defaults to PRIVATE. Choices are GLOBAL, PRIVATE, INTERNAL. +Access level of the project. Defaults to PRIVATE. Choices are: +- GLOBAL: Accessible to all users +- PRIVATE: Accessible only to project members +- INTERNAL: Accessible to all workspace members ``` - [ ] **Apply this suggestion**
    Suggestion importance[1-10]: 8 Why: The suggestion provides clear descriptions for each access level, which enhances user understanding and helps them make informed decisions when setting access levels.
    8
    Provide an explanation of project forking and its use cases ___ **Add a brief explanation of what forking a project means and its use cases to provide
    context for users who may be unfamiliar with the concept.** [docs/cli/project.md [81-86]](https://github.com/keyshade-xyz/keyshade/pull/466/files#diff-51dda6d0363b68d5edcb22cfc3132d3f133bf9ac2bc7c0d2233c9e10c4585b6bR81-R86) ```diff ## `fork` + +Forking a project creates a copy of an existing project in a different workspace, allowing you to make changes without affecting the original project. This is useful for collaborative work or experimenting with project modifications. ### Usage ```bash keyshade project fork [options] ``` ``` - [ ] **Apply this suggestion**
    Suggestion importance[1-10]: 8 Why: The suggestion adds valuable context for users unfamiliar with forking, enhancing the documentation's educational value and usability.
    8
    Add usage examples for common project operations ___ **Add examples for each subcommand to demonstrate their usage, making it easier for
    users to understand how to use the CLI.** [docs/cli/project.md [5-13]](https://github.com/keyshade-xyz/keyshade/pull/466/files#diff-51dda6d0363b68d5edcb22cfc3132d3f133bf9ac2bc7c0d2233c9e10c4585b6bR5-R13) ```diff # `project` The `project` command is used to manage projects within a workspace in Keyshade. It provides various subcommands to perform different operations on projects. ## Usage ```bash keyshade project [options] ``` +## Examples + +Create a new project: +```bash +keyshade project create my-workspace --name "My New Project" --description "A sample project" --access-level PRIVATE +``` + +List all projects in a workspace: +```bash +keyshade project list my-workspace +``` + +Update an existing project: +```bash +keyshade project update my-project --name "Updated Project Name" --description "Updated description" +``` + ``` - [ ] **Apply this suggestion**
    Suggestion importance[1-10]: 7 Why: Adding examples improves user comprehension and usability of the CLI by demonstrating practical usage scenarios, though it is not critical for functionality.
    7

    πŸ’‘ Need additional feedback ? start a PR chat