Build packages #2865
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
workflow_dispatch: | |
inputs: | |
name: | |
description: "who is responsible for this" | |
required: true | |
default: 'Carpenter' | |
schedule: | |
- cron: "5 */12 * * *" | |
push: | |
path: | |
packages.txt | |
.github/workflows/render-pkgs.yaml | |
name: Build packages | |
jobs: | |
render: | |
name: Build packages on Ubuntu | |
runs-on: ubuntu-latest | |
env: | |
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: r-lib/actions/setup-r@v2 | |
- uses: r-lib/actions/setup-pandoc@v2 | |
- name: Install remotes | |
run: Rscript -e "install.packages('remotes')" | |
- name: Install drat.builder | |
run: Rscript -e "remotes::install_github('richfitz/drat.builder')" | |
- name: Update DRAT | |
run: | | |
git config --global user.name "[drat bot]" | |
Rscript -e "drat.builder::build()" | |
- name: Push results | |
run: | | |
git push https://${{github.actor}}:${{secrets.GITHUB_TOKEN}}@github.com/${{github.repository}}.git HEAD:${{ github.ref }} || echo "No changes to commit" |