Skip to content

fix: manually source .Rprofile etc. after R initialization on Windows#20

Merged
eitsupi merged 1 commit intomainfrom
fix/windows-rprofile-loading
Jan 31, 2026
Merged

fix: manually source .Rprofile etc. after R initialization on Windows#20
eitsupi merged 1 commit intomainfrom
fix/windows-rprofile-loading

Conversation

@eitsupi
Copy link
Copy Markdown
Owner

@eitsupi eitsupi commented Jan 31, 2026

Fix #18

On Windows, R's built-in profile loading is disabled during initialization
(load_init_file = R_FALSE) for compatibility with globalCallingHandlers().
This commit adds manual sourcing of site and user R profiles after R
initialization completes.

- Add arf-harp/src/startup.rs with profile sourcing functions
- Use sys.source() wrapped in R_ToplevelExec for safe execution
- Respect --no-site-file, --no-init-file, and --vanilla flags
- Only applies to Windows (#[cfg(windows)]) since Unix handles this automatically

Fixes #18

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@eitsupi eitsupi merged commit eb2e913 into main Jan 31, 2026
5 checks passed
@eitsupi eitsupi deleted the fix/windows-rprofile-loading branch January 31, 2026 14:10
@eitsupi eitsupi added this to the 0.1.2 milestone Jan 31, 2026
eitsupi added a commit that referenced this pull request Feb 1, 2026
- [Unreleased] history import (#31), :info enhancements (#29)
- [0.2.0-beta.1] vi mode indicator (#23), Windows Rprofile fix (#20)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
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.

arf ignore the user config file .Rprofile on Windows

1 participant