-
Notifications
You must be signed in to change notification settings - Fork 5.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add R starter workflow #166
Conversation
This adds a workflow for [R packages](https://www.r-project.org/). It uses a [setup-r](https://github.com/r-lib/actions/tree/master/setup-r) action and two R packages - [remotes](https://remotes.r-lib.org/) - to install the R package dependencies - [rcmdcheck](https://github.com/r-lib/rcmdcheck) - to run and format the output of the package checking tool used in the R ecosystem.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @jimhester. Unfortunately as mentioned in the contributing guidelines we can't accept starter workflows that use Actions outside of the actions
org and this uses rlib/actions/setup-r
.
Your next question then is probably "how can we get R added to the actions" and I'm not sure on the answer to that right now.
So sorry, there might be some work to figure out what to do with this workflow. Thank you 🙇 for your contribution and we'll try and get there.
Yes, I figured as much, in the meantime I will point the R community to my collection of actions in the If not I think that is OK as well. |
@chrispat great chatting with you today at GitHub Universe. Looking forward to seeing if we can find an owner for R within GitHub so we can move this forward. |
👋 Hi @jimhester - sorry about the delay here. We've changed the requirements a bit here, and we're now able to support starter workflow templates that use third-party actions. In particular:
In addition - we've updated the checkout action since you created this PR. Could you update it to Finally, we've changed the triggers that we use by default for CI templates. Could you update the triggers to be:
Thanks so much! |
@ethomson I tweaked the workflow as suggested, adding the comment, changing the triggers, pinning the commit for the setup-r action and bumping the checkout version to v2. I also added a link in the comment to where users can find more workflow examples for R packages, hope that is OK. Let me know if there is anything else you might need, thanks for circling back to this! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could I check what license the R logo is under please? This repo is under an MIT License https://github.com/actions/starter-workflows/blob/main/LICENSE. The website https://www.r-project.org/Licenses/ didn't mention anything about the logo and we want to make sure that's all cool.
|
||
jobs: | ||
build: | ||
runs-on: macOS-latest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm curious that its running macOS-latest
, could this run on ubuntu-latest
instead? The cost for a user of running on MacOS is significantly higher than running on Ubuntu, so we'd like to default to that if we can to prevent any surprises.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It could use ubuntu-latest.
The main advantage to using macOS for R is CRAN provides pre-compiled binaries for R packages on macOS, something they do not do for linux. So building dependencies will take more time.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The RStudio Package Manager does provide R package binaries on linux, and we have example workflows which use that, e.g. (https://github.com/r-lib/actions/blob/master/examples/check-standard.yaml#L25-L30).
However I was trying to keep this workflow as basic as we could.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, if this is the simplest way to go, let's do that. Thanks!
Co-authored-by: Andy McKay <andymckay@github.com>
The logo is under CC-BY-SA 4.0 (https://www.r-project.org/logo/) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made a quick change to fix the case sensitivity of the icon.
@jimhester 🙇🏾 thank you so much for this and your patience. |
This adds a workflow for R packages. It uses a setup-r action and two R packages
Contributing checklist
Thank you for sending in this pull request. Please make sure you take a look at the [contributing file](CONTRIBUTING.md). Here's a few things for you to consider in this pull request:In the workflow and properties files:
ci/properties/*.properties.json
file.push
.release
withtypes: [created]
.Some general notes:
actions
organization.The action used (
setup-r
) is not currently part of theactions
organization. I have written a few actions often needed for R packages at https://github.com/r-lib/actions/, which is where thissetup-r
action currently lives.I also added a svg of the R logo, but did not try to resize it to correspond with the existing logo sizes.