Skip to content

Fix packaging step for GitHub installs with a subdirectory#290

Merged
gaborcsardi merged 9 commits into
r-lib:mainfrom
paleolimbot:fix-pkg-subdir
Nov 22, 2022
Merged

Fix packaging step for GitHub installs with a subdirectory#290
gaborcsardi merged 9 commits into
r-lib:mainfrom
paleolimbot:fix-pkg-subdir

Conversation

@paleolimbot
Copy link
Copy Markdown
Contributor

@paleolimbot paleolimbot commented Nov 18, 2022

Fixes r-lib/pak#431 locally (but I'm rather unfamiliar with the consequences this might have for other types of package installs).

If it's helpful, my local tests were:

pak::pkg_install("apache/arrow-nanoarrow/r")

...and

pak::pkg_install("paleolimbot/narrow")

paleolimbot and others added 6 commits November 18, 2022 09:25
Including updating the cache, and selecting the
right package from the cache.
A leftover package tree might be in the cache directory,
and then a later install picks that up instead of the
binary package file from the cache.
Take the subdirrectory from the metadata, that is
available when using a lock file.
@gaborcsardi
Copy link
Copy Markdown
Member

Thanks! I had to understand this again, so I refactored it a bit, fixed another issue, and added tests.

Will merge once the CI is green.

Not needed any more, because we use a fake GH
for testing.
No reason that we should keep them, I think.
@gaborcsardi gaborcsardi merged commit ea7f223 into r-lib:main Nov 22, 2022
@gaborcsardi
Copy link
Copy Markdown
Member

Thanks again!

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.

pkg_install() fails for GitHub package in subdirectory

2 participants