The two commands I use are listed in my post: env:Path in powershell and Sys.getenv("PATH") in R. So I'm not sure what you are asking for. I included the complete output.
To test, I create a new "package" project, then without any modifications, I try to "Build".
In this case the "Build" message is
==> Rcmd.exe INSTALL --preclean --no-multiarch --with-keep.source test
* installing to library 'C:/Users/hnelson3/AppData/Local/R/win-library/4.2'
* installing *source* package 'test' ...
** using staged installation
** R
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (test)
WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding:
https://cran.rstudio.com/bin/windows/Rtools/
Of course I also do not want to install to the C:/ drive but will try to fix that later.
pkgbuild::find_rtools()
WARNING: Rtools is required to build R packages, but no version of Rtools compatible with R 4.2.2 was found. (Only the following incompatible version(s) of Rtools were found: 4.3)
Please download and install Rtools 4.2 from https://cran.r-project.org/bin/windows/Rtools/ or https://www.r-project.org/nosvn/winutf8/ucrt3/.
>
Thanks. Congratulations, you are more useful thanchat.openai.com/chat Now I just have to figure out how to get the builds to go to D: instead of C:.
==> Rcmd.exe INSTALL --preclean --no-multiarch --with-keep.source test
* installing to library 'C:/Users/hnelson3/AppData/Local/R/win-library/4.2'
This is because it is a virtual machine and the C: drive is very limited. I guess every virtual machine on this system has to share the C: drive for critical OS stuff, not my R package libraries.