Skip to content

Commit

Permalink
Add validation
Browse files Browse the repository at this point in the history
  • Loading branch information
epijim authored Oct 15, 2021
1 parent b67049f commit 20fed60
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/validation-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
---
name: R Package Validation report

on: # Run this action when a release is published
release:
types: [published]

jobs:
r-pkg-validation:
name: Create report 📃
runs-on: ubuntu-latest
# Set Github token permissions
permissions:
contents: write
packages: write
deployments: write
steps:
- name: Checkout repo 🛎
uses: actions/checkout@v2

- name: Build report 🏗
uses: insightsengineering/thevalidatoR@main
with:
# R package root path, in case your R package is within a subdirectory of the repo
report_pkg_dir: "."
# Template location
report_template_path: ".github/validation_template.rmd"
# Report format - provided to `rmarkdown::render` `output_format`
report_rmarkdown_format: "pdf_document"

# Upload the validation report to the release
- name: Upload report to release 🔼
if: success()
uses: svenstaro/upload-release-action@v2
with:
file: ./validation-report.pdf
asset_name: validation-report.pdf
repo_token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ github.ref }}
overwrite: false

0 comments on commit 20fed60

Please sign in to comment.