Skip to content

Pass Rscript options through ir run - #13

Merged
t-kalinowski merged 2 commits into
mainfrom
pass-vanilla-through-ir-run
Jun 3, 2026
Merged

t-kalinowski merged 2 commits into
mainfrom
pass-vanilla-through-ir-run

Conversation

@t-kalinowski

Copy link
Copy Markdown
Member

Summary

  • Allow ir run to accept leading Rscript options such as --vanilla and forward them to the phase-2 user-code invocation.
  • Keep trailing arguments after the script path as script arguments.
  • Update the CLI help and README examples to document the new invocation shape.
  • Add a regression test covering option forwarding through the fake Rscript harness.

@t-kalinowski
t-kalinowski merged commit 3e0e6ec into main Jun 3, 2026
4 checks passed
t-kalinowski added a commit that referenced this pull request Jun 4, 2026
* Add design spec for ir run on Quarto documents

* Rebase spec onto merged #14 and align arg handling with #13

* Refine quarto run spec per design review

Resolve quarto-check timing, QUARTO_R conditional setting, comma-arg
rejection, extensionless-script dispatch, and frontmatter-fence edges.

* Add implementation plan for ir run on Quarto documents

* Ignore roborev snapshot directory

* Fix two plan-doc defects from branch design review

Comma-bearing Rscript options are now rejected in cmd_run before phase-1
resolution rather than inside run_quarto. As written, resolution ran first, so
the comma-rejection test (whose fake resolver fails loudly) never reached the
check and its "resolver never runs" comment was false; failing fast also avoids
resolving packages for a run that can never launch.

Multi-filter `cargo test` verification commands now pass filters after `--`;
cargo's [TESTNAME] takes a single value and errored on the second filter.

* Add IR_QUARTO seam and Windows/.Rmd test coverage

Selecting the quarto executable now mirrors the IR_RSCRIPT seam: IR_QUARTO if
set, else bare `quarto` on PATH. This closes a real Windows gap surfaced while
adding the reviewer-requested Windows coverage — Rust's bare-name PATH search
resolves only quarto.exe (it does not consult PATHEXT), so a dev quarto.cmd was
unreachable; IR_QUARTO with a full path selects it (and lets tests fake quarto
without touching PATH). Also folds in the spec wording precision (R_LIBS is the
only env var conditional on dependency resolution, not the sole conditional one)
and adds explicit .Rmd-routing and Windows run_quarto integration tests.

* Parse frontmatter from the ir: key for nested documents

* Extract the leading YAML block from Quarto documents

* Add run_quarto and its QUARTO_R and launch helpers

* Dispatch .qmd and .Rmd targets to quarto render

* Document Quarto document support

* Support r-version/exclude-newer for Quarto documents after rig rebase

Rebasing the Quarto support onto #18 (rig-backed R resolution) means a
Quarto document's `ir:` block can now declare `r-version` and
`exclude-newer` alongside `dependencies`, exactly as a script does.
`rscript_for_spec` selects the rig R, and because that one Rscript feeds
both phase-1 resolution and `QUARTO_R`, the document renders with the same
R it was resolved against — the same-R invariant the design called for,
now satisfied through rig rather than a bare PATH `Rscript`.

The merged help/README text kept the pre-#18 frontmatter keys; correct the
Quarto README example to `r-version`/`exclude-newer` and note that the
`ir:` block accepts the same fields as a script. Add a cfg(unix) test that
fakes rig + quarto to prove an `ir.r-version` document pins QUARTO_R to the
rig-selected Rscript, and gate the merged unix-only `prepend_path` helper so
`clippy --all-targets` stays clean on Windows. Plan and design docs get an
adaptation note recording the rig delta.

* Keep agentic planning docs and roborev config out of the PR

The implementation plan, design spec, and .roborev gitignore entry are
contributor-side tooling artifacts, not part of the feature. Drop them
from the branch so the upstream diff is code, tests, README, and example
only. They remain in local history and on the backup branch.

* Extract Quarto helpers into module

---------

Co-authored-by: Tomasz Kalinowski <kalinowskit@gmail.com>
@t-kalinowski
t-kalinowski deleted the pass-vanilla-through-ir-run branch July 7, 2026 12:48
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.

1 participant