generated from kstreet13/assignment
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 3fe9bb2
Showing
4 changed files
with
122 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
on: push | ||
name: Check Render | ||
jobs: | ||
check-renders: | ||
runs-on: ubuntu-latest | ||
container: | ||
image: ghcr.io/sta523-fa22/sta523-base:latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: Install Missing Packages | ||
run: | | ||
missing = checklist::missing_pkgs(dir = "./", glob = "submit.qmd") | ||
if(length(missing)){ | ||
install.packages("pak") | ||
pak::pkg_install(missing, dependencies = TRUE) | ||
} | ||
shell: Rscript {0} | ||
- name: Check Renders | ||
run: | | ||
checklist::check_qmd_renders("submit.qmd") | ||
shell: Rscript {0} | ||
- name: Create artifacts | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: submit-html | ||
path: submit.html |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
# History files | ||
.Rhistory | ||
.Rapp.history | ||
|
||
# Session Data files | ||
.RData | ||
.RDataTmp | ||
|
||
# User-specific files | ||
.Ruserdata | ||
|
||
# Example code in package build process | ||
*-Ex.R | ||
|
||
# Output files from R CMD build | ||
/*.tar.gz | ||
|
||
# Output files from R CMD check | ||
/*.Rcheck/ | ||
|
||
# RStudio files | ||
.Rproj.user/ | ||
|
||
# produced vignettes | ||
vignettes/*.html | ||
vignettes/*.pdf | ||
|
||
# OAuth2 token, see https://github.com/hadley/httr/releases/tag/v0.3 | ||
.httr-oauth | ||
|
||
# knitr and R markdown default cache directories | ||
*_cache/ | ||
/cache/ | ||
|
||
# Temporary files created by R markdown | ||
*.utf8.md | ||
*.knit.md | ||
|
||
# R Environment Variables | ||
.Renviron | ||
|
||
# pkgdown site | ||
docs/ | ||
|
||
# translation temp files | ||
po/*~ | ||
|
||
# RStudio Connect folder | ||
rsconnect/ | ||
|
||
data/ | ||
|
||
# Mac artifacts | ||
**/.DS_Store | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# Example Assignment | ||
|
||
This repository includes a GitHub Actions workflow that will automatically look for a file named `submit.qmd` and render it to an HTML document. You can include as many other files as you want, but only `submit.qmd` will trigger the workflow. | ||
|
||
When the workflow runs successfully, you can view the final HTML product by going to the "Actions" tab, clicking on the most recent run, and downloading the `submit-html` file under "Artifacts." | ||
|
||
If you want to track whether or not your assignment has rendered successfully, add the below line of code to the `README.md` file. Just change the URL to include your GitHub username and the name of your repository: | ||
|
||
```md | ||
![status](https://github.com/<USERNAME>/<REPOSITORY>/actions/workflows/render.yml/badge.svg) | ||
``` | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
--- | ||
title: "" | ||
author: "" | ||
format: | ||
html: | ||
embed-resources: true | ||
--- | ||
|
||
## Quarto | ||
|
||
Quarto enables you to weave together content and executable code into a finished document. To learn more about Quarto see <https://quarto.org>. | ||
|
||
## Running Code | ||
|
||
When you click the **Render** button a document will be generated that includes both content and the output of embedded code. You can embed code like this: | ||
|
||
```{r} | ||
1 + 1 | ||
``` | ||
|
||
You can add options to executable code like this | ||
|
||
```{r} | ||
#| echo: false | ||
2 * 2 | ||
``` | ||
|
||
The `echo: false` option disables the printing of code (only output is displayed). |