Let's say I want to use in my R package a development version of a dependency as it stands on a certain GitHub branch, but the additional complication is that it resides in a subdirectory.
For example, if I wanted to rely on the glmmTMB package from this branch, I can download it using remotes like so:
remotes::install_github("glmmTMB/glmmTMB@ci_tweaks", subdir = "glmmTMB")
If this package were not based in a subdirectory, I could have included the following in the DESCRIPTION file:
Remotes: glmmTMB/glmmTMB@ci_tweaks
But I don't know how to specify a subdirectory here to get the package.
You should know that remotes creates all needed DESCRIPTION file fields for you. So I run the
remotes::install_github("glmmTMB/glmmTMB@ci_tweaks", subdir = "glmmTMB")and thenpackageDescription("glmmTMB"). Check out how many Remote and Github connected fileds are added. There is e.g.RemoteSubdir: glmmTMBtoo.