From @purd|e@@ @end|ng |rom gm@||@com  Sat Feb  2 22:28:44 2019
From: @purd|e@@ @end|ng |rom gm@||@com (Abs Spurdle)
Date: Sun, 3 Feb 2019 10:28:44 +1300
Subject: [Rd] Runnable R packages
In-Reply-To: <CANVKczMRW=8kHvxA3WazD_sF_hTDfhkpXxAe-QBkxos69F0VmA@mail.gmail.com>
References: <a8d7658b8d70467987e724724667ad19@LNXP265MB1705.GBRP265.PROD.OUTLOOK.COM>
 <CANVKczMRW=8kHvxA3WazD_sF_hTDfhkpXxAe-QBkxos69F0VmA@mail.gmail.com>
Message-ID: <CAB8pepwO_PW+2N2ZS=iUWUBPxOSkoyEnPaVB7ZTgh_re5VJfWA@mail.gmail.com>

Creating an .exe file isn't necessarily difficult.
The main problems are that you have to write and compile the C (or other)
files.
Otherwise, the complexity depends on the level of Inter Process
Communication that's required.

Simply starting R with some initial conditions, is easy.
Even if you want to prompt the user to install missing packages, it isn't
necessarily difficult.

It would be possible to take this one step further, and write an .exe
builder, that automates the process of creating .exe files.
Obviously, it would require a compiler and supporting libraries.
I have a preference for GCC, and I'm not sure if you can run GCC on Windows
without Cygwin.

I may (or may not) look into this further, in a few weeks time.


On Sun, Feb 3, 2019 at 2:27 AM Barry Rowlingson <
b.rowlingson at lancaster.ac.uk> wrote:

> I don't think anyone denies that you *could* make an EXE to do all
> that. The discussion is on *how easy* it should be to create a single
> file that contains an initial "main" function plus a set of bundled
> code (potentially as a package) and which when run will install its
> package code (which is contained in itself, its not in a repo),
> install dependencies, and run the main() function.
>
> Now, I could build a self-executable shar file that bundled a package
> together with a script to do all the above. But if there was a "RUN"
> command in R, and a convention that a function called "foo::main"
> would be run by `R CMD RUN foo_1.1.1.tar.gz` then it would be so much
> easier to develop and test.
>
> If people think this adds value, then if they want to offer that value
> to me as $ or ?, I'd consider writing it if their total value was more
> than my cost....
>
> Barry
>


___________________________________________
> > R-devel at r-project.org mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-devel
>

	[[alternative HTML version deleted]]



[Rd] Runnable R packages
Abs Spurdle