Skip to content

Add r.rterm.preferredConsoles for R console selection from PATH#1625

Open
BerriJ wants to merge 1 commit into
REditorSupport:masterfrom
BerriJ:master
Open

Add r.rterm.preferredConsoles for R console selection from PATH#1625
BerriJ wants to merge 1 commit into
REditorSupport:masterfrom
BerriJ:master

Conversation

@BerriJ

@BerriJ BerriJ commented Jul 11, 2025

Copy link
Copy Markdown

This PR will close #1347

It adds a new option r.rterm.preferredConsoles which defaults to ["R"]. You can specify you preferred R consoles like this:

Screenshot_2026-07-20_15-06-22

The extension will open the first item in that list that it finds on the users PATH. However, if r.rterm.linux is specified, it will use that path (given that this is a more precise setting, I suggest we give precedence to it).

Thank you so much for this project. I'm a daily user since many years.

Best,
BerriJ

@eitsupi

eitsupi commented Jan 31, 2026

Copy link
Copy Markdown
Contributor

Would it make more sense to make R and radian selectable via an Enum?

I recently created the arf console that can be used instead of radian, and I have personally switched from radian.
https://github.com/eitsupi/arf

@BerriJ

BerriJ commented Feb 3, 2026

Copy link
Copy Markdown
Author

Would it make more sense to make R and radian selectable via an Enum?

I recently created the arf console that can be used instead of radian, and I have personally switched from radian. https://github.com/eitsupi/arf

This would also work. You mean something like:

preference = [arf, radian, r]

And then this extension would search the PATH for arf, radian, and r, and use the first it finds?

This would be a very flexible solution.

@grantmcdermott

Copy link
Copy Markdown
Contributor

+1 on arf support. I've been using it for the last few days and it's solved several long-standing radian headaches for me.

@grantmcdermott

Copy link
Copy Markdown
Contributor

Fwiw, radian is no longer being (actively) maintained. The package readme explicitly recommends switching over to arf:

radian is no longer under active development. While I may address critical or obvious bugs, no new features will be added. If you are looking for an active alternative, I recommend checking out arf by @eitsupi.

@BerriJ

BerriJ commented Apr 16, 2026

Copy link
Copy Markdown
Author

@randy3k Do you have an idea how to proceed here? I could happily adjust the PR to use arf instead of radian, now that radian is not supported anymore.
I'm also happy to implement other ideas. The core feature I'd need is that vscode-R picks the specified R executable from the PATH, and we do not have to hardcode the specific path in the settings. As discussed here: #1347

I'm also not shure if this PR is completely independent from #1684. Maybe you could tell us something about the big picture here. Many thanks in advance :)

@randy3k

randy3k commented Jun 26, 2026

Copy link
Copy Markdown
Member

We shouldn't reply on radian anymore (python is not really a good platform for development an R console).

I am not oppposing to the idea of "prefer arf". Though I am not sure if we want to "hard code" arf at the same time. A setting like "prefer this program if found" may be more useful?

Add `r.rterm.preferredConsoles` (string array, default `["R"]`), an
ordered list of R console executable names to search for on PATH when no
explicit terminal path (e.g. `r.rterm.linux`) is set. The first entry
found on PATH is used, enabling users to prefer radian, ark, or any
other console over plain R without specifying a full path.
@BerriJ

BerriJ commented Jul 20, 2026

Copy link
Copy Markdown
Author

We shouldn't reply on radian anymore (python is not really a good platform for development an R console).

I am not oppposing to the idea of "prefer arf". Though I am not sure if we want to "hard code" arf at the same time. A setting like "prefer this program if found" may be more useful?

Thanks for your feedback. I agree, hardcoding R consoles is not ideal. I updated the PR and now the new setting takes a list of console names that the user prefers. So you can specify for example ["arf", "radian", "R"] and it will use arf, if available on the PATH, otherwise it falls back to "radian" and so on. Would you mind taking a look at this?

I'll gladly adjust this further, based on your feebdack.

@BerriJ BerriJ changed the title Default to radian console if rterm.preferRadian is true Add r.rterm.preferredConsoles for R console selection from PATH Jul 21, 2026
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.

Search for r.rterm.linux/mac on system PATH

4 participants