Re: Install a package from OSF

Shu Fai Cheung <[email protected]>
Newsgroups gmane.comp.lang.r.general
Message-ID <CAPVJd2UR_NH+Z0bYjwM02-bB99P-nXmxpHPOMzWCHfVm48A4cg@mail.gmail.com>
The file I uploaded to OSF is a source package. However, it seems that OSF
does not have a link of this form

"https://osf.io/...../pkg.tar.gz".

Instead, it is something like this:

"https://osf.io/abcde/download?view_only=abcdefg"

This link will prompt the browser to download the file. However, it is not
a direct URL to the file, as in "https://osf.io/...../pkg.tar.gz".

Regards,
Shu Fai


On Mon, Sep 29, 2025 at 12:10 AM Uwe Ligges <[email protected]>
wrote:

> You have to create a soiurce package via R CMD build (which has file
> ending tar.gz, by the wa), to make that work.
>
> Best,
> Uwe Ligges
>
>
> On 28.09.2025 14:53, Shu Fai Cheung wrote:
> > Hi All,
> >
> > I would like to let reviewers download and install a package from OSF. It
> > is for double-blind review, and so I need to create an anonymized version
> > at OSF. I can ask reviewers to download the file and install it locally.
> > However, the reviewers may not be familiar with this. Is it possible to
> do
> > this in one function call? For example, something like this, from the
> help
> > of remotes::install_url():
> >
> > remotes::install_url("https://github.com/hadley/stringr/archive/HEAD.zip
> ")
> >
> > I tried the following (the link is a fake one, just for illustration):
> >
> > remotes::install_url("https://osf.io/abcde/download?view_only=abcdefg")
> >
> > I confirmed in a browser that the link with "/download" added is a
> > direct link to download the file created by R CMD build.
> >
> > However, I got the following error:
> >
> > Error: Failed to install 'unknown package' from URL:
> >    Don't know how to decompress files with extension
> >
> > Is there another way to install a package directly from OSF?
> >
> > Regards,
> > Shu Fai
> >
> >       [[alternative HTML version deleted]]
> >
> > ______________________________________________
> > [email protected] mailing list -- To UNSUBSCRIBE and more, see
> > https://stat.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide
> https://www.R-project.org/posting-guide.html
> > and provide commented, minimal, self-contained, reproducible code.
>
>

	[[alternative HTML version deleted]]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.