Skip to content

fix(taskfiles)!: Remove quotes when evaluating EXTRA_ARGS in CMake tasks, properly treating them as command flags. - #66

Merged
davidlion merged 5 commits into
y-scope:mainfrom
PacificViking:john_extra_args_fix
Jun 16, 2025
Merged

fix(taskfiles)!: Remove quotes when evaluating EXTRA_ARGS in CMake tasks, properly treating them as command flags.#66
davidlion merged 5 commits into
y-scope:mainfrom
PacificViking:john_extra_args_fix

Conversation

@PacificViking

@PacificViking PacificViking commented Jun 11, 2025

Copy link
Copy Markdown
Contributor

Description

An empty string passed in EXTRA_ARGS throws an error in the previous version. This is undesirable for conditional extra arguments passed to cmake:install.

Checklist

  • The PR satisfies the contribution guidelines.
  • This is a breaking change and that has been indicated in the PR title, OR this isn't a
    breaking change.
  • Necessary docs have been updated, OR no docs need to be updated.

Validation performed

Ran linters and tests.

Summary by CodeRabbit

  • Bug Fixes
    • Improved handling of extra arguments in the install process to ensure correct command-line parsing.
  • New Features
    • Added support for specifying installation components to customize the install process.

@PacificViking
PacificViking requested a review from a team as a code owner June 11, 2025 11:41
@coderabbitai

coderabbitai Bot commented Jun 11, 2025

Copy link
Copy Markdown
Contributor

Walkthrough

The update adds a new COMPONENT variable to the install task in cmake.yaml and conditionally includes a --component option in the cmake --install command. It also changes how EXTRA_ARGS elements are rendered by removing surrounding double quotes.

Changes

File(s) Change Summary
exports/taskfiles/utils/cmake.yaml Added COMPONENT variable; conditionally appended --component option; removed quotes around EXTRA_ARGS elements in the install command.

Possibly related PRs

Suggested reviewers

  • kirkrodrigues

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ 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.
    • Explain this complex logic.
    • 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 explain this code block.
    • @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 explain its main purpose.
    • @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.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

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 generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this 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.

@davidlion davidlion left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@PacificViking

Copy link
Copy Markdown
Contributor Author

It doesn't seem like CMake supports passing multiple --components arguments in install.

@PacificViking
PacificViking requested a review from davidlion June 12, 2025 10:29

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

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: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c4bfd39 and 245a1ea.

📒 Files selected for processing (1)
  • exports/taskfiles/utils/cmake.yaml (2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (2)
  • GitHub Check: unit-tests (ubuntu-24.04)
  • GitHub Check: unit-tests (ubuntu-22.04)
🔇 Additional comments (1)
exports/taskfiles/utils/cmake.yaml (1)

127-127: Verify conditional --component injection
Double-check that the folded >- block preserves spacing/newlines correctly when .COMPONENT is set or empty. Test the rendered command to ensure --component isn’t concatenated or omitted unexpectedly.

Comment thread exports/taskfiles/utils/cmake.yaml
Comment thread exports/taskfiles/utils/cmake.yaml Outdated
Comment on lines +110 to +111
COMPONENT: >-
{{default "" .COMPONENT}}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🧹 Nitpick (assertive)

Sync documentation for new COMPONENT variable
The newly added COMPONENT var isn’t reflected in the install task’s @param block. Please add an entry like @param {string} [COMPONENT] to the comment header to keep docs accurate.

🤖 Prompt for AI Agents
In exports/taskfiles/utils/cmake.yaml around lines 110 to 111, the new COMPONENT
variable is missing from the install task's @param documentation block. Add a
line `@param {string} [COMPONENT]` to the comment header of the install task to
document this new variable and keep the documentation accurate and up to date.

@davidlion davidlion left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Sorry, I should have looked into --components closer. Your original solution was correct. Could you:

  1. revert your change (sorry)
  2. generalize the solution to all the cmake commands (unquote the other range EXTRA_ARGS usage)

@PacificViking
PacificViking requested a review from davidlion June 16, 2025 02:07
@PacificViking

Copy link
Copy Markdown
Contributor Author

Sorry, I forgot to request review again. Pretty sure the unit tests failing is a temporary internet problem, since they worked locally.

@davidlion davidlion changed the title fix(taskfiles): Remove unnecessary double quotes when evaluating EXTRA_ARGS in cmake:install fix(taskfiles)!: Remove quotes when evaluating EXTRA_ARGS in CMake tasks, properly treating them as command flags. Jun 16, 2025
@davidlion
davidlion merged commit fd7c42d into y-scope:main Jun 16, 2025
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