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

fix(web): broken links on homepage resolving issue #384 #385

Merged
merged 1 commit into from
Nov 18, 2024

Conversation

Wrench56
Copy link
Contributor

@Wrench56 Wrench56 commented Nov 18, 2024

This resolves issue #384 fixing the broken links.

Summary by CodeRabbit

  • Documentation
    • Updated links in the "Next steps" section of the Commitlint documentation for improved clarity and accuracy.
    • Adjusted resources for "Run the lint" and "Check the Rules" cards to direct users to the correct guides.

Copy link

coderabbitai bot commented Nov 18, 2024

Walkthrough

The changes involve updates to the index.mdx file concerning the Commitlint documentation. While the title and description remain the same, modifications are made primarily in the "Next steps" section, where links for the "Run the lint" and "Check the Rules" cards have been altered to direct users to more accurate resources.

Changes

File Change Summary
web/src/content/docs/index.mdx Updated links in the "Next steps" section: changed CLI guide link to /commitlint-rs/setup/installation and rules links to /commitlint-rs/rules/body-empty.

Poem

In the garden of code, where changes bloom,
Links now guide us, dispelling the gloom.
With a hop and a skip, to the right paths we go,
Commitlint's wisdom, now clearer to show! 🐇✨


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>, please review it.
    • 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 gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @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: 2

🧹 Outside diff range and nitpick comments (2)
web/src/content/docs/index.mdx (2)

34-34: Consider linking to rules overview instead of specific rule

The link now points to a specific rule (body-empty) rather than the rules overview page. This might not provide the best user experience for new users who want to browse all available rules first.

Consider linking to a rules index or overview page instead:

-    rules](/commitlint-rs/rules/body-empty) for more information.
+    rules](/commitlint-rs/rules) for more information.

30-38: Consider implementing a clearer documentation structure

The current link updates fix the broken links but could benefit from a more intuitive documentation structure:

  1. Installation/Setup guide for getting started
  2. Rules overview page listing all available rules
  3. Dedicated configuration guide for customization

This would create a more natural flow for users: install → understand rules → customize.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 246a1d3 and 2dad636.

📒 Files selected for processing (1)
  • web/src/content/docs/index.mdx (1 hunks)

</Card>
<Card title="Customize your rules" icon="setting">
Edit commitlint configurations to customize your rules. See [the
rules](/commitlint-rs/guide/rules) for more information.
rules](/commitlint-rs/rules/body-empty) for more information.
Copy link

Choose a reason for hiding this comment

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

🛠️ Refactor suggestion

Link doesn't match the card's context

The "Customize your rules" card should ideally point to documentation about rule configuration rather than a specific rule definition. This would better align with the card's purpose of helping users customize their commitlint configuration.

Consider updating the link to point to configuration documentation:

-    rules](/commitlint-rs/rules/body-empty) for more information.
+    configuration](/commitlint-rs/guides/configuration) for more information.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
rules](/commitlint-rs/rules/body-empty) for more information.
configuration](/commitlint-rs/guides/configuration) for more information.

@@ -27,15 +27,15 @@ import { Card, CardGrid } from "@astrojs/starlight/components";
</Card>
<Card title="Run the lint" icon="rocket">
Run `commitlint` to lint your commit messages. See [the
guides](/commitlint-rs/guides/cli) about the CLI.
guides](/commitlint-rs/setup/installation) about the CLI.
Copy link

Choose a reason for hiding this comment

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

💡 Codebase verification

The link path in the documentation is incorrect

The link /commitlint-rs/setup/installation is incorrect as the actual documentation file is located at /commitlint-rs/setup/install. This needs to be updated to match the existing file structure.

  • In web/src/content/docs/index.mdx, line 30: Change /commitlint-rs/setup/installation to /commitlint-rs/setup/install
🔗 Analysis chain

Verify the new installation guide path

The link has been updated from CLI guides to installation documentation. Let's verify that this new path exists and is the intended destination.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Check if the new installation guide path exists in the documentation
# and if there are any references to the old CLI guide path

# Check for the existence of the new installation guide
fd -e mdx -e md "installation.mdx?" "web/src/content/docs/setup"

# Check if there are any remaining references to the old CLI guide path
rg -l "guides/cli" "web/src/content/docs"

Length of output: 104


Script:

#!/bin/bash
# Let's try a broader search to understand the documentation structure

# Find all MDX/MD files in the docs directory
fd -e mdx -e md . "web/src/content/docs"

# Search for any files containing "installation" in their content
rg -l "installation" "web/src/content/docs"

# Search for any files containing "cli" in their content
rg -l "cli" "web/src/content/docs"

Length of output: 1681


Script:

#!/bin/bash
# Let's check the actual content of the installation-related files and index.mdx

# Check the content of install.md
cat "web/src/content/docs/setup/install.md"

# Check the content of index.mdx to see the context of links
cat "web/src/content/docs/index.mdx"

Length of output: 2441

Copy link
Owner

@KeisukeYamashita KeisukeYamashita left a comment

Choose a reason for hiding this comment

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

Thank you, LGTM!

@KeisukeYamashita KeisukeYamashita merged commit e63130c into KeisukeYamashita:main Nov 18, 2024
18 of 20 checks passed
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.

2 participants