Setting repository for an internal repo

47 views
Skip to first unread message

Nick Jhirad

unread,
Apr 6, 2017, 2:08:35 PM4/6/17
to packrat-discuss
Hi Kevin,

I was using this walkthrough:


specifically, this example:

sashimiDescPath <- file.path(tempdir(), "sashimi", "DESCRIPTION")
cat("Repository: sushi", file = sashimiDescPath, append = TRUE, sep = "\n")

Here, that repository name corresponds to the name of the repo in the client's options file.

I can certainly work with that, but then I need to standardize the .Rprofile of every user to use the same repo names.
I would prefer not to do this unless is absolutely necessary.

Their repo names could be anything, what's important is the location of the repository.

Would it be possible to change this with packrat so that I could put a web address there instead?

Best,
Nick


Kevin Ushey

unread,
Apr 6, 2017, 2:35:25 PM4/6/17
to Nick Jhirad, packrat-discuss
Hi Nick,

You can also probably just use something like:

Repository: CRAN

but this still comes with the requirement that the 'repos' R option is set to point to (one or more) CRAN mirrors that can provide this package. It might also make sense for packrat to relax this restriction in the future (right now, we only look at CRAN-like repositories for packages which have a 'Repository:' key in their DESCRIPTION) but that's not implemented yet.

Best,
Kevin

--
You received this message because you are subscribed to the Google Groups "packrat-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to packrat-discuss+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Nick Jhirad

unread,
Apr 6, 2017, 3:18:33 PM4/6/17
to packrat-discuss, shap...@gmail.com
Hi Kevin,

So my internal repo is CRAN-like. 

A little background:

I wrote my own miniCRAN-like package https://github.com/shapenaji/cranium 
(Reinvented the wheel to get natural version control out of install.packages, a la `install.packages('cranium_0.1.0')` or `install.packages('cranium_0.2.0')`)
Works great with folks inside our network but it never set the "Repository" setting in the description files.  

We just moved from shiny-server to RStudio Connect, and now we need to get the server to recognize the local package repository.

I can't put these packages on github because they contain private information and methods. So using the github workaround won't fit my use case.

I'm trying to add the functionality to change the name of the repo, for an existing repo

However, if I use a name, like "sushi", then that name has to be standard on the server and the client. 
I need to also go into every user's profile and guarantee that they also name this file sushi, otherwise packrat won't work on their local.

If at all possible I'd like to avoid restricting what they can do with their project settings.

But it sounds like that's not possible yet, so for now I'll attempt to standardize the two.

Best,
Nick


To unsubscribe from this group and stop receiving emails from it, send an email to packrat-discu...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages