Skip to content

Commit

Permalink
testing render of readme
Browse files Browse the repository at this point in the history
  • Loading branch information
RasmusSkytte committed Nov 14, 2023
1 parent 9626b40 commit 2db8c1c
Show file tree
Hide file tree
Showing 12 changed files with 67 additions and 154 deletions.
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
^test\.Rproj$
^\.Rproj\.user$
^README\.Rmd$
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ on:
types: [published]
workflow_dispatch:

name: Run all AEF-DDF workflows

jobs:
all-aef-ddf-workflows:
name: ⚙️ Run all AEF-DDF workflows
Expand Down
9 changes: 9 additions & 0 deletions .github/workflows/call_render-readme.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
on:
push:
paths:
- README.md
- README.Rmd

jobs:
render:
uses: ./.github/workflows/render-readme.yaml
21 changes: 21 additions & 0 deletions .github/workflows/render-readme.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
on:
workflow_call:

jobs:
render:
name: 📖 Render README
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: r-lib/actions/setup-r@v2
- uses: r-lib/actions/setup-pandoc@v2
- name: Install rmarkdown
run: Rscript -e 'install.packages("rmarkdown")'
- name: Render README
run: Rscript -e 'rmarkdown::render("README.Rmd")'
- name: Commit results
run: |
git config --local user.name "$GITHUB_ACTOR"
git config --local user.email "[email protected]"
git commit README.md -m 'Re-build README.Rmd' || echo "No changes to commit"
git push origin || echo "No changes to commit"
7 changes: 6 additions & 1 deletion .github/workflows/workflow_dispatcher.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
jobs:
required: false
type: string
default: document-lint-pkgdown
default: document-lint-pkgdown-readme
event_name:
required: true
type: string
Expand All @@ -29,4 +29,9 @@ jobs:
with:
event_name: ${{ inputs.event_name }}
run_id: ${{ inputs.run_id }}
secrets: inherit

readme:
if: ${{ contains(inputs.jobs, 'readme') }}
uses: ./.github/workflows/render-readme.yaml
secrets: inherit
30 changes: 30 additions & 0 deletions README.Rmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
output: github_document
---

<!-- README.md is generated from README.Rmd. Please edit that file -->

```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```

# test

<!-- badges: start -->
<!-- badges: end -->

The goal of test is to ...

## Installation

You can install the development version of test from [GitHub](https://github.com/) with:

``` r
# install.packages("devtools")
devtools::install_github("ssi-dk/AEF-DDF")
```
File renamed without changes.
File renamed without changes.
File renamed without changes.
40 changes: 0 additions & 40 deletions reusable/document.yaml

This file was deleted.

28 changes: 0 additions & 28 deletions reusable/lint.yaml

This file was deleted.

83 changes: 0 additions & 83 deletions reusable/pkgdown.yaml

This file was deleted.

0 comments on commit 2db8c1c

Please sign in to comment.